Cleaned up cmake output (#3941)

* Follow up to d649ede.
* Renamed svnversion.h to version.hpp.
This commit is contained in:
Aleos 2019-02-15 23:10:17 -05:00 committed by GitHub
parent c80b8acf75
commit 47866f6065
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 10 deletions

1
.gitignore vendored
View File

@ -71,6 +71,7 @@ Thumbs.db
/src/common/Makefile /src/common/Makefile
/src/common/obj_all /src/common/obj_all
/src/common/obj_sql /src/common/obj_sql
/src/common/version.hpp
# /src/custom/ # /src/custom/
/src/custom /src/custom

View File

@ -7514,7 +7514,7 @@ must be used.
This command makes an object display an emotion sprite above their own as This command makes an object display an emotion sprite above their own as
if they were doing that emotion. For a full list of emotion numbers, if they were doing that emotion. For a full list of emotion numbers,
see 'src/map/script_constants.pph' under 'ET_'. The not so obvious ones are 'ET_QUESTION' see 'src/map/script_constants.hpp' under 'ET_'. The not so obvious ones are 'ET_QUESTION'
(a question mark) and 'ET_SURPRISE' (the exclamation mark). (a question mark) and 'ET_SURPRISE' (the exclamation mark).
The optional target parameter specifies who will get the emotion on top of The optional target parameter specifies who will get the emotion on top of

View File

@ -1,9 +1,8 @@
# #
# Create svnversion.h # Create version.hpp
# tbd, could be rename version.h
# #
message( STATUS "Creating svnversion.h" ) message( STATUS "Creating version.hpp" )
if(GIT_VERSION) if(GIT_VERSION)
# those 2 was done in parent to produce this # those 2 was done in parent to produce this
#include(GetGitVersion) #include(GetGitVersion)
@ -12,23 +11,23 @@ if(GIT_VERSION)
string(SUBSTRING ${GIT_HEAD_VERSION} 0 10 SHORT_GIT_HEAD_VERSION) string(SUBSTRING ${GIT_HEAD_VERSION} 0 10 SHORT_GIT_HEAD_VERSION)
string(CONCAT GIT_STR_VERSIONS ${SHORT_GIT_VERSION} "_" ${SHORT_GIT_HEAD_VERSION}) string(CONCAT GIT_STR_VERSIONS ${SHORT_GIT_VERSION} "_" ${SHORT_GIT_HEAD_VERSION})
#message( STATUS "git version=${GIT_STR_VERSIONS}" ) #message( STATUS "git version=${GIT_STR_VERSIONS}" )
file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/svnversion.h file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/version.hpp
"#ifndef SVNVERSION\n#define SVNVERSION ${GIT_STR_VERSIONS}\n#endif\n" ) "#ifndef SVNVERSION\n#define SVNVERSION ${GIT_STR_VERSIONS}\n#endif\n" )
elseif( SVNVERSION ) elseif( SVNVERSION )
file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/svnversion.h file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/version.hpp
"#ifndef SVNVERSION\n#define SVNVERSION ${SVNVERSION}\n#endif\n" ) "#ifndef SVNVERSION\n#define SVNVERSION ${SVNVERSION}\n#endif\n" )
else() else()
file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/svnversion.h "" ) file( WRITE ${CMAKE_CURRENT_BINARY_DIR}/version.hpp "" )
endif() endif()
set( GLOBAL_INCLUDE_DIRS ${GLOBAL_INCLUDE_DIRS} ${CMAKE_CURRENT_BINARY_DIR} CACHE INTERNAL "" ) set( GLOBAL_INCLUDE_DIRS ${GLOBAL_INCLUDE_DIRS} ${CMAKE_CURRENT_BINARY_DIR} CACHE INTERNAL "" )
set( SVNVERSION ${SVNVERSION} set( SVNVERSION ${SVNVERSION}
CACHE STRING "SVN version of the source code" ) CACHE STRING "SVN version of the source code" )
if( INSTALL_COMPONENT_DEVELOPMENT ) if( INSTALL_COMPONENT_DEVELOPMENT )
install( FILES ${CMAKE_CURRENT_BINARY_DIR}/svnversion.h install( FILES ${CMAKE_CURRENT_BINARY_DIR}/version.hpp
DESTINATION "src/common" DESTINATION "src/common"
COMPONENT Development_base ) COMPONENT Development_base )
endif( INSTALL_COMPONENT_DEVELOPMENT ) endif( INSTALL_COMPONENT_DEVELOPMENT )
message( STATUS "Creating svnversion.h - done" ) message( STATUS "Creating version.hpp - done" )
##################################################################### #####################################################################
@ -52,7 +51,7 @@ set( COMMON_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}"
mark_as_advanced( COMMON_SOURCE_DIR ) mark_as_advanced( COMMON_SOURCE_DIR )
set( COMMON_ALL_HEADERS set( COMMON_ALL_HEADERS
"${CMAKE_CURRENT_BINARY_DIR}/svnversion.h" "${CMAKE_CURRENT_BINARY_DIR}/version.hpp"
"${COMMON_SOURCE_DIR}/cbasetypes.hpp" "${COMMON_SOURCE_DIR}/cbasetypes.hpp"
"${COMMON_SOURCE_DIR}/mmo.hpp" "${COMMON_SOURCE_DIR}/mmo.hpp"
) )