PKGBUILD 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. # Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
  2. _libname=jline
  3. pkgname=java-${_libname}
  4. pkgver=1.0
  5. pkgrel=3.parabola1
  6. pkgdesc="Java library for handling console input"
  7. arch=('any')
  8. url="http://jline.sourceforge.net/"
  9. license=('BSD')
  10. depends=('java-runtime-headless')
  11. makedepends=('apache-ant' 'jh' 'junit')
  12. source=("http://downloads.sourceforge.net/project/${_libname}/${_libname}/${pkgver}/${_libname}-${pkgver}.zip"
  13. "http://repo.maven.apache.org/maven2/${_libname}/${_libname}/${pkgver}/${_libname}-${pkgver}.pom"
  14. "build.xml")
  15. md5sums=('811dc1c8a351a2e928524bd79eb9e798'
  16. 'b45424a0b2557589f2f3eddae5fc4944'
  17. '6d198263612535fe617c6d166200c08d')
  18. prepare() {
  19. cd "${srcdir}/${_libname}-${pkgver}"
  20. rm -v "${_libname}-${pkgver}.jar"
  21. mv "${srcdir}/build.xml" .
  22. }
  23. build() {
  24. cd "${srcdir}/${_libname}-${pkgver}"
  25. ant clean jar javadoc
  26. }
  27. package() {
  28. cd "${srcdir}/${_libname}-${pkgver}"
  29. # Install license file
  30. install -Dm644 LICENSE.txt "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.txt"
  31. # Install documentation
  32. install -d "${pkgdir}/usr/share/doc/${pkgname}"
  33. cp -r "api" "${pkgdir}/usr/share/doc/${pkgname}"
  34. # Install Maven artifacts
  35. export DESTDIR=${pkgdir}
  36. jh mvn-install ${_libname} ${_libname} ${pkgver} \
  37. "${srcdir}/${_libname}-${pkgver}.pom" \
  38. "${_libname}.jar" \
  39. "${_libname}.jar"
  40. ln -s "/usr/share/java/${_libname}.jar" \
  41. "${pkgdir}/usr/share/java/${_libname}-${pkgver}.jar"
  42. }