summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBob Jamison <ishmalius@gmail.com>2007-01-11 21:28:22 +0000
committerishmal <ishmal@users.sourceforge.net>2007-01-11 21:28:22 +0000
commitc862a0f96937fde87b6b62e4d53b0aed0672c2b5 (patch)
tree6e4f7cedf6f6b731a71ec831ab20d021d96e59d7
parentlessen the overkill nature of whiteboard's Quit (diff)
downloadinkscape-c862a0f96937fde87b6b62e4d53b0aed0672c2b5.tar.gz
inkscape-c862a0f96937fde87b6b62e4d53b0aed0672c2b5.zip
Allow overriding output name for msgfmt
(bzr r2184)
-rw-r--r--build.xml3
-rw-r--r--buildtool.cpp23
2 files changed, 20 insertions, 6 deletions
diff --git a/build.xml b/build.xml
index b423e3cad..dcec565e1 100644
--- a/build.xml
+++ b/build.xml
@@ -211,7 +211,8 @@
</target>
<target name="i18n" depends="compile">
- <msgfmt todir="${build}/locale" owndir="true">
+ <msgfmt todir="${build}/locale" owndir="true"
+ out="LC_MESSAGES/inkscape.mo">
<fileset dir="po">
</fileset>
</msgfmt>
diff --git a/buildtool.cpp b/buildtool.cpp
index 747e9577e..f78bf8ee8 100644
--- a/buildtool.cpp
+++ b/buildtool.cpp
@@ -6663,6 +6663,7 @@ public:
name = "msgfmt";
command = "msgfmt";
owndir = false;
+ outName = "";
}
virtual ~TaskMsgFmt()
@@ -6704,8 +6705,17 @@ public:
destPath.append(subdir);
destPath.append("/");
}
- destPath.append(fileName);
- destPath[destPath.size()-2] = 'm';
+ //Pick the output file name
+ if (outName.size() > 0)
+ {
+ destPath.append(outName);
+ }
+ else
+ {
+ destPath.append(fileName);
+ destPath[destPath.size()-2] = 'm';
+ }
+
String fullDest = parent.resolve(destPath);
if (!isNewerThan(fullSource, fullDest))
@@ -6750,6 +6760,8 @@ public:
command = s;
if (!parent.getAttribute(elem, "todir", toDirName))
return false;
+ if (!parent.getAttribute(elem, "out", outName))
+ return false;
if (!parent.getAttribute(elem, "owndir", s))
return false;
if (!getBool(s, owndir))
@@ -6771,10 +6783,11 @@ public:
private:
- String command;
- String toDirName;
+ String command;
+ String toDirName;
+ String outName;
FileSet fileSet;
- bool owndir;
+ bool owndir;
};