summaryrefslogtreecommitdiffstats
path: root/0001-Added-support-for-pkg-config-345.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2026-03-27 08:04:39 +0100
committerRemi Collet <remi@php.net>2026-03-27 08:04:39 +0100
commitcc4c0d77cc6da3e5318403bd073c5ff5206c7f66 (patch)
tree4ca611d456bd33ee0f012423b585517ef0c7d744 /0001-Added-support-for-pkg-config-345.patch
parente26c78f0cbe8e415203d8bb543f1a20bfcf9db4d (diff)
improved pkg-config patch (merged upstream)HEADmaster
Diffstat (limited to '0001-Added-support-for-pkg-config-345.patch')
-rw-r--r--0001-Added-support-for-pkg-config-345.patch59
1 files changed, 59 insertions, 0 deletions
diff --git a/0001-Added-support-for-pkg-config-345.patch b/0001-Added-support-for-pkg-config-345.patch
new file mode 100644
index 0000000..b98139b
--- /dev/null
+++ b/0001-Added-support-for-pkg-config-345.patch
@@ -0,0 +1,59 @@
+From 25c9adfa74a80066f193df3b9689d39fec4d656c Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@famillecollet.com>
+Date: Tue, 24 Mar 2026 19:11:05 +0100
+Subject: [PATCH 1/2] Added support for pkg-config (#345)
+
+---
+ CMakeLists.txt | 16 ++++++++++++++++
+ lexbor.pc.in | 12 ++++++++++++
+ 2 files changed, 28 insertions(+)
+ create mode 100644 lexbor.pc.in
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 15f6571..eb3dcff 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -377,6 +377,22 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config.cmake"
+ "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config-version.cmake"
+ DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}/")
+
++################
++## pkg-config configuration
++#########################
++find_package(PkgConfig)
++if (PKG_CONFIG_FOUND)
++ configure_file(
++ "${PROJECT_SOURCE_DIR}/lexbor.pc.in"
++ "${PROJECT_BINARY_DIR}/lexbor.pc"
++ @ONLY
++ )
++ install(
++ FILES "${PROJECT_BINARY_DIR}/lexbor.pc"
++ DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig"
++ )
++endif()
++
+ ################
+ ## Build an RPM.
+ #########################
+diff --git a/lexbor.pc.in b/lexbor.pc.in
+new file mode 100644
+index 0000000..c28b7a1
+--- /dev/null
++++ b/lexbor.pc.in
+@@ -0,0 +1,12 @@
++prefix=@CMAKE_INSTALL_PREFIX@
++exec_prefix=${prefix}
++libdir=@CMAKE_INSTALL_FULL_LIBDIR@
++includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
++
++Name: @PROJECT_NAME@
++Description: HTML Renderer library
++Version: @PROJECT_VERSION@
++
++Libs: -L${libdir} -l@PROJECT_NAME@
++Cflags: -I${includedir}
++
+--
+2.53.0
+