apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pque...@apache.org
Subject svn commit: r751554 - /apr/apr/trunk/build/aprconf.py
Date Sun, 08 Mar 2009 23:44:30 GMT
Author: pquerna
Date: Sun Mar  8 23:44:30 2009
New Revision: 751554

URL: http://svn.apache.org/viewvc?rev=751554&view=rev
Log:
SCons:
Fix usage of TryRun:
  """Returns (1, outputStr) on success, (0, '') otherwise."""
We were recording failure as success, which means lots of things weren't quite right.

Modified:
    apr/apr/trunk/build/aprconf.py

Modified: apr/apr/trunk/build/aprconf.py
URL: http://svn.apache.org/viewvc/apr/apr/trunk/build/aprconf.py?rev=751554&r1=751553&r2=751554&view=diff
==============================================================================
--- apr/apr/trunk/build/aprconf.py (original)
+++ apr/apr/trunk/build/aprconf.py Sun Mar  8 23:44:30 2009
@@ -1,4 +1,5 @@
 import os
+import sys
 
 class APRConfigureBase:
     def __init__(self, env):
@@ -70,8 +71,8 @@
 }
     """
         result = context.TryRun(source, '.c')
-        context.Result(result[0] == 0)
-        return result[0] == 0
+        context.Result(result[0] == 1)
+        return result[0] == 1
 
     def Check_apr_ebcdic(self, context):
         context.Message('Checking whether system uses EBCDIC.. ')
@@ -80,8 +81,8 @@
   return (unsigned char)'A' != (unsigned char)0xC1; 
 }"""
         result = context.TryRun(source, '.c')
-        context.Result(result[0])
-        return result[0]
+        context.Result(result[0] == 1)
+        return result[0] == 1
         
     def Check_apr_nonblock_inherited(self, context):
         context.Message('Checking whether O_NONBLOCK setting is inherited from listening
sockets... ')
@@ -180,8 +181,8 @@
     return 0;
 }"""
         result = context.TryRun(source, '.c')
-        context.Result(result[0] == 0)
-        return result[0] == 0
+        context.Result(result[0] == 1)
+        return result[0] == 1
 
     def Check_apr_largefile64(self, context):
         context.Message('Checking whether to enable -D_LARGEFILE64_SOURCE... ')
@@ -222,8 +223,8 @@
 }"""
         result = context.TryRun(source, '.c')
         self.env.Filter(CPPFLAGS = ['-D_LARGEFILE64_SOURCE'])
-        context.Result(result[0] == 0)
-        return result[0] == 0
+        context.Result(result[0] == 1)
+        return result[0] == 1
 
 
     def Check_apr_mmap_mapping_dev_zero(self, context):
@@ -252,8 +253,8 @@
     }
         """
         result = context.TryRun(source, '.c')
-        context.Result(result[0] == 0)
-        return result[0] == 0
+        context.Result(result[0] == 1)
+        return result[0] == 1
 
     def Check_apr_semaphores(self, context):
         context.Message('Checking for sem_open, sem_close, sem_unlink... ')
@@ -375,8 +376,8 @@
     return 0;
 } """ 
         result = context.TryRun(source, '.c') 
-        context.Result(result[0] == 0)
-        return result[0] == 0
+        context.Result(result[0] == 1)
+        return result[0] == 1
 
     def Check_apr_semun(self, context):
         context.Message('Checking for semun... ')



Mime
View raw message