git.y1.nz

gbdk-2020

GameBoy Development Kit
download: https://git.y1.nz/archives/gbdk.tar.gz
README | Files | Log | Refs | LICENSE

commit bcd716617e8edf64282e6494e601e3cbeb897b34
parent 028f638eb0f1f2605029c6d964befe3d19223258
Author: bbbbbr <bbbbbr@users.noreply.github.com>
Date:   Thu, 18 Jan 2024 19:56:33 -0800

Merge pull request #615 from bbbbbr/examples/gbdk_home_override

Examples: allow environment var to override GBDK_HOME in Makefiles
Diffstat:
Mgbdk-lib/examples/cross-platform/banks/Makefile5++++-
Mgbdk-lib/examples/cross-platform/banks_autobank/Makefile5++++-
Mgbdk-lib/examples/cross-platform/banks_farptr/Makefile5++++-
Mgbdk-lib/examples/cross-platform/banks_nonintrinsic/Makefile5++++-
Mgbdk-lib/examples/cross-platform/emu_debug/Makefile5++++-
Mgbdk-lib/examples/cross-platform/fonts/Makefile5++++-
Mgbdk-lib/examples/cross-platform/gbdecompress/Makefile5++++-
Mgbdk-lib/examples/cross-platform/incbin/Makefile5++++-
Mgbdk-lib/examples/cross-platform/large_map/Makefile5++++-
Mgbdk-lib/examples/cross-platform/libc_memcpy/Makefile5++++-
Mgbdk-lib/examples/cross-platform/libc_string/Makefile5++++-
Mgbdk-lib/examples/cross-platform/logo/Makefile5++++-
Mgbdk-lib/examples/cross-platform/metasprites/Makefile5++++-
Mgbdk-lib/examples/cross-platform/multiplayer/Makefile5++++-
Mgbdk-lib/examples/cross-platform/pong/Makefile5++++-
Mgbdk-lib/examples/cross-platform/randtest/Makefile5++++-
Mgbdk-lib/examples/cross-platform/rle_map/Makefile5++++-
Mgbdk-lib/examples/cross-platform/scroller/Makefile5++++-
Mgbdk-lib/examples/cross-platform/simple_physics/Makefile5++++-
Mgbdk-lib/examples/gb/apa_image/Makefile4+++-
Mgbdk-lib/examples/gb/bcd/Makefile8+++++++-
Mgbdk-lib/examples/gb/colorbar/Makefile8+++++++-
Mgbdk-lib/examples/gb/comm/Makefile8+++++++-
Mgbdk-lib/examples/gb/crash/Makefile8+++++++-
Mgbdk-lib/examples/gb/dscan/Makefile7++++++-
Mgbdk-lib/examples/gb/filltest/Makefile8+++++++-
Mgbdk-lib/examples/gb/galaxy/Makefile8+++++++-
Mgbdk-lib/examples/gb/gb-dtmf/Makefile8+++++++-
Mgbdk-lib/examples/gb/gbtype/Makefile4+++-
Mgbdk-lib/examples/gb/hblank_copy/Makefile4+++-
Mgbdk-lib/examples/gb/hicolor/Makefile2+-
Mgbdk-lib/examples/gb/irq/Makefile8+++++++-
Mgbdk-lib/examples/gb/isr_vector/Makefile7++++++-
Mgbdk-lib/examples/gb/lcd_isr_wobble/Makefile8+++++++-
Mgbdk-lib/examples/gb/linkerfile/Makefile4+++-
Mgbdk-lib/examples/gb/paint/Makefile7++++++-
Mgbdk-lib/examples/gb/ram_function/Makefile8+++++++-
Mgbdk-lib/examples/gb/rpn/Makefile8+++++++-
Mgbdk-lib/examples/gb/sgb_border/Makefile10++++++++--
Mgbdk-lib/examples/gb/sgb_pong/Makefile8+++++++-
Mgbdk-lib/examples/gb/sgb_sfx/Makefile8+++++++-
Mgbdk-lib/examples/gb/sound/Makefile8+++++++-
Mgbdk-lib/examples/gb/space/Makefile8++++++--
Mgbdk-lib/examples/gb/template_minimal/Makefile4+++-
Mgbdk-lib/examples/gb/template_subfolders/Makefile4+++-
Mgbdk-lib/examples/gb/wav_sample/Makefile4+++-
Mgbdk-lib/examples/msxdos/hello/Makefile8+++++++-
Mgbdk-lib/examples/msxdos/smoke/Makefile8+++++++-
Mgbdk-lib/examples/msxdos/test/Makefile8+++++++-
Mgbdk-lib/examples/nes/smoke/Makefile8+++++++-
Mgbdk-lib/examples/nes/snes_joypads/Makefile8+++++++-
Mgbdk-lib/examples/sms/wav_sample/Makefile4+++-
52 files changed, 266 insertions(+), 54 deletions(-)

diff --git a/gbdk-lib/examples/cross-platform/banks/Makefile b/gbdk-lib/examples/cross-platform/banks/Makefile @@ -2,7 +2,10 @@ SHELL := /bin/bash # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/banks_autobank/Makefile b/gbdk-lib/examples/cross-platform/banks_autobank/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/banks_farptr/Makefile b/gbdk-lib/examples/cross-platform/banks_farptr/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/banks_nonintrinsic/Makefile b/gbdk-lib/examples/cross-platform/banks_nonintrinsic/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/emu_debug/Makefile b/gbdk-lib/examples/cross-platform/emu_debug/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/fonts/Makefile b/gbdk-lib/examples/cross-platform/fonts/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/gbdecompress/Makefile b/gbdk-lib/examples/cross-platform/gbdecompress/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)/bin/png2asset diff --git a/gbdk-lib/examples/cross-platform/incbin/Makefile b/gbdk-lib/examples/cross-platform/incbin/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/large_map/Makefile b/gbdk-lib/examples/cross-platform/large_map/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)/bin/png2asset diff --git a/gbdk-lib/examples/cross-platform/libc_memcpy/Makefile b/gbdk-lib/examples/cross-platform/libc_memcpy/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/libc_string/Makefile b/gbdk-lib/examples/cross-platform/libc_string/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/logo/Makefile b/gbdk-lib/examples/cross-platform/logo/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc PNG2ASSETS = $(GBDK_HOME)bin/png2asset diff --git a/gbdk-lib/examples/cross-platform/metasprites/Makefile b/gbdk-lib/examples/cross-platform/metasprites/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)/bin/png2asset diff --git a/gbdk-lib/examples/cross-platform/multiplayer/Makefile b/gbdk-lib/examples/cross-platform/multiplayer/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/pong/Makefile b/gbdk-lib/examples/cross-platform/pong/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/randtest/Makefile b/gbdk-lib/examples/cross-platform/randtest/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/rle_map/Makefile b/gbdk-lib/examples/cross-platform/rle_map/Makefile @@ -2,7 +2,10 @@ SHELL := /bin/bash # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/scroller/Makefile b/gbdk-lib/examples/cross-platform/scroller/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc # Set platforms to build here, spaced separated. (These are in the separate Makefile.targets) diff --git a/gbdk-lib/examples/cross-platform/simple_physics/Makefile b/gbdk-lib/examples/cross-platform/simple_physics/Makefile @@ -1,6 +1,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)/bin/png2asset diff --git a/gbdk-lib/examples/gb/apa_image/Makefile b/gbdk-lib/examples/gb/apa_image/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)bin/png2asset diff --git a/gbdk-lib/examples/gb/bcd/Makefile b/gbdk-lib/examples/gb/bcd/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = bcd.gb diff --git a/gbdk-lib/examples/gb/colorbar/Makefile b/gbdk-lib/examples/gb/colorbar/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m # GBDK_DEBUG = ON ifdef GBDK_DEBUG diff --git a/gbdk-lib/examples/gb/comm/Makefile b/gbdk-lib/examples/gb/comm/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = comm.gb diff --git a/gbdk-lib/examples/gb/crash/Makefile b/gbdk-lib/examples/gb/crash/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = crash.gb diff --git a/gbdk-lib/examples/gb/dscan/Makefile b/gbdk-lib/examples/gb/dscan/Makefile @@ -1,4 +1,9 @@ -LCC = ../../../bin/lcc -Wm-yc +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif +LCC = $(GBDK_HOME)bin/lcc -Wm-yc BINS = dscan.gb diff --git a/gbdk-lib/examples/gb/filltest/Makefile b/gbdk-lib/examples/gb/filltest/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = filltest.gb diff --git a/gbdk-lib/examples/gb/galaxy/Makefile b/gbdk-lib/examples/gb/galaxy/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = galaxy.gb diff --git a/gbdk-lib/examples/gb/gb-dtmf/Makefile b/gbdk-lib/examples/gb/gb-dtmf/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m BINS = gb-dtmf.gb diff --git a/gbdk-lib/examples/gb/gbtype/Makefile b/gbdk-lib/examples/gb/gbtype/Makefile @@ -4,7 +4,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/gb/hblank_copy/Makefile b/gbdk-lib/examples/gb/hblank_copy/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc PNG2ASSET = $(GBDK_HOME)bin/png2asset diff --git a/gbdk-lib/examples/gb/hicolor/Makefile b/gbdk-lib/examples/gb/hicolor/Makefile @@ -1,7 +1,7 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" ifndef GBDK_HOME -GBDK_HOME = ../../../ + GBDK_HOME = ../../../ endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/gb/irq/Makefile b/gbdk-lib/examples/gb/irq/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = irq.gb diff --git a/gbdk-lib/examples/gb/isr_vector/Makefile b/gbdk-lib/examples/gb/isr_vector/Makefile @@ -1,4 +1,9 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j -Wm-yS +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j -Wm-yS BINS = lcd_isr_wobble.gb diff --git a/gbdk-lib/examples/gb/lcd_isr_wobble/Makefile b/gbdk-lib/examples/gb/lcd_isr_wobble/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wl-j -Wm-yS +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wl-j -Wm-yS BINS = lcd_isr_wobble.gb diff --git a/gbdk-lib/examples/gb/linkerfile/Makefile b/gbdk-lib/examples/gb/linkerfile/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/gb/paint/Makefile b/gbdk-lib/examples/gb/paint/Makefile @@ -1,4 +1,9 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = paint.gb diff --git a/gbdk-lib/examples/gb/ram_function/Makefile b/gbdk-lib/examples/gb/ram_function/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = ram_fn.gb diff --git a/gbdk-lib/examples/gb/rpn/Makefile b/gbdk-lib/examples/gb/rpn/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = rpn.gb diff --git a/gbdk-lib/examples/gb/sgb_border/Makefile b/gbdk-lib/examples/gb/sgb_border/Makefile @@ -1,5 +1,11 @@ -LCC = ../../../bin/lcc -PNG2ASSET = ../../../bin/png2asset +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc +PNG2ASSET = $(GBDK_HOME)bin/png2asset # GBDK_DEBUG = ON ifdef GBDK_DEBUG diff --git a/gbdk-lib/examples/gb/sgb_pong/Makefile b/gbdk-lib/examples/gb/sgb_pong/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j -Wm-ys +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j -Wm-ys BINS = sgb_pong.gb diff --git a/gbdk-lib/examples/gb/sgb_sfx/Makefile b/gbdk-lib/examples/gb/sgb_sfx/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc # GBDK_DEBUG = ON ifdef GBDK_DEBUG diff --git a/gbdk-lib/examples/gb/sound/Makefile b/gbdk-lib/examples/gb/sound/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -Wa-l -Wl-m -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wa-l -Wl-m -Wl-j BINS = sound.gb sound.duck # BINS = sound.gb sound.duck sound.pocket diff --git a/gbdk-lib/examples/gb/space/Makefile b/gbdk-lib/examples/gb/space/Makefile @@ -1,5 +1,9 @@ -GBDK = ../../.. -LCC = $(GBDK)/bin/lcc -Wl-m -Wl-w -Wl-j -Wm-yS + +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -Wl-m -Wl-w -Wl-j -Wm-yS BINS = space.gb diff --git a/gbdk-lib/examples/gb/template_minimal/Makefile b/gbdk-lib/examples/gb/template_minimal/Makefile @@ -4,7 +4,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/gb/template_subfolders/Makefile b/gbdk-lib/examples/gb/template_subfolders/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/gb/wav_sample/Makefile b/gbdk-lib/examples/gb/wav_sample/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc diff --git a/gbdk-lib/examples/msxdos/hello/Makefile b/gbdk-lib/examples/msxdos/hello/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -v -mz80:msxdos -Wm-yoA -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -v -mz80:msxdos -Wm-yoA -Wl-j BINS = test.com diff --git a/gbdk-lib/examples/msxdos/smoke/Makefile b/gbdk-lib/examples/msxdos/smoke/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -mz80:msxdos -Wm-yoA -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -mz80:msxdos -Wm-yoA -Wl-j BINS = smoketest.com diff --git a/gbdk-lib/examples/msxdos/test/Makefile b/gbdk-lib/examples/msxdos/test/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -mz80:msxdos -Wm-yoA -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -mz80:msxdos -Wm-yoA -Wl-j BINS = test.com diff --git a/gbdk-lib/examples/nes/smoke/Makefile b/gbdk-lib/examples/nes/smoke/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -mmos6502:nes -Wm-yoA -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -mmos6502:nes -Wm-yoA -Wl-j BINS = smoketest.nes diff --git a/gbdk-lib/examples/nes/snes_joypads/Makefile b/gbdk-lib/examples/nes/snes_joypads/Makefile @@ -1,4 +1,10 @@ -LCC = ../../../bin/lcc -mmos6502:nes -Wm-yoA -Wl-j +# If you move this project you can change the directory +# to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif + +LCC = $(GBDK_HOME)bin/lcc -mmos6502:nes -Wm-yoA -Wl-j BINS = snes_joypads.nes diff --git a/gbdk-lib/examples/sms/wav_sample/Makefile b/gbdk-lib/examples/sms/wav_sample/Makefile @@ -5,7 +5,9 @@ # If you move this project you can change the directory # to match your GBDK root directory (ex: GBDK_HOME = "C:/GBDK/" -GBDK_HOME = ../../../ +ifndef GBDK_HOME + GBDK_HOME = ../../../ +endif LCC = $(GBDK_HOME)bin/lcc

This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.