summaryrefslogblamecommitdiff
path: root/user/poppler/APKBUILD
blob: 6269b5565d183273f013647827d95f08f12f566c (plain) (tree)
1
2
3
4
5
6
7
8
9

               
             
        




                                                       
          








                                                                              
                       








                                                   
                                                      






























                                                                 
                                                                                                                                                                    
# Maintainer: 
pkgname=poppler
pkgver=0.73.0
pkgrel=0
pkgdesc="PDF rendering library based on xpdf 3.0"
url="https://poppler.freedesktop.org/"
arch="all"
options="!check"  # Test data is available in Git only.
license="GPL-2.0+"
depends=""
depends_dev="cairo-dev glib-dev"
makedepends="$depends_dev libjpeg-turbo-dev cairo-dev libxml2-dev openjpeg-dev
	fontconfig-dev gobject-introspection-dev lcms2-dev libpng-dev tiff-dev
	zlib-dev cmake"
subpackages="$pkgname-dev $pkgname-doc $pkgname-utils $pkgname-glib"
source="https://poppler.freedesktop.org/poppler-$pkgver.tar.xz"
builddir="$srcdir"/$pkgname-$pkgver/build

prepare() {
	default_prepare
	mkdir "$builddir"
}

build() {
	cd "$builddir"
	cmake \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_LIBDIR=/usr/lib \
		-DENABLE_UNSTABLE_API_ABI_HEADERS=ON \
		..
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

utils() {
	pkgdesc="Poppler's xpdf-workalike command line utilities"
	install -d "$subpkgdir"/usr
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

glib() {
	pkgdesc="Glib wrapper for poppler"
	replaces="poppler-gtk"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/libpoppler-glib.so.* \
		"$pkgdir"/usr/lib/girepository* \
		"$subpkgdir"/usr/lib/
}

_cpp() {
	pkgdesc="Pure C++ wrapper for poppler"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/libpoppler-cpp.so.* \
		"$subpkgdir"/usr/lib/
}

sha512sums="6924a343032573504a0039c56a6263cd1183fa6aca75966fe1f084bd19da78553e455e541a3693896c1ed0c3865f11c11758a0f5a66b2f6cd48ac8a7eccf891a  poppler-0.73.0.tar.xz"