Commit Graph

89 Commits

Author SHA1 Message Date
Brad King
763beb5944 FindGTK2: Fix documentation formatting
Fixes: #20223
2020-01-21 12:05:45 -05:00
Ben Boeckel
be4d1bdf9a FPHSA: acknowledge the name mismatches in CMake-owned modules 2020-01-14 17:25:49 -05:00
Markus Mittendrein
effafca77e FindGTK2: Add harfbuzz to GTK2_INCLUDE_DIRS
Fixes: #19531
2019-10-02 11:31:44 -04:00
Kitware Robot
932dcce1e6 Modules: Consistently use 2 space indentation 2019-05-14 15:26:46 -04:00
Bartosz Kosiorek
cb811d11ce Help: Improve description of modules 2019-04-23 10:39:34 +02:00
Rolf Eike Beer
eea9eda834 remove some platform specific search paths from Find modules
These are added through CMAKE_SYSTEM_PREFIX_PATH on the platforms automatically.
2019-03-19 23:49:11 +01:00
Kitware Robot
df4ed1e9ff Help: Convert remaining modules to block-style comments 2018-10-22 11:09:34 -04:00
Arkady Shapkin
45bf6f6246 Modules: Use MSVC_TOOLSET_VERSION variable to simplify logic 2018-04-04 13:21:16 -04:00
Christian Pfeiffer
f88ef9a9b8 Modules: Remove paths set as global Unix prefixes
This commit removes hardcoded paths that are already given in the
platform files or in `UnixPath` on a global level.
2017-11-20 16:21:49 +01:00
Brad King
a1440504ff Merge topic 'avoid-MSVC-per-version-vars'
9ab966a7 FindRuby: Use `MSVC_VERSION` instead of `MSVC##`
69b9fde1 FindGTK2: Use `MSVC_VERSION` instead of `MSVC##`
3fe31822 FindBoost: Avoid mentioning discouraged `MSVC##`` variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !610
2017-03-23 08:44:22 -04:00
Brad King
69b9fde148 FindGTK2: Use MSVC_VERSION instead of MSVC## 2017-03-23 08:40:35 -04:00
Steven Newbury
bed9c73dec Modules: Add x32-abi support to hard-coded paths
Update hard-coded library paths in bundled CMake Modules for libx32 as
used with x32-abi.
2017-03-07 15:22:55 -05:00
Ben Boeckel
2ab118a859 FindGTK2: handle old libsigc++ versions
Old versions of `libsigc++` do not have the version macros inside of its
`sigc++config.h` header. Assume nothing about such headers and report
version "zero".

Fixes: #16654
2017-02-20 11:58:57 -05:00
Daniele E. Domenichelli
9702b3eefd FindGTK2: Fix GTK2_LIBRARIES and GTK2_TARGETS when called twice
Closes: #16582
2017-01-25 10:20:30 +01:00
Daniel Pfeifer
d6877e6c40 Don't include CMakeParseArguments
The cmake_parse_arguments command is builtin with version 3.5.
The CMakeParseArguments module is empty and exists for backwards
compatibility with CMake 3.4 and lower.

Remove the includes of CMakeParseArguments from CMake's modules.
The modules are always used with the current version of CMake.

Leave the includes in the tests, as the tests may be run with an older
version of CMake.
2017-01-11 13:14:57 +01:00
Rolf Eike Beer
745b56f58c Find*.cmake: drop the comments before including FPHSA
No need to explain this over and over again.  While at it, do some other
minor cleanups to whitespace and comments (i.e. delete them).
2016-11-28 16:40:13 -05:00
Brad King
86578eccf2 Simplify CMake per-source license notices
Per-source copyright/license notice headers that spell out copyright holder
names and years are hard to maintain and often out-of-date or plain wrong.
Precise contributor information is already maintained automatically by the
version control tool.  Ultimately it is the receiver of a file who is
responsible for determining its licensing status, and per-source notices are
merely a convenience.  Therefore it is simpler and more accurate for
each source to have a generic notice of the license name and references to
more detailed information on copyright holders and full license terms.

Our `Copyright.txt` file now contains a list of Contributors whose names
appeared source-level copyright notices.  It also references version control
history for more precise information.  Therefore we no longer need to spell
out the list of Contributors in each source file notice.

Replace CMake per-source copyright/license notice headers with a short
description of the license and links to `Copyright.txt` and online information
available from "https://cmake.org/licensing".  The online URL also handles
cases of modules being copied out of our source into other projects, so we
can drop our notices about replacing links with full license text.

Run the `Utilities/Scripts/filter-notices.bash` script to perform the majority
of the replacements mechanically.  Manually fix up shebang lines and trailing
newlines in a few files.  Manually update the notices in a few files that the
script does not handle.
2016-09-27 15:14:44 -04:00
Daniele E. Domenichelli
5d79b9563f FindGTK2: Use targets in GTK2_LIBRARIES if GTK2_USE_IMPORTED_TARGETS is ON
Also add GTK2_TARGETS variable containing all imported targets.

Previously, the GTK2_LIBRARIES variable was filled with the paths to the
libraries, and only the GTK2_XXX_LIBRARY variables contained the imported
targets.
2015-11-09 09:51:50 -05:00
Daniele E. Domenichelli
3d9e3d7b79 FindGTK2: Enable c++11 for sigc++ 2.5.1 or later
Starting with sigc++ 2.5.1, c++11 must be enabled in order to use
sigc++. The GTK2::sigc++ imported target will automatically enable the
required build flags in order to build with the version found on the
system.
2015-10-12 10:06:55 -04:00
Brad King
2d97178b30 FindGTK2: Avoid depending on if() to dereference a quoted variable
Explicitly dereference GTK2_${_var}CONFIG_INCLUDE_DIR and
GTK2_${_var}_INCLUDE_DIR when comparing their values.
2014-09-11 21:23:24 +02:00
Chuck Atkins
cb8f0f7c81 FindGTK2: Fix missing optional include dirs.
FindGTK2 was adding optional include directories to the
interface include dirs regardless of whether or not they
existed.  This ensures that the directories only get added
if they are actually found. This is particularly a problem
on Solaris where the gtk2 libs and headers might exist but
the FreeType2 headers might not.
2014-09-03 23:25:57 -04:00
Daniele E. Domenichelli
81a3f22882 Do not change minimum required version in modules
Some modules change CMake minimum required version when they are
included. For example:

  cmake_minimum_required(VERSION 2.8.12)
  message("${CMAKE_MINIMUM_REQUIRED_VERSION}")
  include(CheckTypeSize)
  message("${CMAKE_MINIMUM_REQUIRED_VERSION}")

will produce the following output:

  2.8.12
  2.6

This patch ensures that when you include a CMake module the minimum
required version and the policies set are left unchanged.

Fixes Issue #14864
2014-05-19 16:55:12 +02:00
Rolf Eike Beer
55f5ea7b0e FindGTK2: search for Fontconfig and X11 before using them 2014-04-23 22:49:38 +02:00
Daniele E. Domenichelli
d5a6069a12 FindGTK2: Add GTK2_(FONTCONFIG|X11)_INCLUDE_DIR optional includes 2014-04-21 09:28:55 -04:00
Daniele E. Domenichelli
ef9366b0bb FindGTK2: Add /usr/X11R6/ to include paths
Should fix builds on OpenBSD, see
http://open.cdash.org/viewTest.php?onlyfailed&buildid=3286713
2014-04-15 16:26:13 +02:00
Brad King
4bb80396e0 CMake 3.0.0-rc1 version update 2014-02-19 09:30:12 -05:00
Daniele E. Domenichelli
0e9bf6a257 FindGTK2: Add support for Quartz backend on MAC
Fix issue #14593
2013-11-24 14:53:47 +01:00
Kitware Robot
f051814ed0 Convert builtin help to reStructuredText source files
Run the convert-help.bash script to convert documentation:

 ./convert-help.bash "/path/to/CMake-build/bin"

Then remove it.
2013-10-15 14:12:03 -04:00
Daniele E. Domenichelli
95fc47aa49 FindGTK2: Make pangocairo and cairo optional dependencies 2013-10-08 10:47:06 -04:00
Daniele E. Domenichelli
26f790f0b6 FindGTK2: Change extra includes -> optional
On some versions they are not required.
2013-10-08 10:46:27 -04:00
Daniele E. Domenichelli
24e0272b23 FindGTK2: do not skip target creation if optional dependencies are not found
On some older GTK2 version gio, giomm and cairomm are not available
2013-10-08 10:30:13 -04:00
Daniele E. Domenichelli
d5f130cdf6 FindGTK2: Refactor _GTK2_ADJUST_LIB_VARS into _GTK2_ADD_TARGET
This function avoids creating the targets when the required
dependencies were not found.
Also fix some wrong dependency and some typo.

${FREETYPE_INCLUDE_DIR_ft2build} ${FREETYPE_INCLUDE_DIR_freetype2} are
now required for gtkmm component
2013-10-08 10:30:13 -04:00
Daniele E. Domenichelli
fffbd7252d FindGTK2: Do not add freetype includes if they are not found
On some older system they are not required
2013-10-08 10:30:13 -04:00
Daniele E. Domenichelli
b69720d9ad FindGTK2: Add libraries to the GTK2_LIBRARIES variable only when found
Some libraries (e.g. gio) are not necessary, and often not available
with older GTK2 versions, therefore GTK_LIBRARIES should not contain
GTK2_XXX-NOT_FOUND for these libraries.
2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
425ec4080d FindGTK2: Do not link libfreetype
As discussed on the mailing list, freetype includes used in GTK2
headers libraries do not require to link the library explicitly (even
though it is already linked by GTK2 libraries.

Also remove _GTK2_ADD_TARGET_LIBRARIES no longer used and use
${FREETYPE_INCLUDE_DIR_ft2build} ${FREETYPE_INCLUDE_DIR_freetype2}
variables instead of ${FREETYPE_INCLUDE_DIRS}
2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
e9f46dfeb2 FindGTK2: Add config directories only if different from include ones 2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
56a79e1f8c FindGTK2: Set INTERFACE_COMPILE_DEFINITIONS target property only if not empty 2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
4b47586a08 FindGTK2: Add check to ensure that target exists 2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
61242ccc8f FindGTK2: Fix gmodule, glibmm, pangoft2, and pangoxft targets 2013-10-08 10:30:12 -04:00
Daniele E. Domenichelli
4b876de974 FindGTK2: Link freetype libs to targets including freetype includes 2013-10-08 10:30:11 -04:00
Daniele E. Domenichelli
67e761fabc FindGTK2: Small cleanup 2013-10-07 20:19:30 -04:00
Daniele E. Domenichelli
682eea3909 FindGTK2: Do not require the GTK_ prefix in all the internal functions
This saves from using string(REGEXP) to create targets
2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
0bc3763c9e FindGTK2: Better handling of include directories
Add a method _GTK2_ADD_TARGET_INCLUDE_DIRS to handle it.
2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
9905abd150 FindGTK2: Create targets for each library
Methods:
 * _GTK2_ADJUST_LIB_VARS
 * _GTK2_ADD_TARGET_DEPENDS_INTERNAL
 * _GTK2_ADD_TARGET_DEPENDS
are strongly inspired by FindQt4.cmake
2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
7af8ad89af FindGTK2: Search for glib-object.h instead of gobject/gobject.h
This is the topmost include file for GObject header files
2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
fab6c2deb0 FindGTK2: Populate GTK2_DEFINITIONS before searching for libraries 2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
8d7b070410 FindGTK2: Export GTK2_XXX_FOUND to parent scope in _GTK2_FIND_LIBRARY
Also add a debug message to report if the library was found or not
2013-10-07 20:19:29 -04:00
Daniele E. Domenichelli
1bbc7662ea FindGTK2: Search for modules quietly when needed 2013-10-07 20:18:06 -04:00
Daniele E. Domenichelli
d9eb277631 FindGTK2: Find freetype quietly 2013-10-07 20:18:06 -04:00
Daniele E. Domenichelli
675a4d3897 FindGTK2: Mark GTK_*_INCLUDE_DIR as advanced 2013-10-07 20:18:01 -04:00