fmang / opustags

Ogg Opus tags editor
BSD 3-Clause "New" or "Revised" License
75 stars 10 forks source link

No package 'ogg' found #22

Closed sebma closed 5 years ago

sebma commented 5 years ago

Hi,

I installed both libogg0 and libogg-dev but still ccmake says :

-- Checking for module 'ogg'
--   No package 'ogg' found
CMake Error at /usr/local/miniconda3/lib/python3.6/site-packages/cmake/data/share/cmake-3.13/Modules/FindPkgConfig.cmake:452 (message):
  A required package was not found
Call Stack (most recent call first):
  /usr/local/miniconda3/lib/python3.6/site-packages/cmake/data/share/cmake-3.13/Modules/FindPkgConfig.cmake:622 (_pkg_check_modules_internal)
  CMakeLists.txt:13 (pkg_check_modules)

-- Configuring incomplete, errors occurred!
See also "/home/xyztabcd/src/opustags/build/CMakeFiles/CMakeOutput.log".
fmang commented 5 years ago

What package manager did you use to install libogg-dev, and what distribution are you using? If you've installed libogg through conda, make sure you're using conda's pkg-config too.

You can run pkg-config --libs ogg to see if pkg-config sees your installed libogg or not, it should print -logg.

sebma commented 5 years ago

Hi, I'm using Ubuntu and the apt/deb package manager.

dpkg sees the ogg libs intalled :

$ dpkg -l | egrep "libogg"
ii  libogg-dev:amd64                                                  1.3.1-1ubuntu1                                       amd64        Ogg bitstream library development files
ii  libogg0:amd64                                                     1.3.1-1ubuntu1                                       amd64        Ogg bitstream library
ii  libogg0:i386                                                      1.3.1-1ubuntu1                                       i386         Ogg bitstream library
ii  liboggz2                                                          1.1.1-2ubuntu1                                       amd64        convenience interface for Ogg stream I/O

but pkg-config does not :

$ pkg-config --libs ogg
Package ogg was not found in the pkg-config search path.
Perhaps you should add the directory containing `ogg.pc'
to the PKG_CONFIG_PATH environment variable
No package 'ogg' found
fmang commented 5 years ago

According to the package file list, ogg.pc is installed as /usr/lib/x86_64-linux-gnu/pkgconfig/ogg.pc. Could you confirm it's there?

If it is, try the following:

export PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig
pkg-config --libs ogg
# if that works, running cmake in the opustags directory would work too

Out of curiosity, could you show me the output of which pkg-config?

sebma commented 5 years ago

You're right, I was calling the wrong pkg-config :

$ which -a pkg-config
/home/xyztabcd/.linuxbrew/bin/pkg-config
/usr/bin/pkg-config
$ export PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig
$ pkg-config --libs ogg
-L/usr/lib/x86_64-linux-gnu -logg
$ cmake -D CMAKE_INSTALL_PREFIX=/usr/local ..
-- Checking for module 'ogg'
--   Found ogg, version 1.3.1
-- Configuring done
-- Generating done
-- Build files have been written to: /home/xyztabcd/src/opustags/build
$ echo $?
0

Thanks a lot :-)

Now I have another pb. with sudo make install but I'll create another issue and close this one.