Skip to content

Commit 91d618e

Browse files
committed
cmake: 3.2.0 update
1 parent 1475754 commit 91d618e

File tree

1 file changed

+5
-19
lines changed

1 file changed

+5
-19
lines changed

CMakeLists.txt

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -106,28 +106,14 @@ else()
106106
endif()
107107

108108
# get git version hash
109-
if(EXISTS ${CMAKE_SOURCE_DIR}/.git)
110-
add_custom_command(OUTPUT ${CMAKE_SOURCE_DIR}/src/gen_version.h
111-
COMMAND echo "#ifndef __VERSION_H__" > ${CMAKE_SOURCE_DIR}/src/gen_version.h
112-
COMMAND echo "#define __VERSION_H__" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
113-
COMMAND git log -n1 "--format=#define APP_VERSION \"%h_git\"" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
114-
COMMAND echo "#define MAJOR_VERSION 999" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
115-
COMMAND echo "#define MINOR_VERSION 0" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
116-
COMMAND echo "#define PATCH_VERSION 0" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
117-
COMMAND echo "#endif" >> ${CMAKE_SOURCE_DIR}/src/gen_version.h
118-
DEPENDS .git/HEAD
119-
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
120-
VERBATIM)
121-
else()
122-
file(WRITE ${CMAKE_SOURCE_DIR}/src/gen_version.h
109+
file(WRITE ${CMAKE_SOURCE_DIR}/src/gen_version.h
123110
"#ifndef __GEN_VERSIONS_H__\n"
124111
"#define __GEN_VERSIONS_H__\n"
125-
"#define APP_VERSION \"3.0.1\"\n"
112+
"#define APP_VERSION \"3.2.0\"\n"
126113
"#define MAJOR_VERSION 3\n"
127-
"#define MINOR_VERSION 0\n"
128-
"#define PATCH_VERSION 1\n"
114+
"#define MINOR_VERSION 2\n"
115+
"#define PATCH_VERSION 0\n"
129116
"#endif")
130-
endif()
131117

132118
#icon and correct libs/subsystem for windows
133119
if(WIN32)
@@ -200,7 +186,7 @@ set(CPACK_PACKAGE_VENDOR "oldsch00l")
200186
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README.md")
201187
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")
202188
set(CPACK_PACKAGE_VERSION_MAJOR "3")
203-
set(CPACK_PACKAGE_VERSION_MINOR "0")
189+
set(CPACK_PACKAGE_VERSION_MINOR "2")
204190
set(CPACK_PACKAGE_VERSION_PATCH "0")
205191
set(CPACK_PACKAGE_INSTALL_DIRECTORY "SqliteBrowser${CPACK_PACKAGE_VERSION_MAJOR}")
206192
if(WIN32 AND NOT UNIX)

0 commit comments

Comments
 (0)