1 # Maintainer: Julien Nicoulaud <julien.nicoulaud@gmail.com>
2 # Source: https://github.com/nicoulaj/archlinux-packages
7 pkgdesc="A Java graphical Pacman frontend."
9 url="https://github.com/bahmanm/Karun"
11 depends=('bash' 'java-runtime' 'java-commons-io' 'java-commons-lang' 'java-commons-compress' 'desktop-file-utils')
12 makedepends=('git' 'apache-ant')
13 install=${_pkgname}.install
15 provides=(${_pkgname})
16 conflicts=(${_pkgname})
18 _gitroot=git://github.com/bahmanm/Karun.git
23 msg2 "Connecting to GIT server...."
24 if [ -d "${srcdir}/${_gitname}" ] ; then
25 ( cd "${srcdir}/${_gitname}" && git pull origin )
26 msg2 "The local files are updated."
28 git clone $_gitroot "${srcdir}/${_gitname}"
32 cd "${srcdir}/${_gitname}"
35 msg2 "Generate desktop application entry..."
36 cat > "${srcdir}"/${_pkgname}.desktop << EOF
41 Exec=/usr/bin/${_pkgname}
43 Icon=applications-system
48 msg2 "Generate launcher script..."
49 cat <<EOF > "${srcdir}"/${_pkgname}.sh
51 "\$JAVA_HOME/bin/java" \
52 -cp /usr/share/java/commons-io/commons-io.jar:/usr/share/java/commons-lang/commons-lang.jar:/usr/share/java/commons-compress/commons-compress.jar:/usr/share/java/${_pkgname}/${_pkgname}.jar \
53 com.bahmanm.karun.Karun \
61 msg2 "Install library at /usr/share/java/${_pkgname}..."
62 install -Dm644 "${srcdir}"/${_gitname}/dist/${_gitname}.jar "${pkgdir}"/usr/share/java/${_pkgname}/${_pkgname}.jar
64 msg2 "Install desktop application entry..."
65 install -Dm644 "${srcdir}"/${_pkgname}.desktop "${pkgdir}"/usr/share/applications/${_pkgname}.desktop
67 msg2 "Install an executable at /usr/bin/${pkgname}..."
68 install -Dm755 "${srcdir}"/${_pkgname}.sh "${pkgdir}"/usr/bin/${_pkgname}
72 # vim:set ts=2 sw=2 et: