[gspell/wip/cmake] cmake: pkg-config file: Requires and Requires.private



commit 39d0de962bc3c856f50bbbe2547c5ddf568a870b
Author: Sébastien Wilmet <swilmet informatique-libre be>
Date:   Tue Aug 16 16:00:00 2022 +0200

    cmake: pkg-config file: Requires and Requires.private

 CMakeLists.txt | 16 ++++++++++++----
 gspell.pc.in   |  4 ++--
 2 files changed, 14 insertions(+), 6 deletions(-)
---
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6d1a7dd..77f584f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,11 +6,19 @@ project (gspell
 include (cmake/gsw.cmake)
 GswInitBasic ()
 
+set (dep_glib "glib-2.0 >= 2.44")
+set (dep_gtk "gtk+-3.0 >= 3.20")
+set (dep_enchant "enchant-2 >= 2.1.3")
+set (dep_icu "icu-uc")
+
+set (PKG_REQUIRES "${dep_glib} ${dep_gtk} ${dep_enchant}")
+set (PKG_REQUIRES_PRIVATE "${dep_icu}")
+
 pkg_check_modules (DEPS REQUIRED
-  glib-2.0>=2.44
-  gtk+-3.0>=3.20
-  enchant-2>=2.1.3
-  icu-uc)
+  ${dep_glib}
+  ${dep_gtk}
+  ${dep_enchant}
+  ${dep_icu})
 
 set (GSPELL_API_VERSION 1)
 set (GETTEXT_PACKAGE "gspell-${GSPELL_API_VERSION}")
diff --git a/gspell.pc.in b/gspell.pc.in
index e78395b..d34afcc 100644
--- a/gspell.pc.in
+++ b/gspell.pc.in
@@ -5,7 +5,7 @@ includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
 Name: @PROJECT_NAME@
 Description: Spell-checking for GTK applications
 Version: @PROJECT_VERSION@
-Requires: @AX_PACKAGE_REQUIRES@
-Requires.private: @AX_PACKAGE_REQUIRES_PRIVATE@
+Requires: @PKG_REQUIRES@
+Requires.private: @PKG_REQUIRES_PRIVATE@
 Libs: -L${libdir} -lgspell-@GSPELL_API_VERSION@
 Cflags: -I${includedir}/gspell-@GSPELL_API_VERSION@


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]