cjdelisle/cjdns — Issue #2: Unrecognized compiler warning flags
Author: fintler
Created: 2011-12-30 19:17:57+00:00
State: open

It seems like the build breaks on Mac OS X 10.6.8.

The easy way to work around this is to remove those warning flags from the CMakeLists.txt. However, it seems like another way would be to just use -Wextra and set #pragma GCC diagnostic ignored "-Wunused-parameter" around the logging stuff.

jonb@aviso ~/cjdns/build> make
[ 1%] Building C object memory/CMakeFiles/MemAllocator.dir/BufferAllocator.o
cc1: error: unrecognized command line option "-Wclobbered"
cc1: error: unrecognized command line option "-Wignored-qualifiers"
cc1: error: unrecognized command line option "-Wmissing-parameter-type"
cc1: error: unrecognized command line option "-Wold-style-declaration"
cc1: error: unrecognized command line option "-Wtype-limits"
cc1: warnings being treated as errors
cc1: warning: -Wuninitialized is not supported without -O
make[2]: *** [memory/CMakeFiles/MemAllocator.dir/BufferAllocator.o] Error 1
make[1]: *** [memory/CMakeFiles/MemAllocator.dir/all] Error 2
make: *** [all] Error 2
jonb@aviso ~/cjdns/build> gcc --version
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
jonb@aviso ~> cc --version
i686-apple-darwin10-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.9)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
jonb@aviso ~>