summaryrefslogtreecommitdiffstats
path: root/package/mpfr/mpfr.mk
diff options
context:
space:
mode:
Diffstat (limited to 'package/mpfr/mpfr.mk')
-rw-r--r--package/mpfr/mpfr.mk65
1 files changed, 19 insertions, 46 deletions
diff --git a/package/mpfr/mpfr.mk b/package/mpfr/mpfr.mk
index 836d4690d..6d6afa578 100644
--- a/package/mpfr/mpfr.mk
+++ b/package/mpfr/mpfr.mk
@@ -52,70 +52,45 @@ ifneq ($(MPFR_PATCH),)
endif
touch $@
-$(MPFR_TARGET_DIR)/.configured: $(MPFR_DIR)/.unpacked $(STAGING_DIR)/lib/$(GMP_BINARY)
+$(MPFR_TARGET_DIR)/.configured: $(MPFR_DIR)/.unpacked $(STAGING_DIR)/usr/lib/$(GMP_BINARY)
mkdir -p $(MPFR_TARGET_DIR)
(cd $(MPFR_TARGET_DIR); rm -rf config.cache; \
$(TARGET_CONFIGURE_OPTS) \
- CFLAGS="$(TARGET_CFLAGS)" \
- LDFLAGS="$(TARGET_LDFLAGS)" \
ac_cv_c_bigendian=$(MPFR_BE) \
$(MPFR_DIR)/configure \
--target=$(GNU_TARGET_NAME) \
--host=$(GNU_TARGET_NAME) \
--build=$(GNU_HOST_NAME) \
--prefix=/usr \
- --exec-prefix=/usr \
- --bindir=/usr/bin \
- --sbindir=/usr/sbin \
- --libdir=/lib \
- --libexecdir=/usr/lib \
- --sysconfdir=/etc \
- --datadir=/usr/share \
- --localstatedir=/var \
- --includedir=/include \
- --mandir=/usr/man \
- --infodir=/usr/info \
- --enable-shared \
- --with-gmp=$(STAGING_DIR) \
+ $(PREFERRED_LIB_FLAGS) \
+ --with-gmp=$(GMP_TARGET_DIR) \
$(DISABLE_NLS) \
);
touch $@
$(MPFR_TARGET_DIR)/.libs/$(MPFR_BINARY): $(MPFR_TARGET_DIR)/.configured
- $(MAKE) CC=$(TARGET_CC) -C $(MPFR_TARGET_DIR)
-
-$(STAGING_DIR)/lib/$(MPFR_BINARY): $(MPFR_TARGET_DIR)/.libs/$(MPFR_BINARY)
- $(MAKE) prefix=$(STAGING_DIR) \
- exec_prefix=$(STAGING_DIR) \
- bindir=$(STAGING_DIR)/bin \
- sbindir=$(STAGING_DIR)/sbin \
- libexecdir=$(STAGING_DIR)/bin \
- datadir=$(STAGING_DIR)/share \
- sysconfdir=$(STAGING_DIR)/etc \
- sharedstatedir=$(STAGING_DIR)/com \
- localstatedir=$(STAGING_DIR)/var \
- libdir=$(STAGING_DIR)/lib \
- includedir=$(STAGING_DIR)/include \
- oldincludedir=$(STAGING_DIR)/include \
- infodir=$(STAGING_DIR)/info \
- mandir=$(STAGING_DIR)/man \
- -C $(MPFR_TARGET_DIR) install;
- $(STRIP) --strip-unneeded $(STAGING_DIR)/lib/libmpfr$(LIBTGTEXT)*
-
-$(TARGET_DIR)/lib/libmpfr.so $(TARGET_DIR)/lib/libmpfr.so.$(MPFR_LIBVERSION) $(TARGET_DIR)/lib/libmpfr.a: $(STAGING_DIR)/lib/$(MPFR_BINARY)
- cp -dpf $(STAGING_DIR)/lib/libmpfr$(LIBTGTEXT)* $(TARGET_DIR)/lib/
+ #$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(MPFR_TARGET_DIR)
+ $(MAKE) -C $(MPFR_TARGET_DIR)
+
+$(STAGING_DIR)/usr/lib/$(MPFR_BINARY): $(MPFR_TARGET_DIR)/.libs/$(MPFR_BINARY)
+ $(MAKE) DESTDIR=$(STAGING_DIR) -C $(MPFR_TARGET_DIR) install;
+ $(STRIP) --strip-unneeded $(STAGING_DIR)/usr/lib/libmpfr$(LIBTGTEXT)*
+
+$(TARGET_DIR)/usr/lib/libmpfr.so $(TARGET_DIR)/usr/lib/libmpfr.so.$(MPFR_LIBVERSION) $(TARGET_DIR)/usr/lib/libmpfr.a: $(STAGING_DIR)/usr/lib/$(MPFR_BINARY)
+ cp -dpf $(STAGING_DIR)/usr/lib/libmpfr$(LIBTGTEXT)* $(TARGET_DIR)/usr/lib/
ifeq ($(BR2_PACKAGE_LIBMPFR_HEADERS),y)
- cp -dpf $(STAGING_DIR)/include/mpfr.h $(STAGING_DIR)/include/mpf2mpfr.h \
+ cp -dpf $(STAGING_DIR)/usr/include/mpfr.h $(STAGING_DIR)/usr/include/mpf2mpfr.h \
$(TARGET_DIR)/usr/include/
endif
-libmpfr: uclibc $(TARGET_DIR)/lib/libmpfr$(LIBTGTEXT)
-stage-libmpfr: uclibc $(STAGING_DIR)/lib/$(MPFR_BINARY)
+libmpfr: uclibc $(TARGET_DIR)/usr/lib/libmpfr$(LIBTGTEXT)
+stage-libmpfr: uclibc $(STAGING_DIR)/usr/lib/$(MPFR_BINARY)
libmpfr-clean:
- rm -f $(TARGET_DIR)/lib/libmpfr.* \
+ rm -f $(TARGET_DIR)/usr/lib/libmpfr.* \
$(TARGET_DIR)/usr/include/mpfr.h \
- $(TARGET_DIR)/usr/include/mpf2mpfr.h
+ $(TARGET_DIR)/usr/include/mpf2mpfr.h \
+ $(STAGING_DIR)/usr/lib/libmpfr* $(STAGING_DIR)/usr/include/mpfr*
-$(MAKE) -C $(MPFR_TARGET_DIR) clean
libmpfr-dirclean:
@@ -126,13 +101,11 @@ MPFR_HOST_DIR:=$(TOOL_BUILD_DIR)/mpfr
$(MPFR_DIR2)/.configured: $(MPFR_DIR)/.unpacked $(GMP_HOST_DIR)/lib/$(GMP_HOST_BINARY)
mkdir -p $(MPFR_DIR2)
(cd $(MPFR_DIR2); \
- CC="$(HOSTCC)" CC_FOR_BUILD="$(HOSTCC)" \
- CXX="$(HOSTCXX)" \
+ $(HOST_CONFIGURE_OPTS) \
$(MPFR_DIR)/configure \
--prefix="$(MPFR_HOST_DIR)" \
--build=$(GNU_HOST_NAME) \
--host=$(GNU_HOST_NAME) \
- --target=$(REAL_GNU_TARGET_NAME) \
--enable-shared \
--enable-static \
--with-gmp=$(GMP_HOST_DIR) \