@@ -29,7 +29,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
29
29
<
property name =
" ant.project.vendor" value =
" Alexander Barker ([email protected] )" />
30
30
<property name =" ant.project.version" value =" ${ ant.build.major } .${ ant.build.minor } .${ ant.build.revision } " />
31
31
32
- <property file =" build.properties" />
33
32
<property environment =" env" />
34
33
35
34
<!-- Path Settings -->
@@ -69,6 +68,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
69
68
<echo >Cleaning all build related items...</echo >
70
69
71
70
<delete includeEmptyDirs =" true" verbose =" true" failonerror =" false" >
71
+ <fileset file =" ${ basedir } /build.properties" />
72
+
72
73
<fileset dir =" ${ dir.dist } " />
73
74
<fileset dir =" ${ dir.doc } " />
74
75
<fileset file =" ${ dir.jar } /${ ant.project.name } .jar" />
@@ -131,6 +132,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
131
132
</condition >
132
133
</fail >
133
134
135
+ <property file =" build.properties" />
134
136
135
137
<!-- Try to locate the include folder for java headers -->
136
138
<condition property =" ant.build.javac.include" value =" ${ env.JDK_HOME } /include" >
@@ -167,13 +169,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
167
169
</fail >
168
170
169
171
170
- <!-- Set the default javac build properties. -->
171
- <property name =" ant.build.javac.compiler" value =" modern" />
172
- <property name =" ant.build.javac.source" value =" ${ ant.java.version } " />
173
- <property name =" ant.build.javac.target" value =" ${ ant.java.version } " />
174
- <property name =" ant.build.javac.args" value =" " />
175
-
176
-
177
172
<!-- Define the JNI Tasks provided by classpathref. -->
178
173
<typedef resource =" org/jnitasks/antlib.xml" classpathref =" ant.project.class.path" onerror =" failall" />
179
174
@@ -276,6 +271,21 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
276
271
</condition >
277
272
<property name =" ant.build.native.toolchain" value =" gcc" />
278
273
274
+ <!-- Set parallel jobs. -->
275
+ <property name =" ant.build.native.jobs" value =" auto" />
276
+
277
+ <!-- Set default compiler and linker flags. -->
278
+ <condition property =" ant.build.native.cflags" value =" -O1 -g -pipe" else =" -O2 -pipe" >
279
+ <istrue value =" ${ ant.build.debug } " />
280
+ </condition >
281
+ <property name =" ant.build.native.ldflags" value =" " />
282
+
283
+ <!-- Set default javac options. -->
284
+ <property name =" ant.build.debug" value =" false" />
285
+ <property name =" ant.build.javac.compiler" value =" modern" />
286
+ <property name =" ant.build.javac.source" value =" ${ ant.java.version } " />
287
+ <property name =" ant.build.javac.target" value =" ${ ant.java.version } " />
288
+ <property name =" ant.build.javac.args" value =" " />
279
289
280
290
<!-- Set system specific library name. -->
281
291
<condition property =" ant.build.native.executable" value =" lib${ ant.project.name } .dylib" >
@@ -303,6 +313,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
303
313
<echo level =" info" >Native Toolchain: ${ ant.build.native.toolchain } </echo >
304
314
<echo level =" info" >Native CFLAGS: ${ ant.build.native.cflags } </echo >
305
315
<echo level =" info" >Native LDFLAGS: ${ ant.build.native.ldflags } </echo >
316
+
317
+ <!-- Create property file for the descovered values -->
318
+ <propertyfile file =" build.properties" comment =" auto-generated by ant configure" >
319
+ <entry key =" ant.build.debug" value=" ${ ant.build.debug } " />
320
+
321
+ <entry key =" ant.build.javac.compiler" value=" ${ ant.build.javac.compiler } " />
322
+ <entry key =" ant.build.javac.source" value=" ${ ant.build.javac.source } " />
323
+ <entry key =" ant.build.javac.target" value=" ${ ant.build.javac.target } " />
324
+ <entry key =" ant.build.javac.include" value=" ${ ant.build.javac.include } " />
325
+ <entry key =" ant.build.javac.args" value=" ${ ant.build.javac.args } " />
326
+
327
+ <entry key =" ant.build.native.toolchain" value=" ${ ant.build.native.toolchain } " />
328
+ <entry key =" ant.build.native.jobs" value=" ${ ant.build.native.jobs } " />
329
+ <entry key =" ant.build.native.cflags" value=" ${ ant.build.native.cflags } " />
330
+ <entry key =" ant.build.native.ldflags" value=" ${ ant.build.native.ldflags } " />
331
+ </propertyfile >
306
332
</target >
307
333
308
334
0 commit comments