mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 02:02:06 +00:00
Format RGBFIX and RGBGFX warnings/errors the same way as RGBASM and RGBLINK
This commit is contained in:
@@ -75,22 +75,26 @@ void warning(WarningID id, char const *fmt, ...) {
|
||||
|
||||
case WarningBehavior::ENABLED:
|
||||
style_Set(stderr, STYLE_YELLOW, true);
|
||||
fprintf(stderr, "warning: [-W%s]\n ", flag);
|
||||
fputs("warning: ", stderr);
|
||||
style_Reset(stderr);
|
||||
va_start(ap, fmt);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
va_end(ap);
|
||||
putc('\n', stderr);
|
||||
style_Set(stderr, STYLE_YELLOW, true);
|
||||
fprintf(stderr, " [-W%s]\n", flag);
|
||||
style_Reset(stderr);
|
||||
break;
|
||||
|
||||
case WarningBehavior::ERROR:
|
||||
style_Set(stderr, STYLE_RED, true);
|
||||
fprintf(stderr, "error: [-Werror=%s]\n ", flag);
|
||||
fputs("error: ", stderr);
|
||||
style_Reset(stderr);
|
||||
va_start(ap, fmt);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
va_end(ap);
|
||||
putc('\n', stderr);
|
||||
style_Set(stderr, STYLE_RED, true);
|
||||
fprintf(stderr, " [-Werror=%s]\n", flag);
|
||||
style_Reset(stderr);
|
||||
|
||||
warnings.incrementErrors();
|
||||
break;
|
||||
|
||||
@@ -84,22 +84,26 @@ void warning(WarningID id, char const *fmt, ...) {
|
||||
|
||||
case WarningBehavior::ENABLED:
|
||||
style_Set(stderr, STYLE_YELLOW, true);
|
||||
fprintf(stderr, "warning: [-W%s]\n ", flag);
|
||||
fputs("warning: ", stderr);
|
||||
style_Reset(stderr);
|
||||
va_start(ap, fmt);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
va_end(ap);
|
||||
putc('\n', stderr);
|
||||
style_Set(stderr, STYLE_YELLOW, true);
|
||||
fprintf(stderr, " [-W%s]\n", flag);
|
||||
style_Reset(stderr);
|
||||
break;
|
||||
|
||||
case WarningBehavior::ERROR:
|
||||
style_Set(stderr, STYLE_RED, true);
|
||||
fprintf(stderr, "error: [-Werror=%s]\n ", flag);
|
||||
fputs("error: ", stderr);
|
||||
style_Reset(stderr);
|
||||
va_start(ap, fmt);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
va_end(ap);
|
||||
putc('\n', stderr);
|
||||
style_Set(stderr, STYLE_YELLOW, true);
|
||||
fprintf(stderr, " [-Werror=%s]\n", flag);
|
||||
style_Reset(stderr);
|
||||
|
||||
warnings.incrementErrors();
|
||||
break;
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Wmbc]
|
||||
MBC "(unknown)" has no RAM, but RAM size was set to 2
|
||||
warning: MBC "(unknown)" has no RAM, but RAM size was set to 2 [-Wmbc]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the logo
|
||||
warning: Overwrote a non-zero byte in the logo [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
|
||||
@@ -1,3 +1,2 @@
|
||||
warning: 'l' overriding 'L' in fix spec
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating game ID "FOUR!" to 4 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the manufacturer code
|
||||
warning: Truncating game ID "FOUR!" to 4 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the manufacturer code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the manufacturer code
|
||||
warning: Overwrote a non-zero byte in the manufacturer code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the destination code
|
||||
warning: Overwrote a non-zero byte in the destination code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Wmbc]
|
||||
MBC "ROM+RAM+BATTERY" is under-specified and poorly supported
|
||||
warning: MBC "ROM+RAM+BATTERY" is under-specified and poorly supported [-Wmbc]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Wmbc]
|
||||
MBC "ROM+RAM" is under-specified and poorly supported
|
||||
warning: MBC "ROM+RAM" is under-specified and poorly supported [-Wmbc]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wmbc]
|
||||
MBC "ROM" has no RAM, but RAM size was set to 2
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: MBC "ROM" has no RAM, but RAM size was set to 2 [-Wmbc]
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating new licensee "HOMEBREW" to 2 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the new licensee code
|
||||
warning: Truncating new licensee "HOMEBREW" to 2 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the new licensee code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the new licensee code
|
||||
warning: Overwrote a non-zero byte in the new licensee code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the old licensee code
|
||||
warning: Overwrote a non-zero byte in the old licensee code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the old licensee code
|
||||
warning: Overwrote a non-zero byte in the old licensee code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wmbc]
|
||||
MBC "MBC3+RAM" has RAM, but RAM size was set to 0
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: MBC "MBC3+RAM" has RAM, but RAM size was set to 0 [-Wmbc]
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wsgb]
|
||||
SGB compatibility enabled, but old licensee is 0x45, not 0x33
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the SGB flag
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the old licensee code
|
||||
warning: SGB compatibility enabled, but old licensee is 0x45, not 0x33 [-Wsgb]
|
||||
warning: Overwrote a non-zero byte in the SGB flag [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the old licensee code [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the SGB flag
|
||||
warning: [-Wsgb]
|
||||
SGB compatibility enabled, but old licensee was 0xc5, not 0x33
|
||||
warning: Overwrote a non-zero byte in the SGB flag [-Woverwrite]
|
||||
warning: SGB compatibility enabled, but old licensee was 0xc5, not 0x33 [-Wsgb]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the SGB flag
|
||||
warning: Overwrote a non-zero byte in the SGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 15 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Truncating title "0123456789ABCDEF" to 15 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 15 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Truncating title "0123456789ABCDEF" to 15 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 15 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Truncating title "0123456789ABCDEF" to 15 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 15 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the CGB flag
|
||||
warning: Truncating title "0123456789ABCDEF" to 15 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the CGB flag [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 11 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the manufacturer code
|
||||
warning: Truncating title "0123456789ABCDEF" to 11 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the manufacturer code [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEF" to 11 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the manufacturer code
|
||||
warning: Truncating title "0123456789ABCDEF" to 11 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the manufacturer code [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
warning: [-Wtruncation]
|
||||
Truncating title "0123456789ABCDEFGHIJK" to 16 chars
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: Truncating title "0123456789ABCDEFGHIJK" to 16 chars [-Wtruncation]
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the title
|
||||
warning: Overwrote a non-zero byte in the title [-Woverwrite]
|
||||
|
||||
@@ -1,10 +1,5 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 identification code
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 revision number
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the RAM size
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 feature flags
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 identification code [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 revision number [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the RAM size [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 feature flags [-Woverwrite]
|
||||
|
||||
@@ -1,10 +1,5 @@
|
||||
warning: [-Wmbc]
|
||||
TPP1 overwrites region flag for its identification code, ignoring `-j`
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the cartridge type
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 identification code
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 revision number
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the TPP1 feature flags
|
||||
warning: TPP1 overwrites region flag for its identification code, ignoring `-j` [-Wmbc]
|
||||
warning: Overwrote a non-zero byte in the cartridge type [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 identification code [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 revision number [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the TPP1 feature flags [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the Nintendo logo
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the header checksum
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the global checksum
|
||||
warning: Overwrote a non-zero byte in the Nintendo logo [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the header checksum [-Woverwrite]
|
||||
warning: Overwrote a non-zero byte in the global checksum [-Woverwrite]
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Woverwrite]
|
||||
Overwrote a non-zero byte in the mask ROM version number
|
||||
warning: Overwrote a non-zero byte in the mask ROM version number [-Woverwrite]
|
||||
|
||||
@@ -1,3 +1,2 @@
|
||||
error: [-Werror=embedded]
|
||||
Sorting palette colors by PNG's embedded PLTE chunk without '-c/--colors embedded'
|
||||
error: Sorting palette colors by PNG's embedded PLTE chunk without '-c/--colors embedded' [-Werror=embedded]
|
||||
Conversion aborted after 1 error
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
warning: [-Wtrim-nonempty]
|
||||
Trimming a nonempty tile (configure with '-x/--trim-end')
|
||||
warning: Trimming a nonempty tile (configure with '-x/--trim-end') [-Wtrim-nonempty]
|
||||
|
||||
Reference in New Issue
Block a user