pass $(AR) to the GMP build
authorSimon Marlow <marlowsd@gmail.com>
Thu, 10 Jun 2010 08:08:42 +0000 (08:08 +0000)
committerSimon Marlow <marlowsd@gmail.com>
Thu, 10 Jun 2010 08:08:42 +0000 (08:08 +0000)
gmp/ghc.mk

index 0e6a4aa..8496b83 100644 (file)
@@ -116,15 +116,13 @@ libraries/integer-gmp/gmp/libgmp.a libraries/integer-gmp/gmp/gmp.h:
            PATH=`pwd`:$$PATH; \
            export PATH; \
            cd gmpbuild && \
-           CC=$(WhatGccIsCalled) NM=$(NM) $(SHELL) configure \
+           CC=$(WhatGccIsCalled) NM=$(NM) AR=$(AR) $(SHELL) configure \
                  --enable-shared=no --host=$(PLATFORM) --build=$(PLATFORM)
        $(MAKE) -C libraries/integer-gmp/gmp/gmpbuild MAKEFLAGS=
        $(CP) libraries/integer-gmp/gmp/gmpbuild/gmp.h libraries/integer-gmp/gmp/
        $(CP) libraries/integer-gmp/gmp/gmpbuild/.libs/libgmp.a libraries/integer-gmp/gmp/
        $(MKDIRHIER) libraries/integer-gmp/gmp/objs
-# XXX This should be $(AR), except that has the creation options baked in,
-# so we use ar for now instead
-       cd libraries/integer-gmp/gmp/objs && ar x ../libgmp.a
+       cd libraries/integer-gmp/gmp/objs && $(AR) x ../libgmp.a
        $(RANLIB) libraries/integer-gmp/gmp/libgmp.a
 
 ifneq "$(NO_CLEAN_GMP)" "YES"