-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathConfigVersion.cmake.in
57 lines (51 loc) · 2.44 KB
/
ConfigVersion.cmake.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
##############################################################################
# \file @[email protected]
# \brief Package configuration version file of @PACKAGE_NAME@.
#
# This file supports the usage of the package by other projects. It is loaded
# by the find_package () CMake command used by other projects to find this
# package in order to verify that the version of the package found is
# compatible with the version requested.
#
# Input CMake variables:
#
# PACKAGE_FIND_NAME The <package> name.
# PACKAGE_FIND_VERSION Full requested version string.
# PACKAGE_FIND_VERSION_MAJOR Major version if requested, else 0.
# PACKAGE_FIND_VERSION_MINOR Minor version if requested, else 0.
# PACKAGE_FIND_VERSION_PATCH Patch version if requested, else 0.
# PACKAGE_FIND_VERSION_TWEAK Tweak version if requested, else 0.
# PACKAGE_FIND_VERSION_COUNT Number of version components, 0 to 4.
#
# CMake variables which have to be set by this version file:
#
# PACKAGE_VERSION Full provided version string.
# PACKAGE_VERSION_EXACT True if version is exact match.
# PACKAGE_VERSION_COMPATIBLE True if version is compatible.
# PACKAGE_VERSION_UNSUITABLE True if unsuitable as any version.
#
# See http://www.cmake.org/Wiki/CMake_2.6_Notes for details.
#
# Copyright (c) 2015 University of Pennsylvania. All rights reserved.
# See COPYING file or https://www.rad.upenn.edu/sbia/software/license.html.
#
# Contact: SBIA Group <sbia-software at uphs.upenn.edu>
##############################################################################
# ============================================================================
# version
# ============================================================================
SET( PACKAGE_VERSION "@PROJECT_VERSION@" )
# ============================================================================
# check compatibility
# ============================================================================
# Perform compatibility check here using the input CMake variables.
# See example in http://www.cmake.org/Wiki/CMake_2.6_Notes.
SET( PACKAGE_VERSION_COMPATIBLE TRUE )
SET( PACKAGE_VERSION_UNSUITABLE FALSE )
IF( "${PACKAGE_FIND_VERSION_MAJOR}" EQUAL "@PROJECT_VERSION_MAJOR@" )
IF( "${PACKAGE_FIND_VERSION_MINOR}" EQUAL "@PROJECT_VERSION_MINOR@" )
IF( "${PACKAGE_FIND_VERSION_PATCH}" EQUAL "@PROJECT_VERSION_PATCH@" )
SET( PACKAGE_VERSION_EXACT TRUE )
ENDIF()
ENDIF()
ENDIF()