rules.mak 789 Bytes
Newer Older
1 2
# GNU Multiple Precision Arithmetic

Adrien Béraud's avatar
Adrien Béraud committed
3
GMP_VERSION := 6.1.2
4
GMP_URL := $(GNU)/gmp/gmp-$(GMP_VERSION).tar.bz2
5 6 7 8 9 10 11 12

$(TARBALLS)/gmp-$(GMP_VERSION).tar.bz2:
	$(call download,$(GMP_URL))

.sum-gmp: gmp-$(GMP_VERSION).tar.bz2

gmp: gmp-$(GMP_VERSION).tar.bz2 .sum-gmp
	$(UNPACK)
13 14 15 16 17 18
ifdef HAVE_IOS
	$(APPLY) $(SRC)/gmp/clock_gettime.patch
endif
ifdef HAVE_MACOSX
	$(APPLY) $(SRC)/gmp/clock_gettime.patch
endif
19 20 21
	$(MOVE)

.gmp: gmp
Edric Milaret's avatar
Edric Milaret committed
22
ifdef HAVE_IOS
23 24 25 26 27
	$(RECONF)
	cd $< && $(HOSTVARS) CFLAGS="$(CFLAGS) -O3" ./configure --disable-assembly --without-clock-gettime $(HOSTCONF)
else
ifdef HAVE_MACOSX
	$(RECONF)
Adrien Béraud's avatar
Adrien Béraud committed
28
	cd $< && $(HOSTVARS) ./configure --without-clock-gettime --enable-static --disable-shared $(HOSTCONF)
Edric Milaret's avatar
Edric Milaret committed
29
else
30
	cd $< && $(HOSTVARS) ./configure $(HOSTCONF)
31
endif
Edric Milaret's avatar
Edric Milaret committed
32
endif
33 34
	cd $< && $(MAKE) install
	touch $@