From 92646a997779568f3a12367564d47a5edde70989 Mon Sep 17 00:00:00 2001 From: Omar Vega Ramos Date: Tue, 15 Sep 2015 06:19:27 -0500 Subject: cglib: add new package to [pcr] --- pcr/cglib/PKGBUILD | 60 ++++++++++++++++++++++++++++++++++++++++++++ pcr/cglib/cglib-jarjar.patch | 11 ++++++++ 2 files changed, 71 insertions(+) create mode 100644 pcr/cglib/PKGBUILD create mode 100644 pcr/cglib/cglib-jarjar.patch (limited to 'pcr') diff --git a/pcr/cglib/PKGBUILD b/pcr/cglib/PKGBUILD new file mode 100644 index 000000000..e003662ae --- /dev/null +++ b/pcr/cglib/PKGBUILD @@ -0,0 +1,60 @@ +# Maintainer: Omar Vega Ramos + +pkgname=cglib +pkgver=3.1 +pkgrel=1 +pkgdesc="Code generation library for Java" +arch=('any') +url="https://github.com/cglib/cglib" +license=('APACHE') +depends=('java-runtime') +makedepends=('apache-ant' 'java-asm' 'java-jarjar' 'jh') +source=("https://github.com/${pkgname}/${pkgname}/archive/RELEASE_${pkgver//./_}.tar.gz" + "https://repo1.maven.org/maven2/${pkgname}/${pkgname}/${pkgver}/${pkgname}-${pkgver}.pom" + "https://repo1.maven.org/maven2/${pkgname}/${pkgname}-nodep/${pkgver}/${pkgname}-nodep-${pkgver}.pom" + "cglib-jarjar.patch") +md5sums=('6886df33b07c65e23b6a8aed9ae01ae4' + 'cdcb12866a7e341e89ad7c3bf9c19b71' + '41cbb7bc608af67c661ebbd1ac936e23' + '09f089fc00ad12f8df31d35533444152') + +prepare() { + cd "${srcdir}/${pkgname}-RELEASE_${pkgver//./_}" + find . -name \*.jar -delete + patch -Np1 -i "${srcdir}/cglib-jarjar.patch" +} + +build() { + cd "${srcdir}/${pkgname}-RELEASE_${pkgver//./_}" + ant jar javadoc \ + -lib "/usr/share/java/asm-4.jar" \ + -lib "/usr/share/java/asm-util-4.jar" \ + -lib "/usr/share/java/jarjar.jar" +} + +package() { + cd "${srcdir}/${pkgname}-RELEASE_${pkgver//./_}" + + # Install license file + install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.txt" + + # Install documentation + install -d "${pkgdir}/usr/share/doc/${pkgname}" + cp -r "docs" "${pkgdir}/usr/share/doc/${pkgname}" + + # Install Maven artifacts + export DESTDIR=${pkgdir} + jh mvn-install ${pkgname} ${pkgname} ${pkgver} \ + "${srcdir}/${pkgname}-${pkgver}.pom" \ + "${srcdir}/${pkgname}-RELEASE_${pkgver//./_}/dist/${pkgname}-${pkgver}.jar" \ + "${pkgname}.jar" + jh mvn-install ${pkgname} "${pkgname}-nodep" ${pkgver} \ + "${srcdir}/${pkgname}-nodep-${pkgver}.pom" \ + "${srcdir}/${pkgname}-RELEASE_${pkgver//./_}/dist/${pkgname}-nodep-${pkgver}.jar" \ + "${pkgname}-nodep.jar" + + ln -s "/usr/share/java/${pkgname}.jar" \ + "${pkgdir}/usr/share/java/${pkgname}-${pkgver}.jar" + ln -s "/usr/share/java/${pkgname}-nodep.jar" \ + "${pkgdir}/usr/share/java/${pkgname}-nodep-${pkgver}.jar" +} diff --git a/pcr/cglib/cglib-jarjar.patch b/pcr/cglib/cglib-jarjar.patch new file mode 100644 index 000000000..7feee1043 --- /dev/null +++ b/pcr/cglib/cglib-jarjar.patch @@ -0,0 +1,11 @@ +--- cglib-RELEASE_3_1.orig/build.xml 2013-12-07 11:08:18.000000000 -0500 ++++ cglib-RELEASE_3_1/build.xml 2015-09-15 05:59:33.863523848 -0500 +@@ -127,7 +127,7 @@ + + + +- ++ + + + -- cgit v1.2.3