archrelease: copy trunk to extra-x86_64
[arch-packages.git] / visualvm / repos / extra-x86_64 / PKGBUILD
blob8c6787efe612c604731f6ed6708fd7a011671f13
1 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
2 # Contributor: Guillaume ALAUX <guillaume@archlinux.org>
3 # Contributor: Kristof JOZSA <kristof.jozsa@gmail.com>
4 # Contributor: Andrius Semionovas <aneworld at gmail dot com>
6 pkgname=visualvm
7 pkgver=2.1.6
8 _shortver=${pkgver//\./}
9 pkgrel=1
10 pkgdesc='Visual tool integrating several commandline JDK tools and lightweight profiling capabilities'
11 url='https://visualvm.github.io/'
12 arch=('x86_64')
13 license=('custom:GPL')
14 depends=('java-environment')
15 source=(https://github.com/visualvm/visualvm.src/releases/download/${pkgver}/${pkgname}_${_shortver}.zip
16         visualvm.desktop
17         icon.png)
18 sha256sums=('9b1c8adab1f776ea0ab2fca71be4f0e79f0ea6c6d0c9f170506851cccfdc1963'
19             'e820807e8d78446cf156a3947d97856e24865bb0d8c957e9ce2fed309c737441'
20             '452fbd85c968ec7176c5894bc4106b7e25310314d44278d807510675b6a5c864')
21 b2sums=('ff25371b38bf483756750fa9a068976277d92eb644a03bd56b7d59ecbdb013f95c27b348c8b2375ddb6aba12595273d6e1e736c8381a30c1772ddf803a2ce589'
22         'ec51d5613e0b8103c5596b8549bfea2eb7cf6fe7792c790ef67007d469c3ddb0fb8990f9ea1aa575f412b62787c43225a583c2d6936393cbcb1938d396717e18'
23         '5f7659620de6b3d67716e700a5e8724e03cf3343c188a2d5c2470950c27c8e045209e87951971a969497b38f0dd5eff8a021e427367b838254040c6d25eb0b5d')
25 package() {
26   cd ${pkgname}_${_shortver}
28   install -d "${pkgdir}/usr/share/${pkgname}"
29   cp -R bin platform visualvm "${pkgdir}/usr/share/${pkgname}"
31   install -d "${pkgdir}/etc/${pkgname}"
32   cp -R etc/* "${pkgdir}/etc/${pkgname}"
33   ln -s /etc/${pkgname} "${pkgdir}/usr/share/${pkgname}/etc"
34   # 'visualvm' shell script cannot even set his own variable 'visualvm_jdkhome'
35   sed -i \
36     -e 's|#visualvm_jdkhome="/path/to/jdk"|visualvm_jdkhome="${JAVA_HOME}"|' \
37     -e 's|visualvm_default_options="|visualvm_default_options="-J-Dawt.useSystemAAFontSettings=on |' \
38       "${pkgdir}/etc/${pkgname}/visualvm.conf"
40   find "${pkgdir}"/usr/share/${pkgname} \( -name "*.exe" -o -name "*.dll" \) -delete
42   install -d "${pkgdir}/usr/bin"
43   ln -s /usr/share/${pkgname}/bin/visualvm "${pkgdir}/usr/bin/${pkgname}"
45   install -Dm 644 "${srcdir}/icon.png" -t "${pkgdir}/usr/share/${pkgname}"
46   install -Dm 644 "${srcdir}/visualvm.desktop" -t "${pkgdir}/usr/share/applications"
48   install -Dm 644 LICENSE.txt -t "${pkgdir}/usr/share/licenses/${pkgname}"
51 # vim: ts=2 sw=2 et: