저는 Ubuntu를 처음 사용하고 있으며 Amazon EC2 클라우드에서 Ubuntu를 실행 중입니다.우분투 EC2 인스턴스에서 libdl.so를 찾을 수 없습니다.
나는 우분투 상자 (i386
및 amd64
)에 cppunit
를 컴파일하려고하고 libdl.so
이 존재하고 올바른으로는 이해가 안 이제 libdl
g++ -g -O2 -o .libs/DllPlugInTester DllPlugInTester.o CommandLineParser.o -ldl ../../src/cppunit/.libs/libcppunit.so -lm -Wl,--rpath -Wl,/home/ubuntu/cppunit/lib
../../src/cppunit/.libs/libcppunit.so: undefined reference to `dlsym'
../../src/cppunit/.libs/libcppunit.so: undefined reference to `dlopen'
../../src/cppunit/.libs/libcppunit.so: undefined reference to `dlclose'
에 연결되지 않습니다
[email protected]:~/cppunit$ whereis libdl
libdl:
:
[email protected]:~/cppunit$ ls /lib/i386-linux-gnu/libdl*
/lib/i386-linux-gnu/libdl-2.15.so /lib/i386-linux-gnu/libdl.so.2
그러나 whereis
는 아무 상관이 없다
libc6
가 설치됩니다
[email protected]:~/cppunit$ sudo apt-get install libc6
Reading package lists... Done
Building dependency tree
Reading state information... Done
libc6 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
가 왜 내 빌드를 찾을 수 없습니다?
uname -r
는 "일반"3.2.0-25-virtual
입니다 페도라에whereis
은 다음과 같습니다
[matt cppunit] whereis libdl
libdl: /lib/libdl.so /usr/lib/libdl.so /lib64/libdl.so /usr/lib64/libdl.so
어떤 아이디어?
편집 : 내 /etc/ld.so.conf.d/*.conf
이 합리적인 것 같다
[email protected]:~$ cat /etc/ld.so.conf.d/*.conf
/usr/lib/i386-linux-gnu/mesa
# Multiarch support
/lib/i386-linux-gnu
/usr/lib/i386-linux-gnu
/lib/i686-linux-gnu
/usr/lib/i686-linux-gnu
# libc default configuration
/usr/local/lib
# This directive teaches ldconfig to search in nosegneg subdirectories
# and cache the DSOs there with extra bit 1 set in their hwcap match
# fields. In Xen guest kernels, the vDSO tells the dynamic linker to
# search in nosegneg subdirectories and to match this extra hwcap bit
# in the ld.so.cache file.
hwcap 1 nosegneg
이것은 정확히 우리가 발견 한 것입니다. 32 비트에서 작동하지만 64 비트에서 작동한다는 것은 매우 이상합니다. –