Forums » Ryzom Game on GNU/Linux »
/usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges
Added by shackra almost 3 years ago
Hello!
I was updating ryzom for Parabola GNU/Linux, I compiled first the NeL package (ryzom-nel) and then (using the new ryzom-nel) I tried to compile Ryzom Game (ryzom-client) but I got this "funny" error from ld
[ 30%] Building CXX object ryzom/common/src/game_share/CMakeFiles/ryzom_gameshare.dir/time_weather_season/weather_manager.cpp.o Linking CXX shared library ../../../../lib/libryzom_gameshare.so /usr/bin/ld: cannot find -lnelmisc /usr/bin/ld: cannot find -lnelnet /usr/bin/ld: cannot find -lnelligo /usr/bin/ld: cannot find -lnelgeorges collect2: error: ld returned 1 exit status make[2]: *** [lib/libryzom_gameshare.so.0.8.0] Error 1 make[1]: *** [ryzom/common/src/game_share/CMakeFiles/ryzom_gameshare.dir/all] Error 2 make: *** [all] Error 2 ==> ERROR: A failure occurred in build() Aborting...
I'm not sure why that happened, I didn't change anything related to cmake command on my ryzom-nel PKGBUILD nor in my ryzom-client PKGBUILD. Besides that, there is all the files under /usr/lib/nel/:
ryzom-nel-hg /usr/lib/nel/libnel3d.so ryzom-nel-hg /usr/lib/nel/libnel3d.so.0 ryzom-nel-hg /usr/lib/nel/libnel3d.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnel_drv_openal.so ryzom-nel-hg /usr/lib/nel/libnel_drv_opengl.so ryzom-nel-hg /usr/lib/nel/libnelgeorges.so ryzom-nel-hg /usr/lib/nel/libnelgeorges.so.0 ryzom-nel-hg /usr/lib/nel/libnelgeorges.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelligo.so ryzom-nel-hg /usr/lib/nel/libnelligo.so.0 ryzom-nel-hg /usr/lib/nel/libnelligo.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnellogic.so ryzom-nel-hg /usr/lib/nel/libnellogic.so.0 ryzom-nel-hg /usr/lib/nel/libnellogic.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelmisc.so ryzom-nel-hg /usr/lib/nel/libnelmisc.so.0 ryzom-nel-hg /usr/lib/nel/libnelmisc.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelnet.so ryzom-nel-hg /usr/lib/nel/libnelnet.so.0 ryzom-nel-hg /usr/lib/nel/libnelnet.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelpacs.so ryzom-nel-hg /usr/lib/nel/libnelpacs.so.0 ryzom-nel-hg /usr/lib/nel/libnelpacs.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelsnd_lowlevel.so ryzom-nel-hg /usr/lib/nel/libnelsnd_lowlevel.so.0 ryzom-nel-hg /usr/lib/nel/libnelsnd_lowlevel.so.0.8.0 ryzom-nel-hg /usr/lib/nel/libnelsound.so ryzom-nel-hg /usr/lib/nel/libnelsound.so.0 ryzom-nel-hg /usr/lib/nel/libnelsound.so.0.8.0
Best regards!
ryzom-client-hg-02102012-8-x86_64-build.log - Ryzom-client building logs (49.9 kB)
PKGBUILD - ryzom-client PKGBUILD (1.6 kB)
PKGBUILD - ryzom-nel PKGBUILD (1.6 kB)
Replies (7)
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by kervala almost 3 years ago
Perhaps should you run ldconfig -p | grep libnel to check that libnel is findable by ld :)
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by kervala almost 3 years ago
Hum, I wonder if that's normal for CMake to use -lnelmisc... It should use a relative path such as : ../../../../lib/libnelmisc.so because libnelmisc.so is not yet installed and is built in the same project.
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by shackra almost 3 years ago
kervala wrote:
Perhaps should you run ldconfig -p | grep libnel to check that libnel is findable by ld :)
Amazing, it isn't findable by ld!!
jorge@Abril:~$ ldconfig -p | grep nel libpanelw.so.5 (libc6,x86-64) => /lib/libpanelw.so.5 libpanelw.so.5 (libc6) => /usr/lib32/libpanelw.so.5 libpanelw.so (libc6,x86-64) => /lib/libpanelw.so libpanelw.so (libc6) => /usr/lib32/libpanelw.so libpanel-applet-4.so.0 (libc6,x86-64) => /lib/libpanel-applet-4.so.0 libpanel-applet-4.so (libc6,x86-64) => /lib/libpanel-applet-4.so jorge@Abril:~$
This looks like a solution for the problem
jorge@Abril:~$ sudo ldconfig /usr/lib/nel/
and vóilà!
jorge@Abril:~$ ldconfig -p | grep nel libpanelw.so.5 (libc6,x86-64) => /lib/libpanelw.so.5 libpanelw.so.5 (libc6) => /usr/lib32/libpanelw.so.5 libpanelw.so (libc6,x86-64) => /lib/libpanelw.so libpanelw.so (libc6) => /usr/lib32/libpanelw.so libpanel-applet-4.so.0 (libc6,x86-64) => /lib/libpanel-applet-4.so.0 libpanel-applet-4.so (libc6,x86-64) => /lib/libpanel-applet-4.so libnel3d.so.0 (libc6,x86-64) => /usr/lib/nel/libnel3d.so.0 libnel3d.so (libc6,x86-64) => /usr/lib/nel/libnel3d.so libnelsound.so.0 (libc6,x86-64) => /usr/lib/nel/libnelsound.so.0 libnelsound.so (libc6,x86-64) => /usr/lib/nel/libnelsound.so libnelsnd_lowlevel.so.0 (libc6,x86-64) => /usr/lib/nel/libnelsnd_lowlevel.so.0 libnelsnd_lowlevel.so (libc6,x86-64) => /usr/lib/nel/libnelsnd_lowlevel.so libnelpacs.so.0 (libc6,x86-64) => /usr/lib/nel/libnelpacs.so.0 libnelpacs.so (libc6,x86-64) => /usr/lib/nel/libnelpacs.so libnelnet.so.0 (libc6,x86-64) => /usr/lib/nel/libnelnet.so.0 libnelnet.so (libc6,x86-64) => /usr/lib/nel/libnelnet.so libnelmisc.so.0 (libc6,x86-64) => /usr/lib/nel/libnelmisc.so.0 libnelmisc.so (libc6,x86-64) => /usr/lib/nel/libnelmisc.so libnellogic.so.0 (libc6,x86-64) => /usr/lib/nel/libnellogic.so.0 libnellogic.so (libc6,x86-64) => /usr/lib/nel/libnellogic.so libnelligo.so.0 (libc6,x86-64) => /usr/lib/nel/libnelligo.so.0 libnelligo.so (libc6,x86-64) => /usr/lib/nel/libnelligo.so libnelgeorges.so.0 (libc6,x86-64) => /usr/lib/nel/libnelgeorges.so.0 libnelgeorges.so (libc6,x86-64) => /usr/lib/nel/libnelgeorges.so libnel_drv_opengl.so (libc6,x86-64) => /usr/lib/nel/libnel_drv_opengl.so libnel_drv_openal.so (libc6,x86-64) => /usr/lib/nel/libnel_drv_openal.so jorge@Abril:~$
Time to add some postinstall instructions to ryzom-nel, though!
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by kervala almost 3 years ago
I just noticed something with your configuration, you shouldn't install NeL libs in /usr/lib/nel/ it's reserved for plugins (= NeL drivers), NeL libs should go in /usr/lib or /usr/lib/i386-linux-gnu (/usr/lib/x86_64-linux-gnu for 64bits) for MultiArch.
In your NeL PKGBUILD :
cmake .. -Wno-dev -DWITH_RYZOM=OFF -DWITH_NEL_TESTS=OFF -DWITH_NEL=ON -DCMAKE_INSTALL_PREFIX=/usr -DNL_ETC_PREFIX=/etc/nel -DNL_DRIVER_PREFIX=/usr/lib/nel -DNL_SHARE_PREFIX=/usr/share/nel -DNL_BIN_PREFIX=/usr/bin -DNL_SBIN_PREFIX=/usr/sbin -DNL_LIB_PREFIX=/usr/lib/nel -DNL_DRIVER_PREFIX=/usr/lib/nel
-DNL_DRIVER_PREFIX=/usr/lib/nel is defined two times
-DNL_LIB_PREFIX=/usr/lib/nel is wrong, it should be -DNL_LIB_PREFIX=/usr/lib or better don't define it at all because CMAKE_INSTALL_PREFIX is right :)
-DNL_BIN_PREFIX=/usr/bin and -DNL_SBIN_PREFIX=/usr/sbin don't need to be defined neither :)
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by shackra almost 3 years ago
kervala wrote:
I just noticed something with your configuration, you shouldn't install NeL libs in /usr/lib/nel/ it's reserved for plugins (= NeL drivers), NeL libs should go in /usr/lib or /usr/lib/i386-linux-gnu (/usr/lib/x86_64-linux-gnu for 64bits) for MultiArch.
In your NeL PKGBUILD :
cmake .. -Wno-dev -DWITH_RYZOM=OFF -DWITH_NEL_TESTS=OFF -DWITH_NEL=ON -DCMAKE_INSTALL_PREFIX=/usr -DNL_ETC_PREFIX=/etc/nel -DNL_DRIVER_PREFIX=/usr/lib/nel -DNL_SHARE_PREFIX=/usr/share/nel -DNL_BIN_PREFIX=/usr/bin -DNL_SBIN_PREFIX=/usr/sbin -DNL_LIB_PREFIX=/usr/lib/nel -DNL_DRIVER_PREFIX=/usr/lib/nel
-DNL_DRIVER_PREFIX=/usr/lib/nel is defined two times
-DNL_LIB_PREFIX=/usr/lib/nel is wrong, it should be -DNL_LIB_PREFIX=/usr/lib or better don't define it at all because CMAKE_INSTALL_PREFIX is right :)
-DNL_BIN_PREFIX=/usr/bin and -DNL_SBIN_PREFIX=/usr/sbin don't need to be defined neither :)
Oops! Ok!
but, what about -DNL_SHARE_PREFIX=/usr/share/nel ? Should I remove it?
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by kervala almost 3 years ago
shackra wrote:
but, what about -DNL_SHARE_PREFIX=/usr/share/nel ? Should I remove it?
Yes, sorry I forgot to mention it in my previous post :)
And even NL_DRIVER_PREFIX can be removed, the default values are just wrong for CMAKE_INSTALL_PREFIX and NL_ETC_PREFIX respectively set to /usr/local and etc/nel
When values are a relative path, CMAKE_INSTALL_PREFIX is prepended to them, so etc/nel become /usr/local/etc/nel if CMAKE_INSTALL_PREFIX is not defined and if it's defined to /usr, etc/nel will become /usr/etc/nel
RE: /usr/bin/ld: cannot find -lnelmisc -lnelnet -lnelligo -lnelgeorges - Added by shackra almost 3 years ago
fixed :)
(1-7/7)