Open MPI logo

Hardware Locality Development Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Hardware Locality Development mailing list

Subject: Re: [hwloc-devel] [hwloc-users] hwloc and rpath
From: Samuel Thibault (samuel.thibault_at_[hidden])
Date: 2010-06-21 19:26:23


Hello,

Jirka Hladky, le Mon 21 Jun 2010 18:54:47 +0200, a écrit :
> I don't have "/usr/lib64" directory listed in
> /etc/ld.so.conf. However, "/usr/lib64" is considered to be the
> default lib location on 64-bit system.

Ok. And libtool doesn't seem to add it by itself. I believe that's
where the problem resides.

> 1) Add /usr/lib64 into /etc/ld.so.conf. It works like a charm.

Ok.

> The problem is that I cannot use this change in the build environment
> (on a cluster of build servers for compilation on different
> architectures)

Sure. On the long term I wouldn't recommend adding it anyway: it's
already being looked for by the linker.

> Samuel, do you have "/usr/lib64" directory listed in /etc/ld.so.conf listed on
> your 64-bit Debian?

No. Debian does not have a /usr/lib64 directory, 64bit versions are in
/usr/lib. For biarch system, /usr/lib/x86_64-linux-gnu will be used.

> 2) Second approach is to add
> sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
> sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
> into the %configure stage in rpm specs.

Well, the real fix seems to me to fix

sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"

into

sys_lib_dlsearch_path_spec="/lib /usr/lib /usr/lib64 $lt_ld_extra"

on Fedora systems.

> James, any feedback on it? I'm not sure if I should blame libtool or just open
> BZ to add "/usr/lib64" into /etc/ld.so.conf.

I believe in the current state of Fedora it's libtool that should be
blamed. Or Fedora and libtool should talk to each other to determine
how libtool is supposed to discover that /usr/lib64 is in the standard
research path.

Samuel