aboutsummaryrefslogtreecommitdiffstats
path: root/make/build.xml
diff options
context:
space:
mode:
Diffstat (limited to 'make/build.xml')
-rwxr-xr-xmake/build.xml90
1 files changed, 70 insertions, 20 deletions
diff --git a/make/build.xml b/make/build.xml
index 40e72c0..cc0b842 100755
--- a/make/build.xml
+++ b/make/build.xml
@@ -44,13 +44,7 @@
<property name="gluegen.build" value="${gluegen.root}/${rootrel.build}" />
<!-- This is the version of JOAL you are building -->
- <property name="joal_base_version" value="2.0"/>
- <property name="joal_int_version" value="2"/>
- <tstamp>
- <format property="version.timestamp" pattern="yyyyMMdd"/>
- </tstamp>
<property name="joal.build.number" value="manual-build"/>
- <property name="joal.build.id" value="${version.timestamp}"/>
<mkdir dir="${build}" />
<exec dir="." executable="git" logError="true" failonerror="false" failifexecutionfails="false"
output="${build}/localbranch.raw">
@@ -66,8 +60,6 @@
<arg line="rev-parse HEAD"/>
</exec>
<property name="joal.build.commit" value="manual"/> <!-- fallback -->
- <property name="joal.version" value="${joal_base_version}-${version.timestamp}" />
- <property name="joal.version.plus" value="${joal_base_version}-${joal.build.branch}-b${joal.build.number}-${joal.build.commit}-${version.timestamp}" />
<!-- Pull in GlueGen cpptasks build file -->
<import file="${gluegen.root}/make/gluegen-cpptasks.xml" />
@@ -94,6 +86,9 @@
-->
<target name="init" depends="jogamp.env.init, gluegen.cpptasks.detect.os">
+ <property name="joal.build.id" value="${version.timestamp}"/>
+ <property name="joal.version" value="${jogamp.version.base}-${version.timestamp}" />
+
<!-- The location and name of the configuration ANT file that will
- validate to ensure that all user-define variables are set. -->
<property name="validate.user.properties" value="${make}/validate-properties.xml" />
@@ -192,6 +187,23 @@
<property name="archive.name" value="joal-${joal.version}-${os.and.arch}" />
<property name="archive" value="${build}/${archive.name}" />
+
+ <condition property="useLinuxARMv6SFOptions">
+ <and>
+ <isset property="isLinuxARMv6"/>
+ <isset property="isAbiEabiGnuArmel"/>
+ <isset property="isCrosscompilation"/>
+ </and>
+ </condition>
+ <condition property="useLinuxARMv6HFOptions">
+ <and>
+ <isset property="isLinuxARMv6"/>
+ <isset property="isAbiEabiGnuArmhf"/>
+ <isset property="isCrosscompilation"/>
+ </and>
+ </condition>
+ <echo message="useLinuxARMv6SFOptions ${useLinuxARMv6SFOptions}" />
+ <echo message="useLinuxARMv6HFOptions ${useLinuxARMv6HFOptions}" />
</target>
<!-- ================================================================== -->
@@ -436,6 +448,10 @@
output.lib.name="joal"
linker.cfg.id="${linker.cfg.id.base}"/>
+ <antcall target="gluegen.cpptasks.striplibs" inheritRefs="true">
+ <param name="libdir" value="../${rootrel.build}/obj"/>
+ </antcall>
+
<!-- Create Java Web Start jar file from built file -->
<jar destfile="${build}/joal-natives-${os.and.arch}.jar">
<fileset dir="../${rootrel.build}/obj">
@@ -447,7 +463,7 @@
</jar>
</target>
- <target name="c.build.openal.soft.android" if="isAndroid">
+ <target name="c.build.openal.soft.android" if="isAndroid" unless="c.build.openal.soft.done">
<property name="c.build.openal.soft.done" value="true" />
<mkdir dir="${build}/openal-soft" />
<exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
@@ -461,7 +477,7 @@
<exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
</target>
- <target name="c.build.openal.soft.windows" if="isWindows">
+ <target name="c.build.openal.soft.windows" if="isWindows" unless="c.build.openal.soft.done">
<property name="c.build.openal.soft.done" value="true" />
<mkdir dir="${build}/openal-soft" />
<exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
@@ -472,7 +488,7 @@
<exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
</target>
- <target name="c.download.openal.soft.windows" if="isWindows">
+ <target name="c.download.openal.soft.windows">
<property name="c.build.openal.soft.done" value="true" />
<!-- downloads the binaries of OpenAL-Soft for Windows as they aren't bundled with JOAL yet -->
<get src="http://kcat.strangesoft.net/openal-soft-1.15.1-bin.zip" dest="." verbose="true" usetimestamp="true" />
@@ -494,10 +510,42 @@
<delete dir="openal-soft-1.15.1-bin" />
</target>
- <target name="c.build.openal.soft.default" unless="c.build.openal.soft.done">
+ <target name="c.build.openal.soft.gcc.x86_32" if="isI386" unless="c.build.openal.soft.done">
+ <property name="c.build.openal.soft.done" value="true" />
+ <mkdir dir="${build}/openal-soft" />
+ <exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
+ <arg value="../../openal-soft"/>
+ <arg value="-DCMAKE_TOOLCHAIN_FILE=../../openal-soft/cmake/toolchain.gcc-x86_32.cmake"/>
+ </exec>
+ <exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
+ </target>
+
+ <target name="c.build.openal.soft.gcc.armv6.soft" if="useLinuxARMv6SFOptions" unless="c.build.openal.soft.done">
+ <property name="c.build.openal.soft.done" value="true" />
+ <mkdir dir="${build}/openal-soft" />
+ <exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
+ <arg value="../../openal-soft"/>
+ <arg value="-DCMAKE_TOOLCHAIN_FILE=../../openal-soft/cmake/toolchain.gcc-armv6.cmake"/>
+ </exec>
+ <exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
+ </target>
+
+ <target name="c.build.openal.soft.gcc.armv6.hard" if="useLinuxARMv6HFOptions" unless="c.build.openal.soft.done">
+ <property name="c.build.openal.soft.done" value="true" />
+ <mkdir dir="${build}/openal-soft" />
+ <exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
+ <arg value="../../openal-soft"/>
+ <arg value="-DCMAKE_TOOLCHAIN_FILE=../../openal-soft/cmake/toolchain.gcc-armv6hf.cmake"/>
+ </exec>
+ <exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
+ </target>
+
+ <target name="c.build.openal.soft.gcc.default" unless="c.build.openal.soft.done">
+ <property name="c.build.openal.soft.done" value="true" />
<mkdir dir="${build}/openal-soft" />
<exec dir="${build}/openal-soft" executable="cmake" logError="true" failonerror="false" failifexecutionfails="false">
<arg value="../../openal-soft"/>
+ <arg value="-DCMAKE_TOOLCHAIN_FILE=../../openal-soft/cmake/toolchain.gcc-default.cmake"/>
</exec>
<exec dir="${build}/openal-soft" executable="make" logError="true" failonerror="false" failifexecutionfails="false" />
</target>
@@ -513,7 +561,7 @@
</target>
<target name="c.build.openal.soft"
- depends="init, gluegen.cpptasks.detect.os, gluegen.cpptasks.setup.compiler, c.build.openal.use-blobs, c.build.openal.soft.windows, c.build.openal.soft.android, c.build.openal.soft.default">
+ depends="init, gluegen.cpptasks.detect.os, gluegen.cpptasks.setup.compiler, c.build.openal.use-blobs, c.build.openal.soft.windows, c.build.openal.soft.android, c.build.openal.soft.gcc.x86_32, c.build.openal.soft.gcc.armv6.soft, c.build.openal.soft.gcc.armv6.hard, c.build.openal.soft.gcc.default">
<copy todir="../${rootrel.build}/obj" failonerror="false">
<fileset dir="${build}/openal-soft" erroronmissingdir="false">
<include name="*openal.${native.library.suffix}" />
@@ -526,16 +574,18 @@
<!--
- Build the joal.jar file.
-->
- <target name="jar">
+ <target name="jar" depends="init">
<!-- Prepare the manifest -->
<copy file="joalversion"
tofile="tempversion"
overwrite="true">
<filterset>
- <filter token="VERSION" value="${joal.version}"/>
+ <filter token="VERSION" value="${jogamp.version}"/>
+ <filter token="BUILD_VERSION" value="${joal.version}"/>
<filter token="SCM_BRANCH" value="${joal.build.branch}"/>
<filter token="SCM_COMMIT" value="${joal.build.commit}"/>
- <filter token="BASEVERSION" value="${joal_base_version}" />
+ <filter token="BASEVERSION" value="${jogamp.version.base}" />
+ <filter token="JAR_CODEBASE_TAG" value="${jogamp.jar.codebase}"/>
</filterset>
</copy>
@@ -553,7 +603,7 @@
<delete file="tempversion"/>
</target>
- <target name="android.package" if="isAndroid">
+ <target name="android.package" depends="init" if="isAndroid">
<aapt.signed
jarsrcdir="${src.java}"
jarbuilddir="${build}"
@@ -564,8 +614,8 @@
androidmanifest.path="resources/android/AndroidManifest-joal.xml"
androidresources.path="resources/android/res-joal"
jarmanifest.path="tempversion"
- version.code="${joal_int_version}"
- version.name="${joal.version.plus}" />
+ version.code="${jogamp.version.int}"
+ version.name="${jogamp.version}" />
</target>
<!-- ================================================================== -->
@@ -740,7 +790,7 @@
<antcall target="jar" inheritRefs="true" />
</target>
- <target name="tag.build">
+ <target name="tag.build" depends="init">
<copy file="${gluegen.build}/artifact.properties" todir="${build}" overwrite="true" failonerror="false"/>
<echo message='joal.build.number=${joal.build.number}${line.separator}' file="${build}/artifact.properties" append="true"/>
<echo message='joal.build.id=${joal.build.id}${line.separator}' file="${build}/artifact.properties" append="true"/>