Skip to content

Commit

Permalink
cpack: extract version number from resources.
Browse files Browse the repository at this point in the history
Signed-off-by: Andrea Odetti <mariofutire@gmail.com>
  • Loading branch information
audetto committed Jan 10, 2022
1 parent 0264538 commit 726b05c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Expand Up @@ -75,7 +75,11 @@ if (BUILD_LIBRETRO)
add_subdirectory(source/frontends/libretro)
endif()

set(CPACK_PACKAGE_VERSION "1.30.7.0")
file(STRINGS resource/version.h VERSION_FILE LIMIT_COUNT 1)
string(REGEX MATCH "#define APPLEWIN_VERSION (.*)" _ ${VERSION_FILE})
string(REPLACE "," "." VERSION ${CMAKE_MATCH_1})

set(CPACK_PACKAGE_VERSION ${VERSION})
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Apple ][ emulator for Linux")
set(CPACK_PACKAGE_CONTACT "audetto <mariofutire@gmail.com>")

Expand Down

0 comments on commit 726b05c

Please sign in to comment.