Gentoo Archives: gentoo-commits

From: "Ralph Sennhauser (sera)" <sera@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-java/jnr-ffi/files: jnr-ffi_maven-build.xml
Date: Thu, 12 Jan 2012 11:27:15
Message-Id: 20120112112705.9D6A42004C@flycatcher.gentoo.org
1 sera 12/01/12 11:27:05
2
3 Added: jnr-ffi_maven-build.xml
4 Log:
5 New package, replacement for dev-java/jaffl.
6
7 (Portage version: 2.1.10.44/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.1 dev-java/jnr-ffi/files/jnr-ffi_maven-build.xml
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jnr-ffi/files/jnr-ffi_maven-build.xml?rev=1.1&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jnr-ffi/files/jnr-ffi_maven-build.xml?rev=1.1&content-type=text/plain
14
15 Index: jnr-ffi_maven-build.xml
16 ===================================================================
17 <?xml version="1.0" encoding="UTF-8"?>
18
19 <!-- ====================================================================== -->
20 <!-- Ant build file (http://ant.apache.org/) for Ant 1.6.2 or above. -->
21 <!-- ====================================================================== -->
22
23 <!-- ====================================================================== -->
24 <!-- ===================== - DO NOT EDIT THIS FILE! - ===================== -->
25 <!-- ====================================================================== -->
26 <!-- -->
27 <!-- Any modifications will be overwritten. -->
28 <!-- -->
29 <!-- Generated by Maven Ant Plugin on 1/9/12 11:18 AM -->
30 <!-- See: http://maven.apache.org/plugins/maven-ant-plugin/ -->
31 <!-- -->
32 <!-- ====================================================================== -->
33
34 <project name="jnr-ffi-from-maven" default="package" basedir=".">
35
36 <!-- ====================================================================== -->
37 <!-- Build environment properties -->
38 <!-- ====================================================================== -->
39
40 <property file="${user.home}/.m2/maven.properties"/>
41 <property file="maven-build.properties"/>
42
43 <property name="maven.build.finalName" value="jnr-ffi-0.6.0"/>
44 <property name="maven.build.dir" value="target"/>
45 <property name="maven.build.outputDir" value="${maven.build.dir}/classes"/>
46 <property name="maven.build.srcDir.0" value="src/main/java"/>
47 <property name="maven.build.resourceDir.0" value="src/main/resources"/>
48 <property name="maven.build.testOutputDir" value="${maven.build.dir}/test-classes"/>
49 <property name="maven.build.testDir.0" value="src/test/java"/>
50 <property name="maven.build.testResourceDir.0" value="src/test/resources"/>
51 <property name="maven.test.reports" value="${maven.build.dir}/test-reports"/>
52 <property name="maven.reporting.outputDirectory" value="${maven.build.dir}/site"/>
53
54 <property name="maven.repo.local" value="${user.home}/.m2/repository"/>
55 <property name="maven.settings.offline" value="false"/>
56 <property name="maven.settings.interactiveMode" value="true"/>
57
58 <!-- ====================================================================== -->
59 <!-- Defining classpaths -->
60 <!-- ====================================================================== -->
61
62 <path id="build.classpath">
63 <pathelement location="${maven.repo.local}/com/github/jnr/jffi/1.0.11/jffi-1.0.11.jar"/>
64 <pathelement location="${maven.repo.local}/asm/asm/3.2/asm-3.2.jar"/>
65 <pathelement location="${maven.repo.local}/asm/asm-commons/3.2/asm-commons-3.2.jar"/>
66 <pathelement location="${maven.repo.local}/asm/asm-analysis/3.2/asm-analysis-3.2.jar"/>
67 <pathelement location="${maven.repo.local}/asm/asm-tree/3.2/asm-tree-3.2.jar"/>
68 <pathelement location="${maven.repo.local}/asm/asm-util/3.2/asm-util-3.2.jar"/>
69 <pathelement location="${maven.repo.local}/com/github/jnr/jnr-x86asm/1.0.1/jnr-x86asm-1.0.1.jar"/>
70 </path>
71 <path id="build.test.classpath">
72 <pathelement location="${maven.repo.local}/junit/junit/4.8.2/junit-4.8.2.jar"/>
73 <pathelement location="${maven.repo.local}/com/github/jnr/jffi/1.0.11/jffi-1.0.11.jar"/>
74 <pathelement location="${maven.repo.local}/com/github/jnr/jffi/1.0.11/jffi-1.0.11-native.jar"/>
75 <pathelement location="${maven.repo.local}/asm/asm/3.2/asm-3.2.jar"/>
76 <pathelement location="${maven.repo.local}/asm/asm-commons/3.2/asm-commons-3.2.jar"/>
77 <pathelement location="${maven.repo.local}/asm/asm-analysis/3.2/asm-analysis-3.2.jar"/>
78 <pathelement location="${maven.repo.local}/asm/asm-tree/3.2/asm-tree-3.2.jar"/>
79 <pathelement location="${maven.repo.local}/asm/asm-util/3.2/asm-util-3.2.jar"/>
80 <pathelement location="${maven.repo.local}/com/github/jnr/jnr-x86asm/1.0.1/jnr-x86asm-1.0.1.jar"/>
81 </path>
82
83 <!-- ====================================================================== -->
84 <!-- Cleaning up target -->
85 <!-- ====================================================================== -->
86
87 <target name="clean" description="Clean the output directory">
88 <delete dir="${maven.build.dir}"/>
89 </target>
90
91 <!-- ====================================================================== -->
92 <!-- Compilation target -->
93 <!-- ====================================================================== -->
94
95 <target name="compile" depends="get-deps" description="Compile the code">
96 <mkdir dir="${maven.build.outputDir}"/>
97 <javac destdir="${maven.build.outputDir}"
98 nowarn="false"
99 debug="true"
100 optimize="false"
101 deprecation="true"
102 target="1.1"
103 verbose="false"
104 fork="false"
105 source="1.3">
106 <src>
107 <pathelement location="${maven.build.srcDir.0}"/>
108 </src>
109 <classpath refid="build.classpath"/>
110 </javac>
111 </target>
112
113 <!-- ====================================================================== -->
114 <!-- Test-compilation target -->
115 <!-- ====================================================================== -->
116
117 <target name="compile-tests"
118 depends="compile"
119 description="Compile the test code"
120 unless="maven.test.skip">
121 <mkdir dir="${maven.build.testOutputDir}"/>
122 <javac destdir="${maven.build.testOutputDir}"
123 nowarn="false"
124 debug="true"
125 optimize="false"
126 deprecation="true"
127 target="1.1"
128 verbose="false"
129 fork="false"
130 source="1.3">
131 <src>
132 <pathelement location="${maven.build.testDir.0}"/>
133 </src>
134 <classpath>
135 <path refid="build.test.classpath"/>
136 <pathelement location="${maven.build.outputDir}"/>
137 </classpath>
138 </javac>
139 </target>
140
141 <!-- ====================================================================== -->
142 <!-- Run all tests -->
143 <!-- ====================================================================== -->
144
145 <target name="test"
146 depends="compile-tests, junit-missing"
147 unless="junit.skipped"
148 description="Run the test cases">
149 <mkdir dir="${maven.test.reports}"/>
150 <junit printSummary="yes" haltonerror="true" haltonfailure="true" fork="true" dir=".">
151 <sysproperty key="basedir" value="."/>
152 <formatter type="xml"/>
153 <formatter type="plain" usefile="false"/>
154 <classpath>
155 <path refid="build.test.classpath"/>
156 <pathelement location="${maven.build.outputDir}"/>
157 <pathelement location="${maven.build.testOutputDir}"/>
158 </classpath>
159 <batchtest todir="${maven.test.reports}" unless="test">
160 <fileset dir="${maven.build.testDir.0}">
161 <include name="**/Test*.java"/>
162 <include name="**/*Test.java"/>
163 <include name="**/*TestCase.java"/>
164 <exclude name="**/*Abstract*Test.java"/>
165 </fileset>
166 </batchtest>
167 <batchtest todir="${maven.test.reports}" if="test">
168 <fileset dir="${maven.build.testDir.0}">
169 <include name="**/${test}.java"/>
170 <exclude name="**/*Abstract*Test.java"/>
171 </fileset>
172 </batchtest>
173 </junit>
174 </target>
175
176 <target name="test-junit-present">
177 <available classname="junit.framework.Test" property="junit.present"/>
178 </target>
179
180 <target name="test-junit-status"
181 depends="test-junit-present">
182 <condition property="junit.missing">
183 <and>
184 <isfalse value="${junit.present}"/>
185 <isfalse value="${maven.test.skip}"/>
186 </and>
187 </condition>
188 <condition property="junit.skipped">
189 <or>
190 <isfalse value="${junit.present}"/>
191 <istrue value="${maven.test.skip}"/>
192 </or>
193 </condition>
194 </target>
195
196 <target name="junit-missing"
197 depends="test-junit-status"
198 if="junit.missing">
199 <echo>=================================== WARNING ===================================</echo>
200 <echo> JUnit is not present in your $ANT_HOME/lib directory. Tests not executed.</echo>
201 <echo>===============================================================================</echo>
202 </target>
203
204 <!-- ====================================================================== -->
205 <!-- Javadoc target -->
206 <!-- ====================================================================== -->
207
208 <target name="javadoc" description="Generates the Javadoc of the application">
209 <javadoc sourcepath="${maven.build.srcDir.0}"
210 packagenames="*"
211 destdir="${maven.reporting.outputDirectory}/apidocs"
212 access="protected"
213 old="false"
214 verbose="false"
215 version="true"
216 use="true"
217 author="true"
218 splitindex="false"
219 nodeprecated="false"
220 nodeprecatedlist="false"
221 notree="false"
222 noindex="false"
223 nohelp="false"
224 nonavbar="false"
225 serialwarn="false"
226 charset="ISO-8859-1"
227 linksource="false"
228 breakiterator="false"/>
229 </target>
230
231 <!-- ====================================================================== -->
232 <!-- Package target -->
233 <!-- ====================================================================== -->
234
235 <target name="package" depends="compile,test" description="Package the application">
236 <jar jarfile="${maven.build.dir}/${maven.build.finalName}.jar"
237 compress="true"
238 index="false"
239 basedir="${maven.build.outputDir}"
240 excludes="**/package.html"/>
241 </target>
242
243 <!-- ====================================================================== -->
244 <!-- A dummy target for the package named after the type it creates -->
245 <!-- ====================================================================== -->
246
247 <target name="jar" depends="package" description="Builds the jar for the application"/>
248
249 <!-- ====================================================================== -->
250 <!-- Download dependencies target -->
251 <!-- ====================================================================== -->
252
253 <target name="test-offline">
254 <condition property="maven.mode.offline">
255 <equals arg1="${maven.settings.offline}" arg2="true"/>
256 </condition>
257 </target>
258
259 <target name="get-deps"
260 depends="test-offline"
261 description="Download all dependencies"
262 unless="maven.mode.offline">
263 <!-- removed -->
264 </target>
265
266 </project>