This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
probllems with ltdl versions and building newer versions
- From: "Linda A. Walsh" <gcc at tlinx dot org>
- To: "libc-help at sourceware dot org" <libc-help at sourceware dot org>
- Date: Mon, 17 Aug 2015 16:04:39 -0700
- Subject: probllems with ltdl versions and building newer versions
- Authentication-results: sourceware.org; auth=none
I've been using -flto with most of my builds without problems.
Then I got to squid-3.5.7 which had its own and I tried to use.
It didn't play well with what I had installed, (at link time
many things were 'unresolved'), so I tried to use the ltdl included
with squid.
Now my "other builds" no longer work with messages along the lines
of a 2.2 vs. 3.0 version incompat.
Looked up source for lto and found gnu page
https://gcc.gnu.org/wiki/LinkTimeOptimization
...followed instructions there and a few variations ...
nothing would generate lto or any installable.
Error messages center around some struct sizes:
/usr/bin/gcc -c -DHAVE_CONFIG_H -g -fkeep-inline-functions -I.
-I../../lto/libiberty/../include -W -Wall -Wwrite-strings -Wc++-compat
-Wstrict-prototypes -pedantic -fpic ../../lto/libiberty/physmem.c -o
pic/physmem.o; \
else true; fi
../../lto/libiberty/physmem.c: In function 'physmem_total':
../../lto/libiberty/physmem.c:96:23: error: storage size of 'pss' isn't
known
struct pst_static pss;
^
../../lto/libiberty/physmem.c:97:5: warning: implicit declaration of
function 'pstat_getstatic' [-Wimplicit-function-declaration]
if (0 <= pstat_getstatic (&pss, sizeof pss, 1, 0))
^
../../lto/libiberty/physmem.c:96:23: warning: unused variable 'pss'
[-Wunused-variable]
struct pst_static pss;
^
../../lto/libiberty/physmem.c: In function 'physmem_available':
../../lto/libiberty/physmem.c:200:23: error: storage size of 'pss' isn't
known
struct pst_static pss;
^
../../lto/libiberty/physmem.c:201:24: error: storage size of 'psd' isn't
known
struct pst_dynamic psd;
^
../../lto/libiberty/physmem.c:203:2: warning: implicit declaration of
function 'pstat_getdynamic' [-Wimplicit-function-declaration]
&& 0 <= pstat_getdynamic (&psd, sizeof psd, 1, 0))
^
../../lto/libiberty/physmem.c:201:24: warning: unused variable 'psd'
[-Wunused-variable]
struct pst_dynamic psd;
^
../../lto/libiberty/physmem.c:200:23: warning: unused variable 'pss'
[-Wunused-variable]
struct pst_static pss;
^
make[3]: *** [physmem.o] Error 1
make[3]: Leaving directory `/home/tools/lto/bld/libiberty'
make[2]: *** [all-stage1-libiberty] Error 2
make[2]: Leaving directory `/home/tools/lto/bld'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/home/tools/lto/bld'
make: *** [all] Error 2
The symptom of some mismatch is in *either* squid or bash, if I use the
-flto
option, I gets tons of undefined symbols. W/o -flto in bash I get final
stripped binary about 200K larger...
am using gcc-4.9 tool chain on linux 4.1.0
Thanks for any pointers or where I might direct this..
-l