mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-28 23:02:07 +00:00
- Remove the first parameter from updaterevision, since it isn't needed with git.
This commit is contained in:
parent
1032170ccd
commit
a5f5d8adcb
3 changed files with 11 additions and 11 deletions
|
@ -488,7 +488,7 @@ endif( BACKPATCH )
|
||||||
get_target_property( UPDATEREVISION_EXE updaterevision LOCATION )
|
get_target_property( UPDATEREVISION_EXE updaterevision LOCATION )
|
||||||
|
|
||||||
add_custom_target( revision_check ALL
|
add_custom_target( revision_check ALL
|
||||||
COMMAND ${UPDATEREVISION_EXE} . src/gitinfo.h
|
COMMAND ${UPDATEREVISION_EXE} src/gitinfo.h
|
||||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||||
DEPENDS updaterevision )
|
DEPENDS updaterevision )
|
||||||
|
|
||||||
|
|
|
@ -41,9 +41,9 @@ int main(int argc, char **argv)
|
||||||
vertag[0] = '\0';
|
vertag[0] = '\0';
|
||||||
lastlog[0] = '\0';
|
lastlog[0] = '\0';
|
||||||
|
|
||||||
if (argc != 3)
|
if (argc != 2)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "Usage: %s <repository directory> <path to gitinfo.h>\n", argv[0]);
|
fprintf(stderr, "Usage: %s <path to gitinfo.h>\n", argv[0]);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -85,7 +85,7 @@ int main(int argc, char **argv)
|
||||||
hash = lastlog + 1;
|
hash = lastlog + 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
stream = fopen (argv[2], "r");
|
stream = fopen (argv[1], "r");
|
||||||
if (stream != NULL)
|
if (stream != NULL)
|
||||||
{
|
{
|
||||||
if (!gotrev)
|
if (!gotrev)
|
||||||
|
@ -109,7 +109,7 @@ int main(int argc, char **argv)
|
||||||
|
|
||||||
if (needupdate)
|
if (needupdate)
|
||||||
{
|
{
|
||||||
stream = fopen (argv[2], "w");
|
stream = fopen (argv[1], "w");
|
||||||
if (stream == NULL)
|
if (stream == NULL)
|
||||||
{
|
{
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -125,11 +125,11 @@ int main(int argc, char **argv)
|
||||||
"#define GIT_TIME \"%s\"\n",
|
"#define GIT_TIME \"%s\"\n",
|
||||||
hash, vertag, hash, lastlog);
|
hash, vertag, hash, lastlog);
|
||||||
fclose(stream);
|
fclose(stream);
|
||||||
fprintf(stderr, "%s updated to commit %s.\n", argv[2], vertag);
|
fprintf(stderr, "%s updated to commit %s.\n", argv[1], vertag);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
fprintf (stderr, "%s is up to date at commit %s.\n", argv[2], vertag);
|
fprintf (stderr, "%s is up to date at commit %s.\n", argv[1], vertag);
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking gitinfo.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -152,7 +152,7 @@
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking gitinfo.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -265,7 +265,7 @@
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking gitinfo.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -372,7 +372,7 @@
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking gitinfo.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
|
Loading…
Reference in a new issue