From: Thomas Debesse Date: Tue, 4 Jun 2019 23:46:28 +0000 (+0200) Subject: cmake: use complete version string in radiant about dialog X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=1756db43106b40c84de109302f01baf86d9fe2d6;p=xonotic%2Fnetradiant.git cmake: use complete version string in radiant about dialog --- diff --git a/CMakeLists.txt b/CMakeLists.txt index f3d85967..6a13aa64 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -144,6 +144,7 @@ endif () if (BUILD_BINARIES) add_definitions(-DRADIANT_VERSION="${RADIANT_VERSION}") + add_definitions(-DRADIANT_VERSION_STRING="${RADIANT_VERSION_STRING}") if (NOT CMAKE_BUILD_TYPE MATCHES Release) add_definitions(-D_DEBUG=1) diff --git a/Makefile b/Makefile index 58679435..f60b0d18 100644 --- a/Makefile +++ b/Makefile @@ -263,7 +263,7 @@ ifneq ($(GIT_VERSION),) Q3MAP_VERSION := $(Q3MAP_VERSION)-git-$(GIT_VERSION) endif -CPPFLAGS += -DRADIANT_VERSION="\"$(RADIANT_VERSION)\"" -DRADIANT_ABOUTMSG="\"$(RADIANT_ABOUTMSG)\"" -DRADIANT_NAME="\"${RADIANT_NAME}\"" -DRADIANT_BASENAME="\"${RADIANT_BASENAME}\"" -DQ3MAP_VERSION="\"$(Q3MAP_VERSION)\"" -DRADIANT_EXECUTABLE="\"$(RADIANT_EXECUTABLE)\"" +CPPFLAGS += -DRADIANT_VERSION="\"$(RADIANT_VERSION)\"" -DRADIANT_VERSION_STRING="\"$(RADIANT_VERSION_STRING)\"" -DRADIANT_ABOUTMSG="\"$(RADIANT_ABOUTMSG)\"" -DRADIANT_NAME="\"${RADIANT_NAME}\"" -DRADIANT_BASENAME="\"${RADIANT_BASENAME}\"" -DQ3MAP_VERSION="\"$(Q3MAP_VERSION)\"" -DRADIANT_EXECUTABLE="\"$(RADIANT_EXECUTABLE)\"" CPPFLAGS += -DGTK_TARGET=2 .PHONY: all diff --git a/include/version.h b/include/version.h index 745b5d39..cb97e381 100644 --- a/include/version.h +++ b/include/version.h @@ -2,3 +2,6 @@ #ifndef RADIANT_VERSION #error no RADIANT_VERSION defined #endif +#ifndef RADIANT_VERSION_STRING +#error no RADIANT_VERSION_STRING defined +#endif diff --git a/radiant/gtkdlgs.cpp b/radiant/gtkdlgs.cpp index a7e3fbce..6262da59 100644 --- a/radiant/gtkdlgs.cpp +++ b/radiant/gtkdlgs.cpp @@ -450,7 +450,7 @@ void DoAbout(){ } { - char const *label_text = "NetRadiant " RADIANT_VERSION "\n" + char const *label_text = "NetRadiant " RADIANT_VERSION_STRING "\n" __DATE__ "\n\n" RADIANT_ABOUTMSG "\n\n" "This program is free software\n"