| 1 | # $Id: Makefile 3112 2006-02-01 23:53:19Z mbm $
|
|---|
| 2 |
|
|---|
| 3 | include $(TOPDIR)/rules.mk
|
|---|
| 4 |
|
|---|
| 5 | PKG_NAME:=libffi-sable
|
|---|
| 6 | PKG_VERSION:=3325
|
|---|
| 7 | PKG_RELEASE:=3
|
|---|
| 8 | PKG_MD5SUM:=0c32eaaea0269c5fbe156fcd0be3e5bd
|
|---|
| 9 |
|
|---|
| 10 | PKG_SOURCE_URL:=http://sablevm.org/download/snapshot/2005-01-21/
|
|---|
| 11 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 | include $(TOPDIR)/package/rules.mk
|
|---|
| 15 |
|
|---|
| 16 | FWRT_PACKAGE_LIBFFI_SABLE=m
|
|---|
| 17 |
|
|---|
| 18 | $(eval $(call PKG_template,LIBFFI_SABLE,libffi-sable,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
|---|
| 19 |
|
|---|
| 20 | $(WRKBUILD)/.configured:
|
|---|
| 21 | (cd $(WRKBUILD); rm -rf config.{cache,status} ; \
|
|---|
| 22 | $(TARGET_CONFIGURE_OPTS) \
|
|---|
| 23 | CFLAGS="$(strip $(TARGET_CFLAGS))" \
|
|---|
| 24 | CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
|
|---|
| 25 | LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
|
|---|
| 26 | ./configure \
|
|---|
| 27 | --target=$(GNU_TARGET_NAME) \
|
|---|
| 28 | --host=$(GNU_TARGET_NAME) \
|
|---|
| 29 | --build=$(GNU_HOST_NAME) \
|
|---|
| 30 | --program-prefix="" \
|
|---|
| 31 | --program-suffix="" \
|
|---|
| 32 | --prefix=/usr \
|
|---|
| 33 | --exec-prefix=/usr \
|
|---|
| 34 | --bindir=/usr/bin \
|
|---|
| 35 | --datadir=/usr/share \
|
|---|
| 36 | --includedir=/usr/include \
|
|---|
| 37 | --infodir=/usr/share/info \
|
|---|
| 38 | --libdir=/usr/lib \
|
|---|
| 39 | --libexecdir=/usr/lib \
|
|---|
| 40 | --localstatedir=/var \
|
|---|
| 41 | --mandir=/usr/share/man \
|
|---|
| 42 | --sbindir=/usr/sbin \
|
|---|
| 43 | --sysconfdir=/etc \
|
|---|
| 44 | --enable-largefile \
|
|---|
| 45 | --disable-nls \
|
|---|
| 46 | --enable-shared \
|
|---|
| 47 | --enable-static \
|
|---|
| 48 | --disable-debug \
|
|---|
| 49 | );
|
|---|
| 50 | touch $@
|
|---|
| 51 |
|
|---|
| 52 | $(WRKBUILD)/.built:
|
|---|
| 53 | rm -rf $(WRKINST)
|
|---|
| 54 | mkdir -p $(WRKINST)
|
|---|
| 55 | $(MAKE) -C $(WRKBUILD) \
|
|---|
| 56 | DESTDIR="$(WRKINST)" \
|
|---|
| 57 | all install
|
|---|
| 58 | touch $@
|
|---|
| 59 |
|
|---|
| 60 | $(IPKG_LIBFFI_SABLE):
|
|---|
| 61 | install -m0755 -d $(IDIR_LIBFFI_SABLE)/usr/lib
|
|---|
| 62 | $(CP) $(WRKINST)/usr/lib/libffi.so.* $(IDIR_LIBFFI_SABLE)/usr/lib/
|
|---|
| 63 | $(RSTRIP) $(IDIR_LIBFFI_SABLE)
|
|---|
| 64 | $(IPKG_BUILD) $(IDIR_LIBFFI_SABLE) $(PACKAGE_DIR)
|
|---|
| 65 |
|
|---|
| 66 | $(STAGING_DIR)/usr/lib/libffi.so: $(WRKBUILD)/.built
|
|---|
| 67 | mkdir -p $(STAGING_DIR)/usr/include
|
|---|
| 68 | $(CP) $(WRKINST)/usr/include/ffi{,target}.h $(STAGING_DIR)/usr/include/
|
|---|
| 69 | mkdir -p $(STAGING_DIR)/usr/lib
|
|---|
| 70 | $(CP) $(WRKINST)/usr/lib/libffi.{a,so*} $(STAGING_DIR)/usr/lib/
|
|---|
| 71 | touch $@
|
|---|
| 72 |
|
|---|
| 73 | install-dev: $(STAGING_DIR)/usr/lib/libffi.so
|
|---|
| 74 |
|
|---|
| 75 | uninstall-dev:
|
|---|
| 76 | rm -rf \
|
|---|
| 77 | $(STAGING_DIR)/usr/include/ffi{,target}.h \
|
|---|
| 78 | $(STAGING_DIR)/usr/lib/libffi.{a,so*} \
|
|---|
| 79 |
|
|---|
| 80 | compile-targets: install-dev
|
|---|
| 81 | clean-targets: uninstall-dev
|
|---|