diff --git a/CMakeLists.txt b/CMakeLists.txt index 4619524..cba8781 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,7 +6,11 @@ SET(CMAKE_VERBOSE_MAKEFILE ON) set(CMAKE_EXPORT_COMPILE_COMMANDS ON) # N2n release information -set(N2N_VERSION "3.1.0") +execute_process( + COMMAND cat VERSION + WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} + OUTPUT_VARIABLE N2N_VERSION +) set(N2N_OSNAME ${CMAKE_SYSTEM_NAME}) execute_process( COMMAND git status diff --git a/VERSION b/VERSION new file mode 100644 index 0000000..fd2a018 --- /dev/null +++ b/VERSION @@ -0,0 +1 @@ +3.1.0 diff --git a/autogen.sh b/autogen.sh index 89e9846..81ba943 100755 --- a/autogen.sh +++ b/autogen.sh @@ -1,11 +1,6 @@ #!/usr/bin/env bash -# NOTE: update version in CMakeLists.txt after changing these -N2N_MAJOR="3" -N2N_MINOR="1" -N2N_PATCH="0" - -N2N_VERSION_SHORT="$N2N_MAJOR.$N2N_MINOR.$N2N_PATCH" +N2N_VERSION_SHORT=$(cat VERSION) cat configure.seed | sed \ -e "s/@N2N_VERSION_SHORT@/$N2N_VERSION_SHORT/g" \