forked from github/server
set version based on most recent tag
This commit is contained in:
parent
7807f83830
commit
497f53102c
2 changed files with 6 additions and 0 deletions
2
s/build
2
s/build
|
@ -42,5 +42,7 @@ fi
|
|||
|
||||
echo "build eressea"
|
||||
cd $ROOT/$BUILD
|
||||
VERSION=$(git describe --tags)
|
||||
cmake -DERESSEA_VERSION="$VERSION" ..
|
||||
make $MAKEOPTS && make test
|
||||
cd $OLDPWD
|
||||
|
|
|
@ -12,6 +12,10 @@ include_directories (${TOLUA_INCLUDE_DIR})
|
|||
include_directories (${BSON_INCLUDE_DIR})
|
||||
include_directories (${INIPARSER_INCLUDE_DIR})
|
||||
|
||||
IF(DEFINED ERESSEA_VERSION)
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DERESSEA_VERSION=\\\"${ERESSEA_VERSION}\\\"")
|
||||
ENDIF()
|
||||
|
||||
IF(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
|
||||
# SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wconversion -Wno-sign-conversion")
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pedantic -Wsign-compare -Wall -Werror -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wno-char-subscripts -Wno-long-long")
|
||||
|
|
Loading…
Reference in a new issue