This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Messed up library paths?


Hi, I've been trying to compile a program (PlasticFS 1.9) for a while
now linked to glibc 2.3.4 in a non-standard directory.  Here is my set
up:

/home/vorpo/vorpo/usr/src/plasticfs-1.9 < -- my plasticfs source code dir
/home/vorpo/vorpo/Programs/plasticfs-orig-1.9 < -- my plasticfs target dir
/home/vorpo/vorpo/Programs/glibc-orig-2.3.4 < -- my glibc dir
/home/vorpo/vorpo/Programs/glibc-orig-2.3.4/lib < -- my glibc lib dir

I've chrooted into the /home/vorpo/vorpo directory as root, so my
glibc dir is /Programs/glibc-orig-2.3.4.  When I try to run plasticfs'
configure script, it fails:

thebeast:/usr/src/plasticfs-1.9#
CXXFLAGS=-L/Programs/glibc-orig-2.3.4/lib ./configure
--prefix=/Programs/plasticfs-orig-1.9
checking for g++... g++
checking for C++ compiler default output file name... configure:
error: C++ compiler cannot create executables
See `config.log' for more details.

PlasticFS is written in C++, so I'm pretty sure CXXFLAGS is the right
variable to set.  My LIBRARY_PATH=/Programs/glibc-orig-2.3.4/lib.

Here is what config.log says (it fails in the CORE TESTS section):

This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by configure, which was
generated by GNU Autoconf 2.58.  Invocation command line was

$ ./configure --prefix=/Programs/plasticfs-orig-1.9

## --------- ##
## Platform. ##
## --------- ##

hostname = thebeast
uname -m = i686
uname -r = 2.6.8-1-386
uname -s = Linux
uname -v = #1 Thu Nov 11 12:18:43 EST 2004

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = i686
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
hostinfo               = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin
PATH: /usr/bin/X11

## ----------- ##
## Core tests. ##
## ----------- ##

configure:1311: checking for g++
configure:1327: found /bin/g++
configure:1337: result: g++
configure:1353: checking for C++ compiler version
configure:1356: g++ --version </dev/null >&5
g++ (GCC) 3.4.3
Copyright (C) 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:1359: $? = 0
configure:1361: g++ -v </dev/null >&5
Reading specs from /bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/specs
Configured with: ../gcc-3.4.3/configure --prefix=/home/ersin/vorpo
--enable-shared --enable-languages=c,c++,objc --enable-clocale=gnu
--enable-__cxa_atexit --disable-libstdcxx-pch --enable-threads=posix
Thread model: posix
gcc version 3.4.3
configure:1364: $? = 0
configure:1366: g++ -V </dev/null >&5
g++: `-V' option must have argument
configure:1369: $? = 1
configure:1392: checking for C++ compiler default output file name
configure:1395: g++ -L/Programs/glibc-orig-2.3.4/lib   conftest.cc  >&5
/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld:
cannot find /home/ersin/vorpo/Programs/glibc-2.3.4/lib/libc.so.6
collect2: ld returned 1 exit status
configure:1398: $? = 1
configure: failed program was:
| /* confdefs.h.  */
|
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| /* end confdefs.h.  */
|
| int
| main ()
| {
|
|   ;
|   return 0;
| }
configure:1437: error: C++ compiler cannot create executables
See `config.log' for more details.

## ---------------- ##
## Cache variables. ##
## ---------------- ##

ac_cv_env_CC_set=
ac_cv_env_CC_value=
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_CXXFLAGS_set=set
ac_cv_env_CXXFLAGS_value=-L/Programs/glibc-orig-2.3.4/lib
ac_cv_env_CXX_set=
ac_cv_env_CXX_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_prog_ac_ct_CXX=g++

## ----------------- ##
## Output variables. ##
## ----------------- ##

CC=''
CFLAGS=''
CPP=''
CPPFLAGS=''
CXX='g++'
CXXFLAGS='-L/Programs/glibc-orig-2.3.4/lib'
DEFS=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EXEEXT=''
GROFF=''
HAVE_GROFF=''
INSTALL_DATA=''
INSTALL_PROGRAM=''
INSTALL_SCRIPT=''
LDFLAGS=''
LIBOBJS=''
LIBS=''
LTLIBOBJS=''
OBJEXT=''
PACKAGE_BUGREPORT=''
PACKAGE_NAME=''
PACKAGE_STRING=''
PACKAGE_TARNAME=''
PACKAGE_VERSION=''
PATH_SEPARATOR=':'
RANLIB=''
SH=''
SHELL='/bin/sh'
SOELIM=''
YACC=''
ac_ct_CC=''
ac_ct_CXX='g++'
ac_ct_RANLIB=''
bindir='${exec_prefix}/bin'
build_alias=''
datadir='${prefix}/share'
exec_prefix='NONE'
host_alias=''
includedir='${prefix}/include'
infodir='${prefix}/info'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localstatedir='${prefix}/var'
mandir='${prefix}/man'
oldincludedir='/usr/include'
prefix='/Programs/plasticfs-orig-1.9'
program_transform_name='s,x,x,'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
sysconfdir='${prefix}/etc'
target_alias=''

## ----------- ##
## confdefs.h. ##
## ----------- ##

#define PACKAGE_BUGREPORT ""
#define PACKAGE_NAME ""
#define PACKAGE_STRING ""
#define PACKAGE_TARNAME ""
#define PACKAGE_VERSION ""

configure: exit 77

All of my toolchain (gcc, g++, cc, as, ld, etc.) has been compiled
statically, so there are no missing dependencies.  I have _no_ idea
where the /home/ersin/vorpo/Programs/glibc-2.3.4/lib/libc.so.6 came
from, since the directory it should be looking in is
/home/ersin/vorpo/vorpo/Programs/glibc-orig-2.3.4/lib.  I checked out
all my environment variables, but nothing looks wrong.  Is there
something wrong with chroot?

I am running a Debian testing system (sid) with kernel 2.6.8.  My
shell is bash.  I'm compiling using gcc 3.4.3.

What am I missing?

Thanks,
Ersin


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