Skip to content

Commit c6152ff

Browse files
allow in-tree builds by default
1 parent 19517c2 commit c6152ff

File tree

4 files changed

+7
-9
lines changed

4 files changed

+7
-9
lines changed

.github/workflows/branch.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ jobs:
133133
- name: Install Toolchain
134134
env:
135135
PREFIX: ${{github.workspace}}
136-
run: make -j4 -C ${{env.TOOLCHAIN_PATH}} install V=1
136+
run: make -j4 -C ${{env.TOOLCHAIN_PATH}} install V=1 DESTDIR=${{github.workspace}}/
137137

138138
- name: Make Binaries Executable
139139
if: runner.os != 'Windows'

.github/workflows/make.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ jobs:
135135
- name: Install Toolchain
136136
env:
137137
PREFIX: ${{github.workspace}}
138-
run: make -j4 -C ${{env.TOOLCHAIN_PATH}} install V=1
138+
run: make -j4 -C ${{env.TOOLCHAIN_PATH}} install V=1 DESTDIR=${{github.workspace}}/
139139

140140
- name: Make Binaries Executable
141141
if: runner.os != 'Windows'

makefile

+3
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@
1414
# along with this program; if not, write to the Free Software Foundation,
1515
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1616

17+
DESTDIR = $(CURDIR)/
18+
PREFIX = CEdev
19+
1720
include $(CURDIR)/src/common.mk
1821

1922
LIBS := libload graphx fontlibc keypadc fileioc usbdrvce srldrvce msddrvce fatdrvce

src/common.mk

+2-7
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616

1717
GIT_SHA = $(shell git describe --abbrev=8 --dirty --always --tags)
1818

19-
CEDEV_DIR := CEdev
2019
CEDEV_VERSION := $(GIT_SHA)
2120

2221
LINUX := 0
@@ -51,8 +50,6 @@ REMOVE ?= ( del /f /q $1 2>nul || call )
5150
RMDIR ?= ( rmdir /s /q $1 2>nul || call )
5251
COPY ?= ( for %%a in ($(subst $(space),$(comma) ,$1)) do xcopy %%a $2 /Q /Y /I /K 1>nul 2>nul || call )
5352
COPYDIR ?= ( xcopy $1 $2 /S /Q /Y /I /K 1>nul 2>nul || call )
54-
DESTDIR ?=
55-
PREFIX ?= C:
5653
QUOTE_ARG ?= "$(subst ",',$1)"#'
5754
APPEND ?= $(Q)echo.$(subst ",^",$(subst \,^\,$(subst &,^&,$(subst |,^|,$(subst >,^>,$(subst <,^<,$(subst ^,^^,$1))))))) >>$@
5855
RELEASE_NAME = windows
@@ -67,8 +64,6 @@ REMOVE ?= rm -f $1
6764
RMDIR ?= rm -rf $1
6865
COPY ?= cp $1 $2
6966
COPYDIR ?= cp -r $1 $2
70-
DESTDIR ?=
71-
PREFIX ?= $(HOME)
7267
QUOTE_ARG ?= '$(subst ','\'',$1)'#'
7368
APPEND ?= $(Q)echo $(call QUOTE_ARG,$1) >>$@
7469
ifeq ($(shell uname -s),Darwin)
@@ -80,8 +75,8 @@ RELEASE_NAME = linux
8075
endif
8176
endif
8277

83-
INSTALL_PATH := $(call QUOTE_ARG,$(call NATIVEPATH,$(DESTDIR)$(PREFIX)))
84-
INSTALL_DIR := $(DESTDIR)$(PREFIX)/$(CEDEV_DIR)
78+
INSTALL_DIR := $(DESTDIR)$(PREFIX)
79+
INSTALL_PATH := $(call QUOTE_ARG,$(call NATIVEPATH,$(INSTALL_DIR)))
8580
INSTALL_EXAMPLES := $(call QUOTE_ARG,$(call NATIVEPATH,$(INSTALL_DIR)/examples))
8681
INSTALL_LIB := $(call QUOTE_ARG,$(call NATIVEPATH,$(INSTALL_DIR)/lib/libload))
8782
INSTALL_CRT := $(call QUOTE_ARG,$(call NATIVEPATH,$(INSTALL_DIR)/lib/crt))

0 commit comments

Comments
 (0)