Sponsored Content
Full Discussion: unix Library path variables.
Top Forums Shell Programming and Scripting unix Library path variables. Post 302533630 by anilcliff on Friday 24th of June 2011 09:28:06 AM
Old 06-24-2011
Thank you.

I compiled libogg-1.2.2 with ./configure --prefix=/usr/local/myapps --with-pic
It got installed fine.
Code:
[root@ffmpeg src]# ll //usr/local/myapps/lib/libogg.*
-rw-r--r-- 1 root root 75792 Jun 24 09:05 //usr/local/myapps/lib/libogg.a
-rwxr-xr-x 1 root root   935 Jun 24 09:05 //usr/local/myapps/lib/libogg.la
lrwxrwxrwx 1 root root    15 Jun 24 09:05 //usr/local/myapps/lib/libogg.so -> libogg.so.0.7.1
lrwxrwxrwx 1 root root    15 Jun 24 09:05 //usr/local/myapps/lib/libogg.so.0 -> libogg.so.0.7.1
-rwxr-xr-x 1 root root 58396 Jun 24 09:05 //usr/local/myapps/lib/libogg.so.0.7.1

Code:
[root@ffmpeg src]# ll /usr/local/myapps/include/ogg/*
-rw-r--r-- 1 root root  500 Jun 24 09:05 //usr/local/myapps/include/ogg/config_types.h
-rw-r--r-- 1 root root 8347 Jun 24 09:05 /usr/local/myapps/include/ogg/ogg.h
-rw-r--r-- 1 root root 4275 Jun 24 09:05 /usr/local/myapps/include/ogg/os_types.h

Then I typed the following
Code:
[root@ffmpeg /]# LDFLAGS=-L/usr/local/myapps
[root@ffmpeg /]# export  LDFLAGS
[root@ffmpeg /]# echo $LDFLAGS
-L/usr/local/myapps

Then compile libvorbis with ./configure --prefix=/usr
It needs libogg.so and it is not checking the /usr/local/myapps dir for the libraries. It checks /usr/lib or /usr/lib64. I am not sure. How to make it check /usr/local/myapps by default? See the error below.
Code:
checking for OGG... no
checking for Ogg... no
*** Could not run Ogg test program, checking why...
*** The test program failed to compile or link. See the file config.log for the
*** exact error that occured. This usually means Ogg was incorrectly installed
*** or that you have moved Ogg since it was installed.
configure: error: must have Ogg installed!

I should say the .pc file of libogg has got the details. But all packages dont make .pc files.
Code:
[root@ffmpeg  / ]# cat  //usr/local/myapps/lib/pkgconfig/ogg.pc
# ogg pkg-config file

prefix=/usr/local/myapps
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: ogg
Description: ogg is a library for manipulating ogg bitstreams
Version: 1.2.2
Requires:
Conflicts:
Libs: -L${libdir} -logg
Cflags: -I${includedir}

When I issue the following commands, libvorbis configure script will not throw error.
Code:
[root@ffmpeg /]# PKG_CONFIG_PATH=/usr/local/myapps/lib/pkgconfig
[root@ffmpeg /]# export PKG_CONFIG_PATH

I need the configure script check /usr/local/myapps/lib without using PKG_CONFIG_PATH variable.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

library path

How do you get an application to use an alternate library? Dave:confused: (2 Replies)
Discussion started by: nucca
2 Replies

2. HP-UX

removing library path

Hi Everyone I have written an installer dependant on several shared libraries. I am attempting to strip the full path from these dependant libraries using the chatr command via a script file but am having no success. Running ldd on the intaller exe fails with the following error. Cant open... (4 Replies)
Discussion started by: C3000
4 Replies

3. Shell Programming and Scripting

Setting path for a stand alone library in home directory

Hi all, This is probably a basic question. I had installed a stand-alone library called szip in my home directory, as I don't have the necessary root permission. I tried to set an environment for both include and lib files in my .cshrc script as setenv /home/szip/lib setenv... (3 Replies)
Discussion started by: alamcheril
3 Replies

4. UNIX for Advanced & Expert Users

library path in linux

Is there something which is an alternative to the variable LD_LIBRARY_PATH? The behaviour of this variable is that the path specified here will be checked before checking usual paths. But I want to have some folders checked for shared libraries after the usual paths. i.e usual paths have to... (3 Replies)
Discussion started by: bbala
3 Replies

5. Shell Programming and Scripting

Library on Remote machine or $PATH is not working..

I don't know how to put this. However here is the problem. While executing command remotely on a Unix machine i get an error /usr/lib/hpux32/dld.so: Unable to find library 'libxerces-c.sl.21'. However when i execute the command on the remote machine locally. it works fine. Also i have... (2 Replies)
Discussion started by: suraj.sheikh
2 Replies

6. UNIX for Advanced & Expert Users

Can't find path for shared library: libintl.sl

Hello, Any inputs about this one? /usr/lib/dld.sl: Can't find path for shared library: libintl.sl /usr/lib/dld.sl: No such file or directory : Core file for 32-bit PA-RISC application : /tmp/usr/local/bin/git saved to /etc/core.git. ABORT instruction (core dumped) bash-4.0# echo... (3 Replies)
Discussion started by: SystemAddict
3 Replies

7. Programming

C++ library path

Hello, How to set up the path for downloaded C/C++ libraries (or, header files) so that they can be included like system headers (stdio.h or iostream)? The libraries/headers are from a package containing different folders each has different sets of headers and put in... (1 Reply)
Discussion started by: yifangt
1 Replies

8. AIX

Embedding Runtime Search Path into Library on AIX

My product has 2 libraries say "x & y". x depends on y. During the installation of my products package, user will be prompted for his own location to copy my product libraries. Installation will copy libraries "x & y" and create my product specific ENV variable say "MYPATH" pointing to User... (4 Replies)
Discussion started by: erra_krishna
4 Replies

9. Programming

Library/header path for ./configure

Hello, I am always confused about adding library path for ./configure when compiling software under Linux Debian based OS. For example the README of the software tells --with-boost=PATH specify directory for the boost header files --with-mpi=PATH specify prefix directory for... (4 Replies)
Discussion started by: yifangt
4 Replies

10. AIX

AIX full path to socket library

Can somebody help me too identify full path to socket library on AIX? Cannot find anything Thanks for contribution (2 Replies)
Discussion started by: digioleg54
2 Replies
All times are GMT -4. The time now is 03:11 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy