|Summary:||Compilation errors for binutil-2.14 on RedHat 7.2|
|Product:||binutils||Reporter:||Vivek Kulkarni <vivekk>|
Description Vivek Kulkarni 2005-04-23 08:37:13 UTC
Hello, I am getting to compilation errors for binutils-2.14. Here are the details of my machine: 1. RedHat version: RHES 7.2 2. Kernel: 2.4.9-34 3. gcc : 2.96 (default gcc. We compile gcc-3.2 in a different location) Before I run ./configure, I am setting the below variables export CC=/usr/local/gcc-3.2/bin/gcc export CXX=/usr/local/gcc-3.2/bin/g++ I run ./configure (This is successful) make gives the below errors: linking ./libgettext.h to libintl.h make: Entering directory `/usr/local/MPInsight/binutils-2.14/intl' /usr/local/gcc3.2/bin/gcc -c - DLOCALEDIR=\"/usr/local/MPInsight/lib/sys/share/locale\" - DGNULOCALEDIR=\"/usr/local/MPInsight/lib/sys/share/locale\" - DLOCALE_ALIAS_PATH=\"/usr/local/MPInsight/lib/sys/share/locale:.\" - DHAVE_CONFIG_H -I. -I. -I/usr/local/MPInsight/lib/sys/include/ localealias.c localealias.c: In function `read_alias_file': localealias.c:337: void value not ignored as it ought to be localealias.c:341: void value not ignored as it ought to be make: *** [localealias.o] Error 1 make: Leaving directory `/usr/local/MPInsight/binutils-2.14/intl' make: *** [all-intl] Error 2 Am I missing anything? Appreciate your help in this matter.
Comment 1 Nick Clifton 2005-04-25 08:07:20 UTC
Subject: Re: New: Compilation errors for binutil-2.14 on RedHat 7.2 Hi Vivekk, > I am getting to compilation errors for binutils-2.14. FYI: This is an old release of binutils. We are now at 2.15 and version 2.16 is about to be released. > localealias.c:337: void value not ignored as it ought to be > localealias.c:341: void value not ignored as it ought to be > Am I missing anything? It appears that you have a bad prototype for memcpy() somewhere in your include path. Both of these errors refer to the code in localealias.c looking at the return value from memcpy(). memcpy() does return a value so the error message is wrong, hence the probable cause is that the compiler has been given a bad prototype. What happens for example if you add this line: extern void * memcpy (void *, const void *, size_t); at the start of the code for read_alias_file() in intl/localealias.c ? Cheers Nick
Comment 2 Vivek Kulkarni 2005-04-25 12:45:26 UTC
Hello Nick, Thank you for your help. I am able to compile binutils version 2.15 successfully. Since the default gcc on my system is 2.96 and I am using gcc-3.2, I exported the below variables for compiling binutils. export CC=/usr/local/gcc3.2/bin/gcc export CPP=/usr/local/gcc3.2/bin/cpp export CXX=/usr/local/gcc3.2/bin/g++ export CFLAGS='-I/usr/local/gcc3.2/include -L/usr/local/gcc3.2/lib' export CXXFLAGS='-I/usr/local/gcc3.2/include -L/usr/local/gcc3.2/lib' export LDFLAGS=-L/usr/local/gcc3.2/lib If you see CFLAGS and CXXFLAGS above, they are not compilation options but the include and lib paths. I have to do this because I did not get any help from ./configure --help as to which variables should I export as gcc-3.2 is in different location. Please correct me if wrong.
Comment 3 Nick Clifton 2005-04-25 13:07:06 UTC
Hi Vivek, Those environment settings look OK. Since you can build binutils with the 2.15 sources and not the 2.14 source I conclude that the problem must have been a broken prototype somewhere in the 2.14 sources. Since this problem is now resolved for you, I will close the issue. Cheers Nick