public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "martin dot drab at fjfi dot cvut dot cz" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/36213] Wrong search path generation Date: Fri, 23 May 2008 11:10:00 -0000 [thread overview] Message-ID: <20080523110939.16411.qmail@sourceware.org> (raw) In-Reply-To: <bug-36213-8902@http.gcc.gnu.org/bugzilla/> ------- Comment #9 from martin dot drab at fjfi dot cvut dot cz 2008-05-23 11:09 ------- OK, so I tried to compile with autogenerated paths just from the prefix, and with the --enable-version-specific-runtime-libs option. The path no longer seems corrupted. It searches all its internal include directories properly now. So, that rises a question. Why there is the posibility to explicitly set all the various directories (like --libdir, --libexecdir, --includedir, ...etc.), when if you set them gcc can't handle it? And there is also one more problem with the paths. I tried the simple example with the ----x.cc-------------- #include <streambuf> int main () {return 0;} --------------------- as in the initial report. See what it produces below. Though includes are found fine, this time it is the libgcc_s, that is not found. For some reason, it is generated to an entirely different directory than all other libraries of the gcc. While most of the libraries are generated into the <prefix>/lib/gcc/<arch>/<version>/ (for 64-bit libs) and <prefix>/lib/gcc/<arch>/<version>/32 (for 32-bit libs), the libgcc_s is for some unknown reason generated into the <prefix>/lib/gcc/<arch>/lib64/ and <prefix>/lib/gcc/<arch>/lib32/ directories respectively, and gcc can't find them since it does not pass these paths to the linker. Why is that? ---------------- $ gcc -v Using built-in specs. Target: x86_64-pc-linux-gnu Configured with: ../../../gcc-SVN-20080522/gcc-SVN-20080522/configure --build=x86_64-pc-linux-gnu --prefix=/usr/local/opt/MDL/opt/gcc-4.4 --program-suffix=-4.4 --sharedstatedir=/var --localstatedir=/var --enable-languages=c,c++,fortran --enable-generated-files-in-srcdir --enable-targets=all --disable-libada --enable-libssp --disable-werror --enable-shared --enable-static --enable-parallel-mark --enable-version-specific-runtime-libs --with-gnu-ld --disable-werror-always --enable-multilib --enable-threads=posix --enable-tls --disable-rpath --with-demangler-in-ld --with-gnu-as --with-x --disable-coverage --disable-checking --enable-visibility --with-arch=core2 Thread model: posix gcc version 4.4.0 20080522 (experimental) (GCC) ---------------- ---------------- $ g++ -o x x.cc -v Using built-in specs. Target: x86_64-pc-linux-gnu Configured with: ../../../gcc-SVN-20080522/gcc-SVN-20080522/configure --build=x86_64-pc-linux-gnu --prefix=/usr/local/opt/MDL/opt/gcc-4.4 --program-suffix=-4.4 --sharedstatedir=/var --localstatedir=/var --enable-languages=c,c++,fortran --enable-generated-files-in-srcdir --enable-targets=all --disable-libada --enable-libssp --disable-werror --enable-shared --enable-static --enable-parallel-mark --enable-version-specific-runtime-libs --with-gnu-ld --disable-werror-always --enable-multilib --enable-threads=posix --enable-tls --disable-rpath --with-demangler-in-ld --with-gnu-as --with-x --disable-coverage --disable-checking --enable-visibility --with-arch=core2 Thread model: posix gcc version 4.4.0 20080522 (experimental) (GCC) COLLECT_GCC_OPTIONS='-o' 'x' '-v' '-shared-libgcc' '-mtune=generic' '-march=core2' /usr/local/opt/MDL/opt/gcc-4.4/libexec/gcc/x86_64-pc-linux-gnu/4.4.0/cc1plus -quiet -v -D_GNU_SOURCE x.cc -quiet -dumpbase x.cc -mtune=generic -march=core2 -auxbase x -version -o /tmp/ccNva0wT.s ignoring nonexistent directory "/usr/local/include" ignoring nonexistent directory "/usr/local/opt/MDL/opt/gcc-4.4/include" ignoring nonexistent directory "/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/../../../../x86_64-pc-linux-gnu/include" ignoring duplicate directory "/usr/local/opt/MDL/include" #include "..." search starts here: #include <...> search starts here: /usr/local/opt/MDL/include /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/include/c++ /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/include/c++/x86_64-pc-linux-gnu /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/include/c++/backward /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/include /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/include-fixed /usr/include End of search list. GNU C++ (GCC) version 4.4.0 20080522 (experimental) (x86_64-pc-linux-gnu) compiled by GNU C version 4.4.0 20080522 (experimental), GMP version 4.2.2, MPFR version 2.3.1. GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 Compiler executable checksum: f17dd6d038665e28e2542948829f7272 COLLECT_GCC_OPTIONS='-o' 'x' '-v' '-shared-libgcc' '-mtune=generic' '-march=core2' as -v -V -Qy -o /tmp/ccaFqdPM.o /tmp/ccNva0wT.s GNU assembler version 2.18.50 (x86_64-pc-linux-gnu) using BFD version (GNU Binutils) 2.18.50.20080413 COMPILER_PATH=/usr/local/opt/MDL/opt/gcc-4.4/libexec/gcc/x86_64-pc-linux-gnu/4.4.0/:/usr/local/opt/MDL/opt/gcc-4.4/libexec/gcc/x86_64-pc-linux-gnu/4.4.0/:/usr/local/opt/MDL/opt/gcc-4.4/libexec/gcc/x86_64-pc-linux-gnu/:/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/:/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/:/usr/libexec/gcc/x86_64-pc-linux-gnu/:/usr/lib/gcc/x86_64-pc-linux-gnu/ LIBRARY_PATH=/usr/local/opt/MDL/lib/../lib64/:/usr/local/opt/MDL/lib32/../lib64/:/usr/local/opt/MDL/lib/../lib64/:/usr/local/opt/MDL/lib32/../lib64/:/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/:/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/../../../../lib64/:/lib/../lib64/:/usr/lib/../lib64/:/usr/local/opt/MDL/lib/:/usr/local/opt/MDL/lib32/:/usr/local/opt/MDL/lib/:/usr/local/opt/MDL/lib32/:/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/../../../:/lib/:/usr/lib/ COLLECT_GCC_OPTIONS='-o' 'x' '-v' '-shared-libgcc' '-mtune=generic' '-march=core2' /usr/local/opt/MDL/opt/gcc-4.4/libexec/gcc/x86_64-pc-linux-gnu/4.4.0/collect2 --eh-frame-hdr -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o x /usr/lib/../lib64/crt1.o /usr/lib/../lib64/crti.o /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/crtbegin.o -L/usr/local/opt/MDL/lib/../lib64 -L/usr/local/opt/MDL/lib32/../lib64 -L/usr/local/opt/MDL/lib/../lib64 -L/usr/local/opt/MDL/lib32/../lib64 -L/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0 -L/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/local/opt/MDL/lib -L/usr/local/opt/MDL/lib32 -L/usr/local/opt/MDL/lib -L/usr/local/opt/MDL/lib32 -L/usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/../../.. /tmp/ccaFqdPM.o -lstdc++ -lm -lgcc_s -lgcc -lc -lgcc_s -lgcc /usr/local/opt/MDL/opt/gcc-4.4/lib/gcc/x86_64-pc-linux-gnu/4.4.0/crtend.o /usr/lib/../lib64/crtn.o /usr/local/opt/MDL/bin/ld: cannot find -lgcc_s collect2: ld returned 1 exit status ---------------- -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36213
next prev parent reply other threads:[~2008-05-23 11:10 UTC|newest] Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top 2008-05-11 19:40 [Bug preprocessor/36213] New: " martin dot drab at fjfi dot cvut dot cz 2008-05-11 19:44 ` [Bug preprocessor/36213] " martin dot drab at fjfi dot cvut dot cz 2008-05-11 19:44 ` martin dot drab at fjfi dot cvut dot cz 2008-05-22 20:08 ` [Bug middle-end/36213] " pinskia at gcc dot gnu dot org 2008-05-22 21:52 ` martin dot drab at fjfi dot cvut dot cz 2008-05-23 0:41 ` martin dot drab at fjfi dot cvut dot cz 2008-05-23 0:45 ` pinskia at gcc dot gnu dot org 2008-05-23 0:50 ` martin dot drab at fjfi dot cvut dot cz 2008-05-23 1:00 ` martin dot drab at fjfi dot cvut dot cz 2008-05-23 1:10 ` martin dot drab at fjfi dot cvut dot cz 2008-05-23 11:10 ` martin dot drab at fjfi dot cvut dot cz [this message] 2008-05-23 15:26 ` Ralf dot Wildenhues at gmx dot de 2008-05-23 16:06 ` martin dot drab at fjfi dot cvut dot cz
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20080523110939.16411.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).