diff options
author | Sven Gothel <[email protected]> | 2013-03-28 20:06:30 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2013-03-28 20:06:30 +0100 |
commit | a3f2ef50ad33c58a240a17fcf03e415d772207c3 (patch) | |
tree | 82f14cf60ffac5ef81845eccb10686647b804a46 | |
parent | 0b3c2e5944a27e5eebc6fb82270aae3c91cebc1a (diff) |
Bug 588: Adding jogamp.version property, i.e. 2.0.2-rc-<TIMESTAMP> used for Manifest ; Common jogamp_int_version for Android.
Until 2.0.2 gets released, the version string is 2.0.2-rc-<TIMESTAMP>
and used in the Manifest for IMPLEMENTATION_VERSION.
The previous build version name of IMPLEMENTATION_VERSION
goes into the new tag IMPLEMENTATION_BUILD.
Further more, we use a common jogamp_int_version for Android, to make life more easy.
-rwxr-xr-x | make/Manifest | 1 | ||||
-rwxr-xr-x | make/Manifest-android-launcher | 1 | ||||
-rwxr-xr-x | make/Manifest-rt | 1 | ||||
-rwxr-xr-x | make/Manifest-rt-android | 1 | ||||
-rwxr-xr-x | make/Manifest-rt.cdc | 1 | ||||
-rw-r--r-- | make/build-test.xml | 4 | ||||
-rw-r--r-- | make/build.xml | 27 | ||||
-rw-r--r-- | make/jogamp-androidtasks.xml | 2 | ||||
-rwxr-xr-x | make/jogamp-env.xml | 12 | ||||
-rwxr-xr-x | make/scripts/runtest.sh | 4 | ||||
-rw-r--r-- | src/java/com/jogamp/common/util/JogampVersion.java | 25 |
11 files changed, 58 insertions, 21 deletions
diff --git a/make/Manifest b/make/Manifest index d362a39..eebce81 100755 --- a/make/Manifest +++ b/make/Manifest @@ -4,6 +4,7 @@ Specification-Version: @BASEVERSION@ Specification-Vendor: JogAmp Community Implementation-Title: GlueGen Compile-Time Implementation-Version: @VERSION@ +Implementation-Build: @BUILD_VERSION@ Implementation-Branch: @SCM_BRANCH@ Implementation-Commit: @SCM_COMMIT@ Implementation-Vendor: JogAmp Community diff --git a/make/Manifest-android-launcher b/make/Manifest-android-launcher index a8bbbe5..d97af77 100755 --- a/make/Manifest-android-launcher +++ b/make/Manifest-android-launcher @@ -4,6 +4,7 @@ Specification-Version: @BASEVERSION@ Specification-Vendor: JogAmp Community Implementation-Title: JogAmp Android Launcher Implementation-Version: @VERSION@ +Implementation-Build: @BUILD_VERSION@ Implementation-Branch: @SCM_BRANCH@ Implementation-Commit: @SCM_COMMIT@ Implementation-Vendor: JogAmp Community diff --git a/make/Manifest-rt b/make/Manifest-rt index f0ec2c5..99c6c7e 100755 --- a/make/Manifest-rt +++ b/make/Manifest-rt @@ -4,6 +4,7 @@ Specification-Version: @BASEVERSION@ Specification-Vendor: JogAmp Community Implementation-Title: GlueGen Run-Time Implementation-Version: @VERSION@ +Implementation-Build: @BUILD_VERSION@ Implementation-Branch: @SCM_BRANCH@ Implementation-Commit: @SCM_COMMIT@ Implementation-Vendor: JogAmp Community diff --git a/make/Manifest-rt-android b/make/Manifest-rt-android index da1d122..54d8c37 100755 --- a/make/Manifest-rt-android +++ b/make/Manifest-rt-android @@ -4,6 +4,7 @@ Specification-Version: @BASEVERSION@ Specification-Vendor: JogAmp Community Implementation-Title: GlueGen Run-Time For Android Implementation-Version: @VERSION@ +Implementation-Build: @BUILD_VERSION@ Implementation-Branch: @SCM_BRANCH@ Implementation-Commit: @SCM_COMMIT@ Implementation-Vendor: JogAmp Community diff --git a/make/Manifest-rt.cdc b/make/Manifest-rt.cdc index 6cd204f..2e808db 100755 --- a/make/Manifest-rt.cdc +++ b/make/Manifest-rt.cdc @@ -4,6 +4,7 @@ Specification-Version: @BASEVERSION@ Specification-Vendor: JogAmp Community Implementation-Title: GlueGen Run-Time CDC Implementation-Version: @VERSION@ +Implementation-Build: @BUILD_VERSION@ Implementation-Branch: @SCM_BRANCH@ Implementation-Commit: @SCM_COMMIT@ Implementation-Vendor: JogAmp Community diff --git a/make/build-test.xml b/make/build-test.xml index 8a11a17..f3f0f7e 100644 --- a/make/build-test.xml +++ b/make/build-test.xml @@ -148,8 +148,8 @@ android.abi="${android.abi}" androidmanifest.path="resources/android/AndroidManifest-Test.xml" androidresources.path="resources/android/res" - version.code="${gluegen_int_version}" - version.name="${gluegen.version.plus}" + version.code="${jogamp_int_version}" + version.name="${jogamp.version}" /> </target> diff --git a/make/build.xml b/make/build.xml index 188f518..1f46d57 100644 --- a/make/build.xml +++ b/make/build.xml @@ -63,10 +63,6 @@ <property name="javadoc.gluegen.path" location="${javadoc.root.path}/gluegen/javadoc" /> <property name="gluegen.lib.dir" value="${build}/obj"/> - <tstamp> - <format property="version.timestamp" pattern="yyyyMMdd"/> - </tstamp> - <property name="gluegen.build.number" value="manual"/> <property name="gluegen.build.id" value="${version.timestamp}"/> <mkdir dir="${build}" /> @@ -85,11 +81,8 @@ </exec> <property name="gluegen.build.commit" value="manual"/> <!-- fallback --> - <!-- This is the version of GlueGen you are building xxyyzzz, xx=API yy screen-from-to zzz app-version--> - <property name="gluegen_int_version" value="0914011"/> <property name="gluegen_base_version" value="2.0"/> <property name="gluegen.version" value="${gluegen_base_version}-b${gluegen.build.number}-${version.timestamp}" /> - <property name="gluegen.version.plus" value="${gluegen_base_version}-${gluegen.build.branch}-b${gluegen.build.number}-${version.timestamp}" /> <property name="stub.includes.dir" value="stub_includes" /> <!-- NOTE: this MUST be relative for FileSet --> @@ -800,7 +793,8 @@ tofile="${build}/Manifest.temp" overwrite="true"> <filterset> - <filter token="VERSION" value="${gluegen.version}"/> + <filter token="VERSION" value="${jogamp.version}"/> + <filter token="BUILD_VERSION" value="${gluegen.version}"/> <filter token="SCM_BRANCH" value="${gluegen.build.branch}"/> <filter token="SCM_COMMIT" value="${gluegen.build.commit}"/> <filter token="BASEVERSION" value="${gluegen_base_version}"/> @@ -823,7 +817,8 @@ tofile="${build}/Manifest-rt.temp" overwrite="true"> <filterset> - <filter token="VERSION" value="${gluegen.version}"/> + <filter token="VERSION" value="${jogamp.version}"/> + <filter token="BUILD_VERSION" value="${gluegen.version}"/> <filter token="SCM_BRANCH" value="${gluegen.build.branch}"/> <filter token="SCM_COMMIT" value="${gluegen.build.commit}"/> <filter token="BASEVERSION" value="${gluegen_base_version}"/> @@ -882,7 +877,8 @@ tofile="${build}/Manifest-rt-android.temp" overwrite="true"> <filterset> - <filter token="VERSION" value="${gluegen.version}"/> + <filter token="VERSION" value="${jogamp.version}"/> + <filter token="BUILD_VERSION" value="${gluegen.version}"/> <filter token="SCM_BRANCH" value="${gluegen.build.branch}"/> <filter token="SCM_COMMIT" value="${gluegen.build.commit}"/> <filter token="BASEVERSION" value="${gluegen_base_version}"/> @@ -940,7 +936,8 @@ tofile="${build}/Manifest-android-launcher.temp" overwrite="true"> <filterset> - <filter token="VERSION" value="${gluegen.version}"/> + <filter token="VERSION" value="${jogamp.version}"/> + <filter token="BUILD_VERSION" value="${gluegen.version}"/> <filter token="SCM_BRANCH" value="${gluegen.build.branch}"/> <filter token="SCM_COMMIT" value="${gluegen.build.commit}"/> <filter token="BASEVERSION" value="${gluegen_base_version}"/> @@ -964,8 +961,8 @@ androidmanifest.path="resources/android/AndroidManifest-Launcher.xml" androidresources.path="resources/android/res" jarmanifest.path="${build}/Manifest-android-launcher.temp" - version.code="${gluegen_int_version}" - version.name="${gluegen.version.plus}" + version.code="${jogamp_int_version}" + version.name="${jogamp.version}" /> </target> @@ -990,8 +987,8 @@ androidmanifest.path="resources/android/AndroidManifest-Runtime.xml" androidresources.path="resources/android/res" jarmanifest.path="${build}/Manifest-rt-android.temp" - version.code="${gluegen_int_version}" - version.name="${gluegen.version.plus}" + version.code="${jogamp_int_version}" + version.name="${jogamp.version}" /> </target> diff --git a/make/jogamp-androidtasks.xml b/make/jogamp-androidtasks.xml index f5b5d83..015dcc3 100644 --- a/make/jogamp-androidtasks.xml +++ b/make/jogamp-androidtasks.xml @@ -16,7 +16,7 @@ androidmanifest.path="resources/android/AndroidManifest.xml" androidresources.path="resources/android/res" jarmanifest.path="${build}/Manifest-rt.temp" // optional - version.code="${gluegen_int_version}" + version.code="${jogamp_int_version}" version.name="${gluegen.version.plus}" // optional values, for having a valid keystore: diff --git a/make/jogamp-env.xml b/make/jogamp-env.xml index 77421f5..e657e03 100755 --- a/make/jogamp-env.xml +++ b/make/jogamp-env.xml @@ -64,11 +64,21 @@ <target name="jogamp.env.init" depends="jogamp.env.validation"> <property environment="env" /> + <tstamp> + <format property="version.timestamp" pattern="yyyyMMddHHmm"/> + </tstamp> + + <property name="jogamp.version" value="2.0.2-rc-${version.timestamp}" /> + <echo message="jogamp.version ${jogamp.version}"/> + <!-- This is the Android version: xxyyzzz, xx=API yy screen-from-to zzz app-version--> + <property name="jogamp_int_version" value="0914012"/> + <echo message="jogamp_int_version ${jogamp_int_version}"/> + <!-- only set 'junit.is.disabled' if set in environment as 'true' to disable JUNIT tests --> <condition property="junit.is.disabled" value="${env.JUNIT_DISABLED}"> <istrue value="${env.JUNIT_DISABLED}"/> </condition> - <echo message="junit.is.disabled ${junit.is.disabled}"/> + <echo message="junit.is.disabled ${junit.is.disabled}"/> <condition property="junit.run.arg0" value="${env.JUNIT_RUN_ARG0}"> <not> diff --git a/make/scripts/runtest.sh b/make/scripts/runtest.sh index 19cfd43..657c217 100755 --- a/make/scripts/runtest.sh +++ b/make/scripts/runtest.sh @@ -75,7 +75,7 @@ function onetest() { # #onetest com.jogamp.common.GlueGenVersion 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.TestSystemPropsAndEnvs 2>&1 | tee -a $LOG -#onetest com.jogamp.common.util.TestVersionInfo 2>&1 | tee -a $LOG +onetest com.jogamp.common.util.TestVersionInfo 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.TestVersionNumber 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.TestIteratorIndexCORE 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.locks.TestRecursiveLock01 2>&1 | tee -a $LOG @@ -94,7 +94,7 @@ function onetest() { #onetest com.jogamp.common.nio.TestPointerBufferEndian 2>&1 | tee -a $LOG #onetest com.jogamp.common.nio.TestStructAccessorEndian 2>&1 | tee -a $LOG #onetest com.jogamp.common.os.TestElfReader01 2>&1 | tee -a $LOG -onetest com.jogamp.gluegen.test.junit.generation.Test1p1JavaEmitter 2>&1 | tee -a $LOG +#onetest com.jogamp.gluegen.test.junit.generation.Test1p1JavaEmitter 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test1p2ProcAddressEmitter 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.TestPlatform01 2>&1 | tee -a $LOG #onetest com.jogamp.common.util.TestRunnableTask01 2>&1 | tee -a $LOG diff --git a/src/java/com/jogamp/common/util/JogampVersion.java b/src/java/com/jogamp/common/util/JogampVersion.java index de65f90..c44b1db 100644 --- a/src/java/com/jogamp/common/util/JogampVersion.java +++ b/src/java/com/jogamp/common/util/JogampVersion.java @@ -40,7 +40,11 @@ import jogamp.common.os.AndroidUtils; public class JogampVersion { + /** See {@link #getImplementationBuild()} */ + public static final Attributes.Name IMPLEMENTATION_BUILD = new Attributes.Name("Implementation-Build"); + /** See {@link #getImplementationBranch()} */ public static final Attributes.Name IMPLEMENTATION_BRANCH = new Attributes.Name("Implementation-Branch"); + /** See {@link #getImplementationCommit()} */ public static final Attributes.Name IMPLEMENTATION_COMMIT = new Attributes.Name("Implementation-Commit"); private String packageName; @@ -113,10 +117,23 @@ public class JogampVersion { return this.getAttribute(Attributes.Name.EXTENSION_NAME); } + /** + * Returns the implementation build number, e.g. <code>2.0-b456-201303281921</code>. + */ + public final String getImplementationBuild() { + return this.getAttribute(GlueGenVersion.IMPLEMENTATION_BUILD); + } + + /** + * Returns the SCM branch name + */ public final String getImplementationBranch() { return this.getAttribute(GlueGenVersion.IMPLEMENTATION_BRANCH); } + /** + * Returns the SCM version of the last commit, e.g. git's sha1 + */ public final String getImplementationCommit() { return this.getAttribute(GlueGenVersion.IMPLEMENTATION_COMMIT); } @@ -137,6 +154,13 @@ public class JogampVersion { return this.getAttribute(Attributes.Name.IMPLEMENTATION_URL); } + /** + * Retruns the {@link Attributes.Name#IMPLEMENTATION_VERSION IMPLEMENTATION_VERSION}. + * <p> + * E.g. <code>2.0.2-rc-201303281050</code> for snapshots prior to <code>2.0.2</code> release + * and <code>2.0.2</code> for the upcoming release. + * </p> + */ public final String getImplementationVersion() { return this.getAttribute(Attributes.Name.IMPLEMENTATION_VERSION); } @@ -176,6 +200,7 @@ public class JogampVersion { sb.append("Implementation Vendor ID: ").append(getImplementationVendorID()).append(nl); sb.append("Implementation URL: ").append(getImplementationURL()).append(nl); sb.append("Implementation Version: ").append(getImplementationVersion()).append(nl); + sb.append("Implementation Build: ").append(getImplementationBuild()).append(nl); sb.append("Implementation Branch: ").append(getImplementationBranch()).append(nl); sb.append("Implementation Commit: ").append(getImplementationCommit()).append(nl); if(null != getAndroidPackageVersionName()) { |