Module: kamailio Branch: master Commit: 8ebae54cff261b95fcece3be3719da511cc35084 URL: https://github.com/kamailio/kamailio/commit/8ebae54cff261b95fcece3be3719da511cc35084
Author: Xenofon Karamanos <x...@gilawa.com> Committer: Xenofon Karamanos <x...@gilawa.com> Date: 2025-01-29T10:07:24Z cmake: Use pkg-config instead for json-c dev package. --- Modified: src/modules/nsq/CMakeLists.txt --- Diff: https://github.com/kamailio/kamailio/commit/8ebae54cff261b95fcece3be3719da511cc35084.diff Patch: https://github.com/kamailio/kamailio/commit/8ebae54cff261b95fcece3be3719da511cc35084.patch --- diff --git a/src/modules/nsq/CMakeLists.txt b/src/modules/nsq/CMakeLists.txt index b4a482c2a47..e6acfa9a2f7 100644 --- a/src/modules/nsq/CMakeLists.txt +++ b/src/modules/nsq/CMakeLists.txt @@ -4,13 +4,19 @@ add_library(${module_name} SHARED ${MODULE_SOURCES}) find_package(Libev REQUIRED) -find_package(json-c QUIET) -if(NOT json-c_FOUND) - message(STATUS "json-c not found. looking with pkg-config") - find_package(PkgConfig REQUIRED) - pkg_check_modules(json-c REQUIRED IMPORTED_TARGET json-c) - add_library(json-c::json-c ALIAS PkgConfig::json-c) -endif() +# TODO: When we have a proper cmake config file for json-c for most OS, we can +# use that instead of pkg-config. +# json-c v 0.14 and 0.15 have wrong include directories in their cmake config +# files. uncomment the following line when we have a proper cmake config file +# for json-c for most OS. +# find_package(json-c 0.16 CONFIG) + +# if(NOT json-c_FOUND) +# message(STATUS "json-c not found. looking with pkg-config") +find_package(PkgConfig REQUIRED) +pkg_check_modules(json-c REQUIRED IMPORTED_TARGET json-c) +add_library(json-c::json-c ALIAS PkgConfig::json-c) +# endif() find_package(CURL REQUIRED) _______________________________________________ Kamailio - Development Mailing List -- sr-dev@lists.kamailio.org To unsubscribe send an email to sr-dev-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender!