- Make it work inside pipelines
- Add RGBFIX tests to the suite
- Be more flexible in accepted MBC names
- Add warnings for dangerous or nonsensical input params
- Improve man page
Create a new file, platform.h, for platform-specific hacks
for MSVC, this includes defining strncasecmp to _stricmp and
strdup to _strdup, among other things like defining missing
stat macros
Change some things not supported in MSVC, like _Static_assert,
to their counterparts (in this case, static_assert)
Replace usage of VLAs with malloc and free
Update getopt_long and use the getopt implementation from musl
on Windows.
Use comments to show which functions from platform.h are being used
A regression was spotted in rgbfix 0.3.7, where we would accidentally include the first byte of the existing checksum when calculating a global checksum. We now correctly ignore both of the existing checksum bytes.
This was spotted when running rgbfix on the Pokémon Gold/Silver betas, as they have a non-zero global checksum.
Fixes#280.
Signed-off-by: Ben10do <Ben10do@users.noreply.github.com>
Rewrite rgbfix to perform most actions in memory.
Limit file operations to a small number that can be reasonably checked,
and do the majority of the actual work on a buffered header in memory
where operations won't fail.
Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
Limit file operations to a small number that can be reasonably checked,
and do the majority of the actual work on a buffered header in memory
where operations won't fail.
With permission from the main authors [1], most of the code has been
relicensed under the MIT license.
SPDX license identifiers are used so that the license headers in source
code files aren't too large.
Add CONTRIBUTORS.rst file.
[1] https://github.com/rednex/rgbds/issues/128
Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
This option has been added to all programs of the toolchain, and it
prints the version string of the toolchain.
Manpages and help command line output updated.
Add missing 'w' flag to the command line output of rgbasm. It was
correctly documented in the manpages.
Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
The error message shouldn't specify the name of the binary, that's
supposed to be known by the caller.
Update test reference outputs.
Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
Improve error messages generated by `errx()`, `warnx()` and similar.
Set `progname` to a static string with the name of the program so that
the path of the binary isn't included in error messages.
Signed-off-by: AntonioND <antonio_nd@outlook.com>