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:=nupdf |
8 | PKG_RELEASE:=1 |
9 | PKG_REV:=15 |
10 | PKG_VERSION:=r$(PKG_REV) |
11 | PKG_SOURCE_URL:=http://nupdf.googlecode.com/svn/trunk/ |
12 | PKG_SOURCE_PROTO:=svn |
13 | PKG_SOURCE_VERSION:=$(PKG_REV) |
14 | PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) |
15 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz |
16 | |
17 | include $(INCLUDE_DIR)/package.mk |
18 | |
19 | define Package/nupdf |
20 | SECTION:=utils |
21 | CATEGORY:=Utilities |
22 | TITLE:=relatively fast pdf reader in SDL |
23 | URL:=http://code.google.com/p/nupdf/ |
24 | DEPENDS:=+libsdl |
25 | endef |
26 | |
27 | define Package/nupdf/description |
28 | nupdf is a relatively fast pdf reader; it uses the mupdf library to render pages/handle files, and SDL for the UI |
29 | endef |
30 | |
31 | TARGET_CFLAGS += \ |
32 | -I$(STAGING_DIR)/usr/include |
33 | |
34 | TARGET_LDFLAGS += \ |
35 | -Wl,-rpath-link=$(STAGING_DIR)/usr/lib \ |
36 | -ldl -lSDL -lmupdf -lfitz -lfitzdraw \ |
37 | -lcmaps -lfonts -lfreetype -lpthread \ |
38 | -lm -ljpeg -lz |
39 | |
40 | define Build/Compile |
41 | $(TARGET_CC) $(PKG_BUILD_DIR)/*.c -o $(PKG_BUILD_DIR)/nupdf $(TARGET_CFLAGS) -L$(PKG_BUILD_DIR) $(TARGET_LDFLAGS) |
42 | endef |
43 | |
44 | define Package/nupdf/install |
45 | $(INSTALL_DIR) \ |
46 | $(1)/usr/bin $(1)/usr/share/nupdf |
47 | |
48 | $(INSTALL_BIN) \ |
49 | $(PKG_BUILD_DIR)/nupdf $(1)/usr/share/nupdf/nupdf.bin |
50 | |
51 | $(INSTALL_BIN) \ |
52 | $(FILES_DIR)/nupdf.sh $(1)/usr/bin/nupdf |
53 | |
54 | $(CP) \ |
55 | $(PKG_BUILD_DIR)/{data,config} $(1)/usr/share/nupdf |
56 | endef |
57 | |
58 | $(eval $(call BuildPackage,nupdf)) |
59 |