|
|
@ -165,8 +165,6 @@ |
|
|
|
<mkdir dir="${bullet.output.dir}"/> |
|
|
|
<mkdir dir="${bullet.output.dir}"/> |
|
|
|
<mkdir dir="build/bullet-native"/> |
|
|
|
<mkdir dir="build/bullet-native"/> |
|
|
|
<mkdir dir="build/bullet-native-64"/> |
|
|
|
<mkdir dir="build/bullet-native-64"/> |
|
|
|
<mkdir dir="build/bullet-native-mingw"/> |
|
|
|
|
|
|
|
<mkdir dir="build/bullet-native-mingw-64"/> |
|
|
|
|
|
|
|
</target> |
|
|
|
</target> |
|
|
|
|
|
|
|
|
|
|
|
<target name="-nativelib-osx" if="isMac"> |
|
|
|
<target name="-nativelib-osx" if="isMac"> |
|
|
@ -239,17 +237,22 @@ |
|
|
|
</target> |
|
|
|
</target> |
|
|
|
|
|
|
|
|
|
|
|
<target name="-nativelib-linux-mingw-64" if="isLinux64"> |
|
|
|
<target name="-nativelib-linux-mingw-64" if="isLinux64"> |
|
|
|
<echo message="Building 64 bit Linux version of native bullet"/> |
|
|
|
<echo message="Building 64 bit Windows version of native bullet"/> |
|
|
|
|
|
|
|
<!--mkdir dir="build/bullet-native-mingw"/--> |
|
|
|
|
|
|
|
<mkdir dir="build/bullet-native-mingw-64"/> |
|
|
|
<mkdir dir="${bullet.output.dir}/windows"/> |
|
|
|
<mkdir dir="${bullet.output.dir}/windows"/> |
|
|
|
<cc libtool="i686-w64-mingw32" name="${bullet.linux.compiler}" warnings="severe" debug="${bullet.compile.debug}" link="shared" outfile="${bullet.output.dir}/windows/${bullet.library.name}64" objdir="build/bullet-native-mingw-64"> |
|
|
|
<cc compilertarget="${cross.compile.target64}" name="${bullet.linux.crosscompiler}" warnings="severe" debug="${bullet.compile.debug}" outfile="${bullet.output.dir}/windows/${bullet.library.name}64.dll" objdir="build/bullet-native-mingw-64"> |
|
|
|
<fileset dir="${bullet.source.dir}"> |
|
|
|
<fileset dir="${bullet.source.dir}"> |
|
|
|
<include name="*.cpp"> |
|
|
|
<include name="*.cpp"> |
|
|
|
</include> |
|
|
|
</include> |
|
|
|
</fileset> |
|
|
|
</fileset> |
|
|
|
|
|
|
|
<sysincludepath path="/usr/${cross.compile.target64}/include"/> |
|
|
|
<includepath path="${bullet.java.include}"/> |
|
|
|
<includepath path="${bullet.java.include}"/> |
|
|
|
<includepath path="${bullet.java.include}/win32"/> |
|
|
|
<includepath path="${bullet.java.include}/win32"/> |
|
|
|
<includepath path="${bullet.bullet.include}"/> |
|
|
|
<includepath path="${bullet.bullet.include}"/> |
|
|
|
<linker name="${bullet.linux.compiler}" libtool="i686-w64-mingw32"> |
|
|
|
<compilerarg value="-m32"/> |
|
|
|
|
|
|
|
<linker name="${bullet.linux.crosscompiler}"> |
|
|
|
|
|
|
|
<linkerarg value="-mdll"/> |
|
|
|
<libset dir="build/bullet-base-mingw-64" libs="BulletMultiThreaded,BulletDynamics,BulletCollision,LinearMath"/> |
|
|
|
<libset dir="build/bullet-base-mingw-64" libs="BulletMultiThreaded,BulletDynamics,BulletCollision,LinearMath"/> |
|
|
|
</linker> |
|
|
|
</linker> |
|
|
|
</cc> |
|
|
|
</cc> |
|
|
@ -369,10 +372,10 @@ |
|
|
|
|
|
|
|
|
|
|
|
<target name="-check-bullet-sources"> |
|
|
|
<target name="-check-bullet-sources"> |
|
|
|
<available file="${bullet.folder}" property="haveBulletSource"/> |
|
|
|
<available file="${bullet.folder}" property="haveBulletSource"/> |
|
|
|
<available file="build/bullet-base/libBulletMultiThreaded.a" property="haveBulletLibrary"/> |
|
|
|
<available file="build/bullet-base/libLinearMath.a" property="haveBulletLibrary"/> |
|
|
|
<available file="build/bullet-base-64/libBulletMultiThreaded.a" property="haveBulletLibrary64"/> |
|
|
|
<available file="build/bullet-base-64/libLinearMath.a" property="haveBulletLibrary64"/> |
|
|
|
<available file="build/bullet-base-mingw/libBulletMultiThreaded.a" property="haveBulletLibraryMingw"/> |
|
|
|
<available file="build/bullet-base-mingw/libLinearMath.a" property="haveBulletLibraryMingw"/> |
|
|
|
<available file="build/bullet-base-mingw-64/libBulletMultiThreaded.a" property="haveBulletLibraryMingw64"/> |
|
|
|
<available file="build/bullet-base-mingw-64/libLinearMath.a" property="haveBulletLibraryMingw64"/> |
|
|
|
</target> |
|
|
|
</target> |
|
|
|
|
|
|
|
|
|
|
|
<target name="-compile-bullet-sources-windows" if="isWindows"> |
|
|
|
<target name="-compile-bullet-sources-windows" if="isWindows"> |
|
|
@ -439,7 +442,45 @@ |
|
|
|
<exec executable="${make.linux}" dir="${bullet.folder}"/> |
|
|
|
<exec executable="${make.linux}" dir="${bullet.folder}"/> |
|
|
|
</target> |
|
|
|
</target> |
|
|
|
|
|
|
|
|
|
|
|
<target name="-compile-bullet-sources-linux-mingw-64" if="isLinux64" unless="haveBulletLibraryMingw64"> |
|
|
|
<target name="-compile-bullet-sources-linux-mingw-64" depends="-fix-bullet-sources" if="isLinux64" unless="haveBulletLibraryMingw64"> |
|
|
|
|
|
|
|
<exec executable="${make.linux}" dir="${bullet.folder}"> |
|
|
|
|
|
|
|
<arg value="clean"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${cmake.linux}" dir="${bullet.folder}" failonerror="true"> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_SYSTEM_NAME=Windows"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_C_COMPILER=${cross.compile.target64}-gcc"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_CXX_COMPILER=${cross.compile.target64}-g++"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_RC_COMPILER=${cross.compile.target64}-windres"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH=/usr/${cross.compile.target64}"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<mkdir dir="build/bullet-base-mingw-64"/> |
|
|
|
|
|
|
|
<property location="build/bullet-base-mingw-64" name="build-mingw64.folder.resolved"/> |
|
|
|
|
|
|
|
<exec executable="${cmake.linux}" dir="${bullet.folder}" failonerror="true"> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_BUILD_TYPE=Release"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_SHARED_LIBS=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_EXTRAS=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_DEMOS=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DLIBRARY_OUTPUT_PATH='${build-mingw64.folder.resolved}'"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${make.linux}" dir="${bullet.folder}"/> |
|
|
|
|
|
|
|
<exec executable="${cross.compile.target64}-ranlib"> |
|
|
|
|
|
|
|
<arg value="${basedir}/build/bullet-base-mingw-64/libBulletMultiThreaded.a"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${cross.compile.target64}-ranlib"> |
|
|
|
|
|
|
|
<arg value="${basedir}/build/bullet-base-mingw-64/libBulletDynamics.a"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${cross.compile.target64}-ranlib"> |
|
|
|
|
|
|
|
<arg value="${basedir}/build/bullet-base-mingw-64/libBulletCollision.a"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${cross.compile.target64}-ranlib"> |
|
|
|
|
|
|
|
<arg value="${basedir}/build/bullet-base-mingw-64/libLinearMath.a"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
</target> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<target name="-fix-bullet-sources"> |
|
|
|
<replace file="${bullet.folder}/CMakeLists.txt" token="#TODO add better GLUT detection for MinGW" |
|
|
|
<replace file="${bullet.folder}/CMakeLists.txt" token="#TODO add better GLUT detection for MinGW" |
|
|
|
value="INCLUDE_DIRECTORIES($${BULLET_PHYSICS_SOURCE_DIR}/Glut)${line.separator} |
|
|
|
value="INCLUDE_DIRECTORIES($${BULLET_PHYSICS_SOURCE_DIR}/Glut)${line.separator} |
|
|
|
SET(GLUT_INCLUDE_DIR ${BULLET_PHYSICS_SOURCE_DIR}/Glut)${line.separator} |
|
|
|
SET(GLUT_INCLUDE_DIR ${BULLET_PHYSICS_SOURCE_DIR}/Glut)${line.separator} |
|
|
@ -450,25 +491,5 @@ |
|
|
|
message('Win64 using Glut/glut64.lib')${line.separator} |
|
|
|
message('Win64 using Glut/glut64.lib')${line.separator} |
|
|
|
SET(GLUT_glut_LIBRARY $${BULLET_PHYSICS_SOURCE_DIR}/Glut/glut64.lib)${line.separator} |
|
|
|
SET(GLUT_glut_LIBRARY $${BULLET_PHYSICS_SOURCE_DIR}/Glut/glut64.lib)${line.separator} |
|
|
|
ENDIF (WIN32)${line.separator}"/> |
|
|
|
ENDIF (WIN32)${line.separator}"/> |
|
|
|
<property name="cross.compile.target" value="i686-w64-mingw32"/> |
|
|
|
|
|
|
|
<mkdir dir="build/bullet-base-mingw-64"/> |
|
|
|
|
|
|
|
<property location="build/bullet-base-mingw-64" name="build-mingw64.folder.resolved"/> |
|
|
|
|
|
|
|
<exec executable="${cmake.linux}" dir="${bullet.folder}" failonerror="true"> |
|
|
|
|
|
|
|
<arg value="-DLIBRARY_OUTPUT_PATH='${build-mingw64.folder.resolved}'"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_SHARED_LIBS=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_EXTRAS:BOOL=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DBUILD_DEMOS:BOOL=OFF"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_BUILD_TYPE=Release"/> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<arg value="-DCMAKE_SYSTEM_NAME=Windows"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_C_COMPILER=${cross.compile.target}-gcc"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_CXX_COMPILER=${cross.compile.target}-g++"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_RC_COMPILER=${cross.compile.target}-windres"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH=/usr/${cross.compile.target}"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY"/> |
|
|
|
|
|
|
|
<arg value="-DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY"/> |
|
|
|
|
|
|
|
</exec> |
|
|
|
|
|
|
|
<exec executable="${make.linux}" dir="${bullet.folder}"/> |
|
|
|
|
|
|
|
</target> |
|
|
|
</target> |
|
|
|
</project> |
|
|
|
</project> |
|
|
|