core: move definitions with version and license in root CMakeLists.txt
parent
6c4b574945
commit
26f415f5db
|
@ -46,6 +46,14 @@ endif()
|
|||
# license
|
||||
set(LICENSE "GPL3")
|
||||
|
||||
# add definitions for version and license
|
||||
if(COMMAND cmake_policy)
|
||||
cmake_policy(SET CMP0005 NEW)
|
||||
add_definitions(-DWEECHAT_VERSION="${VERSION}" -DWEECHAT_LICENSE="${LICENSE}")
|
||||
else()
|
||||
add_definitions(-DWEECHAT_VERSION='"${VERSION}"' -DWEECHAT_LICENSE='"${LICENSE}"')
|
||||
endif()
|
||||
|
||||
# package string
|
||||
set(PKG_STRING "${PROJECT_NAME} ${VERSION}")
|
||||
string(REPLACE "\";\"" "\ " PKG_STRING ${PKG_STRING})
|
||||
|
|
|
@ -19,13 +19,6 @@
|
|||
# along with WeeChat. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
|
||||
if(COMMAND cmake_policy)
|
||||
cmake_policy(SET CMP0005 NEW)
|
||||
add_definitions(-DWEECHAT_VERSION="${VERSION}" -DWEECHAT_LICENSE="${LICENSE}")
|
||||
else()
|
||||
add_definitions(-DWEECHAT_VERSION='"${VERSION}"' -DWEECHAT_LICENSE='"${LICENSE}"')
|
||||
endif()
|
||||
|
||||
add_subdirectory(core)
|
||||
list(APPEND STATIC_LIBS weechat_core)
|
||||
|
||||
|
|
Loading…
Reference in New Issue