Author: loonycyborg
Date: Thu May  1 10:51:30 2008
New Revision: 26271

URL: http://svn.gna.org/viewcvs/wesnoth?rev=26271&view=rev
Log:
- Fixed InstallWithSuffix crash if some binaries are disabled.
- Worked around scons bug that caused spurious success of C++ check.

Modified:
    trunk/SConstruct

Modified: trunk/SConstruct
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/SConstruct?rev=26271&r1=26270&r2=26271&view=diff
==============================================================================
--- trunk/SConstruct (original)
+++ trunk/SConstruct Thu May  1 10:51:30 2008
@@ -185,7 +185,7 @@
         \n""" % version_num
     message += "... "
     context.Message(message)
-    if context.TryBuild(context.env.Program, test_program, ".cpp") == 1:
+    if context.TryBuild(context.env.Program, test_program, ".cpp") == 1 and 
context.lastTarget.get_contents() != "":
         context.Result("yes")
         return True
     else:
@@ -647,6 +647,8 @@
 env.Append(BUILDERS={'InstallFiltered':Builder(action=InstallFilteredHook)})
 
 def InstallWithSuffix(env, target, source):
+    if not source:
+        return source
     return env.InstallAs(os.path.join(target, source[0].name + 
env["program_suffix"]), source)
 
 #env.AddMethod(InstallWithSuffix)


_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits

Reply via email to