Skip to content

Commit

Permalink
allow version info from variable
Browse files Browse the repository at this point in the history
  • Loading branch information
jmlich committed Mar 5, 2021
1 parent dad46f8 commit 4d65393
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
4 changes: 3 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ execute_process(COMMAND
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE
)

add_definitions( -DGIT_VERSION="${GIT_VERSION}" )
set(VERSION "${GIT_VERSION}" CACHE STRING "Manaly defined version string")

add_definitions( -DGIT_VERSION="${VERSION}" )

find_package(Qt5 COMPONENTS Core Gui Network Widgets WebEngineWidgets WebChannel LinguistTools REQUIRED)

Expand Down
3 changes: 2 additions & 1 deletion com.github.jmlich.geotagging.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
"name": "geotagging",
"buildsystem": "cmake-ninja",
"config-opts": [
"-DCMAKE_BUILD_TYPE=RelWithDebInfo"
"-DCMAKE_BUILD_TYPE=RelWithDebInfo",
"-DVERSION:STRING=0.5.7"
],
"sources": [
{
Expand Down
2 changes: 1 addition & 1 deletion com.github.jmlich.geotagging.spec
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Photography geotagging tool
%setup -q -n %{name}-%{version}

%build
%cmake
%cmake -DVERSION:STRING=%{version}
%cmake_build


Expand Down

0 comments on commit 4d65393

Please sign in to comment.