[ivyplusplus] 02/07: custom ant build file to work around circular dependencies
Hans-Christoph Steiner
eighthave at moszumanska.debian.org
Tue Dec 15 14:15:00 UTC 2015
This is an automated email from the git hooks/post-receive script.
eighthave pushed a commit to branch master
in repository ivyplusplus.
commit 1f953302e3b41c70ff643b3b665a8ec10d352bbe
Author: Hans-Christoph Steiner <hans at eds.org>
Date: Sun Dec 13 23:05:19 2015 +0100
custom ant build file to work around circular dependencies
---
debian/build.xml | 86 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
debian/rules | 5 ++--
2 files changed, 88 insertions(+), 3 deletions(-)
diff --git a/debian/build.xml b/debian/build.xml
new file mode 100644
index 0000000..ca4a9ff
--- /dev/null
+++ b/debian/build.xml
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="com.zwitserloot.ivyplusplus" default="dist">
+
+ <mkdir dir="build/pack" />
+ <mkdir dir="lib/build" />
+
+ <path id="build.path">
+ <fileset dir="lib/build">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <path id="runtime.path">
+ <fileset dir="lib/runtime">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <path id="pack.path">
+ <fileset dir="lib/pack">
+ <include name="*.jar" />
+ </fileset>
+ </path>
+
+ <target name="clean">
+ <delete dir="build" />
+ <delete dir="dist" />
+ <delete dir="lib" />
+ <delete file=".project" />
+ <delete file=".classpath" />
+ <delete dir=".settings" />
+ </target>
+
+ <target name="compile">
+ <javac srcdir="src" destdir="build/pack">
+ <classpath refid="build.path" />
+ <classpath location="/usr/share/java/bcpg.jar" />
+ <classpath location="/usr/share/java/bcprov.jar" />
+ <classpath location="/usr/share/java/com.zwitserloot.cmdreader.jar" />
+ <classpath location="/usr/share/java/ivy.jar" />
+ </javac>
+ </target>
+
+ <target name="isolateBridges" depends="compile">
+ <mkdir dir="build/runtimedeps" />
+ <jar jarfile="build/runtimedeps/ipp-bc-bridges.jar">
+ <fileset dir="build/pack">
+ <include name="com/zwitserloot/ivyplusplus/mavencentral/CreateSigningKey_.class" />
+ <include name="com/zwitserloot/ivyplusplus/mavencentral/CreateDetachedSignatures_.class" />
+ </fileset>
+ </jar>
+ <delete file="build/pack/com/zwitserloot/ivyplusplus/mavencentral/CreateSigningKey_.class" />
+ <delete file="build/pack/com/zwitserloot/ivyplusplus/mavencentral/CreateDetachedSignatures_.class" />
+ </target>
+
+ <target name="dist" depends="isolateBridges, stripeIvy">
+ <mkdir dir="dist" />
+ <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/build/jarjar.jar" />
+ <jarjar jarfile="dist/ivyplusplus-${ivyplusplus.version}.jar">
+ <fileset dir="build/pack" />
+ <fileset dir="build/runtimedeps" />
+ <rule pattern="com.zwitserloot.cmdreader.**" result="com.zwitserloot.ivyplusplus.libs.com.zwitserloot.cmdreader. at 1" />
+ <manifest>
+ <attribute name="Main-Class" value="com.zwitserloot.ivyplusplus.createProject.CreateProject" />
+ <attribute name="ivyplusplus-version" value="${ivyplusplus.version}" />
+ </manifest>
+ </jarjar>
+ <copy file="dist/ivyplusplus-${ivyplusplus.version}.jar" tofile="dist/ivyplusplus.jar" />
+ </target>
+
+ <target name="stripeIvy">
+ <mkdir dir="build/pack" />
+ <unjar src="lib/build/ivy.jar" dest="build/pack" />
+ <move file="build/pack/META-INF/LICENSE" tofile="build/pack/META-INF/LICENSE.ivy" />
+ <copy file="LICENSE" tofile="build/pack/META-INF/LICENSE.ivyplusplus" />
+ <loadresource property="antlib-ivy.contents">
+ <file file="build/pack/org/apache/ivy/ant/antlib.xml" />
+ <filterchain>
+ <linecontainsregexp negate="true">
+ <regexp pattern="(?:\b/?antlib[^>]*>)|(?:\?[^>]*\?>)" />
+ </linecontainsregexp>
+ </filterchain>
+ </loadresource>
+ <replace file="build/pack/com/zwitserloot/ivyplusplus/antlib.xml" token="-- insert here -->" value="-- ivy's antlib -->${antlib-ivy.contents}" />
+ </target>
+</project>
diff --git a/debian/rules b/debian/rules
index cf1b927..ff29373 100755
--- a/debian/rules
+++ b/debian/rules
@@ -8,8 +8,7 @@ include /usr/share/dpkg/default.mk
override_dh_auto_clean:
dh_auto_clean
- ant clean
- -rm -rf ivyCache lib/build lib/test
+ ant -buildfile debian/build.xml -Dbasedir=`pwd` clean
override_dh_auto_build:
- ant dist -lib /usr/share/java/ivy.jar
+ ant -buildfile debian/build.xml -Dbasedir=`pwd` dist
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/ivyplusplus.git
More information about the pkg-java-commits
mailing list