Use CMake PROJECT_VERSION components in version files

This commit is contained in:
Luis Díaz Más 2018-09-13 10:46:47 +02:00
parent 5eb692d536
commit 808de65c37
2 changed files with 7 additions and 12 deletions

View File

@ -106,6 +106,11 @@
/* Define to the version of this package. */
#cmakedefine EXV_PACKAGE_VERSION "@PROJECT_VERSION@"
#define EXIV2_MAJOR_VERSION (@PROJECT_VERSION_MAJOR@)
#define EXIV2_MINOR_VERSION (@PROJECT_VERSION_MINOR@)
#define EXIV2_PATCH_VERSION (@PROJECT_VERSION_PATCH@)
#define EXIV2_TWEAK_VERSION (@PROJECT_VERSION_TWEAK@)
/* Define to empty if `const' does not conform to ANSI C. */
#cmakedefine const

View File

@ -30,6 +30,8 @@
#ifndef VERSION_HPP_
#define VERSION_HPP_
#include "exv_conf.h"
// *****************************************************************************
// included header files
// + standard includes
@ -64,18 +66,6 @@
typedef std::vector<Exiv2_grep_key_t> exv_grep_keys_t ;
#endif
/*!
@brief %Exiv2 MAJOR version number of the library used at compile-time.
*/
#define EXIV2_MAJOR_VERSION (0)
/*!
@brief %Exiv2 MINOR version number of the library used at compile-time.
*/
#define EXIV2_MINOR_VERSION (26)
/*!
@brief %Exiv2 PATCH version number of the library used at compile-time.
*/
#define EXIV2_PATCH_VERSION (0)
/*!
@brief Make an integer version number for comparison from a major, minor and
a patch version number.