void-packages/srcpkgs/mupdf/template

56 lines
1.5 KiB
Text
Raw Normal View History

2013-11-17 19:45:22 +00:00
# Template file for 'mupdf'
pkgname=mupdf
2014-06-12 21:06:39 +00:00
version=1.5
2014-07-14 10:13:38 +00:00
revision=3
2013-11-17 19:45:22 +00:00
wrksrc="${pkgname}-${version}-source"
2014-04-15 07:54:38 +00:00
hostmakedepends="pkg-config zlib-devel libcurl-devel freetype-devel libjpeg-turbo-devel jbig2dec-devel"
2013-11-17 19:45:22 +00:00
makedepends="zlib-devel libcurl-devel freetype-devel libjpeg-turbo-devel jbig2dec-devel libXext-devel desktop-file-utils"
depends="desktop-file-utils"
2013-11-17 19:45:22 +00:00
short_desc="Lightweight PDF and XPS viewer"
maintainer="Juan RP <xtraeme@gmail.com>"
license="GPL-3"
homepage="http://mupdf.com"
2014-04-15 07:54:38 +00:00
distfiles="http://mupdf.com/downloads/mupdf-${version}-source.tar.gz"
2014-06-12 21:06:39 +00:00
checksum=e41fa8951de3b44a5ec95052b8897fbcca1eb721e0fd0289862e31e2f03f846a
2013-11-17 19:45:22 +00:00
2014-04-15 07:54:38 +00:00
pre_configure() {
2013-11-17 19:45:22 +00:00
rm -rf thirdparty/{curl,freetype,jpeg,zlib,jbig2dec}
}
2014-04-15 07:54:38 +00:00
do_configure() {
if [ "$CROSS_BUILD" ]; then
unset CFLAGS
make CC=cc LD=ld AR=ar build=release generate
fi
}
2013-11-17 19:45:22 +00:00
do_build() {
2014-07-08 11:09:13 +00:00
CFLAGS+=" -fPIC"
2014-04-15 07:54:38 +00:00
if [ "$CROSS_BUILD" ]; then
make CROSSCOMPILE=yes CURL_LIBS='-lcurl -lpthread' build=release
else
make CURL_LIBS='-lcurl -lpthread' build=release
fi
2013-11-17 19:45:22 +00:00
}
do_install() {
make build=release prefix=${DESTDIR}/usr install
mv ${DESTDIR}/usr/bin/mupdf-x11-curl ${DESTDIR}/usr/bin/mupdf
rm ${DESTDIR}/usr/bin/mupdf-x11
2014-07-08 11:09:47 +00:00
vinstall build/release/libmujs.a 644 usr/lib
2014-06-12 21:06:39 +00:00
vinstall ${FILESDIR}/mupdf.xpm 644 usr/share/pixmaps
vinstall ${FILESDIR}/mupdf.desktop 644 usr/share/applications
2013-11-17 19:45:22 +00:00
}
mupdf-devel_package() {
short_desc+=" - development files"
depends="libjpeg-turbo-devel jbig2dec-devel"
2013-11-17 19:45:22 +00:00
pkg_install() {
vmove usr/include
vmove usr/lib
}
}