Skip to content

Get libxenon to compile without errors with -Wall -Werror#68

Open
mitchellwaite wants to merge 10 commits intoFree60Project:masterfrom
mitchellwaite:resolveCompilerWarnings
Open

Get libxenon to compile without errors with -Wall -Werror#68
mitchellwaite wants to merge 10 commits intoFree60Project:masterfrom
mitchellwaite:resolveCompilerWarnings

Conversation

@mitchellwaite
Copy link

After I was bitten by implicit function definitions, I set out to see what it would take to get libxenon to compile with -Wall -Werror. Where practical, I've done so by making the following changes:

  • printf statement changes to resolve most formatting errors
  • Include headers as appropriate to resolve implicit function definitions
  • explicit casts where needed in xenon_smc putchar and xenon_get_logical_nand_data
  • remove unused variable in netif/enet.c lwIP port layer
  • changed %r0 to 0 in startup and cache asm files, as per proper PPC assembly convention. They assemble to the same result.

In some files, GCC pragmas have been added to ignore certain errors specifically for those files. These files can be addressed in separate changes. I can open issues for this.

  • elf.c (this one had a lot)
  • iso9660.c
  • c_except.c
  • ehci.c
  • debug.c (though ignoring -Wframe-address might be a requirement)

With these changes I can build both libxenon and XeLL with -Wall -Werror and produce a binary that is apparently fully functional on the FFFFalcon

these files in particular throw a lot of warnings, can disable them in the file and enable -Werror for everything else globally
- Unused variables
- integer to pointer cast
- signed to unsigned without cast
disable -Wformat-overflow in c_except.c due to how the string is built... needs to be reworked so as to not throw *multiple compiler errors*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant