building against gmp in a nonstandard location

Ian Lynagh igloo at earth.li
Thu Mar 20 10:31:10 EDT 2008


Hi Paul,

On Sun, Mar 16, 2008 at 12:05:03AM -0400, Paul Jarc wrote:
> 
> make[1]: *** No rule to make target `stage1//package/host/code.dogmap.org/foreign/ghc-6.8.2+spf+0/conf/gmp/include/gmp.h', needed by `stage1/parser/cutils.o'.  Stop.

Where is gmp.h actually installed?

Do you know where this dependency is coming from? Is it
compiler/.depend-1? If so, try looking at the mkdependC commandline and
see if that provides any clues.

> Second attempt: CPPFLAGS, LDFLAGS and mk/build.mk as above, and I also
> gave --with-gmp-{includes,libraries} to ./configure.  This ends with
> the same error.

What happens if you only use the flags?

> Third attempt: all of the above, plus I modified mkdependC.prl to omit
> dependencies on absolute paths.  (I suspect this is wrong, since I
> assume other people have successfully used gmp in a nonstandard path
> without having to patch anything, but anyway...)  New failure:
> 
> ../../compiler/stage1/ghc-inplace -Iinclude -package rts-1.0 -optc-O2 -odir dist/build -c cbits/longlong.c -o dist/build/cbits/longlong.o
> In file included from /fs/pkgs/mount/package/host/code.dogmap.org/foreign/ghc-6.8.2+spf+0/compile/src/ghc-6.8.2/includes/Stg.h:150,
>                  from /fs/pkgs/mount/package/host/code.dogmap.org/foreign/ghc-6.8.2+spf+0/compile/src/ghc-6.8.2/includes/Rts.h:19,
>                  from cbits/longlong.c:29:0: 
> /fs/pkgs/mount/package/host/code.dogmap.org/foreign/ghc-6.8.2+spf+0/compile/src/ghc-6.8.2/includes/Regs.h:28:17:
>      error: gmp.h: No such file or directory
> 
> I would have thought the SRC_HC_OPTS options I put in mk/build.mk
> would be used for this compilation, but apparently not.  Does anyone
> see where the problem might be?

This is compiling a C file, so it uses SRC_CC_OPTS instead.


Thanks
Ian



More information about the Glasgow-haskell-users mailing list