LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Lib path and compile (https://www.linuxquestions.org/questions/linux-software-2/lib-path-and-compile-222770/)

toolshed 08-26-2004 02:34 PM

Lib path and compile
 
I have kde installed at /opt/kde

I am installing a package kionjb-0.2.2-st and it wants kde libs.

When I create symbolic links from the /opt/kde/lib/library to /lib/library, the package will find the lib it wants.

How can I get the package to look in the /opt/kde/lib directory for these libs?

[root@tlinux: kionjb-0.2.2-st]$echo $LD_LIBRARY_PATH
/opt/kde/lib

I have all the libs it needs, it just cannot find them in that dir.

R /usr/lib -R /usr/X11R6/lib cache.lo mp3.lo njb.lo playlist.lo track.lo -lid -lkio -lnjb -lusb -lkio -lkdeui -lkdecore -lqt-mt -lz -lpng -lz -lm -lXext -lX11 -lSM -lICE -lpthread -lXext -lX11 -lid3 -lnjb -lusb


These are the kde libs it wants. I want a way to compile without creating symbolic links to them.
-lkio -lkdeui -lkdecore

Code:

# Begin /etc/ld.so.conf
/usr/local/lib
/opt/lib
/usr/X11R6/lib
/usr/lib
/opt/kde-3.2.2/lib
# End /etc/ld.so.conf


Andrew Benton 08-26-2004 02:56 PM

Edit /etc/ld.so.conf (if it doesn't exist, create it with a plain text editor like kedit or gedit) and add the line

/opt/kde/lib

Then run (as root) ldconfig

toolshed 08-26-2004 03:02 PM

I forgot to put in their that /opt/kde/lib is /opt/kde-3.2.2/lib.
/opt/kde is symbolic link to /opt/kde-3.2.2

I have ran ldconfig as well, so the cache is up to date.

This is the error i get for the libkio error: /usr/bin/ld: cannot find -lkio

Here is the ldconfig cache for that file:
[root@tlinux: lib]$ldconfig -p | grep libkio.so
libkio.so.4 (libc6) => /opt/kde-3.2.2/lib/libkio.so.4
libkio.so (libc6) => /opt/kde-3.2.2/lib/libkio.so
[root@tlinux: lib]$

A symbolic link from /opt/kde-3.2.2/lib/libkio.so to /lib/libkio.so solves it.

toolshed 08-26-2004 06:56 PM

bump

toolshed 08-27-2004 12:10 PM

I believe my path and libs are detected but it is the makefile that is the issue. Here is the makefile that is generated and you can see that the all kde dirs are found. However it does not use them for some reason. Well, if anyone has any ideas.

Code:

[root@tlinux: kionjb-0.2.2-st]$grep kde Makefile
ARTSCCONFIG = /opt/kde-3.2.2/bin/artsc-config
DCOPIDL = /opt/kde-3.2.2/bin/dcopidl
DCOPIDL2CPP = /opt/kde-3.2.2/bin/dcopidl2cpp
DCOPIDLNG = /opt/kde-3.2.2/bin/dcopidlng
KCONFIG_COMPILER = /opt/kde-3.2.2/bin/kconfig_compiler
KDECONFIG = /opt/kde-3.2.2/bin/kde-config
KDE_INCLUDES = -I/opt/kde-3.2.2/include
KDE_LDFLAGS = -L/opt/kde-3.2.2/lib
KDE_RPATH = -R $(kde_libraries) -R $(qt_libraries) -R $(x_libraries)
KDE_XSL_STYLESHEET = /opt/kde-3.2.2/share/apps/ksgmltools2/customization/kde-chu
nk.xsl
LIB_KDECORE = -lkdecore
LIB_KDEPIM = -lkdepim
LIB_KDEPRINT = -lkdeprint
LIB_KDEUI = -lkdeui
MCOPIDL = /opt/kde-3.2.2/bin/mcopidl
MEINPROC = /opt/kde-3.2.2/bin/meinproc
UIC = /usr/bin/uic -L $(kde_widgetdir) -nounload
all_includes = -I/opt/kde-3.2.2/include -I/usr/include/qt -I/usr/X11R6/include
all_libraries = -L/usr/X11R6/lib -L/usr/lib -L/opt/kde-3.2.2/lib
kde_appsdir = ${datadir}/applnk
kde_bindir = ${exec_prefix}/bin
kde_confdir = ${datadir}/config
kde_datadir = ${datadir}/apps
kde_htmldir = ${datadir}/doc/HTML
kde_icondir = ${datadir}/icons
kde_includes = /opt/kde-3.2.2/include
kde_kcfgdir = ${datadir}/config.kcfg
kde_libraries = /opt/kde-3.2.2/lib
kde_libs_htmldir = /opt/kde-3.2.2/share/doc/HTML
kde_libs_prefix = /opt/kde-3.2.2
kde_locale = ${datadir}/locale
kde_mimedir = ${datadir}/mimelnk
kde_moduledir = ${libdir}/kde3
kde_qtver = 3
kde_servicesdir = ${datadir}/services
kde_servicetypesdir = ${datadir}/servicetypes
kde_sounddir = ${datadir}/sounds
kde_styledir = ${libdir}/kde3/plugins/styles
kde_templatesdir = ${datadir}/templates
kde_wallpaperdir = ${datadir}/wallpapers
kde_widgetdir = /opt/kde-3.2.2/lib/kde3/plugins/designer
kdeinitdir = $(kde_moduledir)
prefix = /opt/kde-3.2.2
xdg_appsdir = ${datadir}/applications/kde
clean: kde-rpo-clean  clean-recursive
kde-rpo-clean:
[root@tlinux: kionjb-0.2.2-st]$



All times are GMT -5. The time now is 03:21 PM.