Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/Remmina/Remmina.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntenore Gatta (tmow) <antenore@simbiosi.org>2022-03-08 02:27:31 +0300
committerAntenore Gatta (tmow) <antenore@simbiosi.org>2022-03-08 02:27:31 +0300
commiteba4883d20ca38e12aeb394c4d4b43f3d6bee036 (patch)
treea9a19a95e55f7c042e11846a714a62ea46d9b36b /cmake/FindPCRE2.cmake
parentf56a81c403d3c7bdc149bd6ecf7e136934769bc8 (diff)
Removing dependencies that are available as extensions
Removed packages: - libgnutls28-dev - libjpeg-dev - libxcursor-dev - libxdamage-dev - libxext-dev - libxi-dev - libxinerama-dev - libxml2-dev - libxrandr-dev - libxtst-dev - libgcrypt20-dev - libwebkit2gtk-4.0-dev - libpcre2-dev - python3-dev - xdg-user-dirs - gtk-3-examples - libthai0 - libsndfile1 - libasyncns0 - libflac8 - libvorbisenc2 - libxau6 - libxdmcp6 - libogg0 - libvorbis0a - libpcre2-8-0 I've improved some CMakeFiles that were not handling correctly the include and librari directories
Diffstat (limited to 'cmake/FindPCRE2.cmake')
-rw-r--r--cmake/FindPCRE2.cmake63
1 files changed, 36 insertions, 27 deletions
diff --git a/cmake/FindPCRE2.cmake b/cmake/FindPCRE2.cmake
index 9cd074ef7..eb0a444c9 100644
--- a/cmake/FindPCRE2.cmake
+++ b/cmake/FindPCRE2.cmake
@@ -17,31 +17,40 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
-include(FindPackageHandleStandardArgs)
-
-pkg_check_modules(PC_LIBPCRE2 libpcre2-8-0)
-
-
-find_path(PCRE2_INCLUDE_DIR
- NAMES pcre2.h
- PATHS ../../../../libs
- /usr
- PATH_SUFFIXES include)
-
-find_library(PCRE2_LIBRARY
- NAMES pcre2-8
- PATHS ../../../../libs
- /usr
- PATH_SUFFIXES lib)
-
-if (PCRE2_INCLUDE_DIR AND PCRE2_LIBRARY)
- message(STATUS "Found pcre2 headers at ${PCRE2_INCLUDE_DIR}")
- message(STATUS "Found pcre2 libraries at ${PCRE2_LIBRARY}")
- set(PCRE2_INCLUDE_DIRS ${PCRE2_INCLUDE_DIR})
- set(PCRE2_LIBRARIES ${PCRE2_LIBRARY})
- set(PCRE2_FOUND yes)
-else()
- set(PCRE2_INCLUDE_DIRS)
- set(PCRE2_LIBRARIES)
- set(PCRE2_FOUND no)
+#
+# PCRE2_INCLUDE_DIRS
+# PCRE2_LIBRARIES
+# PCRE2_CFLAGS
+
+find_package(PkgConfig)
+
+if(PKG_CONFIG_FOUND)
+ pkg_check_modules(_PCRE2 libpcre2-8)
+endif(PKG_CONFIG_FOUND)
+
+find_library(PCRE2_LIB pcre
+ HINTS
+ ${_PCRE2_LIBRARY_DIRS}
+ ${COMMON_LIB_DIR}
+)
+
+if(PCRE2_LIB)
+ set(PCRE2_LIBRARIES ${PCRE2_LIB})
+ message(STATUS "PCRE2-Libs: ${PCRE2_LIBRARIES}")
+endif()
+
+find_path(PCRE2_INCLUDE_DIR pcre2.h
+ PATHS
+ ${_PCRE2_INCLUDE_DIRS}
+ ${COMMON_INCLUDE_DIR}
+)
+
+
+if(PCRE2_INCLUDE_DIR)
+ set(PCRE2_INCLUDE_DIRS ${PCRE2_INCLUDE_DIR})
+ message(STATUS "PCRE2-Include-Dirs: ${PCRE2_INCLUDE_DIRS}")
+endif()
+
+if(PCRE2_INCLUDE_DIRS)
+ set(PCRE2_FOUND TRUE)
endif()