diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-01-20 20:54:05 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-01-20 20:54:05 +0000 |
commit | 0ea07a948760e68ebb6e46140425e4c3d5670902 (patch) | |
tree | a640de65c492103e188136657337d8f8be82700a | |
parent | 36b371f2dcaf3235f441b0b2500dbd72ede66229 (diff) |
- dmalloc attempted to install itself to /
- make certain features dependant on the respective BR2 settings.
-rw-r--r-- | package/dmalloc/dmalloc.mk | 32 |
1 files changed, 27 insertions, 5 deletions
diff --git a/package/dmalloc/dmalloc.mk b/package/dmalloc/dmalloc.mk index 31aea34b7..d9e6fe98f 100644 --- a/package/dmalloc/dmalloc.mk +++ b/package/dmalloc/dmalloc.mk @@ -22,7 +22,22 @@ $(DMALLOC_DIR)/.unpacked: $(DL_DIR)/$(DMALLOC_SOURCE) $(SED) 's/^ac_cv_page_size=0$$/ac_cv_page_size=12/' $(DMALLOC_DIR)/configure $(SED) 's/(ld -/($${LD-ld} -/' $(DMALLOC_DIR)/configure $(SED) 's/'\''ld -/"$${LD-ld}"'\'' -/' $(DMALLOC_DIR)/configure - touch $(DMALLOC_DIR)/.unpacked + -$(SED) 's/ar cr/$$(AR) cr/' $(DMALLOC_DIR)/Makefile.in + touch $@ + +ifeq ($(BR2_INSTALL_LIBSTDCPP),y) +DMALLOC_CONFIG_ARGS:=--enable-cxx +else +DMALLOC_CONFIG_ARGS:=--disable-cxx +endif + +ifeq ($(BR2_PTHREADS_NONE),y) +DMALLOC_CONFIG_ARGS+=--disable-threads +else +DMALLOC_CONFIG_ARGS+=--enable-threads +endif + + $(DMALLOC_DIR)/.configured: $(DMALLOC_DIR)/.unpacked (cd $(DMALLOC_DIR); rm -rf config.cache; \ @@ -45,19 +60,26 @@ $(DMALLOC_DIR)/.configured: $(DMALLOC_DIR)/.unpacked --includedir=/include \ --mandir=/usr/man \ --infodir=/usr/info \ - --enable-threads \ --enable-shlib \ + $(DMALLOC_CONFIG_ARGS) \ ); - touch $(DMALLOC_DIR)/.configured + touch $@ $(DMALLOC_DIR)/$(DMALLOC_BINARY): $(DMALLOC_DIR)/.configured $(MAKE) -C $(DMALLOC_DIR) $(TARGET_DIR)/$(DMALLOC_TARGET_BINARY): $(DMALLOC_DIR)/$(DMALLOC_BINARY) - $(MAKE) DESTDIR=$(STAGING_DIR) -C $(DMALLOC_DIR) install + # both DESTDIR and PREFIX are ignored.. + $(MAKE) includedir="$(STAGING_DIR)/usr/include" \ + bindir="$(STAGING_DIR)/usr/bin" \ + libdir="$(STAGING_DIR)/usr/lib" \ + shlibdir="$(STAGING_DIR)/usr/lib" \ + includedir="$(STAGING_DIR)/usr/share/info/" \ + -C $(DMALLOC_DIR) install (cd $(STAGING_DIR)/usr/lib; \ mv libdmalloc*.so $(TARGET_DIR)/usr/lib); - touch $(TARGET_DIR)/$(DMALLOC_TARGET_BINARY) + cp -dpf $(STAGING_DIR)/usr/bin/dmalloc $(TARGET_DIR)/$(DMALLOC_TARGET_BINARY) + $(STRIP) -s $(TARGET_DIR)/$(DMALLOC_TARGET_BINARY) dmalloc: uclibc $(TARGET_DIR)/$(DMALLOC_TARGET_BINARY) |