diff options
author | Luke Shumaker <LukeShu@sbcglobal.net> | 2012-10-20 13:50:12 -0400 |
---|---|---|
committer | Luke Shumaker <LukeShu@sbcglobal.net> | 2012-10-20 13:50:12 -0400 |
commit | c375e36ec4c4e0b3c276e2b71bdd0651fa1a6a1d (patch) | |
tree | 4006c9e76bca24bbbdce343f8a7ac4c65b3b2ca2 | |
parent | 2ecf59e36659c710c187166da65d40e0d8b6af7b (diff) | |
parent | 422d616c151e4df847fdc5fc23af4f15946092ee (diff) | |
download | abslibre-c375e36ec4c4e0b3c276e2b71bdd0651fa1a6a1d.tar.gz abslibre-c375e36ec4c4e0b3c276e2b71bdd0651fa1a6a1d.tar.bz2 abslibre-c375e36ec4c4e0b3c276e2b71bdd0651fa1a6a1d.zip |
Merge branch 'java'
42 files changed, 1279 insertions, 120 deletions
diff --git a/java-ugly/junit/PKGBUILD b/java-ugly/junit/PKGBUILD new file mode 100644 index 000000000..7204cd5c9 --- /dev/null +++ b/java-ugly/junit/PKGBUILD @@ -0,0 +1,55 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> +# Maintainer (Arch): Guillaume ALAUX <Guillaume at Arch Linux dot org> + +pkgname=junit +pkgver=4.10 +pkgrel=1 +pkgdesc="Automated testing framework for Java" +arch=('any') +url="http://www.junit.org/" +license=('CPL') +depends=('java-runtime') +makedepends=('apache-ant' 'jh') +source=("$pkgname::git://github.com/KentBeck/junit.git#tag=r$pkgver") + +mksource() { + cd "${srcdir}/${pkgname}" + #find . -name '*.jar' -delete + + # Shut up some warnings from javac 1.7 + sed -ri 's|target="([0-9.]+)"|\0 source="\1"|' build.xml +} + +build() { + mksource + cd "${srcdir}/${pkgname}" + + # Shut up some warnings from javac 1.7 + sed -ri 's|target="([0-9.]+)"$|\0 source="\1"|' build.xml + + ant jars + for pkg in junit junit-dep; do + sed \ + -e "s|@artifactID@|$pkg|" \ + -e "s|@version@|$pkgver|" \ + < build/maven/pom-template.xml > $pkgname$pkgver/$pkg-$pkgver.pom + done +} + +package() { + cd "${srcdir}/${pkgname}" + install -Dm644 cpl-v10.html "$pkgdir/usr/share/licenses/junit/cpl-v10.html" + + cd "${srcdir}/${pkgname}/${pkgname}${pkgver}" + + export DESTDIR="$pkgdir" + jh mvn-install $pkgname junit $pkgver junit-$pkgver.{jar,pom} + jh mvn-install $pkgname junit-dep $pkgver junit-dep-$pkgver.{jar,pom} + install -d "${pkgdir}/usr/share/java/${pkgname}" + ln -s `jh mvn-basename $pkgname junit $pkgver`.jar "${pkgdir}/usr/share/java/${pkgname}" + ln -s `jh mvn-basename $pkgname junit-dep $pkgver`.jar "${pkgdir}/usr/share/java/${pkgname}" + ln -s ${pkgname}/${pkgname}-${pkgver}.jar ${pkgdir}/usr/share/java/${pkgname}.jar + ln -s ${pkgname}/${pkgname}-dep-${pkgver}.jar ${pkgdir}/usr/share/java/${pkgname}-dep.jar +} + +md5sums=('SKIP') diff --git a/libre/maven-libre/PKGBUILD b/java-ugly/maven/PKGBUILD index 2bd99940e..2bd99940e 100755 --- a/libre/maven-libre/PKGBUILD +++ b/java-ugly/maven/PKGBUILD diff --git a/libre/maven-libre/maven.csh b/java-ugly/maven/maven.csh index f5750cfc8..f5750cfc8 100755 --- a/libre/maven-libre/maven.csh +++ b/java-ugly/maven/maven.csh diff --git a/libre/maven-libre/maven.sh b/java-ugly/maven/maven.sh index b6655cc22..b6655cc22 100755 --- a/libre/maven-libre/maven.sh +++ b/java-ugly/maven/maven.sh diff --git a/java-ugly/not-working/java-bnd/PKGBUILD b/java-ugly/not-working/java-bnd/PKGBUILD new file mode 100644 index 000000000..86820469a --- /dev/null +++ b/java-ugly/not-working/java-bnd/PKGBUILD @@ -0,0 +1,24 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +_pkgname=bnd +pkgname=java-bnd +pkgver=1.50.0 +pkgdesc="A swiss army knife for OSGi" +url="http://www.aqute.biz/Bnd/" +license=('Apache2') + +pkgrel=1 +arch=(any) +makedepends=('apache-ant' 'junit') +source=("git://github.com/bndtools/bnd.git") + +build() { + cd "$srcdir/$_pkgname" + ant dist +} + +package() { + : +} + +md5sums=('SKIP') diff --git a/libre/apache-ant/PKGBUILD b/java/apache-ant/PKGBUILD index 77e0dfe94..77e0dfe94 100755 --- a/libre/apache-ant/PKGBUILD +++ b/java/apache-ant/PKGBUILD diff --git a/libre/apache-ant/apache-ant.csh b/java/apache-ant/apache-ant.csh index fdc04b2f8..fdc04b2f8 100755 --- a/libre/apache-ant/apache-ant.csh +++ b/java/apache-ant/apache-ant.csh diff --git a/libre/apache-ant/apache-ant.sh b/java/apache-ant/apache-ant.sh index 6e4809da5..6e4809da5 100755 --- a/libre/apache-ant/apache-ant.sh +++ b/java/apache-ant/apache-ant.sh diff --git a/java/arduino/PKGBUILD b/java/arduino/PKGBUILD new file mode 100644 index 000000000..426664a37 --- /dev/null +++ b/java/arduino/PKGBUILD @@ -0,0 +1,101 @@ +# Maintainer: PyroPeter <googlemail.com@abi1789> + +pkgname=arduino +pkgver=1.0.1 +pkgrel=2 +pkgdesc="Arduino SDK and IDE" +arch=('i686' 'x86_64') +url="http://arduino.cc/en/Main/Software" +options=(!strip) +license=('GPL') + +depends=('avr-gcc' 'avr-libc' 'libusb-compat' 'java-runtime' 'avrdude' + 'java-rxtx' 'antlr2' 'eclipse-ecj' 'jna') +makedepends=(java-environment apache-ant jh) +install="arduino.install" +source=("http://arduino.googlecode.com/files/arduino-$pkgver-src.tar.gz" + 'sig-patch.diff' + 'arduino.png' + 'arduino.desktop') + +unset _JAVA_OPTIONS +. /etc/profile.d/jdk.sh + +mksource() { + cd "$srcdir/arduino-$pkgver" + find . -name '*.jar' -delete + find . -name '*.swp' -delete + find . -name '*.so' -delete + rm -rf build/linux/dist/*/* +} + +build() { + cd "$srcdir/arduino-$pkgver" + eval `jh mksource build/shared/reference.zip` + + cd "$srcdir" + mkdir empty.d + cd empty.d + bsdtar cjf ../empty.tar.bz2 . + cd .. + rmdir empty.d + + cd "$srcdir/arduino-$pkgver" + + # Fix issue 955 to be compatible with newer versions of avr-libc + # https://code.google.com/p/arduino/issues/detail?id=955 + # Note: this patch is not the patch given in the comments + patch -Np1 -i "$srcdir/sig-patch.diff" + + #ln -s /.../RXTXcomm.jar app/lib # already on the classpath + ln -s /usr/share/java/antlr2.jar app/lib/antlr.jar + #ln -s /.../apple.jar app/lib # only used on Mac OS + ln -s /usr/share/java/ecj.jar app/lib + ln -s /usr/share/java/jna.jar app/lib + ln -s /usr/bin/avrdude build/linux/dist/tools + + ln -s "$srcdir/empty.tar.bz2" build/linux/avr_tools_linux32.tar.bz2 + ln -s "$srcdir/empty.tar.bz2" build/linux/avr_tools_linux64.tar.bz2 + + for d in methods preproc; do + cd "$srcdir/arduino-$pkgver/core/$d" + ant + done + + cd "$srcdir/arduino-$pkgver/build" + + log=`mktemp` + ant 2>&1|tee "$log" + if egrep -q 'Error|FAILED' "$log"; then + rm "$log" + false + else + rm "$log" + fi +} + +package() { + cd "$srcdir/arduino-$pkgver/build/linux/work" + + # arduino excutable should accept arguments + sed -i 's|^java .* processing.app.Base$|\0 "$@"|' arduino + sed -i 's|^APPDIR=.*|APPDIR=/usr/share/arduino|' arduino + + mkdir -p "$pkgdir"/usr/{bin,share/{doc,applications,pixmaps}} + + # copy the whole SDK to /usr/share/arduino/ + cp -r . "$pkgdir/usr/share/arduino" + + # at least support the FHS a little bit: + install -m755 "arduino" "$pkgdir/usr/bin/arduino" + ln -s /usr/share/arduino/reference "$pkgdir/usr/share/doc/arduino" + + # desktop icon + install -m644 "$srcdir/arduino.desktop" "$pkgdir/usr/share/applications/" + install -m644 "$srcdir/arduino.png" "$pkgdir/usr/share/pixmaps/" +} + +md5sums=('03263613f4be4f865989244420be04fa' + 'acadc724cbe08c09711825f4bd5c04f6' + '9e36d33891d5e68d38ec55d1494499a5' + 'eebc4d6495864bea99ad057af801afb9') diff --git a/java/arduino/arduino.desktop b/java/arduino/arduino.desktop new file mode 100644 index 000000000..8469724ea --- /dev/null +++ b/java/arduino/arduino.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Arduino +GenericName=Arduino IDE +Comment=The open-source Arduino environment +Exec=arduino +Icon=arduino +Type=Application +Terminal=false +Categories=Development;IDE;Qt;KDE;;Application; diff --git a/java/arduino/arduino.install b/java/arduino/arduino.install new file mode 100644 index 000000000..35d283fab --- /dev/null +++ b/java/arduino/arduino.install @@ -0,0 +1,10 @@ +post_install() { + xdg-icon-resource install --size 256 --novendor /usr/share/pixmaps/arduino.png + echo "Don't forget to add yourself to the uucp group: gpasswd -a <user> uucp" +} + +pre_remove() { + xdg-icon-resource uninstall --size 256 arduino +} + +# vim:set ts=2 sw=2 et: diff --git a/java/arduino/arduino.png b/java/arduino/arduino.png Binary files differnew file mode 100644 index 000000000..ea3ac81b4 --- /dev/null +++ b/java/arduino/arduino.png diff --git a/java/arduino/sig-patch.diff b/java/arduino/sig-patch.diff new file mode 100644 index 000000000..4be3a6cdc --- /dev/null +++ b/java/arduino/sig-patch.diff @@ -0,0 +1,256 @@ +diff -ruN arduino-1.0.1.orig/hardware/arduino/cores/arduino/HardwareSerial.cpp arduino-1.0.1/hardware/arduino/cores/arduino/HardwareSerial.cpp +--- arduino-1.0.1.orig/hardware/arduino/cores/arduino/HardwareSerial.cpp 2012-05-21 13:01:43.000000000 -0400 ++++ arduino-1.0.1/hardware/arduino/cores/arduino/HardwareSerial.cpp 2012-10-19 23:26:46.000000000 -0400 +@@ -88,24 +88,16 @@ + #if !defined(USART0_RX_vect) && defined(USART1_RX_vect) + // do nothing - on the 32u4 the first USART is USART1 + #else +-#if !defined(USART_RX_vect) && !defined(SIG_USART0_RECV) && \ +- !defined(SIG_UART0_RECV) && !defined(USART0_RX_vect) && \ +- !defined(SIG_UART_RECV) ++#if !defined(USART_RX_vect) && !defined(USART0_RX_vect) + #error "Don't know what the Data Received vector is called for the first UART" + #else + void serialEvent() __attribute__((weak)); + void serialEvent() {} + #define serialEvent_implemented + #if defined(USART_RX_vect) +- SIGNAL(USART_RX_vect) +-#elif defined(SIG_USART0_RECV) +- SIGNAL(SIG_USART0_RECV) +-#elif defined(SIG_UART0_RECV) +- SIGNAL(SIG_UART0_RECV) ++ ISR(USART_RX_vect) + #elif defined(USART0_RX_vect) +- SIGNAL(USART0_RX_vect) +-#elif defined(SIG_UART_RECV) +- SIGNAL(SIG_UART_RECV) ++ ISR(USART0_RX_vect) + #endif + { + #if defined(UDR0) +@@ -124,39 +116,33 @@ + void serialEvent1() __attribute__((weak)); + void serialEvent1() {} + #define serialEvent1_implemented +- SIGNAL(USART1_RX_vect) ++ ISR(USART1_RX_vect) + { + unsigned char c = UDR1; + store_char(c, &rx_buffer1); + } +-#elif defined(SIG_USART1_RECV) +- #error SIG_USART1_RECV + #endif + + #if defined(USART2_RX_vect) && defined(UDR2) + void serialEvent2() __attribute__((weak)); + void serialEvent2() {} + #define serialEvent2_implemented +- SIGNAL(USART2_RX_vect) ++ ISR(USART2_RX_vect) + { + unsigned char c = UDR2; + store_char(c, &rx_buffer2); + } +-#elif defined(SIG_USART2_RECV) +- #error SIG_USART2_RECV + #endif + + #if defined(USART3_RX_vect) && defined(UDR3) + void serialEvent3() __attribute__((weak)); + void serialEvent3() {} + #define serialEvent3_implemented +- SIGNAL(USART3_RX_vect) ++ ISR(USART3_RX_vect) + { + unsigned char c = UDR3; + store_char(c, &rx_buffer3); + } +-#elif defined(SIG_USART3_RECV) +- #error SIG_USART3_RECV + #endif + + void serialEventRun(void) +diff -ruN arduino-1.0.1.orig/hardware/arduino/cores/arduino/HardwareSerial.h arduino-1.0.1/hardware/arduino/cores/arduino/HardwareSerial.h +--- arduino-1.0.1.orig/hardware/arduino/cores/arduino/HardwareSerial.h 2012-05-21 13:01:43.000000000 -0400 ++++ arduino-1.0.1/hardware/arduino/cores/arduino/HardwareSerial.h 2012-10-19 23:13:59.000000000 -0400 +@@ -76,6 +76,15 @@ + extern HardwareSerial Serial3; + #endif + ++/* ++ * on ATmega8, the uart and its bits are not numbered, so there is no "TXC0" ++ * definition. It is slightly cleaner to define this here instead of having ++ * conditional code in the cpp module. ++ */ ++#if !defined(TXC0) ++#define TXC0 TXC ++#endif ++ + extern void serialEventRun(void) __attribute__((weak)); + + #endif +diff -ruN arduino-1.0.1.orig/hardware/arduino/cores/arduino/WInterrupts.c arduino-1.0.1/hardware/arduino/cores/arduino/WInterrupts.c +--- arduino-1.0.1.orig/hardware/arduino/cores/arduino/WInterrupts.c 2012-05-21 13:01:43.000000000 -0400 ++++ arduino-1.0.1/hardware/arduino/cores/arduino/WInterrupts.c 2012-10-19 23:13:59.000000000 -0400 +@@ -216,72 +216,72 @@ + */ + + #if defined(__AVR_ATmega32U4__) +-SIGNAL(INT0_vect) { ++ISR(INT0_vect) { + if(intFunc[EXTERNAL_INT_0]) + intFunc[EXTERNAL_INT_0](); + } + +-SIGNAL(INT1_vect) { ++ISR(INT1_vect) { + if(intFunc[EXTERNAL_INT_1]) + intFunc[EXTERNAL_INT_1](); + } + + #elif defined(EICRA) && defined(EICRB) + +-SIGNAL(INT0_vect) { ++ISR(INT0_vect) { + if(intFunc[EXTERNAL_INT_2]) + intFunc[EXTERNAL_INT_2](); + } + +-SIGNAL(INT1_vect) { ++ISR(INT1_vect) { + if(intFunc[EXTERNAL_INT_3]) + intFunc[EXTERNAL_INT_3](); + } + +-SIGNAL(INT2_vect) { ++ISR(INT2_vect) { + if(intFunc[EXTERNAL_INT_4]) + intFunc[EXTERNAL_INT_4](); + } + +-SIGNAL(INT3_vect) { ++ISR(INT3_vect) { + if(intFunc[EXTERNAL_INT_5]) + intFunc[EXTERNAL_INT_5](); + } + +-SIGNAL(INT4_vect) { ++ISR(INT4_vect) { + if(intFunc[EXTERNAL_INT_0]) + intFunc[EXTERNAL_INT_0](); + } + +-SIGNAL(INT5_vect) { ++ISR(INT5_vect) { + if(intFunc[EXTERNAL_INT_1]) + intFunc[EXTERNAL_INT_1](); + } + +-SIGNAL(INT6_vect) { ++ISR(INT6_vect) { + if(intFunc[EXTERNAL_INT_6]) + intFunc[EXTERNAL_INT_6](); + } + +-SIGNAL(INT7_vect) { ++ISR(INT7_vect) { + if(intFunc[EXTERNAL_INT_7]) + intFunc[EXTERNAL_INT_7](); + } + + #else + +-SIGNAL(INT0_vect) { ++ISR(INT0_vect) { + if(intFunc[EXTERNAL_INT_0]) + intFunc[EXTERNAL_INT_0](); + } + +-SIGNAL(INT1_vect) { ++ISR(INT1_vect) { + if(intFunc[EXTERNAL_INT_1]) + intFunc[EXTERNAL_INT_1](); + } + + #if defined(EICRA) && defined(ISC20) +-SIGNAL(INT2_vect) { ++ISR(INT2_vect) { + if(intFunc[EXTERNAL_INT_2]) + intFunc[EXTERNAL_INT_2](); + } +@@ -290,9 +290,8 @@ + #endif + + /* +-SIGNAL(SIG_2WIRE_SERIAL) { ++ISR(TWI_vect) { + if(twiIntFunc) + twiIntFunc(); + } + */ +- +diff -ruN arduino-1.0.1.orig/hardware/arduino/cores/arduino/wiring.c arduino-1.0.1/hardware/arduino/cores/arduino/wiring.c +--- arduino-1.0.1.orig/hardware/arduino/cores/arduino/wiring.c 2012-05-21 13:01:43.000000000 -0400 ++++ arduino-1.0.1/hardware/arduino/cores/arduino/wiring.c 2012-10-19 23:13:59.000000000 -0400 +@@ -42,9 +42,9 @@ + static unsigned char timer0_fract = 0; + + #if defined(__AVR_ATtiny24__) || defined(__AVR_ATtiny44__) || defined(__AVR_ATtiny84__) +-SIGNAL(TIM0_OVF_vect) ++ISR(TIM0_OVF_vect) + #else +-SIGNAL(TIMER0_OVF_vect) ++ISR(TIMER0_OVF_vect) + #endif + { + // copy these to local variables so they can be stored in registers +diff -ruN arduino-1.0.1.orig/libraries/Servo/Servo.cpp arduino-1.0.1/libraries/Servo/Servo.cpp +--- arduino-1.0.1.orig/libraries/Servo/Servo.cpp 2012-05-08 20:34:38.000000000 -0400 ++++ arduino-1.0.1/libraries/Servo/Servo.cpp 2012-10-19 23:13:59.000000000 -0400 +@@ -100,28 +100,28 @@ + #ifndef WIRING // Wiring pre-defines signal handlers so don't define any if compiling for the Wiring platform
+ // Interrupt handlers for Arduino
+ #if defined(_useTimer1)
+-SIGNAL (TIMER1_COMPA_vect)
++ISR(TIMER1_COMPA_vect)
+ {
+ handle_interrupts(_timer1, &TCNT1, &OCR1A);
+ }
+ #endif
+
+ #if defined(_useTimer3)
+-SIGNAL (TIMER3_COMPA_vect)
++ISR(TIMER3_COMPA_vect)
+ {
+ handle_interrupts(_timer3, &TCNT3, &OCR3A);
+ }
+ #endif
+
+ #if defined(_useTimer4)
+-SIGNAL (TIMER4_COMPA_vect)
++ISR(TIMER4_COMPA_vect)
+ {
+ handle_interrupts(_timer4, &TCNT4, &OCR4A);
+ }
+ #endif
+
+ #if defined(_useTimer5)
+-SIGNAL (TIMER5_COMPA_vect)
++ISR(TIMER5_COMPA_vect)
+ {
+ handle_interrupts(_timer5, &TCNT5, &OCR5A);
+ }
+diff -ruN arduino-1.0.1.orig/libraries/Wire/utility/twi.c arduino-1.0.1/libraries/Wire/utility/twi.c +--- arduino-1.0.1.orig/libraries/Wire/utility/twi.c 2012-02-18 19:57:03.000000000 -0500 ++++ arduino-1.0.1/libraries/Wire/utility/twi.c 2012-10-19 23:13:59.000000000 -0400 +@@ -360,7 +360,7 @@ + twi_state = TWI_READY; + } + +-SIGNAL(TWI_vect) ++ISR(TWI_vect) + { + switch(TW_STATUS){ + // All Master diff --git a/java/java-asm2/PKGBUILD b/java/java-asm2/PKGBUILD new file mode 100644 index 000000000..3541c20ab --- /dev/null +++ b/java/java-asm2/PKGBUILD @@ -0,0 +1,18 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgver=2.2.3 +. common.sh + +#### + +pkgrel=5 +_checksource_ignore=('test/conform/org/objectweb/asm/signature/signatures.txt') + +mksource() { + cd "$srcdir/$_pkgname-$pkgver" + rm test/conform/org/objectweb/asm/attrs/StackMapTableSample.data + rm test/conform/cases/*.class + mkdir -p test/lib +} + +md5sums=('7a92c87bf067925685cf68dcc0dd8998') diff --git a/java/java-asm2/PKGBUILD-bootstrap b/java/java-asm2/PKGBUILD-bootstrap new file mode 100644 index 000000000..9e896a90e --- /dev/null +++ b/java/java-asm2/PKGBUILD-bootstrap @@ -0,0 +1,23 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +# "java-asm2" is required to build "java-ow-util-ant-tasks", which is in turn +# required to build "java-asm2". + +. PKGBUILD + +makedepends=(jh) +source=("http://download.forge.objectweb.org/$_pkgname/$_pkgname-$pkgver-bin.zip") +_distdir="$_pkgname-$pkgver" + +provides+=("$pkgname=$pkgver") +pkgname+='-bootstrap' +pkgdesc+=" (prebuilt binary release for bootstrapping purposes)" + +build() { + cd "$srcdir/$_pkgname-$pkgver" + echo "3-clause BSD license; install the non-bootstrap version for full text" > LICENSE.txt + cd "$srcdir/$_distdir/lib" + ln -s all/* . +} + +md5sums=('9bedaa1d00c5b5f1c7fec10a2d2f7142') diff --git a/libre/java-asm2/PKGBUILD b/java/java-asm2/common.sh index 4853d79c0..6a664c9ff 100755..100644 --- a/libre/java-asm2/PKGBUILD +++ b/java/java-asm2/common.sh @@ -1,76 +1,59 @@ # Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> _pkgname=asm -pkgname=java-asm2 -_pkgver=2 -pkgver=2.2.3 -pkgrel=4 +pkgname=java-asm${pkgver%%.*} pkgdesc="An all purpose Java bytecode manipulation and analysis framework." -arch=('any') url="http://asm.ow2.org/" license=('custom:BSD3') + +arch=('any') depends=('java-runtime') makedepends=( apache-ant java-ow-util-ant-tasks + jh ) source=("http://download.forge.objectweb.org/$_pkgname/$_pkgname-$pkgver.tar.gz") -_M2_LOCALREPO='/usr/share/maven/repository' +_distdir="$_pkgname-$pkgver/output/dist" _ow_util_ant_tasks='/usr/share/java/ow_util_ant_tasks.jar' -_m2_packages=( - asm - asm-analysis - asm-attrs - asm-commons - asm-tree - asm-util - asm-xml - asm-all) build() { cd "$srcdir/$_pkgname-$pkgver" - - mkdir -p test/lib + eval `jh mksource ${_checksource_ignore[@]}` echo "objectweb.ant.tasks.path $_ow_util_ant_tasks" >> build.properties ant dist # This will make package() easier: - cd output/dist/lib + cd "$srcdir/$_distdir/lib" ln -s all/* . } package() { - cd "$srcdir/$_pkgname-$pkgver" - # Install license file + cd "$srcdir/$_pkgname-$pkgver" install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE" # Install documentation - cd output/dist + cd "$srcdir/$_distdir" install -d "$pkgdir/usr/share/doc/$pkgname" cp -r doc/javadoc/user "$pkgdir/usr/share/doc/$pkgname/javadoc" cp -r examples "$pkgdir/usr/share/doc/$pkgname/examples" - - # Install Apache Maven modules - cd lib - install -d "$pkgdir"/usr/share/java/asm - for pkg in "${_m2_packages[@]}"; do - dir="$_M2_LOCALREPO"/asm/$pkg/$pkgver - # Create the Maven directory - install -d "$pkgdir$dir" - # Install the files - cp $pkg-$pkgver.* "$pkgdir$dir" + + # Install the README about the -all files + cd "$srcdir/$_distdir/lib" + install -Dm644 README.txt \ + "$pkgdir"/usr/share/java/$_pkgname/README-$pkgver.txt + + # Install Maven artifacts + export DESTDIR=$pkgdir + for artifact in $(ls *.jar|sed 's/-[0-9.]*\.jar$//'); do + jh mvn-install $_pkgname $artifact $pkgver $artifact-$pkgver.{jar,pom} # Symlink them to /usr/share/java - ln -s "$dir"/$pkg-$pkgver.jar "$pkgdir"/usr/share/java/asm/ - ln -s asm/$pkg-$pkgver.jar "$pkgdir"/usr/share/java/$pkg-$_pkgver.jar + ln -s "$(jh mvn-basename asm $artifact $pkgver).jar" \ + "$pkgdir"/usr/share/java/$_pkgname/ + ln -s $_pkgname/$artifact-$pkgver.jar \ + "$pkgdir"/usr/share/java/$artifact-${pkgver%%.*}.jar done - - # Install a README file about the -all files - cd "$srcdir/$_pkgname-$pkgver" - install -m644 output/dist/lib/all/README.txt \ - "$pkgdir"/usr/share/java/asm/README-$pkgver.txt } - -md5sums=('7a92c87bf067925685cf68dcc0dd8998') diff --git a/java/java-asm3/PKGBUILD b/java/java-asm3/PKGBUILD new file mode 100644 index 000000000..e85896b72 --- /dev/null +++ b/java/java-asm3/PKGBUILD @@ -0,0 +1,17 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgver=3.3.1 +. ../java-asm2/common.sh + +#### + +pkgrel=5 +_checksource_ignore=(src/org/objectweb/asm/optimizer/jdk{1.2.2_017,1.3.1_19}.txt.gz) + +mksource() { + cd "$srcdir/$_pkgname-$pkgver" + rm cobertura.ser # We regenerate this + rm examples/jasmin/test/jasmin.jar +} + +md5sums=('433024df8176f09922646316e415631c') diff --git a/java/java-jarjar/PKGBUILD b/java/java-jarjar/PKGBUILD new file mode 100644 index 000000000..8d1d1120b --- /dev/null +++ b/java/java-jarjar/PKGBUILD @@ -0,0 +1,49 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +# jarjar 1.2 is old, but is the last version that used java-asm3 +# java-asm4 is not packaged + +_pkgname=jarjar +pkgname=java-jarjar +pkgver=1.2 +_pkgrev=132 # v1.2 wasn't tagged, but this is clearly it +pkgdesc="Java static linker (instead of the normal dynamic linking)" +url="https://code.google.com/p/jarjar/" +license=('Apache2') + +pkgrel=1 +arch=('any') +depends=('java-runtime') +makedepends=('apache-ant' 'java-asm3' 'junit' 'maven' 'jh') +source=("svn+http://jarjar.googlecode.com/svn/trunk/jarjar#revision=$_pkgrev") + +mksource() { + cd "$srcdir/$_pkgname" + rm -f src/test/*.{class,jar} + rm -f lib/*.jar +} + +build() { + cd "$srcdir/$_pkgname" + eval `jh mksource` + + ln -s /usr/share/java/asm-3.jar lib/asm-3.3.1.jar + ln -s /usr/share/java/asm-commons-3.jar lib/asm-commons-3.3.1.jar + ln -s /usr/share/java/junit.jar lib/junit-4.8.1.jar + ln -s /opt/maven/lib/maven-plugin-api-*.jar lib/maven-plugin-api.jar + + ln -s /opt/apache-ant/lib/ant.jar lib/ + + export CLASSPATH=/usr/share/java/asm-3.jar + echo 'includeantruntime false' > build.properties + ant jar +} + +package() { + cd "$srcdir/$_pkgname" + install -d "$pkgdir/usr/share/java/$_pkgname" + install -D "dist/$_pkgname-$pkgver.jar" "$pkgdir/usr/share/java/$_pkgname" + ln -s "$_pkgname/$_pkgname-$pkgver.jar" "$pkgdir/usr/share/java/$_pkgname.jar" +} + +md5sums=('SKIP') diff --git a/java/java-jarjar/PKGBUILD-1.4 b/java/java-jarjar/PKGBUILD-1.4 new file mode 100644 index 000000000..f0ebe9270 --- /dev/null +++ b/java/java-jarjar/PKGBUILD-1.4 @@ -0,0 +1,41 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +_pkgname=jarjar +pkgname=java-jarjar +pkgver=1.4 +pkgdesc="Java static linker (instead of the normal dynamic linking)" +url="https://code.google.com/p/jarjar/" +license=('Apache2') + +pkgrel=1 +arch=('any') +depends=('java-runtime') +makedepends=('apache-ant' 'java-asm4' 'junit' 'maven' 'jh') +source=("https://${_pkgname}.googlecode.com/files/${_pkgname}-src-${pkgver}.zip") + +mksource() { + cd "$srcdir/$_pkgname-$pkgver" + rm -f src/test/*.{class,jar} + rm -f lib/*.jar +} + +build() { + cd "$srcdir/$_pkgname-$pkgver" + eval `jh mksource` + + ln -s /usr/share/java/asm-4.jar lib/asm-4.0.jar + ln -s /usr/share/java/asm-commons-4.jar lib/asm-commons-4.0.jar + ln -s /usr/share/java/junit.jar lib/junit-4.8.1.jar + ln -s /opt/maven/lib/maven-plugin-api-*.jar lib/maven-plugin-api.jar + + ant jar +} + +package() { + cd "$srcdir/$pkgname" + install -d "$pkgdir/usr/share/java/$_pkgname" + install -D "dist/$_pkgname-$pkgver.jar" "$pkgdir/usr/share/java/$_pkgname" + ln -s "$_pkgname/$_pkgname-$pkgver.jar" "$pkgdir/usr/share/java/$_pkgname.jar" +} + +sha1sums=('803ad79cf429faeb4d767b2fb45d84bbc904ea04') diff --git a/libre/java-ow-util-ant-tasks/PKGBUILD b/java/java-ow-util-ant-tasks/PKGBUILD index 023048188..f1add43ea 100755..100644 --- a/libre/java-ow-util-ant-tasks/PKGBUILD +++ b/java/java-ow-util-ant-tasks/PKGBUILD @@ -13,8 +13,8 @@ source=("http://repo.parabolagnulinux.org/sources/${pkgname}-${pkgver}-1-any.src build() { cd "$srcdir/$pkgname-$pkgver" - ln -s /usr/share/java/asm-2.jar externals - ln -s /usr/share/java/xalan.jar externals + ln -s /usr/share/java/asm-2.jar externals/ + ln -s /usr/share/java/xalan.jar externals/ ant jar } diff --git a/libre/java-ow-util-ant-tasks/SRCBUILD b/java/java-ow-util-ant-tasks/SRCBUILD index 01241907d..01241907d 100755..100644 --- a/libre/java-ow-util-ant-tasks/SRCBUILD +++ b/java/java-ow-util-ant-tasks/SRCBUILD diff --git a/java/java-rxtx/ChangeLog.txt b/java/java-rxtx/ChangeLog.txt new file mode 100644 index 000000000..7efab2514 --- /dev/null +++ b/java/java-rxtx/ChangeLog.txt @@ -0,0 +1,8 @@ +Differences from rxtx-2.1-7r2 made by Arduino: + * Adding support for /dev/ttyACM* devices on Linux. + * Fixing (I hope) problems on 64-bit Linux systems. + * Adding checks for Java 1.6. + * Removing unnecessary compiler warning. + +Differences from Arduino's version: + * Adding checks for Java 1.7. diff --git a/java/java-rxtx/PKGBUILD b/java/java-rxtx/PKGBUILD new file mode 100644 index 000000000..30ed25967 --- /dev/null +++ b/java/java-rxtx/PKGBUILD @@ -0,0 +1,54 @@ +# Maintainer (Parabola): Luke Shumaker <lukeshu@sbcglobal.net> +# Maintainer (AUR): PyroPeter <googlemail.com@abi1789> + +pkgname=java-rxtx +_pkgver=2.1-7r2-arduino4 +_gitver='commit=a8cd90f8505d7c472b57550b1192fe67885dd638' +pkgver=${_pkgver//-/.} + +pkgrel=1 +pkgdesc="A native library providing serial and parallel communication for Java" +arch=('i686' 'x86_64') +depends=('java-environment') + +case "$_pkgver" in + *arduino*) + url="https://github.com/arduino/RXTX" + source=("git://github.com/arduino/RXTX.git#${_gitver}" + java7-configure.patch + destdir.patch) + license=(LGPL) + changelog=ChangeLog.txt + _dirname=RXTX + ;; + *) + url="http://rxtx.qbang.org/" + source=("http://rxtx.qbang.org/pub/rxtx/rxtx-${_pkgver}.zip" + destdir.patch) + # Todo: patch for Java 6 AND Java 7 + license=('custom:LGPL-with-java-exception') + _dirname=rxtx-{$_pkgver} + ;; +esac + +build() { + cd "$srcdir/$_dirname" + . /etc/profile.d/jdk.sh + + patch -i "$srcdir/java7-configure.patch" + patch -i "$srcdir/destdir.patch" + + ./configure --prefix=/usr + make +} + +package() { + cd "$srcdir/$_dirname" + . /etc/profile.d/jdk.sh + + make DESTDIR="$pkgdir" install +} + +md5sums=('SKIP' + 'f07bc244660852dd9b016c190e38e1c9' + '90be9bdf1d8cbe5304739df066559a13') diff --git a/java/java-rxtx/destdir.patch b/java/java-rxtx/destdir.patch new file mode 100644 index 000000000..11416841f --- /dev/null +++ b/java/java-rxtx/destdir.patch @@ -0,0 +1,20 @@ +--- Makefile.in.orig 2012-09-21 15:21:00.000000000 -0400 ++++ Makefile.in 2012-09-21 15:21:07.000000000 -0400 +@@ -566,13 +566,15 @@ + # install librxtxSerial.so into the proper directory and copy $(JARTARGET) to its + # proper location + install: all ++ $(mkinstalldirs) $(DESTDIR)$(RXTX_PATH) ++ $(mkinstalldirs) $(DESTDIR)$(JHOME) + @$(LIBTOOL_INST) \ + `for i in $(TARGETLIB);do \ + if [ -f $$i ];then \ + echo $$i; \ + fi; \ +- done` $(RXTX_PATH) +- $(INSTALL_PROGRAM) $(JARTARGET) $(JHOME)/ ++ done` $(DESTDIR)$(RXTX_PATH) ++ $(INSTALL_PROGRAM) $(JARTARGET) $(DESTDIR)$(JHOME)/ + + clean-generic: + rm -rf $(DEST) $(TOP)/$(CLASSTOP) diff --git a/java/java-rxtx/java7-configure.patch b/java/java-rxtx/java7-configure.patch new file mode 100644 index 000000000..fed710200 --- /dev/null +++ b/java/java-rxtx/java7-configure.patch @@ -0,0 +1,38 @@ +--- configure.orig 2012-09-21 15:02:54.000000000 -0400 ++++ configure 2012-09-21 15:03:38.000000000 -0400 +@@ -21541,7 +21541,7 @@ + CFLAGS=$CFLAGS" -D__need_timespec" + case $JAVA_VERSION in + +- 1.2*|1.3*|1.4*|1.5*|1.6*) ++ 1.2*|1.3*|1.4*|1.5*|1.6*|1.7*) + #fix_parameters $JPATH/jre/lib/javax.comm.properties + CLASSPATH=".:\$(TOP):\$(TOP)/src:"`find $JPATH/ -name RXTXcomm.jar |head -n1` + JHOME=$JPATH"/jre/lib/ext" +@@ -21611,7 +21611,7 @@ + TARGETLIB="\$(target_triplet)/librxtxSerial.la \ + \$(target_triplet)/librxtxParallel.la" + case $JAVA_VERSION in +- 1.2*|1.3*|1.4*|1.5*|1.6*) ++ 1.2*|1.3*|1.4*|1.5*|1.6*|1.7*) + #fix_parameters $JPATH/jre/lib/javax.comm.properties + CLASSPATH=".:\$(TOP):\$(TOP)/src:"`find $JPATH/ -name RXTXcomm.jar |head -n1` + RXTX_PATH="\$(JPATH)/jre/lib/\$(OS_ARCH)" +@@ -21747,7 +21747,7 @@ + + WIN32) + case $JAVA_VERSION in +- 1.2*|1.3*|1.4*|1.5*|1.6*) ++ 1.2*|1.3*|1.4*|1.5*|1.6*|1.7*) + CLASSPATH=".:\$(TOP):\$(TOP)/src:`find $JPATH/ -name RXTXcomm.jar |head -n1`:$CLASSPATH" + JHOME=$JPATH"/jre/lib/ext" + ;; +@@ -21799,7 +21799,7 @@ + CLASSPATH=".:\$(TOP):\$(TOP)/src:\$(JPATH)/lib/classes.zip:\$(JPATH)/lib/RXTXcomm.jar:$CLASSPATH" + + case $JAVA_VERSION in +- 1.2*|1.3*|1.4*|1.5*|1.6*) ++ 1.2*|1.3*|1.4*|1.5*|1.6*|1.7*) + RXTX_PATH="\$(JPATH)/jre/lib/\$(OS_ARCH)" + ;; + 1.1*) diff --git a/java/java-sonatype-oss-parent/PKGBUILD b/java/java-sonatype-oss-parent/PKGBUILD new file mode 100644 index 000000000..f42f6adc5 --- /dev/null +++ b/java/java-sonatype-oss-parent/PKGBUILD @@ -0,0 +1,27 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgname=java-sonatype-oss-parent +pkgver=7 +pkgdesc="Metadata file for Maven-based build systems to inherit from" +license='Apache2' + +_groupId=org/sonatype/oss +_artifactId=oss-parent + +pkgrel=1 +arch=('any') +depends=('maven') +makedepends=('java-sonatype-oss-parent=7' 'jh') +source=("http://search.maven.org/remotecontent?filepath=$_groupId/$_artifactId/$pkgver/$_artifactId-$pkgver.pom") + +build() { + : +} + +package() { + cd "$srcdir" + install -Dm644 $_artifactId-$pkgver.pom \ + "$pkgdir/`jh mvn-basename $_groupId $_artifactId $pkgver`".pom +} + +md5sums=('3e418cf7f2607bf359e6c514a992cb38') diff --git a/java/jh/PKGBUILD b/java/jh/PKGBUILD new file mode 100644 index 000000000..5382cb0e5 --- /dev/null +++ b/java/jh/PKGBUILD @@ -0,0 +1,24 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgname=jh +pkgver=0.3.2 +pkgdesc="Java helpers for PKGBUILDs" +url="https://gitorious.org/parabola/jh" +license=('Public Domain') + +pkgrel=1 +arch=(any) +depends=(xmlstarlet maven) +source=("git://gitorious.org/parabola/jh.git#tag=v$pkgver") + +build() { + cd "$srcdir/$pkgname" + make +} + +package() { + cd "$srcdir/$pkgname" + make install DESTDIR="$pkgdir" +} + +md5sums=('SKIP') diff --git a/java/jna/PKGBUILD b/java/jna/PKGBUILD new file mode 100644 index 000000000..db5f552cb --- /dev/null +++ b/java/jna/PKGBUILD @@ -0,0 +1,117 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgname=jna +pkgver=3.4.2 + +pkgdesc="Provides Java programs easy access to native shared libraries" +url="https://github.com/twall/jna" +license=('LGPL') +source=("git://github.com/twall/jna.git#tag=${pkgver}" + 'libre-without-clover.patch' + 'bugfix-type-inference.patch' + 'webstart-test.keystore') + +#### + +pkgrel=1 +arch=('i686' 'x86_64') +depends=('java-environment' 'libffi') +makedepends=('apache-ant' 'zip') +checkdepends=('junit' 'icedtea-web-java7') +options=('!makeflags') + +unset _JAVA_OPTIONS +_M2_LOCALREPO='/usr/share/maven/repository' +. /etc/profile.d/jdk.sh + +_ant_options=( + '-Ddynlink.native=true' # use the system install of libffi +) + +#### + +mksource() { + cd "$srcdir/jna" + find . -name '*.jar' -delete + rm -rf dist + rm -rf native/libffi # make sure it doesn't cheat + rm lib/clover.license + rm w32ce-test.lnk + + ln -s /usr/share/java/junit.jar lib/ + + # Create an emtpy zip (jar) file + cd "$srcdir" + touch file + zip empty.zip file + zip -d empty.zip file + rm file +} + +#### + +build() { + mksource + cd "$srcdir/jna" + + # Because JNA's release process is ridiculous, it wants a jar file for every + # architecture to be present. So let's just dump in an empty jar file! + sed -n 's|\s*<zipfileset src="${lib\.native}/\(.*\)"|\1|p' build.xml \ + | while read jarfile; do + cp "$srcdir/empty.zip" lib/native/$jarfile + done + + patch -p1 -i "$srcdir/libre-without-clover.patch" + patch -p1 -i "$srcdir/bugfix-type-inference.patch" + + # Disable tests that intermittently fail + # crashes vm (segfault) + sed -i -e 's|testRegisterMethods|no&|' test/com/sun/jna/DirectTest.java + # crashes vm, java 7 only (icedtea-7, oracle-jdk-bin-1.7) + sed -i -e 's|testGCCallbackOnFinalize|no&|' test/com/sun/jna/CallbacksTest.java + + # Actually build + ant "${_ant_options[@]}" dist +} + +check() { + cd "$srcdir/jna" + + # Create a foke home directory to trash + mkdir "$srcdir/user.home" + export _JAVA_OPTIONS="-Duser.home=$srcdir/user.home" + + # The webstart test looks for this config file + mkdir -p "$srcdir/user.home/.java/deployment" + touch "$srcdir/user.home/.java/deployment/deployment.properties" + + # Trust the cert used for the webstart test + mkdir -p "$srcdir/user.home/.icedtea/security" + cp "$srcdir/webstart-test.keystore" "$srcdir/user.home/.icedtea/security/trusted.certs" + + _ant_options+=('-Dtests.exclude-patterns=**/DirectTest.java') + + # Run the tests + ant "${_ant_options[@]}" test +} + +package() { + cd "$srcdir/jna" + + install -d "$pkgdir/usr/share/java/jna" + + for pkg in jna platform; do + dir="$_M2_LOCALREPO"/net/java/dev/jna/$pkg/$pkgver + install -d "$pkgdir$dir" + cp dist/$pkg.jar "$pkgdir$dir/$pkg-$pkgver.jar" + cp pom-$pkg.xml "$pkgdir$dir/$pkg-$pkgver.pom" + ln -s "$dir/$pkg-$pkgver.jar" "$pkgdir/usr/share/java/jna/$pkg.jar" + done + + ln -s jna/jna.jar "$pkgdir/usr/share/java/jna.jar" +} + +md5sums=('SKIP' + '3a2f96b868f49ca125b677779e846484' + '932d9cb2da1531a2315ae132480683fa' + 'b704c7d2cb1fe7a93f8cad8d321d16f8') diff --git a/java/jna/bugfix-type-inference.patch b/java/jna/bugfix-type-inference.patch new file mode 100644 index 000000000..2322b13fc --- /dev/null +++ b/java/jna/bugfix-type-inference.patch @@ -0,0 +1,13 @@ +diff -ru jna-3.4.2.orig/test/com/sun/jna/NativeTest.java jna-3.4.2/test/com/sun/jna/NativeTest.java +--- jna-3.4.2.orig/test/com/sun/jna/NativeTest.java 2012-09-03 08:30:42.000000000 -0400 ++++ jna-3.4.2/test/com/sun/jna/NativeTest.java 2012-09-24 15:29:48.000000000 -0400 +@@ -374,7 +374,8 @@ + for (int i=0;i < args.length;i++) { + System.out.println("Running tests on class " + args[i]); + try { +- junit.textui.TestRunner.run(Class.forName(args[i])); ++ Class<?> klass = Class.forName(args[i]); ++ junit.textui.TestRunner.run((Class<? extends TestCase>)klass); + } + catch(Throwable e) { + e.printStackTrace(); diff --git a/java/jna/libre-without-clover.patch b/java/jna/libre-without-clover.patch new file mode 100644 index 000000000..b4947e8b2 --- /dev/null +++ b/java/jna/libre-without-clover.patch @@ -0,0 +1,71 @@ +diff -ru jna-3.4.2.orig/build.xml jna-3.4.2/build.xml +--- jna-3.4.2.orig/build.xml 2012-09-06 06:55:52.000000000 -0400 ++++ jna-3.4.2/build.xml 2012-09-24 15:49:59.000000000 -0400 +@@ -230,7 +230,6 @@ + <path id="test.runpath"> + <pathelement path="${build}/${jar}"/> + <pathelement path="${test.classes}"/> +- <pathelement path="lib/clover.jar"/> + <path refid="test.libs"/> + </path> + </target> +@@ -536,12 +535,11 @@ + <copy todir="${build}/jws" file="${build}/${jar}"/> + <copy todir="${build}/jws" file="${build}/${testjar}"/> + <copy todir="${build}/jws" file="lib/junit.jar"/> +- <copy todir="${build}/jws" file="lib/clover.jar"/> + <jar jarfile="${build}/jws/jnidispatch.jar"> + <fileset dir="${build.native}" includes="*jnidispatch.*"/> + </jar> + <signjar alias="jna" keystore="jna.keystore" storepass="jnadev" lazy="true"> +- <fileset dir="${build}/jws" includes="jna.jar,jna-test.jar,junit.jar,jnidispatch.jar,clover.jar"/> ++ <fileset dir="${build}/jws" includes="jna.jar,jna-test.jar,junit.jar,jnidispatch.jar"/> + </signjar> + </target> + +@@ -626,7 +624,7 @@ + <report todir="${reports.junit}"/> + </junitreport> + <echo>View test report in file://${reports.junit}/index.html</echo> +- <fail if="testfailure" unless="clover">One or more tests failed</fail> ++ <fail if="testfailure">One or more tests failed</fail> + </target> + + <target name="contrib-test" depends="contrib-jars,compile-tests"> +@@ -640,27 +638,6 @@ + </subant> + </target> + +- <target name="with.clover" description="Enable code coverage for tests"> +- <taskdef resource="cloverlib.xml" classpath="lib/clover.jar"/> +- <property name="clover" value="true"/> +- <property name="build" value="build.clover"/> +- <clover-setup/> +- </target> +- +- <target name="clover" depends="with.clover,test" +- description="Generate test code coverage reports"> +- <property name="reports.clover" value="${reports}/clover"/> +- <mkdir dir="${reports.clover}"/> +- <clover-report> +- <current outfile="${reports.clover}" title="clover"> +- <fileset dir="." includes="**/*.java" /> +- <testresults dir="${results.junit}" includes="TEST-*.xml"/> +- <format type="html"/> +- </current> +- </clover-report> +- <echo>Reports generated in ${reports.clover}</echo> +- </target> +- + <target name="javadoc" depends="-setup"> + <path id="javadoc.src.path"> + <path refid="src.path"/> +@@ -881,7 +858,7 @@ + <!-- Full sources required to build and test everything --> + <zip zipfile="${dist}/src-full.zip"> + <zipfileset src="${dist}/src.zip"/> +- <zipfileset dir="lib" includes="junit.jar,clover.jar" prefix="lib"/> ++ <zipfileset dir="lib" includes="junit.jar" prefix="lib"/> + <zipfileset dir="." includes=".classpath,.project"/> + <zipfileset dir="${native}" includes="libffi,libffi/**/*" prefix="native"/> + </zip> diff --git a/java/jna/webstart-test.keystore b/java/jna/webstart-test.keystore Binary files differnew file mode 100644 index 000000000..1bbe8c829 --- /dev/null +++ b/java/jna/webstart-test.keystore diff --git a/java/not-working/closure-compiler/PKGBUILD b/java/not-working/closure-compiler/PKGBUILD new file mode 100644 index 000000000..8318379a2 --- /dev/null +++ b/java/not-working/closure-compiler/PKGBUILD @@ -0,0 +1,73 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgname=closure-compiler +pkgver=20120917 +_pkgrev=2180 +pkgdesc="A JavaScript optimizing compiler." +url="https://code.google.com/closure/compiler/" +license=('Apache') + +pkgrel=1 +arch=('any') +depends=('java-runtime') +makedepends=( + 'apache-ant' + 'java-args4j' # does not exist + 'google-caja' # does not exist + 'java-guava' # does not build + 'java-jarjar' + 'java-json' # does not exist + 'java-jsr305' # does not exist + 'junit' + 'java-protobuf' # does not build + # maven-ant-tasks + 'jh') +source=("compiler-$pkgver::svn+http://closure-compiler.googlecode.com/svn/trunk/#revision=$_pkgrev") + +# For some reason, `file` detects this as a Fortran binary +_funny_js=( + lib/rhino/testsrc/benchmarks/sunspider-0.9.1/bitops-3bit-bits-in-byte.js +) + +mksource() { + cd "$srcdir/compiler-$pkgver" + rm lib/ant.jar + rm lib/ant-launcher.jar + rm lib/args4j.jar + rm lib/caja-r4314.jar + rm lib/guava.jar + rm lib/jarjar.jar + rm lib/json.jar + rm lib/jsr305.jar + rm lib/junit.jar + rm lib/protobuf-java.jar + rm lib/rhino/testsrc/org/mozilla/javascript/tests/commonjs/module/modules.jar + rm tools/maven-ant-tasks-2.1.3.jar +} + +build() { + cd "$srcdir/compiler-$pkgver" + eval `jh mksource ${_funny_js[@]}` + + ln -s /opt/apache-ant/lib/ant.jar lib/ant.jar + ln -s /opt/apache-ant/lib/ant-launcher.jar lib/ant-launcher.jar + ln -s /usr/share/java/... lib/args4j.jar + ln -s /usr/share/java/... lib/caja-r4314.jar + ln -s /usr/share/java/... lib/guava.jar + ln -s /usr/share/java/jarjar.jar lib/jarjar.jar + ln -s /usr/share/java/... lib/json.jar + ln -s /usr/share/java/... lib/jsr305.jar + ln -s /usr/share/java/junit.jar lib/junit.jar + ln -s /usr/share/java/protobuf.jar lib/protobuf-java.jar + # I think lib/rhino/.../module.jar autogenerates + ln -s /... tools/maven-ant-tasks-2.1.3.jar + + ant jar +} + +package() { + cd "$srcdir/$pkgname" + : +} + +md5sums=('SKIP') diff --git a/java/not-working/closure-compiler/TODO b/java/not-working/closure-compiler/TODO new file mode 100644 index 000000000..8527a4898 --- /dev/null +++ b/java/not-working/closure-compiler/TODO @@ -0,0 +1,2 @@ +* Has plenty of missing dependencies (most of the 'not-working' folder) +* package() has not been written diff --git a/java/not-working/java-asm4/PKGBUILD b/java/not-working/java-asm4/PKGBUILD new file mode 100644 index 000000000..3db06dddc --- /dev/null +++ b/java/not-working/java-asm4/PKGBUILD @@ -0,0 +1,17 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgver=4.1 +. ../java-asm2/common.sh +depends+=('java-bnd') + +#### + +pkgrel=5 +_checksource_ignore=(src/org/objectweb/asm/optimizer/jdk{1.2.2_017,1.3.1_19}.txt.gz) + +mksource() { + cd "$srcdir/$_pkgname-$pkgver" + rm examples/jasmin/test/jasmin.jar +} + +md5sums=('cbfd7445edc517e0867ad410e48cb106') diff --git a/java/not-working/java-asm4/TODO b/java/not-working/java-asm4/TODO new file mode 100644 index 000000000..563c88bc9 --- /dev/null +++ b/java/not-working/java-asm4/TODO @@ -0,0 +1 @@ +Depends on java-bnd, which is not packaged
\ No newline at end of file diff --git a/java/not-working/java-guava/PKGBUILD b/java/not-working/java-guava/PKGBUILD new file mode 100644 index 000000000..0250e7183 --- /dev/null +++ b/java/not-working/java-guava/PKGBUILD @@ -0,0 +1,34 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +_pkgname=guava +pkgname=java-guava +pkgver=13.0.1 +pkgdesc="Google Core Libraries for Java." +url="https://code.google.com/p/guava-libraries/" +license=('Apache2') + +pkgrel=1 +arch=('any') +depends=('java-runtime>=5') +makedepends=('java-runtime>=6' 'maven' 'junit-truth' 'jh') +conflicts=('openjdk6') # OpenJDK bug 100167 conflicts +source=("$pkgname::git+https://code.google.com/p/guava-libraries/#tag=v$pkgver") + +mksource() { + cd "$srcdir/$pkgname" + rm guava/lib/*.jar + rm guava-test/lib/*.jar +} + +build() { + cd "$srcdir/$pkgname" + eval `jh mksource` + + ln -s /usr/share/java/junit-truth.jar guava-tests/lib/libtruth.java + + mvn package +} + +package() { + : +} diff --git a/java/not-working/java-guava/TODO b/java/not-working/java-guava/TODO new file mode 100644 index 000000000..ee0a18042 --- /dev/null +++ b/java/not-working/java-guava/TODO @@ -0,0 +1,2 @@ +* depends on junit-truth, which does not build yet +* package() hasn't been written diff --git a/java/not-working/junit-truth/PKGBUILD b/java/not-working/junit-truth/PKGBUILD new file mode 100644 index 000000000..61a0ee469 --- /dev/null +++ b/java/not-working/junit-truth/PKGBUILD @@ -0,0 +1,45 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> + +pkgname=junit-truth +pkgdesc="Assertion/Proposition framework for Java unit tests." +url="https://github.com/truth0/truth" +license=('Apache2') + +#_pkgver=0.5.0-beta1 +#pkgver=${_pkgver//-/.} +#_tag=v${_pkgver} + +#pkgver=0.7.0 +#_tag=truth-rel-${pkgver//./-} + +#pkgver=0.8 +#_tag=truth-${pkgver} + +#pkgver=0.9 +#_tag=release_${pkgver//./_} + +pkgver=0.10 +_tag=release_${pkgver//./_} + +pkgrel=1 +arch=('any') +depends=('junit') +makedepends=('maven' 'jh') +conflicts=('openjdk6') # OpenJDK bug 100167 conflicts +source=("$pkgname::git://github.com/truth0/truth.git#tag=$tag") + +build() { + cd "${srcdir}/${pkgname}" + jh checksource + mvn package +} + +package() { + cd "${srcdir}/${pkgname}" + install -d "${pkgdir}"/usr/share/java/${pkgname} + JAR=${pkgname}-${pkgver}.jar + install -Dm 644 target/${JAR} "${pkgdir}"/usr/share/java/${pkgname} + ln -s ${pkgname}/${JAR} "${pkgdir}"/usr/share/java/${pkgname}.jar +} + +md5sums=('SKIP') diff --git a/java/not-working/junit-truth/TODO b/java/not-working/junit-truth/TODO new file mode 100644 index 000000000..d21b3e472 --- /dev/null +++ b/java/not-working/junit-truth/TODO @@ -0,0 +1 @@ +has unpackaged dependencies diff --git a/java/not-working/protobuf/PKGBUILD b/java/not-working/protobuf/PKGBUILD new file mode 100644 index 000000000..699bde0cf --- /dev/null +++ b/java/not-working/protobuf/PKGBUILD @@ -0,0 +1,99 @@ +# Maintainer: Thomas S Hatch <thatch45@gmail.com> +# Contributor: Geoffroy Carrier <geoffroy@archlinux.org> +# Contributor: Daniel J Griffiths <ghost1227@archlinux.us> + +pkgbase=protobuf +pkgname=('protobuf' 'python2-protobuf' 'java-protobuf') +pkgver=2.4.1 +pkgrel=2.1 +pkgdesc="A way of encoding structured data in an efficient yet extensible format" +arch=('i686' 'x86_64') +url="http://code.google.com/p/protobuf/" +license=('APACHE') +depends=('gcc-libs' 'zlib') +makedepends=('python2' 'python2-distribute' 'java-environment') +options=(!libtool) +source=(http://$pkgname.googlecode.com/files/$pkgname-$pkgver.tar.bz2) +md5sums=('ed436802019c9e1f40cc750eaf78f318') + +#### + +build() { + build_protobuf + build_python2-protobuf + build_java-protobuf +} + +check() { + check_protobuf + check_python2-protobuf + check_java-protobuf +} + +package() { + package_protobuf + package_python2-protobuf + package_java-protobuf +} + +#### + +build_protobuf() { + cd $srcdir/$pkgname-$pkgver + ./configure --prefix=/usr --disable-static + make +} + +check_protobuf() { + cd $srcdir/$pkgname-$pkgver + make check +} + +package_protobuf() { + cd $srcdir/$pkgname-$pkgver + make DESTDIR=$pkgdir install +} + +#### + +build_python2-protobuf() { + cd $srcdir/$pkgname-$pkgver/python + python2 setup.py build +} + +check_python2-protobuf() { + cd $srcdir/$pkgname-$pkgver/python + python2 setup.py test +} + +package_python2-protobuf() { + pkgdesc="protobuf python2 API" + replaces=('protobuf-python') + provides=("protobuf-python=${pkgver}") + depends=("python2" "protobuf=${pkgver}") + + cd $srcdir/protobuf-$pkgver/python + python2 setup.py install --prefix=/usr --root $pkgdir +} + +#### + +build_java-protobuf() { + cd $srcdir/$pkgname-$pkgver/java + mvn compile +} + +check_java-protobuf() { + cd $srcdir/$pkgname-$pkgver/java + mvn test +} + +package_java-protobuf() { + pkgdesc="protobuf Java API" + replaces=('protobuf-java') + provides=("protobuf-java=${pkgver}") + depends=("java-runtime" "protobuf=${pkgver}") + + cd $srcdir/$pkgname-$pkgver/java + : +} diff --git a/java/not-working/protobuf/TODO b/java/not-working/protobuf/TODO new file mode 100644 index 000000000..6a126b757 --- /dev/null +++ b/java/not-working/protobuf/TODO @@ -0,0 +1,5 @@ +* Missing dependencies: + * junit:junit:4.4 (4.10 is packaged, patch to use 4.10?) + * org.easymock:easymock:2.2 + * org.easymock:easymockclassextension:2.2.1 +* package_java-protobuf() has not been written diff --git a/libre/java-asm3/PKGBUILD b/libre/java-asm3/PKGBUILD deleted file mode 100755 index 7e66a5b5a..000000000 --- a/libre/java-asm3/PKGBUILD +++ /dev/null @@ -1,78 +0,0 @@ -# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> - -_pkgname=asm -pkgname=java-asm3 -_pkgver=3 -pkgver=3.3.1 -pkgrel=4.1 -pkgdesc="An all purpose Java bytecode manipulation and analysis framework." -arch=('any') -url="http://asm.ow2.org/" -license=('custom:BSD3') -depends=('java-runtime') -makedepends=( - apache-ant - java-ow-util-ant-tasks -) -source=("http://download.forge.objectweb.org/$_pkgname/$_pkgname-$pkgver.tar.gz") - -_M2_LOCALREPO='/usr/share/maven/repository' -_ow_util_ant_tasks='/usr/share/java/ow_util_ant_tasks.jar' -_m2_packages=( - asm - asm-analysis - asm-commons - asm-parent - asm-tree - asm-util - asm-xml - asm-all - asm-debug-all) - -build() { - cd "$srcdir/$_pkgname-$pkgver" - - rm cobertura.ser # We regenerate this - rm examples/jasmin/test/jasmin.jar - - echo "objectweb.ant.tasks.path $_ow_util_ant_tasks" >> build.properties - ant dist - - # This will make package() easier: - cd output/dist/lib - ln -s all/* . -} - -package() { - cd "$srcdir/$_pkgname-$pkgver" - - # Install license file - install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE" - - # Install documentation - cd output/dist - install -d "$pkgdir/usr/share/doc/$pkgname" - cp -r doc/javadoc/user "$pkgdir/usr/share/doc/$pkgname/javadoc" - cp -r examples "$pkgdir/usr/share/doc/$pkgname/examples" - - # Install Apache Maven modules - cd lib - install -d "$pkgdir"/usr/share/java/asm - for pkg in "${_m2_packages[@]}"; do - dir="$_M2_LOCALREPO"/asm/$pkg/$pkgver - # Create the Maven directory - install -d "$pkgdir$dir" - # Install the files - cp $pkg-$pkgver.* "$pkgdir$dir" - # Symlink them to /usr/share/java - ln -s "$dir"/$pkg-$pkgver.jar "$pkgdir"/usr/share/java/asm/ - ln -s asm/$pkg-$pkgver.jar "$pkgdir"/usr/share/java/$pkg-$_pkgver.jar - done - - # Install a README file about the -all files - cd "$srcdir/$_pkgname-$pkgver" - install -m644 output/dist/lib/all/README.txt \ - "$pkgdir"/usr/share/java/asm/README-$pkgver.txt -} - -md5sums=('433024df8176f09922646316e415631c') |