Holger Schurig
2008-Feb-06 11:10 UTC
[LLVMdev] strange visibility error when compiling llvm-gcc-4.2
I'm on Debian Etch and re-compile llvm/llvm-gcc-4.2 from
scratch. I'm on svn revision 46813.
I'm using the following commands for the compilation:
----------------------------------
# Get the sources
mkdir /s/llvm
cd /s/llvm
svn co http://llvm.org/svn/llvm-project/llvm/trunk /s/llvm/svn.llvm
svn co http://llvm.org/svn/llvm-project/llvm-gcc-4.2/trunk /s/llvm/svn.gcc42
# Compile llvm
mkdir -p /s/llvm/obj.llvm
cd /s/llvm/obj.llvm
/s/llvm/svn.llvm/configure \
--prefix=/s/llvm/dist \
--with-llvmgccdir=/s/llvm/dist \
--enable-optimized \
--disable-debug \
--disable-doxygen
make tools-only
# Compile llvm-gcc-4.2
mkdir -p /s/llvm/obj.gcc42
cd /s/llvm/obj.gcc42
/s/llvm/svn.gcc42/configure \
--prefix=/s/llvm/dist \
--enable-llvm=/s/llvm/obj.llvm \
--program-prefix=llvm- \
--enable-languages=c,c++ \
--disable-bootstrap \
--disable-shared
make
----------------------------------
This takes some time, and then I get this:
----------------------------------
if /bin/sh ./libtool --mode=compile /s/llvm/obj.gcc42/./gcc/xgcc
-B/s/llvm/obj.gcc42/./gcc/ -B/usr/local/i686-pc-linux-gnu/bin/
-B/usr/local/i686-pc-linux-gnu/lib/ -isystem
/usr/local/i686-pc-linux-gnu/include -isystem
/usr/local/i686-pc-linux-gnu/sys-include -DHAVE_CONFIG_H -I.
-I/s/llvm/svn.gcc42/libgomp -I. -I/s/llvm/svn.gcc42/libgomp/config/linux/x86
-I/s/llvm/svn.gcc42/libgomp/config/linux
-I/s/llvm/svn.gcc42/libgomp/config/posix -I/s/llvm/svn.gcc42/libgomp -Wall
-Werror -ftls-model=initial-exec -march=i486 -mtune=i686 -Wc,-pthread -O2 -g -O2
-MT lock.lo -MD -MP -MF ".deps/lock.Tpo" -c -o lock.lo
/s/llvm/svn.gcc42/libgomp/config/linux/lock.c; \
then mv -f ".deps/lock.Tpo" ".deps/lock.Plo"; else
rm -f ".deps/lock.Tpo"; exit 1; fi
yes
cc1: warnings being treated as errors
/s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute not
supported in this configuration; ignored
/s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute not
supported in this configuration; ignored
checking for tanl... make[5]: *** [team.lo] Error 1
----------------------------------
Because of the -Werror, this warning is taken as an error
and compilation aborts. I wonder why it warns in the first
place, is something broken with xgcc?
Not knowing details about the gcc build system, I'm
wondering also why it builds xgcc, doesn't
--disable-bootstrap turn this off?
Duncan Sands
2008-Feb-06 13:18 UTC
[LLVMdev] strange visibility error when compiling llvm-gcc-4.2
Hi,> if /bin/sh ./libtool --mode=compile /s/llvm/obj.gcc42/./gcc/xgcc -B/s/llvm/obj.gcc42/./gcc/ -B/usr/local/i686-pc-linux-gnu/bin/ -B/usr/local/i686-pc-linux-gnu/lib/ -isystem /usr/local/i686-pc-linux-gnu/include -isystem /usr/local/i686-pc-linux-gnu/sys-include -DHAVE_CONFIG_H -I. -I/s/llvm/svn.gcc42/libgomp -I. -I/s/llvm/svn.gcc42/libgomp/config/linux/x86 -I/s/llvm/svn.gcc42/libgomp/config/linux -I/s/llvm/svn.gcc42/libgomp/config/posix -I/s/llvm/svn.gcc42/libgomp -Wall -Werror -ftls-model=initial-exec -march=i486 -mtune=i686 -Wc,-pthread -O2 -g -O2 -MT lock.lo -MD -MP -MF ".deps/lock.Tpo" -c -o lock.lo /s/llvm/svn.gcc42/libgomp/config/linux/lock.c; \ > then mv -f ".deps/lock.Tpo" ".deps/lock.Plo"; else rm -f ".deps/lock.Tpo"; exit 1; fi > yes > cc1: warnings being treated as errors > /s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute not supported in this configuration; ignored > /s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute not supported in this configuration; ignored > checking for tanl... make[5]: *** [team.lo] Error 1 > ---------------------------------- > > Because of the -Werror, this warning is taken as an error > and compilation aborts. I wonder why it warns in the first > place, is something broken with xgcc?I suspect this is due to the recent change by Bill (revision 46747). Best wishes, Duncan.
Chris Lattner
2008-Feb-06 17:20 UTC
[LLVMdev] strange visibility error when compiling llvm-gcc-4.2
On Feb 6, 2008, at 5:18 AM, Duncan Sands wrote:> Hi, > >> if /bin/sh ./libtool --mode=compile /s/llvm/obj.gcc42/./gcc/xgcc -B/ >> s/llvm/obj.gcc42/./gcc/ -B/usr/local/i686-pc-linux-gnu/bin/ -B/usr/ >> local/i686-pc-linux-gnu/lib/ -isystem /usr/local/i686-pc-linux-gnu/ >> include -isystem /usr/local/i686-pc-linux-gnu/sys-include - >> DHAVE_CONFIG_H -I. -I/s/llvm/svn.gcc42/libgomp -I. -I/s/llvm/ >> svn.gcc42/libgomp/config/linux/x86 -I/s/llvm/svn.gcc42/libgomp/ >> config/linux -I/s/llvm/svn.gcc42/libgomp/config/posix -I/s/llvm/ >> svn.gcc42/libgomp -Wall -Werror -ftls-model=initial-exec - >> march=i486 -mtune=i686 -Wc,-pthread -O2 -g -O2 -MT lock.lo -MD -MP >> -MF ".deps/lock.Tpo" -c -o lock.lo /s/llvm/svn.gcc42/libgomp/config/ >> linux/lock.c; \ >> then mv -f ".deps/lock.Tpo" ".deps/lock.Plo"; else rm -f >> ".deps/lock.Tpo"; exit 1; fi >> yes >> cc1: warnings being treated as errors >> /s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute >> not supported in this configuration; ignored >> /s/llvm/svn.gcc42/libgomp/team.c:341: warning: visibility attribute >> not supported in this configuration; ignored >> checking for tanl... make[5]: *** [team.lo] Error 1 >> ---------------------------------- >> >> Because of the -Werror, this warning is taken as an error >> and compilation aborts. I wonder why it warns in the first >> place, is something broken with xgcc? > > I suspect this is due to the recent change by Bill (revision 46747).Bill's change only affected darwin IIRC. I don't know that anyone has built GOMP on linux yet, and OpenMP hasn't been widely tested at all. I'd suggest using --enable-languages=c,c++ -Chris
Reasonably Related Threads
- [LLVMdev] strange visibility error when compiling llvm-gcc-4.2
- [LLVMdev] strange visibility error when compiling llvm-gcc-4.2
- [LLVMdev] strange visibility error when compiling llvm-gcc-4.2
- [LLVMdev] strange visibility error when compiling llvm-gcc-4.2
- [LLVMdev] strange visibility error when compiling llvm-gcc-4.2