summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 73f1a205237fae8732039c236976cd8adebbe1c5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Contributor: ZappaBoy <federico dot zappone at justanother dot cloud>

_gituser="vedang"
_gitrepo="pdf-tools"

pkgname=emacs-pdf-tools-git
pkgver=0.91.r39.gfedd930
pkgrel=1
pkgdesc="Emacs support library for PDF files."
url="https://github.com/${_gituser}/${_gitrepo}"
arch=('any')
license=('GPL3')
depends=('emacs' 'emacs-tablist-git' 'libpng' 'zlib' 'poppler-glib')
optdepends=('imagemagick: following links of a PDF document by plain keystrokes')
makedepends=('git' 'cask')
provides=('emacs-pdf-tools')
conflicts=('emacs-pdf-tools')
source=("git+https://github.com/${_gituser}/${_gitrepo}.git")
sha256sums=('SKIP')

pkgver() {
  cd "$_gitrepo"
  git describe --tags|sed 's+-+.r+'|tr - .|cut -c2-
}

build() {
  cd "$_gitrepo"
  export CXXFLAGS='-std=c++17'
  make bytecompile
  make server/epdfinfo
}

package() {
  cd "$_gitrepo"
  install -d  "$pkgdir"/usr/share/emacs/site-lisp/${_gitrepo}/
  install -d  "$pkgdir"/usr/bin
  install -m644 lisp/*.el{c,} "$pkgdir"/usr/share/emacs/site-lisp/${_gitrepo}/
  install -m755 server/epdfinfo "$pkgdir"/usr/bin/
}