mxe/src/mpfr.mk

40 lines
1.5 KiB
Makefile
Raw Normal View History

2012-03-28 14:46:58 +01:00
# This file is part of MXE.
2012-03-29 11:14:15 +01:00
# See index.html for further information.
2011-10-21 23:24:34 +01:00
PKG := mpfr
$(PKG)_IGNORE :=
2015-06-20 09:26:33 +01:00
$(PKG)_VERSION := 3.1.3
$(PKG)_CHECKSUM := 6835a08bd992c8257641791e9a6a2b35b02336c8de26d0a8577953747e514a16
$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
2012-07-04 08:00:57 +01:00
$(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.xz
$(PKG)_URL := ftp://ftp.gnu.org/pub/gnu/$(PKG)/$($(PKG)_FILE)
2011-10-23 03:37:14 +01:00
$(PKG)_URL_2 := http://www.mpfr.org/mpfr-$($(PKG)_VERSION)/$($(PKG)_FILE)
2011-10-21 23:24:34 +01:00
$(PKG)_DEPS := gcc gmp
define $(PKG)_UPDATE
$(WGET) -q -O- 'http://www.mpfr.org/mpfr-current/#download' | \
2011-10-21 23:24:34 +01:00
grep 'mpfr-' | \
$(SED) -n 's,.*mpfr-\([0-9][^>]*\)\.tar.*,\1,p' | \
head -1
endef
define $(PKG)_BUILD
cd '$(1)' && ./configure \
$(MXE_CONFIGURE_OPTS) \
2011-10-21 23:24:34 +01:00
--enable-threads=win32 \
--with-gmp-include='$(PREFIX)/$(TARGET)/include/'
--with-gmp-lib='$(PREFIX)/$(TARGET)/lib/'
2011-10-21 23:24:34 +01:00
$(MAKE) -C '$(1)' -j '$(JOBS)'
$(MAKE) -C '$(1)' -j '$(JOBS)' install
# build runtime tests to verify toolchain components
-$(MAKE) -C '$(1)' -j '$(JOBS)' check -k
rm -rf '$(PREFIX)/$(TARGET)/bin/$(PKG)-tests'
cp -R '$(1)/tests' '$(PREFIX)/$(TARGET)/bin/$(PKG)-tests'
(printf 'date /t > all-tests-$(PKG)-$($(PKG)_VERSION).txt\r\n'; \
printf 'time /t >> all-tests-$(PKG)-$($(PKG)_VERSION).txt\r\n'; \
printf 'set PATH=..\\;%%PATH%%\r\n'; \
printf 'for /R %%%%f in (*.exe) do %%%%f || echo %%%%f fail >> all-tests-$(PKG)-$($(PKG)_VERSION).txt\r\n';) \
> '$(PREFIX)/$(TARGET)/bin/$(PKG)-tests/all-tests-$(PKG)-$($(PKG)_VERSION).bat'
2011-10-21 23:24:34 +01:00
endef