summaryrefslogtreecommitdiffstats
path: root/config/cmake/hdf5-config-version.cmake.in
blob: c1201ccc9849cc7087b27908651937c052c9f8a7 (plain)
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
#-----------------------------------------------------------------------------
# HDF5 Version file for install directory
#-----------------------------------------------------------------------------

SET (PACKAGE_VERSION @HDF5_VERSION_STRING@)

IF ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H5_VERS_MAJOR@)

  # exact match for version @H5_VERS_MAJOR@.@H5_VERS_MINOR@
  IF ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H5_VERS_MINOR@)

    # compatible with any version @H5_VERS_MAJOR@.@H5_VERS_MINOR@.x
    SET (PACKAGE_VERSION_COMPATIBLE 1) 
    
    IF ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H5_VERS_RELEASE@)
      SET (PACKAGE_VERSION_EXACT 1)    

      IF ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H5_VERS_SUBRELEASE@)
        # not using this yet
      ENDIF ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H5_VERS_SUBRELEASE@)
      
    ENDIF ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H5_VERS_RELEASE@)
    
  ENDIF ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H5_VERS_MINOR@)
ENDIF ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H5_VERS_MAJOR@)