Coin.pc file is missing in /usr/lib/pkgconfig

Asked by gpunktet


hopefully I'm at the right corner here, but i searched the internet this day but didn't find any answer to it:

When installing the "libcoin60-dev" package in Ubuntu (mine i 64 bit Oneiric) no pkg-config file "Coin.pc" is provided under "/usr/lib/pkgconfig/". Is it possible to "install" a pkg-config file in with the package manager? This would spare me the time to install Coin manually...

Question information

English Edit question
Ubuntu coin3 Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :

Can you give the output of:

lsb_release -a; uname -a; dpkg -l | grep -i coin


Revision history for this message
mycae (mycae) said :

hi gpunktet,

Pkg-config are not always shipped with all libraries, such as is the case with COIN. This is unlikely to be resolved at any short notices -- you can post a bug, but its not likely that this will solve your problem within the timeframe you are interested in.

However, it sounds like you are trying to compile or develop something -- normally you can override the necessary flags using environment variables, or by modifying makefiles, or by passing the right info to configure, without the need to use pkg-config.

If you can give us more info, we may be able to provide some input.

Revision history for this message
gpunktet (kilian-grundl) said :

Hi there,

thank you for your fast answers. I'm always surprised how fast this works ...

output of
lsb_release -a; uname -a; dpkg -l | grep -i coin :

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 11.10
Release: 11.10
Codename: oneiric
Linux grundl-Latitude-E5420 3.0.0-14-generic #23-Ubuntu SMP Mon Nov 21 20:28:43 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
ii libcoin60 3.1.3-2 high-level 3D graphics kit implementing the Open Inventor API
ii libcoin60-dev 3.1.3-2 high-level 3D graphics devkit with Open Inventor and VRML97 support
ii libcoin60-doc 3.1.3-2 high-level 3D graphics kit with Open Inventor and VRML97 support

Yes indeed, I modified the as the project uses GNU-Autotools:

Old-Version (works fine with pkg-config...):

New-version (works fine with pkg-config and if the command-line tool coin-config exists - as far as I can tell):
test=$(coin-config --cflags --cppflags --cxxflags)
COIN_CFLAGS=$(echo $test)
test=$(coin-config --libs --ldflags)
COIN_LIBS=$(echo $test)

The problem is, that the configure-script doesn't return an error, if the command line tool coin-config doesn't exist. Well probably this isn't the right place to ask this question, but maybe one of you can give me a hint (at least to a better forum?):
Is it possible to use any Autoconf-Macros to test, whether this program is available? And is this way of doing it the "correct" way?

Revision history for this message
gpunktet (kilian-grundl) said :

btw: Is it possible some how to format the output of commands or a commands itself in another way as the rest of the text?

Revision history for this message
mycae (mycae) said :

I would recommend using pkg-config as a fallback, rather than a primary -- this is how most autotools scripts run things.

The classic way to do this is to use AC_CHECK_HEADERS and AC_CHECK_LIB, to compile a test program. You might previously set the libs to use a few common linker flags, like in this case, -lcoin60 (assuming is the soname, which by convention is the same as the library filename).


                AC_DEFINE_UNQUOTED(HAVE_COIN,1,[Define if you have the COIN library])],
                [AC_MSG_ERROR(Error: COIN library not available - no libcoin.)])

you may also want to use AC_ARG_WITH to allow users to pass in something like


Can you help with this problem?

Provide an answer of your own, or ask gpunktet for more information if necessary.

To post a message you must log in.