blob: 114d6ddda83413eb3502ffc66c23ec5b53148d7f (
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
|
# Maintainer : Taiki Sugawara <buzz.taiki@gmail.com>
pkgname=gcviewer-git
_pkgname=gcviewer
pkgver=1.37.SNAPSHOT.r40.af97692
pkgrel=1
pkgdesc="GCViewer is a little tool that visualizes verbose GC output generated by Sun, IBM, HP and BEA Java Virtual Machines."
arch=('any')
url="https://github.com/chewiebug/GCViewer"
license=('LGPL')
depends=('java-runtime')
makedepends=('git' 'java-environment' 'maven' 'imagemagick' 'perl-xml-xpath')
conflicts=('gcviewer-bin')
provides=('gcviewer')
source=("$_pkgname::git+https://github.com/chewiebug/GCViewer.git#branch==develop"
'gcviewer.sh'
'gcviewer.desktop')
sha256sums=('SKIP'
'20316cd8975215966d9983aab9cc61a1a95acdbd397d30db6ad1da7f2ecc2e0b'
'255f2a7b966832b98b0e8683d3a2b97a3a71bd354000d226ab21500ec52e8a91')
_mvn() {
mvn -Dmaven.repo.local="$srcdir/m2" "$@"
}
pkgver() {
cd "$srcdir/$_pkgname"
local ver="$(xpath -q -e '/project/version/text()' pom.xml 2> /dev/null)"
local rev="$(git describe --long | sed -e 's/.*-\([0-9]*\)-g/r\1./')"
echo "$ver"."$rev" | tr - .
}
build() {
cd "$srcdir/$_pkgname"
_mvn package -DskipTests
convert "target/classes/images/gcviewericon.gif" "$srcdir/gcviewericon.png"
}
check() {
cd "$srcdir/$_pkgname"
# use fr locale to avoid test failure (see https://github.com/chewiebug/GCViewer/blob/af97692884ac918ccbdf7a123fa698460a1d397e/src/test/java/com/tagtraum/perf/gcviewer/exp/SummaryDataWriterTest.java#L173-L178)
_mvn -DargLine=-Duser.language=fr test
}
package() {
install -D -m644 "$srcdir/$_pkgname/target/$_pkgname"-*.jar "$pkgdir/usr/share/java/$_pkgname/$_pkgname.jar"
install -D -m644 "$srcdir/$_pkgname/README.md" "$pkgdir/usr/share/doc/$_pkgname/README.md"
install -D -m644 "$srcdir/gcviewericon.png" "$pkgdir/usr/share/pixmaps/$_pkgname.png"
install -D -m755 "$srcdir/gcviewer.sh" "$pkgdir/usr/bin/gcviewer"
install -D -m644 "$srcdir/gcviewer.desktop" "$pkgdir/usr/share/applications/$_pkgname.desktop"
}
# vim:set ts=2 sw=2 et:
|