finding C compiler and preprocessor?
simonpj at microsoft.com
Thu Mar 18 14:08:42 EST 2004
ghc -v Foo.hs
will show you what C compiler GHC invokes
| -----Original Message-----
| From: glasgow-haskell-users-bounces at haskell.org
| bounces at haskell.org] On Behalf Of David Roundy
| Sent: 18 March 2004 14:05
| To: glasgow-haskell-users at haskell.org
| Subject: finding C compiler and preprocessor?
| Is there any way to find out what C compiler and preprocessor are used
| I've run into problems with a windows user, since the ghc distribution
| apparently uses a different compiler than the one that my configure
| finds, and so the configure script indicates that a certain header
| found, but then the program fails to compile, since ghc doesn't find
| :( The only other option that comes to mind would be to write autoconf
| macros to check for header files and/or libraries using ghc, but that
| sounds to me like a real pain.
| Alternatively, if I could tell ghc which compiler to use, that would
| as well, since autoconf is perfectly capable of identifying a working
| I've tried telling autoconf that ghc is my C compiler, but that fails
| the user provides a CFLAGS that isn't supported by ghc. One could get
| around this by prepending -optc to all the CFLAGS (but I haven't
| out how to do this in shell), but then there is still the trouble of
| to convince ghc to preprocess a C file with the C preprocessor. :(
| Any suggestions would be welcome!
| David Roundy
| Glasgow-haskell-users mailing list
| Glasgow-haskell-users at haskell.org
More information about the Glasgow-haskell-users