| 1 | # $Id: Makefile 3121 2006-02-03 08:31:25Z nico $
|
|---|
| 2 |
|
|---|
| 3 | include $(TOPDIR)/rules.mk
|
|---|
| 4 |
|
|---|
| 5 | PKG_NAME:=gd
|
|---|
| 6 | PKG_VERSION:=2.0.33
|
|---|
| 7 | PKG_RELEASE:=2
|
|---|
| 8 | PKG_MD5SUM:=be0a6d326cd8567e736fbc75df0a5c45
|
|---|
| 9 |
|
|---|
| 10 | PKG_SOURCE_URL:=http://www.boutell.com/gd/http
|
|---|
| 11 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 | include $(TOPDIR)/package/rules.mk
|
|---|
| 15 |
|
|---|
| 16 | $(eval $(call PKG_template,LIBGD,libgd,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
|---|
| 17 |
|
|---|
| 18 | $(WRKBUILD)/.configured:
|
|---|
| 19 | (cd $(WRKBUILD); rm -rf config.{cache,status} ; \
|
|---|
| 20 | $(TARGET_CONFIGURE_OPTS) \
|
|---|
| 21 | CFLAGS="$(TARGET_CFLAGS)" \
|
|---|
| 22 | CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
|
|---|
| 23 | LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
|
|---|
| 24 | LIBPNG12_CONFIG="$(STAGING_DIR)/usr/bin/libpng12-config" \
|
|---|
| 25 | ./configure \
|
|---|
| 26 | --target=$(GNU_TARGET_NAME) \
|
|---|
| 27 | --host=$(GNU_TARGET_NAME) \
|
|---|
| 28 | --build=$(GNU_HOST_NAME) \
|
|---|
| 29 | --program-prefix="" \
|
|---|
| 30 | --program-suffix="" \
|
|---|
| 31 | --prefix=/usr \
|
|---|
| 32 | --exec-prefix=/usr \
|
|---|
| 33 | --bindir=/usr/bin \
|
|---|
| 34 | --datadir=/usr/share \
|
|---|
| 35 | --includedir=/usr/include \
|
|---|
| 36 | --infodir=/usr/share/info \
|
|---|
| 37 | --libdir=/usr/lib \
|
|---|
| 38 | --libexecdir=/usr/lib \
|
|---|
| 39 | --localstatedir=/var \
|
|---|
| 40 | --mandir=/usr/share/man \
|
|---|
| 41 | --sbindir=/usr/sbin \
|
|---|
| 42 | --sysconfdir=/etc \
|
|---|
| 43 | --enable-largefile \
|
|---|
| 44 | --disable-nls \
|
|---|
| 45 | --enable-shared \
|
|---|
| 46 | --enable-static \
|
|---|
| 47 | --disable-rpath \
|
|---|
| 48 | --with-gnu-ld \
|
|---|
| 49 | --without-x \
|
|---|
| 50 | --without-freetype \
|
|---|
| 51 | --with-jpeg=$(STAGING_DIR)/usr \
|
|---|
| 52 | --with-png=$(STAGING_DIR)/usr \
|
|---|
| 53 | --without-xpm \
|
|---|
| 54 | )
|
|---|
| 55 | touch $@
|
|---|
| 56 |
|
|---|
| 57 | $(WRKBUILD)/.built:
|
|---|
| 58 | rm -rf $(WRKINST)
|
|---|
| 59 | mkdir -p $(WRKINST)
|
|---|
| 60 | $(MAKE) -C $(WRKBUILD) \
|
|---|
| 61 | DESTDIR="$(WRKINST)" \
|
|---|
| 62 | all install
|
|---|
| 63 | touch $@
|
|---|
| 64 |
|
|---|
| 65 | $(IPKG_LIBGD):
|
|---|
| 66 | install -d -m0755 $(IDIR_LIBGD)/usr/lib
|
|---|
| 67 | $(CP) $(WRKINST)/usr/lib/libgd.so.* $(IDIR_LIBGD)/usr/lib/
|
|---|
| 68 | $(RSTRIP) $(IDIR_LIBGD)
|
|---|
| 69 | $(IPKG_BUILD) $(IDIR_LIBGD) $(PACKAGE_DIR)
|
|---|
| 70 |
|
|---|
| 71 | $(STAGING_DIR)/usr/lib/libgd.so: $(WRKBUILD)/.built
|
|---|
| 72 | mkdir -p $(STAGING_DIR)/usr/bin
|
|---|
| 73 | $(CP) $(WRKINST)/usr/bin/gdlib-config $(STAGING_DIR)/usr/bin/
|
|---|
| 74 | mkdir -p $(STAGING_DIR)/usr/include
|
|---|
| 75 | $(CP) $(WRKINST)/usr/include/entities.h $(STAGING_DIR)/usr/include/
|
|---|
| 76 | $(CP) $(WRKINST)/usr/include/gd*.h $(STAGING_DIR)/usr/include/
|
|---|
| 77 | mkdir -p $(STAGING_DIR)/usr/lib
|
|---|
| 78 | $(CP) $(WRKINST)/usr/lib/libgd.{a,so*} $(STAGING_DIR)/usr/lib/
|
|---|
| 79 | touch $@
|
|---|
| 80 |
|
|---|
| 81 | install-dev: $(STAGING_DIR)/usr/lib/libgd.so
|
|---|
| 82 |
|
|---|
| 83 | uninstall-dev:
|
|---|
| 84 | rm -rf \
|
|---|
| 85 | $(STAGING_DIR)/usr/bin/gdlib-config \
|
|---|
| 86 | $(STAGING_DIR)/usr/include/entities.h \
|
|---|
| 87 | $(STAGING_DIR)/usr/include/gd*.h \
|
|---|
| 88 | $(STAGING_DIR)/usr/lib/libgd.{a,so*} \
|
|---|
| 89 |
|
|---|
| 90 | compile-targets: install-dev
|
|---|
| 91 | clean-targets: uninstall-dev
|
|---|
| 92 |
|
|---|