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