Update Windows resource and version.h.in files

This commit is contained in:
scribam 2021-05-28 12:51:04 +02:00 committed by flyinghead
parent d6e15544bc
commit 57ae9022dd
8 changed files with 46 additions and 49 deletions

View File

@ -950,7 +950,7 @@ elseif(WIN32)
endif() endif()
target_sources(${PROJECT_NAME} PRIVATE target_sources(${PROJECT_NAME} PRIVATE
core/windows/win_vmem.cpp core/windows/win_vmem.cpp
shell/windows/reicast.rc) shell/windows/flycast.rc)
target_link_libraries(${PROJECT_NAME} PRIVATE dsound opengl32 winmm ws2_32 wsock32 xinput9_1_0) target_link_libraries(${PROJECT_NAME} PRIVATE dsound opengl32 winmm ws2_32 wsock32 xinput9_1_0)
endif() endif()

View File

@ -254,7 +254,7 @@ RZDCY_FILES += $(LIBZIP_DIR)/zip_add.c \
endif endif
$(VERSION_HEADER): $(VERSION_HEADER):
echo "#define REICAST_VERSION \"`git describe --tags --always`\"" > $(VERSION_HEADER) echo "#define GIT_VERSION \"`git describe --tags --always`\"" > $(VERSION_HEADER)
echo "#define GIT_HASH \"`git rev-parse --short HEAD`\"" >> $(VERSION_HEADER) echo "#define GIT_HASH \"`git rev-parse --short HEAD`\"" >> $(VERSION_HEADER)
echo "#define BUILD_DATE \"`date '+%Y-%m-%d %H:%M:%S %Z'`\"" >> $(VERSION_HEADER) echo "#define BUILD_DATE \"`date '+%Y-%m-%d %H:%M:%S %Z'`\"" >> $(VERSION_HEADER)

View File

@ -1580,7 +1580,7 @@ static void gui_display_settings()
ImGui::PushStyleVar(ImGuiStyleVar_FramePadding, normal_padding); ImGui::PushStyleVar(ImGuiStyleVar_FramePadding, normal_padding);
if (ImGui::CollapsingHeader("Flycast", ImGuiTreeNodeFlags_DefaultOpen)) if (ImGui::CollapsingHeader("Flycast", ImGuiTreeNodeFlags_DefaultOpen))
{ {
ImGui::Text("Version: %s", REICAST_VERSION); ImGui::Text("Version: %s", GIT_VERSION);
ImGui::Text("Git Hash: %s", GIT_HASH); ImGui::Text("Git Hash: %s", GIT_HASH);
ImGui::Text("Build Date: %s", BUILD_DATE); ImGui::Text("Build Date: %s", BUILD_DATE);
} }

View File

@ -1,8 +1,5 @@
/*
* reicast: version.h
*/
#pragma once #pragma once
#define REICAST_VERSION "@GIT_VERSION@" #define GIT_VERSION "@GIT_VERSION@"
#define GIT_HASH "@GIT_HASH@" #define GIT_HASH "@GIT_HASH@"
#define BUILD_DATE "@BUILD_TIMESTAMP@" #define BUILD_DATE "@BUILD_TIMESTAMP@"

View File

@ -2594,7 +2594,7 @@
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh; shellPath = /bin/sh;
shellScript = "echo \"#define REICAST_VERSION \\\"`git describe --tags --always`\\\"\" > $SRCROOT/../../../core/version.h\necho \"#define GIT_HASH \\\"`git rev-parse --short HEAD`\\\"\" >> $SRCROOT/../../../core/version.h\necho \"#define BUILD_DATE \\\"`date '+%Y-%m-%d %H:%M:%S %Z'`\\\"\" >> $SRCROOT/../../../core/version.h\ncd $SRCROOT/../../../core/deps/miniupnpc; sh ./updateminiupnpcstrings.sh\n"; shellScript = "echo \"#define GIT_VERSION \\\"`git describe --tags --always`\\\"\" > $SRCROOT/../../../core/version.h\necho \"#define GIT_HASH \\\"`git rev-parse --short HEAD`\\\"\" >> $SRCROOT/../../../core/version.h\necho \"#define BUILD_DATE \\\"`date '+%Y-%m-%d %H:%M:%S %Z'`\\\"\" >> $SRCROOT/../../../core/version.h\ncd $SRCROOT/../../../core/deps/miniupnpc; sh ./updateminiupnpcstrings.sh\n";
}; };
/* End PBXShellScriptBuildPhase section */ /* End PBXShellScriptBuildPhase section */

View File

@ -482,8 +482,8 @@ OBJECTS:=$(OBJECTS:.S=.build_obj)
OBJECTS:=$(patsubst $(RZDCY_SRC_DIR)/%,$(BUILDDIR)/%,$(OBJECTS)) OBJECTS:=$(patsubst $(RZDCY_SRC_DIR)/%,$(BUILDDIR)/%,$(OBJECTS))
ifdef FOR_WINDOWS ifdef FOR_WINDOWS
OBJECTS += $(BUILDDIR)/reicastres.build_obj OBJECTS += $(BUILDDIR)/flycastres.build_obj
$(BUILDDIR)/reicastres.build_obj: $(LOCAL_PATH)/../windows/reicast.rc $(LOCAL_PATH)/../windows/flycast.ico $(RZDCY_SRC_DIR)/version.h $(BUILDDIR)/flycastres.build_obj: $(LOCAL_PATH)/../windows/flycast.rc $(LOCAL_PATH)/../windows/flycast.ico $(RZDCY_SRC_DIR)/version.h
$(WINDRES) $< $@ $(WINDRES) $< $@
endif endif

View File

@ -1,39 +1,39 @@
// Microsoft Visual C++ generated resource script. // Microsoft Visual C++ generated resource script.
// //
#include "resource.h" #include "resource.h"
#include "../../core/version.h" #include "../../core/version.h"
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// //
// Icon // Icon
// //
// Icon with lowest ID value placed first to ensure application icon // Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems. // remains consistent on all systems.
IDI_ICON1 ICON "flycast.ico" IDI_ICON1 ICON "flycast.ico"
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
1 VERSIONINFO 1 VERSIONINFO
FILEVERSION 1,0,0,0 FILEVERSION 1,0,0,0
PRODUCTVERSION 1,0,0,0 PRODUCTVERSION 1,0,0,0
BEGIN BEGIN
BLOCK "StringFileInfo" BLOCK "StringFileInfo"
BEGIN BEGIN
BLOCK "040904E4" BLOCK "040904E4"
BEGIN BEGIN
VALUE "CompanyName", "Flycast Team" VALUE "CompanyName", "Flycast Team"
VALUE "FileDescription", "Flycast" VALUE "FileDescription", "Flycast is a multiplatform Sega Dreamcast, Naomi and Atomiswave emulator"
VALUE "FileVersion", REICAST_VERSION VALUE "FileVersion", GIT_VERSION
VALUE "InternalName", "reicast" VALUE "InternalName", "flycast"
VALUE "LegalCopyright", "Copyright (c) Reicast contributors. All rights reserved." VALUE "LegalCopyright", "Copyright various authors. Released under the GNU General Public License."
VALUE "OriginalFilename", "flycast.exe" VALUE "OriginalFilename", "flycast.exe"
VALUE "ProductName", "Flycast" VALUE "ProductName", "Flycast"
VALUE "ProductVersion", REICAST_VERSION VALUE "ProductVersion", GIT_VERSION
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"
BEGIN BEGIN
VALUE "Translation", 0x409, 1252 VALUE "Translation", 0x409, 1252
END END
END END

View File

@ -1,6 +1,6 @@
//{{NO_DEPENDENCIES}} //{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file. // Microsoft Visual C++ generated include file.
// Used by reicast.rc // Used by flycast.rc
// //
#define IDI_ICON1 105 #define IDI_ICON1 105