diff --git a/build.xml b/build.xml
index 77d91cf98a4f539c7f5a1eb3b25df59818051c64..abfbc1a3ff75539c4506945857fc47276c600664 100644
--- a/build.xml
+++ b/build.xml
@@ -55,8 +55,7 @@
</subant>
</target>
- <target name="test" depends="clean">
- <ant dir="com.amd.aparapi" target="build"/>
+ <target name="test" depends="build">
<subant target="junit">
<fileset dir="test" includes="*/build.xml"/>
</subant>
diff --git a/test/runtime/build.xml b/test/runtime/build.xml
index b52d42acbf253653eaf5eb582488138bc477612c..f80e0ffcc650d7d8cf75a019e5b803cee95bfe8e 100644
--- a/test/runtime/build.xml
+++ b/test/runtime/build.xml
@@ -64,7 +64,7 @@
<!-- even though fork is slower we need to set the library path and this requires fork -->
<junit printsummary="false" fork="true" haltonfailure="false" failureproperty="tests.failed" showoutput="false">
- <sysproperty key="java.library.path" value="..\..\com.amd.aparapi.jni\dist"/>
+ <sysproperty key="java.library.path" value="${basedir}/../../com.amd.aparapi.jni/dist"/>
<formatter type="xml" />
<classpath refid="classpath"/>
<batchtest todir="junit/data">