Procházet zdrojové kódy

- unzip android bullet natives on copy

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8812 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
nor..67 před 14 roky
rodič
revize
d4f799d8b2

+ 11 - 2
sdk/jme3-android/src/com/jme3/gde/android/mobile-targets.xml

@@ -24,6 +24,7 @@
     
     <target name="-copy-android-libs" if="is.android.enabled">
         <!--property name="libs.jme3-android" location="${libs.jme3-android.classpath}"/-->
+        <echo>Copying application libraries to android project.</echo>
         <delete dir="mobile/libs" failonerror="false"/>
         <mkdir dir="mobile/libs"/>
         <copy todir="mobile/libs" verbose="false" flatten="true">
@@ -41,13 +42,14 @@
             </fileset>
         </copy>
 
+        <echo>Adding jMonkeyEngine3.jar for android.</echo>
         <copy todir="mobile/libs" flatten="true">
-            <mapper type="flatten" from="*jMonkeyEngine-android.jar" to="jMonkeyEngine.jar"/>
+            <!--mapper type="flatten" from="*jMonkeyEngine-android.jar" to="jMonkeyEngine.jar"/-->
             <path>
                 <pathelement path="${libs.jme3-android.classpath}"/>
             </path>
         </copy>
-        <antcall target="-delete-bullet-libs"/>
+        <antcall target="-unzip-bullet-libs"/>
         <copy file="${dist.jar}" todir="mobile/libs/" verbose="false"/>
     </target>
     
@@ -56,6 +58,13 @@
         <delete file="mobile/libs/jME3-bullet-natives-android.jar"/>
     </target>
     
+    <target name="-unzip-bullet-libs" depends="-delete-bullet-libs" if="bulletIsIncluded">
+        <echo>Replacing bullet library with android native version.</echo>
+        <unzip src="mobile/libs/jME3-bullet-natives-android.jar" dest="mobile/libs"/>
+        <delete file="mobile/libs/jME3-bullet-natives-android.jar"/>
+        <delete dir="mobile/libs/x86"/>
+    </target>
+    
     <target name="-test-bullet-included">
         <condition property="bulletIsIncluded">
             <contains string="${javac.classpath}" substring="bullet.jar"/>