summaryrefslogtreecommitdiffstats
path: root/make/build.xml
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2014-08-28 07:21:47 +0200
committerSven Gothel <[email protected]>2014-08-28 07:21:47 +0200
commitd220090818a531cafee28cbf885e07e10b9c2992 (patch)
treed7fff05bee5951e85628af6ada06deb33ea50dd9 /make/build.xml
parentbe0f9da108aaad99d91d43e59d30bed9b8b79574 (diff)
Revert "gluegen: directly use git subcommands rather than sed over a temp file"
This reverts commit 1bf89ec4fde4227f8935f8c91b7ee22d160da581.
Diffstat (limited to 'make/build.xml')
-rw-r--r--make/build.xml32
1 files changed, 13 insertions, 19 deletions
diff --git a/make/build.xml b/make/build.xml
index 9c96481..534f122 100644
--- a/make/build.xml
+++ b/make/build.xml
@@ -66,33 +66,27 @@
<property name="gluegen.build.number" value="manual"/>
<property name="gluegen.build.id" value="${version.timestamp}"/>
-
- <exec dir="${project.root}" executable="git" logError="false" failonerror="false" failifexecutionfails="false"
- outputproperty="gluegen.build.branch.raw" resultproperty="gluegen.build.branch.ret">
- <arg value="symbolic-ref"/>
- <arg value="-q"/>
- <arg value="--short"/>
- <arg value="HEAD"/>
+ <mkdir dir="${build}" />
+ <exec dir="." executable="git" logError="true" failonerror="false" failifexecutionfails="false"
+ output="${build}/localbranch.raw">
+ <arg line="branch --no-color"/>
</exec>
- <condition property="gluegen.build.branch" value="${gluegen.build.branch.raw}" else="manual">
- <not> <isfailure code="${gluegen.build.branch.ret}"/> </not>
- </condition>
-
- <exec dir="${project.root}" executable="git" logError="false" failonerror="false" failifexecutionfails="false"
- outputproperty="gluegen.build.commit.raw" resultproperty="gluegen.build.commit.ret">
- <arg value="rev-parse"/>
- <arg value="HEAD"/>
+ <exec dir="." executable="sed" logError="true" failonerror="false" failifexecutionfails="false"
+ outputproperty="gluegen.build.branch">
+ <arg line="-e '/^[^*]/d' -e 's/* \(.*\)/\1/' '${build}/localbranch.raw'"/>
</exec>
- <condition property="gluegen.build.commit" value="${gluegen.build.commit.raw}" else="manual">
- <not> <isfailure code="${gluegen.build.commit.ret}"/> </not>
- </condition>
+ <property name="gluegen.build.branch" value="manual"/> <!-- fallback -->
+ <exec dir="${project.root}" executable="git" logError="true" failonerror="false" failifexecutionfails="false"
+ outputproperty="gluegen.build.commit">
+ <arg line="rev-parse HEAD"/>
+ </exec>
+ <property name="gluegen.build.commit" value="manual"/> <!-- fallback -->
<property name="gluegen.version" value="${jogamp.version.base}-b${gluegen.build.number}-${version.timestamp}" />
<property name="stub.includes.dir" value="stub_includes" /> <!-- NOTE: this MUST be relative for FileSet -->
<!-- The generated source directories. -->
- <mkdir dir="${build}" />
<property name="src.generated" value="${build}/gensrc" />
<property name="src.generated.java" value="${src.generated}/java" />
<property name="src.generated.c" value="${src.generated}/native" />