diff options
author | Jack Palevich <jackpal@google.com> | 2009-11-12 15:21:42 +0800 |
---|---|---|
committer | Jack Palevich <jackpal@google.com> | 2009-11-12 15:21:42 +0800 |
commit | e0f9d91dc73d293764822dcb1b49a4cef5d12275 (patch) | |
tree | 0b0d9129a989d45089d06d6d6f02abbf421a7ce4 /libacc | |
parent | 464407588fce5991b7e6e654695f0665d7f2d008 (diff) | |
download | system_core-e0f9d91dc73d293764822dcb1b49a4cef5d12275.zip system_core-e0f9d91dc73d293764822dcb1b49a4cef5d12275.tar.gz system_core-e0f9d91dc73d293764822dcb1b49a4cef5d12275.tar.bz2 |
Skip OTCCANSI test on OS X
OS X can't load stderr/stdin/stdout through the DLL symbol lookup
interface, so it can't compile the otcc-ansi.c test.
Diffstat (limited to 'libacc')
-rw-r--r-- | libacc/tests/test.py | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/libacc/tests/test.py b/libacc/tests/test.py index c32ce9f..1b444c7 100644 --- a/libacc/tests/test.py +++ b/libacc/tests/test.py @@ -10,6 +10,7 @@ gArmInitialized = False gUseArm = True gUseX86 = True gRunOTCCOutput = True +gCompileOTCCANSI = True def parseArgv(): @@ -59,7 +60,12 @@ def outputCanRun(): def checkEnvironment(): global gRunOTCCOutput - gRunOTCCOutput = uname() == "Linux" and unameM() != "x86_64" and outputCanRun() + global gCompileOTCCANSI + osName = uname() + gRunOTCCOutput = osName == "Linux" and unameM() != "x86_64" and outputCanRun() + # OSX doesn't have stdin/stdout/stderr accessible through dll load symbols, so + # we can't compile the ANSI version of the OTCC compiler on OS X. + gCompileOTCCANSI = osName == "Linux" def adb(args): return runCmd(["adb"] + args) @@ -180,8 +186,10 @@ class TestACC(unittest.TestCase): def testCompileReturnVal(self): self.compileCheck(["data/returnval-ansi.c"], "") - def testCompileOTCCANSII(self): - self.compileCheck(["data/otcc-ansi.c"], "", "", ['x86']) + def testCompileOTCCANSI(self): + global gCompileOTCCANSI + if gCompileOTCCANSI: + self.compileCheck(["data/otcc-ansi.c"], "", "", ['x86']) def testRunReturnVal(self): self.compileCheck(["-R", "data/returnval-ansi.c"], |