Issue 373: unable to compile - error: unused function

Reported by Jack Quasinil, May 12, 2014

Chameleon -  revision 2378.
Darwin Kernel Version 13.1.0

        [CC] stringTable.c
stringTable.c:43:1: error: unused function 'keyncmp' 
keyncmp(const char *str, const char *key, int n)
1 error generated.

Comment 1 by Jack Quasinil, May 12, 2014

** PS  
The same Chameleon code (version 2378) compiles fine on 
OsX Lion  ( Darwin Kernel Version 11.4.2)
with gcc version: 4.2.1

Has anyone compiled it under Mavericks ??

thanks in advance

Comment 2 by Yang Xia, May 24, 2014

I avoided this error per remove the '-Werror' flag in the file 
Make.rules, but it was failed again when compiled the uClibcxx,
ld: internal error: atom not found in 
for architecture i386

Mavericks 10.9.3
gcc version: 4.2.1

Comment 3 by viv xix, Jun 8, 2014

1.make config
2.remove the uClibcxx module

buil can be OK

Comment 4 by jeremy motyka, Aug 9, 2014

I removed uClibcxx module and stil got the same error.

Comment 5 by MacMan, Aug 11, 2014

In Make.rules, add to CFLAGS -Wno-unused-function

Comment 6 by Mel Mozinski, Oct 1, 2014

CFLAGS -Wno-unused-function didn't work for me on Mountain Lion 
-anyway I worked around with manually commenting ou the unused 
functions and can succesfully compile.

I am on Mountain Lion 10.9.5:

gcc -v
Configured with: 
Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn)
Target: x86_64-apple-darwin12.5.0

Comment 7 by zenith432, Oct 20, 2014

Attached is a patch file to eliminate all compilation errors when 
building revision 2402 with XCode 6.1.

Comment 8 by zenith432, Oct 20, 2014

Here's the attachment

Comment 9 by ErmaC , Oct 21, 2014

Status: Fixed

Created: 7 years 4 months ago by Jack Quasinil

Updated: 6 years 11 months ago

Status: Fixed

Followed by: 7 persons