ghc --make + #include directories

Simon Marlow
Wed, 14 Nov 2001 15:45:33 -0000

> Thanks to ghc --make it is now common to compile files from a=20
> different directory.
> This creates a new problem, in that if a file starts with a=20
> {-# include <c-header.h> #-}
> directive, ghc will try to find c-header.h in the current=20
> directory, not in the directory
> containing the source file.  So we need a way of changing the=20
> gcc include path during
> compilation of .hc files to include the directory containing=20
> the source file.

What's wrong with just saying -I<dir> whenever you say -i<dir>?