git.y1.nz

gbdk-2020

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

commit ee1401cd41e307db278f253118a80c6c852642fa
parent fcc92604afa5f9972490a69c37997405ce671f0c
Author: bbbbbr <reg+github@roughhousing.com>
Date:   Sun, 19 Sep 2021 00:36:24 -0700

Merge pull request #265 from bbbbbr/docs_4_0_5

Docs: toolchain notes updates for 4.0.5
Diffstat:
MMakefile16++++++++++++++--
Mdocs/pages/06b_supported_consoles.md14+++++++++++++-
Mdocs/pages/20_toolchain_settings.md80+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 107 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile @@ -336,25 +336,37 @@ ifneq (,$(wildcard $(BUILDDIR)/bin/)) echo \# sdcc settings >> $(TOOLCHAIN_DOCS_FILE); echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); $(BUILDDIR)/bin/sdcc -h >> $(TOOLCHAIN_DOCS_FILE) 2>&1 + echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); # sdasgb - echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); echo \@anchor sdasgb-settings >> $(TOOLCHAIN_DOCS_FILE); echo \# sdasgb settings >> $(TOOLCHAIN_DOCS_FILE); echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); $(BUILDDIR)/bin/sdasgb -h >> $(TOOLCHAIN_DOCS_FILE) 2>&1 || true echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); +# sdasz80 + echo \@anchor sdasz80-settings >> $(TOOLCHAIN_DOCS_FILE); + echo \# sdasz80 settings >> $(TOOLCHAIN_DOCS_FILE); + echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); + $(BUILDDIR)/bin/sdasgb -h >> $(TOOLCHAIN_DOCS_FILE) 2>&1 || true + echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); # bankpack echo \@anchor bankpack-settings >> $(TOOLCHAIN_DOCS_FILE); echo \# bankpack settings >> $(TOOLCHAIN_DOCS_FILE); echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); $(BUILDDIR)/bin/bankpack -h >> $(TOOLCHAIN_DOCS_FILE) 2>&1 || true echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); -# sdldgb +# sdldgb echo \@anchor sdldgb-settings >> $(TOOLCHAIN_DOCS_FILE); echo \# sdldgb settings >> $(TOOLCHAIN_DOCS_FILE); echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); $(BUILDDIR)/bin/sdldgb >> $(TOOLCHAIN_DOCS_FILE) 2>&1 || true echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); +# sdldz80 + echo \@anchor sdldz80-settings >> $(TOOLCHAIN_DOCS_FILE); + echo \# sdldz80 settings >> $(TOOLCHAIN_DOCS_FILE); + echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); + $(BUILDDIR)/bin/sdldgb >> $(TOOLCHAIN_DOCS_FILE) 2>&1 || true + echo \`\`\` >> $(TOOLCHAIN_DOCS_FILE); # ihxcheck echo \@anchor ihxcheck-settings >> $(TOOLCHAIN_DOCS_FILE); echo \# ihxcheck settings >> $(TOOLCHAIN_DOCS_FILE); diff --git a/docs/pages/06b_supported_consoles.md b/docs/pages/06b_supported_consoles.md @@ -20,7 +20,19 @@ When compiling and building through @ref lcc use the `-m<port>:<plat>` flag to s ## sdcc -When compiling directly with @ref sdcc use: `-m<port>`, `-D__PORT_<port>` and `-D__TARGET_<plat> ` +When building directly with the sdcc toolchain, the following must be specified manually +(when using @ref lcc it will populate these automatically based on `-m<port>:<plat>`). + +When compiling with @ref sdcc-settings "sdcc": + - `-m<port>`, `-D__PORT_<port>` and `-D__TARGET_<plat> ` + +When assembling with @ref sdasgb-settings "sdasgb" (for GB/AP) and @ref sdasz80-settings "sdasz80" (for SMS/GG): + - Select the appropriate include path: `-I<gbdk-path>lib/small/asxxxx/<plat>` + +When linking with @ref sdldgb-settings "sdldgb" (for GB/AP) and @ref sdldz80-settings "sdldz80" (for SMS/GG): + - Select the appropriate include paths: `-k <gbdk-path>lib/small/asxxxx/<port>`, `-k <gbdk-path>lib/small/asxxxx/<plat>` + - Include the appropriate library files `-l <port>.lib`, `-l <plat>.lib` + - The crt will be under ` <gbdk-path>lib/small/asxxxx/<plat>/crt0.o` ## Console Port and Platform Settings diff --git a/docs/pages/20_toolchain_settings.md b/docs/pages/20_toolchain_settings.md @@ -155,6 +155,8 @@ Linker options: Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) + -bo <num> use code bank <num> + -ba <num> use data bank <num> --asm= Define assembler name (rgbds/asxxxx/isas/z80asm/gas) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment @@ -216,6 +218,44 @@ Usage: [-Options] outfile file1 [file2 file3 ...] removing ``` +@anchor sdasz80-settings +# sdasz80 settings +``` + +sdas Assembler V02.00 + NoICE + SDCC mods (GameBoy Z80-like CPU) + + +Copyright (C) 2012 Alan R. Baldwin +This program comes with ABSOLUTELY NO WARRANTY. + +Usage: [-Options] file +Usage: [-Options] outfile file1 [file2 file3 ...] + -d Decimal listing + -q Octal listing + -x Hex listing (default) + -g Undefined symbols made global + -n Don't resolve global assigned value symbols + -a All user symbols made global + -b Display .define substitutions in listing + -bb and display without .define substitutions + -c Disable instruction cycle count in listing + -j Enable NoICE Debug Symbols + -y Enable SDCC Debug Symbols + -l Create list file/outfile[.lst] + -o Create object file/outfile[.rel] + -s Create symbol file/outfile[.sym] + -p Disable automatic listing pagination + -u Disable .list/.nlist processing + -w Wide listing format for symbol table + -z Disable case sensitivity for symbols + -f Flag relocatable references by ` in listing file + -ff Flag relocatable references by mode in listing file + -I Add the named directory to the include file + search path. This option may be used more than once. + Directories are searched in the order given. + +removing +``` @anchor bankpack-settings # bankpack settings ``` @@ -294,6 +334,46 @@ End: -e or null line terminates input ``` +@anchor sdldz80-settings +# sdldz80 settings +``` + +sdld Linker V03.00 + NoICE + sdld + +Usage: [-Options] [-Option with arg] file +Usage: [-Options] [-Option with arg] outfile file1 [file2 ...] +Startup: + -p Echo commands to stdout (default) + -n No echo of commands to stdout +Alternates to Command Line Input: + -c ASlink >> prompt input + -f file[.lk] Command File input +Libraries: + -k Library path specification, one per -k + -l Library file specification, one per -l +Relocation: + -b area base address = expression + -g global symbol = expression + -a (platform) Select platform specific virtual address translation +Map format: + -m Map output generated as (out)file[.map] + -w Wide listing format for map file + -x Hexadecimal (default) + -d Decimal + -q Octal +Output: + -i Intel Hex as (out)file[.ihx] + -s Motorola S Record as (out)file[.s19] + -j NoICE Debug output as (out)file[.noi] + -y SDCDB Debug output as (out)file[.cdb] +List: + -u Update listing file(s) with link data as file(s)[.rst] +Case Sensitivity: + -z Disable Case Sensitivity for Symbols +End: + -e or null line terminates input + +``` @anchor ihxcheck-settings # ihxcheck settings ```

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