It is somewhat redundant and could make SF
name too long, so use just Version, in case
of a signature build Version will be set to
'sig-xxx' otherwise, if left empty, we fall
back on usual date stamp.
No functional change.
$(MAKE) ARCH=$(ARCH) COMP=$(COMP) all
@echo "Running benchmark for getting the signature ..."
@$(SIGNBENCH) 2>&1 | grep 'Nodes searched' | grep -o ": .*" | tr -d ': ' > sign.txt
$(MAKE) ARCH=$(ARCH) COMP=$(COMP) all
@echo "Running benchmark for getting the signature ..."
@$(SIGNBENCH) 2>&1 | grep 'Nodes searched' | grep -o ": .*" | tr -d ': ' > sign.txt
- @sed -i -e 's,^,/static const string Tag/s/"\\(.*\\)"/",1' -e 's,$$,"/1,1' sign.txt
+ @sed -i -e 's,^,/static const string Version/s/"\\(.*\\)"/"sig-,1' -e 's,$$,"/1,1' sign.txt
@sed -i -f sign.txt misc.cpp
@rm sign.txt
$(MAKE) ARCH=$(ARCH) COMP=$(COMP) all
@sed -i -f sign.txt misc.cpp
@rm sign.txt
$(MAKE) ARCH=$(ARCH) COMP=$(COMP) all
-/// Version number. If Version is left empty, then Tag plus current
-/// date, in the format DD-MM-YY, are used as a version number.
-
+/// Version number. If Version is left empty, then compile date, in the
+/// format DD-MM-YY, is shown in engine_info.
static const string Version = "";
static const string Version = "";
-static const string Tag = "";
/// engine_info() returns the full name of the current Stockfish version. This
/// engine_info() returns the full name of the current Stockfish version. This
string month, day, year;
stringstream s, date(__DATE__); // From compiler, format is "Sep 21 2008"
string month, day, year;
stringstream s, date(__DATE__); // From compiler, format is "Sep 21 2008"
- s << "Stockfish " << Version;
+ s << "Stockfish " << Version << setfill('0');
if (Version.empty())
{
date >> month >> day >> year;
if (Version.empty())
{
date >> month >> day >> year;
-
- s << Tag << string(Tag.empty() ? "" : " ") << setfill('0') << setw(2) << day
- << setw(2) << (1 + months.find(month) / 4) << year.substr(2);
+ s << setw(2) << day << setw(2) << (1 + months.find(month) / 4) << year.substr(2);
}
s << (Is64Bit ? " 64" : "")
}
s << (Is64Bit ? " 64" : "")