This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

undefined reference to `std::strchr(char const*, int)'


I just recompiled/installed snapshot 20010521 again, where I *only* changed
the way I called configure, and now I get:

>g++-3.0 -v test.cc
Reading specs from /usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/specs
Configured with: /usr/src/gcc/gcc-cvs-3.0/configure --prefix=/usr/local/gcc-3.0 --enable-shared --with-gnu-as --with-gnu-ld --enable-languages=c++ --enable-debug --enable-cxx-flags=-fno-omit-frame-pointer
Thread model: single
gcc version 3.0 20010521 (prerelease)
 /usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/cc1plus -v -D__GNUC__=3 -D__GNUC_MINOR__=0 -D__GNUC_PATCHLEVEL__=0 -D__ELF__ -Dunix -Dlinux -D__ELF__ -D__unix__ -D__linux__ -D__unix -D__linux -Asystem=posix -D__STDC_HOSTED__=1 -Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i686__ -D__tune_pentiumpro__ test.cc -D__GNUG__=3 -D_GNU_SOURCE -D__GXX_DEPRECATED -D__EXCEPTIONS -D__GXX_ABI_VERSION=100 -quiet -dumpbase test.cc -version -o /tmp/ccv3knEq.s
GNU CPP version 3.0 20010521 (prerelease) (cpplib) (i386 Linux/ELF)
GNU C++ version 3.0 20010521 (prerelease) (i686-pc-linux-gnu)
        compiled by GNU C version 3.0 20010521 (prerelease).
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/gcc-3.0/include/g++-v3
 /usr/local/gcc-3.0/include/g++-v3/i686-pc-linux-gnu
 /usr/local/gcc-3.0/include/g++-v3/backward
 /usr/local/include
 /usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/include
 /usr/local/gcc-3.0/i686-pc-linux-gnu/include
 /usr/include
End of search list.
 as --traditional-format -V -Qy -o /tmp/ccAGqlQx.o /tmp/ccv3knEq.s
GNU assembler version 2.10.91 (i386-redhat-linux) using BFD version 2.10.91.0.2
 /usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/collect2 -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o /usr/lib/crti.o
/usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/crtbegin.o -L/usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0 -L/usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/../../.. -rpath /usr/local/gcc-3.0/lib: /tmp/ccAGqlQx.o -lstdc++ -lm -lgcc_s -lc -lgcc_s /usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/crtend.o /usr/lib/crtn.o
/usr/local/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0/../../../libstdc++.so: undefined reference to `std::strchr(char const*, int)'
collect2: ld returned 1 exit status

Anyone seen this before?

-- 
Carlo Wood <carlo@alinoe.com>

PS Configured/compiled/installed with:

env CC=gcc CFLAGS="-O9 -march=pentiumpro -fomit-frame-pointer" \
    ./gcc-cvs-3.0/contrib/gcc_build \
        -d /usr/src/gcc/gcc-cvs-3.0 \
        -o ../gcc-objdir-3.0 \
        -c "--prefix=/usr/local/gcc-3.0 --enable-shared --with-gnu-as --with-gnu-ld \
            --enable-languages=c++ --enable-debug --enable-cxx-flags='-fno-omit-frame-pointer'" \
        configure

env CC=gcc CFLAGS="-O9 -march=pentiumpro -fomit-frame-pointer" \
    ./gcc-cvs-3.0/contrib/gcc_build \
        -d /usr/src/gcc/gcc-cvs-3.0 \
        -o ../gcc-objdir-3.0 \
        -c "--prefix=/usr/local/gcc-3.0 --enable-shared --with-gnu-as --with-gnu-ld \
            --enable-languages=c++ --enable-debug --enable-cxx-flags='-fno-omit-frame-pointer'" \
        bootstrap

env CC=gcc CFLAGS="-O9 -march=pentiumpro -fomit-frame-pointer" \
    ./gcc-cvs-3.0/contrib/gcc_build \
        -d /usr/src/gcc/gcc-cvs-3.0 \
        -o ../gcc-objdir-3.0 \
        -c "--prefix=/usr/local/gcc-3.0 --enable-shared --with-gnu-as --with-gnu-ld \
            --enable-languages=c++ --enable-debug --enable-cxx-flags='-fno-omit-frame-pointer'" \
        install



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]