From 07846c5a4f285839929009a7c74d30c0c44a0c45 Mon Sep 17 00:00:00 2001 From: Ian Lynagh Date: Wed, 31 Mar 2010 16:13:02 +0000 Subject: [PATCH] Use machdepCCOpts when compiling the file to toggle -(no-)rtsopts Should fix toggling on OS X "Snow Leopard". Diagnosed by Roman Leshchinskiy. --- compiler/main/DriverPipeline.hs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs index c0aed96..d54bb0f 100644 --- a/compiler/main/DriverPipeline.hs +++ b/compiler/main/DriverPipeline.hs @@ -1305,12 +1305,14 @@ mkExtraCObj dflags xs oFile <- newTempName dflags "o" writeFile cFile $ unlines xs let rtsDetails = getPackageDetails (pkgState dflags) rtsPackageId + (md_c_flags, _) = machdepCCOpts dflags SysTools.runCc dflags ([Option "-c", FileOption "" cFile, Option "-o", FileOption "" oFile] ++ - map (FileOption "-I") (includeDirs rtsDetails)) + map (FileOption "-I") (includeDirs rtsDetails) ++ + map Option md_c_flags) return oFile -- generates a Perl skript starting a parallel prg under PVM -- 1.7.10.4