-----------------------------------------------------------------------------
--- $Id: DriverPipeline.hs,v 1.91 2001/07/19 14:23:16 rrt Exp $
+-- $Id: DriverPipeline.hs,v 1.92 2001/07/23 20:19:53 sof Exp $
--
-- GHC Driver
--
[ "-u", "_PrelMain_mainIO_closure" ,
"-u", "___init_PrelMain"]
#else
- [ "-u", "PrelMain_mainIO_closure" ,
- "-u", "__init_PrelMain"]
+ [ "-u", prefixUnderscore "PrelMain_mainIO_closure" ,
+ "-u", prefixUnderscore "__init_PrelMain"]
#endif
else [])
-----------------------------------------------------------------------------
--- $Id: DriverUtil.hs,v 1.25 2001/06/27 10:14:13 rrt Exp $
+-- $Id: DriverUtil.hs,v 1.26 2001/07/23 20:19:53 sof Exp $
--
-- Utils for the driver
--
import Util
import Panic
+import Config ( cLeadingUnderscore )
import IOExts
import Exception
)
-----------------------------------------------------------------------------
+-- Prefixing underscore to linker-level names
+prefixUnderscore :: String -> String
+prefixUnderscore
+ | cLeadingUnderscore == "YES" = ('_':)
+ | otherwise = id
+
+-----------------------------------------------------------------------------
-- Utils
unknownFlagErr :: String -> a