mail[Wesnoth-commits] r25410 - /trunk/SConstruct


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by loonycyborg on March 31, 2008 - 22:20:
Author: loonycyborg
Date: Mon Mar 31 22:20:30 2008
New Revision: 25410

URL: http://svn.gna.org/viewcvs/wesnoth?rev=25410&view=rev
Log:
Made scons recipe automatically delete temporary .wml.po and .cpp.po files.

Modified:
    trunk/SConstruct

Modified: trunk/SConstruct
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/SConstruct?rev=25410&r1=25409&r2=25410&view=diff
==============================================================================
--- trunk/SConstruct (original)
+++ trunk/SConstruct Mon Mar 31 22:20:30 2008
@@ -946,15 +946,27 @@
         env.Precious(pot)
         NoClean(pot)
         if cfgs and sources:
-            env.Command(
-                pot,
-                [source_pot, wml_pot],
-                "msgcat --sort-by-file $SOURCES -o $TARGET"
+            env.AddPostAction(
+                env.Command(
+                    pot,
+                    [source_pot, wml_pot],
+                    "msgcat --sort-by-file $SOURCES -o $TARGET"
+                    ),
+                        [
+                        Delete(os.path.join(domain, name + ".wml.po")),
+                        Delete(os.path.join(domain, name + ".cpp.po"))
+                        ]
                 )
         elif cfgs:
-            env.InstallAs(pot, wml_pot)
+            env.AddPostAction(
+                env.InstallAs(pot, wml_pot),
+                    Delete(os.path.join(domain, name + ".wml.po"))
+                )
         else:
-            env.InstallAs(pot, source_pot)
+            env.AddPostAction(
+                env.InstallAs(pot, source_pot),
+                    Delete(os.path.join(domain, name + ".cpp.po"))
+                )
     env.Alias("pot-update", "po")
 
 if "update-po" in COMMAND_LINE_TARGETS:




Related Messages


Powered by MHonArc, Updated Mon Mar 31 22:42:14 2008