[LLVMdev] strange visibility error when compiling llvm-gcc-4.2

Holger Schurig hs4233 at mail.mn-solutions.de
Wed Feb 6 03:10:38 PST 2008


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?



More information about the llvm-dev mailing list