struct / union in initializer, RFE #901.
[sdcc.git] / sdcc-cf / packages / build.gmp_mpfr / Makefile
blob0049d1e50178397004b1c3a3a9508d260ed0001a
1 include ../packages.mk
3 GMP_VERSION = 5.0.5
4 MPFR_VERSION = 3.1.6
5 MPC_VERSION = 0.9
7 GMP_DIR = gmp-$(GMP_VERSION)
8 MPFR_DIR = mpfr-$(MPFR_VERSION)
9 MPC_DIR = mpc-$(MPC_VERSION)
11 ifeq ($(OS),SunOS)
12 CFGENV=CFLAGS='-xO3 -m32' ABI=32
13 endif
15 .PHONY: all
16 all: gmp-install.tag gmp-clean mpfr-install.tag mpfr-clean mpc-install.tag mpc-clean
18 .PHONY: clean
19 clean: gmp-clean mpfr-clean mpc-clean
20 rm -rf download/* *.tag
23 download/gmp-$(GMP_VERSION).tar.bz2:
24 wget -P download ftp://ftp.gnu.org/gnu/gmp/gmp-$(GMP_VERSION).tar.bz2
26 gmp-unpack.tag: download/gmp-$(GMP_VERSION).tar.bz2
27 tar xjf download/gmp-$(GMP_VERSION).tar.bz2
28 touch $@
30 gmp-configure.tag: gmp-unpack.tag
31 cd $(GMP_DIR) && \
32 ./configure --prefix=$(LOCAL_DIR) $(CFGENV)
33 touch $@
35 gmp-make.tag: gmp-configure.tag
36 make -C $(GMP_DIR)
37 touch $@
39 gmp-install.tag: gmp-make.tag
40 make -C $(GMP_DIR) install
41 touch $@
44 download/mpfr-$(MPFR_VERSION).tar.bz2:
45 wget -P download http://www.mpfr.org/mpfr-$(MPFR_VERSION)/mpfr-$(MPFR_VERSION).tar.bz2
47 mpfr-unpack.tag: download/mpfr-$(MPFR_VERSION).tar.bz2
48 tar xjf download/mpfr-$(MPFR_VERSION).tar.bz2
49 touch $@
51 mpfr-configure.tag: mpfr-unpack.tag
52 cd $(MPFR_DIR) && \
53 ./configure --prefix=$(LOCAL_DIR) --with-gmp=$(LOCAL_DIR) $(CFGENV)
54 touch $@
56 mpfr-make.tag: mpfr-configure.tag
57 make -C $(MPFR_DIR)
58 touch $@
60 mpfr-install.tag: mpfr-make.tag
61 make -C $(MPFR_DIR) install
62 touch $@
65 download/mpc-$(MPC_VERSION).tar.gz:
66 wget -P download http://www.multiprecision.org/downloads/mpc-$(MPC_VERSION).tar.gz
68 mpc-unpack.tag: download/mpc-$(MPC_VERSION).tar.gz
69 tar xzf download/mpc-$(MPC_VERSION).tar.gz
70 touch $@
72 mpc-configure.tag: mpc-unpack.tag
73 cd $(MPC_DIR) && \
74 ./configure --prefix=$(LOCAL_DIR) --with-gmp=$(LOCAL_DIR) --with-mpfr=$(LOCAL_DIR) $(CFGENV)
75 touch $@
77 mpc-make.tag: mpc-configure.tag
78 make -C $(MPC_DIR)
79 touch $@
81 mpc-install.tag: mpc-make.tag
82 make -C $(MPC_DIR) install
83 touch $@
86 .PHONY: gmp-clean
87 gmp-clean:
88 rm -rf $(GMP_DIR) gmp-*.tag
90 .PHONY: mpfr-clean
91 mpfr-clean:
92 rm -rf $(MPFR_DIR) mpfr-*.tag
94 .PHONY: mpc-clean
95 mpc-clean:
96 rm -rf $(MPC_DIR) mpc-*.tag