Fix version & requires fields in pkg config files

Details:
 - When building with CMake, pkg-config files flac.pc and flac++.pc
   are not updated with Version information. This causes a failure
   when running a configure script in opus-tools
   (https://github.com/xiph/opus-tools).

   Note that OGG_PACKAGE is set to "ogg" exactly as in the configure.ac,
   but it is only set when the building explicitly with libogg.
This commit is contained in:
TGMarkiewicz 2021-05-26 18:17:06 +02:00 committed by Ralph Giles
parent a9557c13fa
commit 1ac2a6314b
1 changed files with 3 additions and 0 deletions

View File

@ -22,8 +22,11 @@ option(INSTALL_PKGCONFIG_MODULES "Install PkgConfig modules" ON)
option(INSTALL_CMAKE_CONFIG_MODULE "Install CMake package-config module" ON)
option(WITH_OGG "ogg support (default: test for libogg)" ON)
set(VERSION ${PROJECT_VERSION})
if(WITH_OGG)
find_package(Ogg REQUIRED)
set(OGG_PACKAGE "ogg")
endif()
find_package(Iconv)