[SCM] ktp-text-ui packaging branch, master, updated. debian/15.12.1-1-1918-gdf4b0ec
Maximiliano Curia
maxy at moszumanska.debian.org
Sat May 28 00:20:15 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-text-ui.git;a=commitdiff;h=6d8cd51
The following commit has been merged in the master branch:
commit 6d8cd511f143d91f81b8171762c91aaaed32a22f
Author: Dominik Schmidt <dev at dominik-schmidt.de>
Date: Wed Oct 12 21:03:42 2011 +0200
Replace my FindGIO.cmake with drf's version
---
cmake/modules/FindGIO.cmake | 78 ++++++++++++++++++++++++++++++++++++---------
1 file changed, 63 insertions(+), 15 deletions(-)
diff --git a/cmake/modules/FindGIO.cmake b/cmake/modules/FindGIO.cmake
index 247fa42..4c570b7 100644
--- a/cmake/modules/FindGIO.cmake
+++ b/cmake/modules/FindGIO.cmake
@@ -1,23 +1,71 @@
-# - Try to find GIO
+# - Try to find the GIO libraries
# Once done this will define
-# GIO_FOUND - System has GIO
-# GIO_INCLUDE_DIRS - The GIO include directories
-# GIO_LIBRARIES - The libraries needed to use GIO
-# GIO_DEFINITIONS - Compiler switches required for using GIO
+#
+# GIO_FOUND - system has GIO
+# GIO_INCLUDE_DIR - the GIO include directory
+# GIO_LIBRARIES - GIO library
+#
+# Copyright (c) 2010 Dario Freddi <drf at kde.org>
+#
+# Redistribution and use is allowed according to the terms of the BSD license.
+# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
-set(GIO_DEFINITIONS "")
+if(GIO_INCLUDE_DIR AND GIO_LIBRARIES)
+ # Already in cache, be silent
+ set(GIO_FIND_QUIETLY TRUE)
+endif(GIO_INCLUDE_DIR AND GIO_LIBRARIES)
-find_path(GIO_INCLUDE_DIR glib-2.0/gio/gio.h)
+if (NOT WIN32)
+ include(UsePkgConfig)
+ pkgconfig(gio-2.0 _LibGIOIncDir _LibGIOLinkDir _LibGIOLinkFlags _LibGIOCflags)
+endif(NOT WIN32)
-find_library(GIO_LIBRARY NAMES gio-2.0)
+MESSAGE(STATUS "gio include dir: ${_LibGIOIncDir}")
-set(GIO_LIBRARIES ${GIO_LIBRARY} )
-set(GIO_INCLUDE_DIRS ${GIO_INCLUDE_DIR} ${GIO_INCLUDE_DIR}/glib-2.0/ )
+# first try without default paths to respect PKG_CONFIG_PATH
+
+find_path(GIO_MAIN_INCLUDE_DIR glib.h
+ PATH_SUFFIXES glib-2.0
+ PATHS ${_LibGIOIncDir}
+ NO_DEFAULT_PATH)
+
+find_path(GIO_MAIN_INCLUDE_DIR glib.h
+ PATH_SUFFIXES glib-2.0
+ PATHS ${_LibGIOIncDir} )
+
+MESSAGE(STATUS "found gio main include dir: ${GIO_MAIN_INCLUDE_DIR}")
+
+# search the glibconfig.h include dir under the same root where the library is found
+find_library(GIO_LIBRARIES
+ NAMES gio-2.0
+ PATHS ${_LibGIOLinkDir}
+ NO_DEFAULT_PATH)
+
+find_library(GIO_LIBRARIES
+ NAMES gio-2.0
+ PATHS ${_LibGIOLinkDir})
+
+
+get_filename_component(GIOLibDir "${GIO_LIBRARIES}" PATH)
+
+find_path(GIO_INTERNAL_INCLUDE_DIR glibconfig.h
+ PATH_SUFFIXES glib-2.0/include
+ PATHS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH}
+ NO_DEFAULT_PATH)
+
+find_path(GIO_INTERNAL_INCLUDE_DIR glibconfig.h
+ PATH_SUFFIXES glib-2.0/include
+ PATHS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH})
+
+set(GIO_INCLUDE_DIR "${GIO_MAIN_INCLUDE_DIR}")
+
+# not sure if this include dir is optional or required
+# for now it is optional
+if(GIO_INTERNAL_INCLUDE_DIR)
+ set(GIO_INCLUDE_DIR ${GIO_INCLUDE_DIR} "${GIO_INTERNAL_INCLUDE_DIR}")
+endif(GIO_INTERNAL_INCLUDE_DIR)
include(FindPackageHandleStandardArgs)
-# handle the QUIETLY and REQUIRED arguments and set LIBXML2_FOUND to TRUE
-# if all listed variables are TRUE
-find_package_handle_standard_args(GIO DEFAULT_MSG
- GIO_LIBRARY GIO_INCLUDE_DIR)
+find_package_handle_standard_args(GIO DEFAULT_MSG GIO_LIBRARIES GIO_MAIN_INCLUDE_DIR)
-mark_as_advanced(GIO_INCLUDE_DIR GIO_LIBRARY )
+mark_as_advanced(GIO_INCLUDE_DIR GIO_LIBRARIES)
--
ktp-text-ui packaging
More information about the pkg-kde-commits
mailing list