LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-14-2019, 04:31 AM   #1
Pippin_89
LQ Newbie
 
Registered: Jul 2019
Location: Ireland
Distribution: Bodhi Linux 5.0.0
Posts: 7

Rep: Reputation: Disabled
Question Library pkg file (.pc) exists but is not found


Hello all,

I'm currenty installing the libraries required to compile FFADO. Their readme lists the following libraries as required:

libraw1394 (>= 2.0.7), https://ieee1394.wiki.kernel.org/
libiec61883 (>= 1.1.0), https://ieee1394.wiki.kernel.org/
dbus-1 (>= 1.0), http://dbus.freedesktop.org
dbus-c++ (>= 0), http://sourceforge.net/apps/mediawiki/dbus-cplusplus/
libconfig (>= 0), http://www.hyperrealm.com/libconfig/

The steps I took in terminal to install the first one:

1. tar xvf libraw1394-2.1.2.tar.gz
2. cd libraw1394-2.1.2/
3. ./configure

This completed without errors. When I tried to repeat these steps for the second one, the process ended on:
checking for LIBRAW1394... configure: error: package requirements (libraw1394 >= 1.2.1 were not met:
No package 'libraw1394' found
Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix.
Alternatively, you may set the environment variables LIBRAW1394_CFLAGS and LIBRAW1394_LIBS to avoid the need to call pkg_config.

I then ran the following to confirm from pkg_config perspective:
pkg-config --exists 'libraw1394' --print-errors
This returned:
Package libraw1394 was not found in the pkg-config search path

I then did a system wide search like this:
sudo find / -name libraw1394.pc
This returned:
/home/pippin/libraw1394-2.1.2/libraw1394.pc (the first location I installed to, more or less by mistake)
find: '/run/user/1000/gvfs': Permission denied
/usr/lib/libraw1394-2.1.2/libraw1394.pc (the proper location)

So: according to search the .pc file is there, but pkg-config says it doesn't exist.

What should be the next step? Please note I have not tried rebooting yet at this stage.

Thanks!
 
Old 07-14-2019, 06:05 AM   #2
ehartman
Member
 
Registered: Jul 2007
Location: Delft, The Netherlands
Distribution: Slackware
Posts: 672

Rep: Reputation: 317Reputation: 317Reputation: 317Reputation: 317
Edit: addi
Quote:
Originally Posted by Pippin_89 View Post
/usr/lib/libraw1394-2.1.2/libraw1394.pc (the proper location)

So: according to search the .pc file is there, but pkg-config says it doesn't exist.
As far as I know (and in my distribution) the proper location for .pc files should be /usr/lib/pkgconfig and it should point to (contain the path of) where you installed the .so file. This is my libraw1394.pc
Code:
prefix=/usr
exec_prefix=${prefix}
libdir=/usr/lib
includedir=${prefix}/include

Name: libraw1394
Description: Interface library for the Linux IEEE1394 drivers.
Version: 2.1.2
Libs: -L${libdir} -lraw1394
Cflags: -I${includedir}
and you'll see it points to /usr/lib and /usr/include, no libraw1394-2.1.2 subdirectory.

Edit: furthermore, after
3. ./configure
you normally have to do
4. make # to create the binaries (libraries and/or kernel modules)
and
5. make install # to install them under the right "prefix".

The prefix is normally specified through the --prefix= option to the configure script, if not given it normally defaults to either /usr (as in the .pc script above) or /usr/local
(so then the .so goes into /usr/local/lib and the include files into /usr/local/include).
The pkg file is adjusted TO your specified prefix, that's why it is a variable in that .pc file.
BTW: for a 64-bit system the lib dir mostly is /usr/lib64, the include directory stays the same.

Last edited by ehartman; 07-14-2019 at 08:54 AM. Reason: addition about make
 
2 members found this post helpful.
Old 07-14-2019, 04:20 PM   #3
Pippin_89
LQ Newbie
 
Registered: Jul 2019
Location: Ireland
Distribution: Bodhi Linux 5.0.0
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ehartman View Post
after
3. ./configure
you normally have to do
4. make # to create the binaries (libraries and/or kernel modules)
and
5. make install # to install them under the right "prefix".
This seems to have sorted it out - I didn't realise further steps were necessary after ./configure. Learning by doing over here

I ran ./configure and then "make" and "sudo make install" (after "make install" failed with an authorisation error) in the first dir, then ran them in the 2nd dir and got no errors. I might go and clean up the .pc files that ended up in the wrong place but they don't seem to be generating any errors.

Thanks for your help!
 
Old 07-14-2019, 05:40 PM   #4
scasey
Senior Member
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.6
Posts: 3,215

Rep: Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104Reputation: 1104
Aside: Usually the untarred directory will contain a README and/or INSTALL file. Itís a good idea to read them before attempting the actual compilation/installation...
 
1 members found this post helpful.
  


Reply

Tags
library, pkg-config


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] pkg-config --exists fails but --list-all lists the package c0uchm0nster Linux - Software 2 01-10-2016 07:47 PM
directory exists but no such directory exists yumito Linux - Newbie 3 06-09-2013 02:02 AM
ldd reports shared library missing, but library exists on disk athv_gr Linux - Newbie 7 05-13-2009 12:31 PM
SIOCADDRT: File exists SIOCCADDRT: File Exists Failed to bring up eth0. opsraja Linux - Networking 0 01-10-2005 08:29 AM
Shared Library not found but exists as symlink davoman Slackware 2 04-11-2004 05:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:31 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration