|
| 1 | +# RGBDS |
| 2 | + |
| 3 | +RGBDS (Rednex Game Boy Development System) is a free assembler/linker package |
| 4 | +for the Game Boy and Game Boy Color. It consists of: |
| 5 | + |
| 6 | +- rgbasm (assembler) |
| 7 | +- rgblink (linker) |
| 8 | +- rgbfix (checksum/header fixer) |
| 9 | +- rgbgfx (PNG‐to‐Game Boy graphics converter) |
| 10 | + |
| 11 | +This is a fork of the original RGBDS which aims to make the programs more like |
| 12 | +other UNIX tools. |
| 13 | + |
| 14 | +This toolchain is maintained [on GitHub](https://github.com/gbdev/rgbds). |
| 15 | + |
| 16 | +The documentation of this toolchain can be viewed online [here](https://rgbds.gbdev.io/docs/). |
| 17 | +It is generated from the man pages found in this repository. |
| 18 | +The source code of the website itself is on GitHub as well under the repo |
| 19 | +[rgbds-www](https://github.com/gbdev/rgbds-www). |
| 20 | + |
| 21 | +If you want to contribute or maintain RGBDS, and have questions regarding the code, its |
| 22 | +organisation, etc. you can find the maintainers [on the gbdev community channels](https://gbdev.io/chat) |
| 23 | +or via mail at `rgbds at gbdev dot io`. |
| 24 | + |
| 25 | +## 1. Installing RGBDS |
| 26 | + |
| 27 | +The [installation procedure](https://rgbds.gbdev.io/install) is available |
| 28 | +online for various platforms. [Building from source](https://rgbds.gbdev.io/install/source) |
| 29 | +is possible using `make` or `cmake`; follow the link for more detailed instructions. |
| 30 | + |
| 31 | +```sh |
| 32 | + make |
| 33 | + sudo make install |
| 34 | +``` |
| 35 | + |
| 36 | +```sh |
| 37 | + cmake -S . -B build -DCMAKE_BUILD_TYPE=Release |
| 38 | + cmake --build build |
| 39 | + cmake --install build |
| 40 | +``` |
| 41 | + |
| 42 | +## 2. RGBDS Folder Organization |
| 43 | + |
| 44 | +The RGBDS source code file structure is as follows: |
| 45 | + |
| 46 | +``` |
| 47 | + . |
| 48 | + ├── .github/ |
| 49 | + │ ├── scripts/ |
| 50 | + │ │ └── ... |
| 51 | + │ └── workflows/ |
| 52 | + │ └── ... |
| 53 | + ├── contrib/ |
| 54 | + │ ├── zsh_compl/ |
| 55 | + │ │ └── ... |
| 56 | + │ └── ... |
| 57 | + ├── include/ |
| 58 | + │ └── ... |
| 59 | + ├── man/ |
| 60 | + │ └── ... |
| 61 | + ├── src/ |
| 62 | + │ ├── asm/ |
| 63 | + │ │ └── ... |
| 64 | + │ ├── extern/ |
| 65 | + │ │ └── ... |
| 66 | + │ ├── fix/ |
| 67 | + │ │ └── ... |
| 68 | + │ ├── gfx/ |
| 69 | + │ │ └── ... |
| 70 | + │ ├── link/ |
| 71 | + │ │ └── ... |
| 72 | + │ ├── CMakeLists.txt |
| 73 | + │ └── ... |
| 74 | + ├── test/ |
| 75 | + │ ├── ... |
| 76 | + │ └── run-tests.sh |
| 77 | + ├── .clang-format |
| 78 | + ├── CMakeLists.txt |
| 79 | + ├── Dockerfile |
| 80 | + ├── Makefile |
| 81 | + └── README.md |
| 82 | +``` |
| 83 | + |
| 84 | +- `.github/` - files and scripts related to the integration of the RGBDS codebase with |
| 85 | + GitHub. |
| 86 | + * `scripts/` - scripts used by workflow files. |
| 87 | + * `workflows/` - CI workflow description files. |
| 88 | +- `contrib/` - scripts and other resources which may be useful to users and developers of |
| 89 | + RGBDS. |
| 90 | + * `zsh_compl` contains tab completion scripts for use with zsh. Put them somewhere in |
| 91 | + your `fpath`, and they should auto-load. |
| 92 | + * `bash_compl` contains tab completion scripts for use with bash. Run them with `source` |
| 93 | + somewhere in your `.bashrc`, and they should load every time you open a shell. |
| 94 | +- `include/` - header files for the respective source files in `src`. |
| 95 | +- `man/` - manual pages. |
| 96 | +- `src/` - source code of RGBDS. |
| 97 | + * Note that the code unique to each RGBDS tool is stored in its respective subdirectory |
| 98 | + (rgbasm's code is in `src/asm/`, for example). `src/extern/` contains code imported from |
| 99 | + external sources. |
| 100 | +- `test/` - testing framework used to verify that changes to the code don't break or |
| 101 | + modify the behavior of RGBDS. |
| 102 | +- `.clang-format` - code style for automated C++ formatting with |
| 103 | + [`clang-format`](https://clang.llvm.org/docs/ClangFormat.html). |
| 104 | +- `Dockerfile` - defines how to build RGBDS with Docker. |
| 105 | + |
| 106 | +## 3. History |
| 107 | + |
| 108 | +- 1996-10-01: Carsten Sørensen (a.k.a. SurfSmurf) releases |
| 109 | + [xAsm](http://otakunozoku.com/RGBDSdocs/asm.htm), |
| 110 | + [xLink](http://otakunozoku.com/RGBDSdocs/link.htm), and |
| 111 | + [RGBFix](http://otakunozoku.com/RGBDSdocs/fix.htm), |
| 112 | + a Game Boy SM83 (GBZ80) assembler/linker system for DOS/Win32. |
| 113 | +- 1997-07-03: Sørensen releases [ASMotor](http://otakunozoku.com/RGBDSdocs/geninfo.htm), |
| 114 | + packaging the three programs together and moving towards making them a |
| 115 | + general-purpose target-independent system. |
| 116 | +- 1999-08-01: Justin Lloyd (a.k.a. Otaku no Zoku) adapts ASMotor to re-focus |
| 117 | + on SM83 assembly/machine code, and releases this version as |
| 118 | + [RGBDS](http://otakunozoku.com/rednex-gameboy-development-system/). |
| 119 | +- 2009-06-11: Vegard Nossum adapts the code to be more UNIX-like and releases |
| 120 | + this version as [rgbds-linux](https://github.com/vegard/rgbds-linux). |
| 121 | +- 2010-01-12: Anthony J. Bentley [forks](https://github.com/bentley) Nossum's |
| 122 | + repository. The fork becomes the reference implementation of RGBDS. |
| 123 | +- 2015-01-18: stag019 begins implementing [rgbgfx](https://github.com/stag019/rgbgfx), |
| 124 | + a PNG‐to‐Game Boy graphics converter, for eventual integration into RGBDS. |
| 125 | +- 2016-09-05: rgbgfx is [integrated](https://github.com/gbdev/rgbds/commit/c3c31138ddbd8680d4e67957e387f2816798a71b) |
| 126 | + into Bentley's repository. |
| 127 | +- 2017-02-23: Bentley's repository is moved to the [rednex](https://github.com/rednex) |
| 128 | + organization. |
| 129 | +- 2018-01-26: The codebase is [relicensed](https://github.com/gbdev/rgbds/issues/128) |
| 130 | + under the MIT license. |
| 131 | +- 2020-09-15: The repository is [moved](https://github.com/gbdev/rgbds/issues/567) |
| 132 | + to the [gbdev](https://github.com/gbdev) organization. |
| 133 | +- 2022-05-17: The [rgbds.gbdev.io](https://rgbds.gbdev.io) website for RGBDS |
| 134 | + documentation and downloads is published. |
| 135 | + |
| 136 | +## 4. Acknowledgements |
| 137 | + |
| 138 | +RGBGFX generates palettes using algorithms found in the paper |
| 139 | +["Algorithms for the Pagination Problem, a Bin Packing with Overlapping Items"](http://arxiv.org/abs/1605.00558) |
| 140 | +([GitHub](https://github.com/pagination-problem/pagination), MIT license), |
| 141 | +by Aristide Grange, Imed Kacem, and Sébastien Martin. |
| 142 | + |
| 143 | +RGBGFX's color palette was taken from [SameBoy](https://sameboy.github.io), with permission and help |
| 144 | +by [LIJI](https://github.com/LIJI32). |
0 commit comments