summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7481f0e259dcf0e264d5fe1fd1398549af949aa3 (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
40
41
42
43
44
45
# Maintainer: Skjnldsv <skjnldsv at protonmail com>

pkgname=gnome-pomodoro-git
pkgver=r1038.1e1d8d5
pkgrel=1
_gitbranch='master'
pkgdesc='A time management utility for GNOME based on the pomodoro technique'
arch=('i686' 'x86_64')
url='https://github.com/codito/gnome-pomodoro/'
license=('GPL3')
depends=('gnome-desktop' 'libcanberra' 'gstreamer' 'gobject-introspection' 'libpeas' 'appstream-glib' 'gom')
makedepends=('intltool' 'vala' 'gnome-common' 'docbook2x' 'perl-xml-sax-expat' 'gom')
conflicts=('gnome-pomodoro' 'gnome-shell-pomodoro')
provides=('gnome-pomodoro')
source=("$pkgname"::"git+https://github.com/codito/gnome-pomodoro.git#branch=${_gitbranch}")
sha256sums=('SKIP')
install='gschemas.install'

pkgver() {
  cd "$srcdir/$pkgname"
  printf "r%s.%s" "$(git rev-list --count HEAD)" \
      "$(git rev-parse --short HEAD)"
}

prepare() {
  cd "$srcdir/$pkgname"
  # Fixes some build issues when 'docbook2x' package is installed
  # Big thanks to user maus25 for the fix
  #sed -i "s/docbook2man \$?/docbook2man --sgml \$?/g" man/Makefile.am

  # https://github.com/codito/gnome-pomodoro/issues/332
  sed -i "s/\[ \$datadir\/ = \/usr\/share\/\*/[ \"\$datadir\/\" = \"\/usr\/share\/\"/" configure.ac

  ./autogen.sh --prefix=/usr --datadir=/usr/share
}

build() {
  cd "$srcdir/$pkgname"
  make
}

package() {
  cd "$srcdir/$pkgname"
  make DESTDIR="$pkgdir" install
}