#!/bin/bash ####FIXME: change those patches according your situation # ponints to java location export JAVA_HOME=${PWD}/ibm-java-x86_64-60/ # points to unpacked jna-testcase.tar.bz2 export JNA_DIR=${PWD}/jna export JNA_PATH=${JNA_DIR}/build-d64/native/ export JNA_BUILDDIR=${JNA_DIR}/build-d64/ cd jna/ #/usr/share/java/ant-launcher.jar:/usr/share/java/ant.jar:/usr/share/java/ant/ant-junit.jar' # either installed packages, either copy jars directly ln -sf $(build-classpath junit) lib/test/junit.jar ln -sf $(build-classpath ant) lib/test/ant.jar ln -sf /usr/share/java/ant/ant-junit.jar lib/test/ant-junit.jar #ant -v -d \ # -Dcflags_extra.native="$(rpm -E %{optflags})" \ # -Ddynlink.native=true \ # -Dnomixedjar.native=true \ # -Dld.preload.name="LD_PRELOAD" \ # test export LD_PRELOAD=${JAVA_HOME}/jre/lib/amd64/libjsig.so ${JAVA_HOME}/jre/bin/java \ -d64 \ -Djava.awt.headless=true \ -Djna.library.path="${JNA_PATH}" \ -Djna.nosys=true \ -Djna.protected=true \ -Djna.builddir="${JNA_BUILDDIR}" \ -Dld.preload.name=LD_PRELOAD \ -classpath \ "${JNA_BUILDDIR}/jna.jar:${JNA_BUILDDIR}/test-classes:${JNA_BUILDDIR}/jna-test.jar:${JNA_DIR}/lib/clover.jar/${JNA_DIR}/lib/test/guava-11.0.2.jar:${JNA_DIR}/lib/test/javassist-3.12.1.GA.jar:${JNA_DIR}/lib/test/junit.jar:${JNA_DIR}/lib/test/reflections-0.9.8.jar:${JNA_BUILDDIR}/classes:${JNA_DIR}/lib/test/junit.jar:${JNA_DIR}/lib/test/ant-junit.jar:${JNA_DIR}/lib/test/ant.jar" \ org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner \ com.sun.jna.VMCrashProtectionTest \ filtertrace=false \ haltOnError=true \ haltOnFailure=true \ showoutput=true \ outputtoformatters=true \ logfailedtests=true \ logtestlistenerevents=false \ formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter # crashfile=${JNA_BUILDDIR}/junitvmwatcher.properties #propsfile=${JNA_BUILDDIR}/junit.properties #formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${JNA_BUILDDIR}/junit-results/TEST-com.sun.jna.VMCrashProtectionTest.xml \