summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 5ddebba677932fc8a58718bf3a189e18da3193bc (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
60
61
62
63
64
65
66
67
68
69
70
71
#Contributor: mathieu.clabaut <mathieu.clabaut@gmail.com>

pkgname=gnatcoverage-git
pkgver=r4612.aefb23f8
pkgrel=2
pkgdesc="Source and object coverage analysis tool"
arch=('i686' 'x86_64')
url="https://github.com/AdaCore/gnatcoverage"
license=('GPL3')
provides=('gnatcoverage')
conflict=()
makedepends=('git' 'gnatcoll-core-git' 'gcc-ada' 'binutils' 'valgrind'
'gnat_util')
depends=()
optdeps=()
source=(gnatcoverage::git+https://github.com/AdaCore/gnatcoverage
https://ftp.gnu.org/gnu/binutils/binutils-2.31.1.tar.xz)

md5sums=('SKIP')

prepare() {
  cd $srcdir/binutils-2.31.1

  ./configure \
    --prefix=/usr \
    --enable-targets=all\
    --disable-gdb \
    --disable-werror \
    --disable-sim \
    --disable-ld \
    --disable-lquadmath \
    --disable-readline \
    --without-zlib

  make
}

build() {
  cd $srcdir/gnatcoverage/tools/gnatcov
  # 
  sed -i -e 's/\(Pragma_Acc_.*\)/-- \1/' sc_obligations.ads
  make bin adapters VALGRIND_PREFIX=/usr \
                                  BINUTILS_SRC_DIR=$srcdir/binutils-2.31.1
}

package() {
  cd $srcdir/gnatcoverage/tools/gnatcov
  make PREFIX=$pkgdir/usr VALGRIND_PREFIX=$pkgdir/usr \
                                  install-bin install-examples \
                                  install-adapters
#  cd $srcdir/notifymuch
#  python setup.py install --root=$pkgdir || return 1
#  install -m755  -d $pkgdir/usr/share/icons/hicolor/512x512/apps/
#  install -m644  $srcdir/notifymuch.png $pkgdir/usr/share/icons/hicolor/512x512/apps/
#  install -m755 -d  $pkgdir/usr/share/applications/
#  install -m644 $srcdir/notifymuch.desktop  $pkgdir/usr/share/applications/
}

pkgver() {
  cd "gnatcoverage"
    ( set -o pipefail
    git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
  )
}

md5sums=('SKIP'
         '5b7c9d4ce96f507d95c1b9a255e52418'
         'SKIP')
md5sums=('SKIP'
         '5b7c9d4ce96f507d95c1b9a255e52418')