1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-02-03 10:35:03 +00:00

Fix version display in windows builds (mingw)

This commit is contained in:
troky 2014-11-16 19:52:30 +01:00
parent 32d95dd967
commit ba9818a707
2 changed files with 9 additions and 9 deletions

View File

@ -66,7 +66,7 @@ char *curly = ":D";
#include <sys/wait.h>
#endif
#ifdef GIT_VERSION
#if defined(USE_GIT_VERSION) && defined(GIT_VERSION)
#undef VERSION
#define VERSION GIT_VERSION
#endif

View File

@ -123,8 +123,8 @@
del /f "$(OutDir)*.exe"
del /f "$(OutDir)*.dll"
type nul &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt; "$(ProjectDir)dist\include\gitversion.h"
echo #define USE_GIT_VERSION 1 &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt;&gt; "$(ProjectDir)dist\include\gitversion.h"
exit 0
</Command>
</PreBuildEvent>
@ -165,8 +165,8 @@
del /f "$(OutDir)*.exe"
del /f "$(OutDir)*.dll"
type nul &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt; "$(ProjectDir)dist\include\gitversion.h"
echo #define USE_GIT_VERSION 1 &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt;&gt; "$(ProjectDir)dist\include\gitversion.h"
exit 0
</Command>
</PreBuildEvent>
@ -208,8 +208,8 @@
del /f "$(OutDir)*.exe"
del /f "$(OutDir)*.dll"
type nul &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt; "$(ProjectDir)dist\include\gitversion.h"
echo #define USE_GIT_VERSION 1 &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt;&gt; "$(ProjectDir)dist\include\gitversion.h"
exit 0
</Command>
</PreBuildEvent>
@ -252,8 +252,8 @@
del /f "$(OutDir)*.exe"
del /f "$(OutDir)*.dll"
type nul &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt; "$(ProjectDir)dist\include\gitversion.h"
echo #define USE_GIT_VERSION 1 &gt; "$(ProjectDir)dist\include\gitversion.h"
FOR /F "tokens=*" %%i IN ('call git describe "--abbrev=4" --dirty') DO echo #define GIT_VERSION "%%i" &gt;&gt; "$(ProjectDir)dist\include\gitversion.h"
exit 0
</Command>
</PreBuildEvent>