Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.development.apps > #332

Re: Linking problem

From Kevin Nathan <knathan@project54.com>
Newsgroups comp.os.linux.development.apps
Subject Re: Linking problem
Date 2011-12-15 23:42 -0700
Message-ID <20111215234243.40f9ed06@efreet.linux> (permalink)
References <20111215001104.13eda1b8@efreet.linux> <8762himaw3.fsf@sapphire.mobileactivedefense.com> <20111215162948.60b95d1c@efreet.linux> <874nx17375.fsf@sapphire.mobileactivedefense.com>

Show all headers | View raw


On Fri, 16 Dec 2011 00:47:10 +0000
Rainer Weikusat <rweikusat@mssgmbh.com> wrote:

>Forget --sysroot. You need to add your include directories with -I,
>add your library directories with -L and add them again with -Wl,-R
>and that's it. If the binaries are still linked against system
>libraries you don't want, something is still missing in your custom
>library directory.

That was the ticket! I am 99% there, now. By using this:

export LDFLAGS=" -Wl,-R /home/username/progroot/lib/
-Wl,-R /home/username/progroot/usr/lib/
-Wl,-R /home/username/progroot/usr/lib/mysql/
-Wl,-R /home/username/progroot/opt/kde3/lib/
-Wl,-R /home/username/progroot/usr/lib/qt3/lib/ "

all the libs listed in "ldd program" are properly pointed to my local
libs locations. However, I still have one lib that will not get the
local subdir: /lib/ld-linux.so.2 (the dynamic loader). This lib is
in ../progroot/usr/lib/ and I don't know why it still insists on
using /lib/. On kernel 2.3.3 this results in a seg fault (compiled on
2.6.1). I guess I will probably have to look at statically linking...

Thanks for all of your help, Rainer, I really do appreciate it!


-- 
Kevin Nathan (Arizona, USA)  
Linux Potpourri -- http://www.project54.com/linux/

Open standards. Open source. Open minds. 
The command line is the front line.
Linux 2.6.37.6-0.9-desktop
 22:39pm  up 5 days  9:48,  13 users,  load average: 0.08, 0.13, 0.28

Back to comp.os.linux.development.apps | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Linking problem Kevin Nathan <knathan@project54.com> - 2011-12-15 00:11 -0700
  Re: Linking problem Rainer Weikusat <rweikusat@mssgmbh.com> - 2011-12-15 09:39 +0000
    Re: Linking problem Kevin Nathan <knathan@project54.com> - 2011-12-15 16:29 -0700
      Re: Linking problem Rainer Weikusat <rweikusat@mssgmbh.com> - 2011-12-16 00:47 +0000
        Re: Linking problem Kevin Nathan <knathan@project54.com> - 2011-12-15 23:42 -0700
          Re: Linking problem Rainer Weikusat <rweikusat@mssgmbh.com> - 2011-12-16 17:46 +0000
            Re: Linking problem Kevin Nathan <knathan@project54.com> - 2011-12-16 10:55 -0700
            Re: Linking problem Kevin Nathan <knathan@project54.com> - 2012-01-01 10:49 -0700
          Re: Linking problem Lusotec <nomail@nomail.not> - 2011-12-19 00:27 +0000
            Re: Linking problem Kevin Nathan <knathan@project54.com> - 2011-12-19 10:16 -0700

csiph-web