OpenWrt packages
Sign in or create your account | Project List | Help
OpenWrt packages Git Source Tree
Root/
| 1 | # |
| 2 | # This is free software, licensed under the GNU General Public License v2. |
| 3 | # |
| 4 | |
| 5 | include $(TOPDIR)/rules.mk |
| 6 | |
| 7 | PKG_NAME:=ghostscript |
| 8 | PKG_VERSION:=9.02 |
| 9 | PKG_RELEASE:=1 |
| 10 | |
| 11 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz |
| 12 | PKG_SOURCE_URL:=http://downloads.ghostscript.com/public/ |
| 13 | PKG_MD5SUM:=86cc3a0509c0d96a641d58879d54274b |
| 14 | |
| 15 | include $(INCLUDE_DIR)/package.mk |
| 16 | include $(INCLUDE_DIR)/nls.mk |
| 17 | |
| 18 | define Package/ghostscript |
| 19 | SECTION:=utils |
| 20 | CATEGORY:=Utilities |
| 21 | TITLE:=interpreter for the PostScript language and for PDF |
| 22 | URL:=http://pages.cs.wisc.edu/~ghost/ |
| 23 | DEPENDS:=+libtiff $(ICONV_DEPENDS) +libpng +fontconfig +libfreetype @BUILD_NLS +libidn |
| 24 | endef |
| 25 | |
| 26 | define Package/ghostscript/description |
| 27 | Ghostscript is an interpreter for the PostScript language and for PDF |
| 28 | endef |
| 29 | |
| 30 | define Build/Prepare |
| 31 | $(call Build/Prepare/Default) |
| 32 | mkdir $(PKG_BUILD_DIR)/obj |
| 33 | #(cd $(PKG_BUILD_DIR); ./configure;); |
| 34 | #make -C $(PKG_BUILD_DIR) obj/arch.h obj/genconf obj/echogs |
| 35 | for i in genarch genconf echogs; do \ |
| 36 | gcc -O2 -Wall -Wstrict-prototypes -Wundef -Wmissing-declarations -Wmissing-prototypes -Wwrite-strings -Wno-strict-aliasing -Wdeclaration-after-statement -fno-builtin -fno-common -DHAVE_STDINT_H -DGX_COLOR_INDEX_TYPE="unsigned long long" -I$(PKG_BUILD_DIR)/base -o $(PKG_BUILD_DIR)/obj/$$$$i $(PKG_BUILD_DIR)/base/$$$$i.c; \ |
| 37 | done |
| 38 | endef |
| 39 | |
| 40 | TARGET_LDFLAGS+= \ |
| 41 | -Wl,-rpath-link=$(STAGING_DIR)/usr/lib |
| 42 | |
| 43 | CONFIGURE_ARGS += \ |
| 44 | --with-system-libtiff \ |
| 45 | $(if $(ICONV_FULL),--with-libiconv=gnu) \ |
| 46 | --without-x \ |
| 47 | --without-jbig2dec \ |
| 48 | --without-jasper |
| 49 | |
| 50 | MAKE_FLAGS += \ |
| 51 | EXTRALIBS="-Wl,-rpath-link=$(STAGING_DIR)/usr/lib \ |
| 52 | $(ICONV_LDFLAGS) -L$(STAGING_DIR)/usr/lib \ |
| 53 | -lfontconfig -lfreetype -ldl -liconv -lidn" \ |
| 54 | COMPILE_INITS="0" |
| 55 | |
| 56 | define Package/ghostscript/install |
| 57 | $(INSTALL_DIR) \ |
| 58 | $(1)/usr/bin $(1)/usr/share/$(PKG_NAME)/$(PKG_VERSION) |
| 59 | |
| 60 | $(INSTALL_BIN) \ |
| 61 | $(PKG_BUILD_DIR)/bin/gs \ |
| 62 | $(1)/usr/bin/gs |
| 63 | |
| 64 | $(CP) $(PKG_BUILD_DIR)/{Resource,lib,iccprofiles} \ |
| 65 | $(1)/usr/share/$(PKG_NAME)/$(PKG_VERSION)/ |
| 66 | endef |
| 67 | |
| 68 | $(eval $(call BuildPackage,ghostscript)) |
| 69 |
