diff options
author | Ian Lynagh <igloo@earth.li> | 2012-07-16 20:53:21 +0100 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2012-07-16 22:40:37 +0100 |
commit | cdf946e45024f76ce4f22462f511a0490fef1dff (patch) | |
tree | 993709cdc4a579e34b056cfb31826cd2b358f340 /compiler/main/StaticFlagParser.hs | |
parent | 5d0fce85fd5c885343196142b15b8a8d2928d3fe (diff) | |
download | haskell-cdf946e45024f76ce4f22462f511a0490fef1dff.tar.gz |
Make -fPIC a dynamic flag
Hopefully I've kept the logic the same, and we now generate warnings if
the user does -fno-PIC but we ignore them (e.g. because they're on OS X
amd64).
Diffstat (limited to 'compiler/main/StaticFlagParser.hs')
-rw-r--r-- | compiler/main/StaticFlagParser.hs | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/compiler/main/StaticFlagParser.hs b/compiler/main/StaticFlagParser.hs index b927f12d2c..2ef2914b30 100644 --- a/compiler/main/StaticFlagParser.hs +++ b/compiler/main/StaticFlagParser.hs @@ -158,10 +158,6 @@ flagsStatic = [ ------ Compiler flags ----------------------------------------------- - -- -fPIC requires extra checking: only the NCG supports it. - -- See also DynFlags.parseDynamicFlags. - , Flag "fPIC" (PassFlag setPIC) - -- All other "-fno-<blah>" options cancel out "-f<blah>" on the hsc cmdline , Flag "fno-" (PrefixPred (\s -> isStaticFlag ("f"++s)) (\s -> removeOpt ("-f"++s))) @@ -171,12 +167,6 @@ flagsStatic = [ , Flag "f" (AnySuffixPred isStaticFlag addOpt) ] -setPIC :: String -> StaticP () -setPIC | cGhcWithNativeCodeGen == "YES" || cGhcUnregisterised == "YES" - = addOpt - | otherwise - = ghcError $ CmdLineError "-fPIC is not supported on this platform" - isStaticFlag :: String -> Bool isStaticFlag f = f `elem` [ @@ -196,7 +186,6 @@ isStaticFlag f = "funregisterised", "fcpr-off", "ferror-spans", - "fPIC", "fhpc" ] || any (`isPrefixOf` f) [ |