JMFord Posted March 24, 2017 Posted March 24, 2017 Hi all. We would like to raise the warning level of the compiler. In particular, bad code is generated if you forget to declare a function returning a double, and it gets declared implicitly. We generally compile all our other code with -Wall and -Wextra to be sure we're not wandering into any risky territory, and it seems prudent to do that with PMAC code. Is there a way to add more warnings to the compiler with the IDE? Or by editing some file somewhere in the system? Thanks! John
JMFord Posted April 28, 2017 Author Posted April 28, 2017 Well, I thought I would answer my question for the benefit of others, oddly enough the release version of the makefile addes -Wall to the compile command. This is very helpful to get rid of errors caused by implicit declarations and other errors in the code that the compiler accepts without complaint in the "debug" version. Can someone tell me why there is no way to pass in other compiler flags to the make process?
steve.milici Posted May 5, 2017 Posted May 5, 2017 This was basically a marketing decision to limit the IDE product to stay “within the Power PMAC documented box”.
JMFord Posted May 6, 2017 Author Posted May 6, 2017 It might make sense to make -Wall a default choice even in debug mode, as that is when you want to find the warnings and fix them! Thanks for the info! John
steve.milici Posted May 8, 2017 Posted May 8, 2017 I will make a point of this to the software development group.
Recommended Posts