pkgname=pandoc-bin pkgver=2.11.0.2 pkgrel=1 pkgdesc="Pandoc - executable only, without 750MB Haskell depends/makedepends" url="http://pandoc.org" license=("GPL") arch=('x86_64') conflicts=("pandoc") provides=("pandoc") replaces=('pandoc-static' 'pandoc-lite') depends=() optdepends=( 'texlive-core: for pdf output' ) source=( "https://github.com/jgm/pandoc/releases/download/${pkgver}/pandoc-${pkgver}-linux-amd64.tar.gz" # The binary release doesn't have the datafiles, so we need to yoink those out of the source tarball, too. "https://github.com/jgm/pandoc/archive/${pkgver}.tar.gz" ) sha256sums=('18a6fe80adca5defb16c2729b2e07fdadc708df1721126c8026466f0ab6f37b6' '47daf20fc56eaefb35d1a04b19ac120131bf8b208a7883c6524e88fb7bd4b18f') package() { cd "${srcdir}/pandoc-${pkgver}" # To avoid having to download over a gigabyte of haskell makedepends (400-ish for ghc, plus 750 in libs), we # just yoink the binary from static compiled binary distributed by pandoc: mkdir -p "${pkgdir}/usr/share/pandoc" cp -R bin share "${pkgdir}/usr" # We're still missing all the datafiles and so on. We get those from the source tarball... cp -R data "${pkgdir}/usr/share/pandoc/" cp COPYRIGHT MANUAL.txt "${pkgdir}/usr/share/pandoc/" # When pandoc stopped having templates as a submodule, they copied various github turds into their source # tree, so let's tidy that up... rm -R ${pkgdir}/usr/share/pandoc/data/templates/{.github,README.markdown} }