id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc,os,architecture,failure,difficulty,testcase,blockedby,blocking,related
5093,ghc source build cannot find -lgmp even with the build.mk changes and configure options,guest,,"Hi, I have been trying to build ghc 7.0.3 from source, but the configure script itself always fails when it tries to build ghc-pwd with the error ""cannot find -lgmp"". I have gmp installed in a non-standard directory, but I have copied mk/build.mk.sample to mk/build.mk and added
{{{
EXTRA_CABAL_CONFIGURE_FLAGS = --extra-include-dirs=MY_INCLUDE_DIR \
                              --extra-lib-dirs=MY_LIB_DIR
}}}
to the end. Moreover, I have used 
{{{
--with-gmp-includes=MY_INCLUDE_DIR --with-gmp-libraries=MY_LIB_DIR
}}}
as the configure option. Yet, the configure script fails every time at the attempt to build ghc-pwd with the error message ""cannot find -lgmp"". If I manually modify ""configure"" to add -LMY_LIB_DIR to the command to build ghc-pwd, then the configure can succeed, but the make will fail when it tries to link ghc-cabal, with the same error.

Is there any way at all I can let the build take in MY_LIB_DIR? Thanks!
",bug,closed,normal,,Build System,7.0.3,invalid,gmp,pho@…,Linux,x86_64 (amd64),Building GHC failed,,,,,
