summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ff872dc4f49a2d488900806bbe6d7040ff08ecc7 (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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Maintainer: lilydjwg <lilydjwg@gmail.com>
# Maintainer: Shang Yuanchun <idealities@gmail.com>

pkgname=systemtap-git
pkgver=4.0.102.g1832b8f51
pkgrel=1
pkgdesc="provides infrastructure to simplify the gathering of information about the running Linux system."
url="https://sourceware.org/systemtap/"
arch=('i686' 'x86_64')
license=('GPL')
depends=('elfutils' 'nss' 'python' 'json-c' 'avahi' 'readline' 'nspr')
makedepends=('git' 'python-setuptools' 'xmlto' 'cpio')
optdepends=('sqlite')
provides=(systemtap=4.0)
conflicts=(systemtap)
_gitroot=https://sourceware.org/git/systemtap.git
_gitname=systemtap
source=("git+$_gitroot")
md5sums=('SKIP')
install=systemtap.install

pkgver() {
  cd "$srcdir/$_gitname"
  git describe | sed 's/release-//;s/-/./g'
}

build() {
  cd "$srcdir/$_gitname"
  msg "Starting make..."

  # docs failed to build
  ./configure \
    --prefix=/usr \
    --sbindir=/usr/bin \
    --sysconfdir=/etc \
    --localstatedir=/var \
    --libdir=/usr/lib \
    --libexecdir=/usr/lib \
    --with-python3 \
    --enable-pie \
    --disable-docs \
    --enable-htmldocs
  make
}

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

  # glibc 2.30-2 already provides these two files
  rm -f "$pkgdir"/usr/include/sys/sdt-config.h
  rm -f "$pkgdir"/usr/include/sys/sdt.h

  cd "${pkgdir}"
  pushd var >/dev/null
  rmdir -p run/stap-server log
  popd >/dev/null
  rmdir var
}