From 2753f97adb8be522b4b75a9e7bde2bbdeb806440 Mon Sep 17 00:00:00 2001 From: JazzyNico Date: Fri, 31 Jul 2009 13:31:14 +0000 Subject: [PATCH] Fix for LP #386256 (Inkscape-0.47pre0 does not build on win32). Returns an empty string instead of false when looking for svn.revision when the snapshot doesn't contain an svn dir. --- build.xml | 2 +- buildtool.cpp | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/build.xml b/build.xml index 62eda3aaa..3d21a6740 100644 --- a/build.xml +++ b/build.xml @@ -103,7 +103,7 @@ namespace Inkscape { - char const *version_string = "${version} r${svn.revision}"; + char const *version_string = "${version} ${svn.revision}"; } diff --git a/buildtool.cpp b/buildtool.cpp index 4ba7ccfe9..538a6faa5 100644 --- a/buildtool.cpp +++ b/buildtool.cpp @@ -4704,6 +4704,12 @@ bool MakeBase::lookupProperty(const String &propertyName, String &result) varname = varname.substr(svnPrefix.size()); String val; SvnInfo svnInfo; + if (varname == "revision") + { + if (!svnInfo.query(varname, val)) + return ""; + result = "r"+val; + } if (!svnInfo.query(varname, val)) return false; result = val; -- 2.30.2