This is the mail archive of the
mailing list for the GCC project.
Re: Graphite build fails if PPL configured with --disable-shared
- From: Ian Lance Taylor <iant at google dot com>
- To: Roberto Bagnara <bagnara at cs dot unipr dot it>
- Cc: janis187 at us dot ibm dot com, gcc at gcc dot gnu dot org, "The Parma Polyhedra Library developers' list" <ppl-devel at cs dot unipr dot it>
- Date: Tue, 12 May 2009 10:54:10 -0700
- Subject: Re: Graphite build fails if PPL configured with --disable-shared
- References: <email@example.com> <1242072864.6516.18.camel@janis-laptop> <4A09A801.firstname.lastname@example.org>
Roberto Bagnara <email@example.com> writes:
> Janis Johnson wrote:
>> On Mon, 2009-05-11 at 13:07 -0700, Ian Lance Taylor wrote:
>>> Another Graphite build issue: it appears that I must not use
>>> --disable-shared when I configure PPL. If I do use --disable-shared, I
>>> get this:
>>> /home/iant/gnu/ppl-0.10.2-install/lib/libppl_c.a(ppl_c_implementation_common.o): In function `finalize':
>>> /home/iant/gnu/ppl-0.10.2/interfaces/C/../../src/ppl.hh:1842: undefined reference to `operator delete(void*)'
>>> followed by thousands of similar errors. This is unfortunate, as it
>>> means that I must manually set LD_LIBRARY_PATH to the directory where
>>> the PPL library is installed. This also makes it harder for anybody
>>> else to run the compiler that I build. This needs to be fixed.
>> I get around this by setting LDFLAGS for the ppl configure:
>> LDFLAGS="-static" \
>> ./configure \
>> --prefix=$PREFIX \
>> --build=powerpc-linux \
>> --with-gnu-ld \
>> --with-libgmp-prefix=$PREFIX \
>> --with-libgmpxx-prefix=$PREFIX \
> I am not sure I understand: we trust that Libtool, which provides us
> with the --disable-shared option, will do the right thing. And it
> seems it does here: the static library is built and passes its checks.
> Perhaps you want something different from what --disable-shared promises,
> that is, not to build any shared libraries?
>> I copy libstdc++.a into the directory with the other GCC host
>> libraries (gmp/mpfr/ppl/cloog/mpc).
>> Building these libraries is indeed quite painful.
> Any suggestion about how to improve the PPL is welcome. This, of course,
> applies also to the build machinery.
I don't think this is a problem with PPL.
The problem is that PPL uses libstdc++ and gcc does not. Thus, linking
against PPL configured with --disable-shared requires also linking
against libstdc++. That is the part which needs to be improved when
using gcc with PPL. We have ways to do it, but they are not good ways,
and they are not documented on the Graphite_build wiki page.