Skip to content

Commit 50a216e

Browse files
committed
build: a single place to define package version
Change-Id: I2cd7397895ed4852f852e99b97543dde76eaff8f
1 parent 82c9637 commit 50a216e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ add_custom_target(libyang-cpp-version-cmake
2121
cmake/ProjectGitVersionRunner.cmake
2222
)
2323
include(cmake/ProjectGitVersion.cmake)
24-
prepare_git_version(LIBYANG_CPP_VERSION "3")
24+
set(LIBYANG_CPP_PKG_VERSION "3")
25+
prepare_git_version(LIBYANG_CPP_VERSION ${LIBYANG_CPP_PKG_VERSION})
2526

2627
find_package(Doxygen)
2728
option(WITH_DOCS "Create and install internal documentation (needs Doxygen)" ${DOXYGEN_FOUND})
2829
option(BUILD_SHARED_LIBS "By default, shared libs are enabled. Turn off for a static build." ON)
2930

3031
find_package(PkgConfig REQUIRED)
3132
pkg_check_modules(LIBYANG REQUIRED libyang>=3.7.8 IMPORTED_TARGET)
32-
set(LIBYANG_CPP_PKG_VERSION "3")
3333

3434
# FIXME from gcc 14.1 on we should be able to use the calendar/time from libstdc++ and thus remove the date dependency
3535
find_package(date)

0 commit comments

Comments
 (0)