-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.xml
3735 lines (3445 loc) · 189 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<?xml version="1.0" encoding="ISO-8859-1"?>
<project basedir="." default="all" name="i2p" xmlns:artifact="antlib:org.apache.maven.artifact.ant">
<!-- Define the ant-contrib tasks -->
<taskdef resource="net/sf/antcontrib/antcontrib.properties">
<classpath>
<pathelement location="/usr/share/java/ant-contrib.jar"/>
</classpath>
</taskdef>
<!-- for javac "release" parameter -->
<property name="ant.minimumVersion" value="1.9.8"/>
<!--
Include property files so that values can be easily overridden.
Users should create an override.properties file to make changes.
-->
<property file="override.properties"/>
<property file="build.properties"/>
<!--
When changing, also change javadoc URL in build.properties,
and checksum in apps/jetty/build.xml
and versions in gradle.properties and apps/jetty/build.gradle
-->
<property name="jetty.ver" value="9.3.30.v20211001"/>
<property name="tomcat.ver" value="9.0.88"/>
<!-- You probably don't want to change anything from here down -->
<target name="help" depends="all"/>
<target name="all">
<echo message="Ant: ${ant.version}"/>
<echo message="JDK: ${java.vendor} ${java.version} (${java.runtime.name} ${java.runtime.version})"/>
<echo message=" "/>
<echo message="Useful targets:"/>
<echo message=" bench Build benchmarks"/>
<echo message=" buildAddressbook Build Addressbook .jar component ➜ ./build/addressbook.jar"/>
<echo message=" buildCore Build i2p .jar component ➜ ./build/i2p.jar"/>
<echo message=" buildDesktopGui Build standalone DesktopGUI ➜ ./build/desktopgui.jar"/>
<echo message=" buildI2PControl Build I2PControl .war component ➜ ./build/jsonrpc.war"/>
<echo message=" buildI2PSnark Build I2PSnark .jar & .war components ➜ ./build/i2psnark.(jar|war)"/>
<echo message=" buildI2PTunnel Build I2PTunnel .jar & .war components ➜ ./build/i2ptunnel.(jar|war)"/>
<echo message=" buildImagegen Build Imagegen .war component ➜ ./build/imagegen.war"/>
<echo message=" buildJetty Build all Jetty related jar components ➜ ./build/"/>
<echo message=" buildJrobin Build the JRobin (RRD4J) .jar component ➜ ./build/jrobin.jar"/>
<echo message=" buildMinistreaming Build MiniStreaming .jar component ➜ ./build/mstreaming.jar"/>
<echo message=" buildPack200 Build Pack200 .jar component ➜ ./build/pack200.jar"/>
<echo message=" buildProperties Display build properties and Ant / JDK versions for current build"/>
<echo message=" buildRequirements Information about requirements for building packages using ant"/>
<echo message=" buildRouter Build Router .jar component ➜ ./build/router.jar"/>
<echo message=" buildRouterConsole Build required .jar components for RouterConsole ➜ ./build/"/>
<echo message=" buildSAM Build SAM .jar component ➜ ./build/sam.jar"/>
<echo message=" buildStreaming Build Streaming .jar component ➜ ./build/streaming.jar"/>
<echo message=" buildSusiDNS Build SusiDNS .war component ➜ ./build/susidns.war"/>
<echo message=" buildSusiMail Build SusiMail .war component ➜ ./build/susimail.war"/>
<echo message=" buildSusiMailJar Build SusiMail .jar component for testing ➜ ./build/susimail.jar"/>
<echo message=" buildWEB Build required .jar & .war components for RouterConsole ➜ ./build/"/>
<echo message=" bump Increment build (minor version) by 1"/>
<echo message=" bumpBuildTime Update core/java/src/net/i2p/time/BuildTime.java with today's date"/>
<echo message=" createThemesZip Create zip with all console and webapp themes and resources ➜ ./dist/themes.zip"/>
<echo message=" debian Generate Debian packages in ../ then run 'debian-clean'"/>
<echo message=" debian-clean Rollback Debian specific patches then run 'distclean'"/>
<echo message=" debianhowto Instructions on building Debian packages"/>
<echo message=" dist Run 'pkg' and 'javadoc'"/>
<echo message=" dist200 Run 'pkg', 'updater200' and 'javadoc'"/>
<echo message=" distclean Clean up all derived and temporary files in workspace"/>
<echo message=" distcleanWebapps Clean up all webapp-related derived and temporary files in workspace"/>
<echo message=" getGitRev Check current Git revision in workspace and print truncated revision hash"/>
<echo message=" getGitRevLong Check current Git revision in workspace and print full revision hash"/>
<echo message=" i2psnark Build standalone I2PSnark install ➜ ./dist/i2psnark-standalone.zip"/>
<echo message=" i2psnark7zip Build standalone I2PSnark 7zip install ➜ ./dist/i2psnark-standalone.7z"/>
<echo message=" i2psnark_nozip Build standalone I2PSnark install, no zip file ➜ ./dist/i2psnark-standalone"/>
<echo message=" installer / installer5 Build GUI installer (IzPack4 / IzPack5) ➜ ./dist/i2pinstall.exe"/>
<echo message=" installer-freebsd Build FreeBSD GUI installer ➜ ./dist/i2pinstall…freebsd-only.jar"/>
<echo message=" installer-linux / installer5-linux Build Linux GUI installer (IzPack4 / Izpack5) ➜ i2pinstall…linux-only.jar"/>
<echo message=" installer-nowindows / installer5-nowindows Build GUI installer without Windows support (IzPack4 / IzPack5) ➜ i2pinstall….jar"/>
<echo message=" installer-osx Build OS X GUI installer ➜ ./dist/i2pinstall…osx.tar.bz2"/>
<echo message=" installer-windows / installer5-windows Build Windows GUI installer (IzPack4 / IzPack5) ➜ ./dist/i2pinstall…windows.exe"/>
<echo message=" javadoc Create javadocs for project ➜ ./dist/javadoc"/>
<echo message=" javadoc-nostylesheet Create javadocs for project without custom stylesheet ➜ ./dist/javadoc"/>
<echo message=" javadoc-test Javadocs for unit test classes ➜ ./build/javadoc-test"/>
<echo message=" javadoc-zip Create javadocs zip for project ➜ ./dist/javadoc.zip"/>
<echo message=" javadoc-zip-nostylesheet Create javadocs zip without custom stylesheet for project ➜ ./dist/javadoc.zip"/>
<echo message=" jsdoc Create jsdoc for project (requires jsdoc-toolkit) ➜ ./dist/jsdoc"/>
<echo message=" pkg Run 'distclean' then package everything up (updater, installer)"/>
<echo message=" pkg-portable-win32 Build a minimal, portable install for Win32 ➜ ./portable-win32.zip"/>
<echo message=" poupdate-source Update the .po files for translators (requires jsp files to be compiled first)"/>
<echo message=" signed-updater Signed Updater ➜ ./dist/i2pupdate.su3 (Java14+ compatible)"/>
<echo message=" signed-updater200 Signed Updater (pack200) ➜ ./dist/i2pupdate.su3"/>
<echo message=" signed-updater200WithJavadoc Signed Updater (pack200) + javadocs ➜ ./dist/i2pupdate.su3"/>
<echo message=" signed-updater200WithJavadocAndJetty Signed Updater (pack200) + javadocs + Jetty ➜ ./dist/i2pupdate.su3"/>
<echo message=" signed-updater200withJetty Signed Updater (pack200) + Jetty"/>
<echo message=" slackpkg Build Slackware package in ./Slackware/i2p"/>
<echo message=" tarball Create tar archive for clean install ➜ ./dist/i2p.tar.bz2"/>
<echo message=" testscripts Run various scripts to check certificate validity, file integrity etc"/>
<echo message=" updater Build updater for existing installs ➜ ./dist/i2pupdate.zip"/>
<echo message=" updater200 Updater (pack200 - requires Java < v14 or pre-existing lib/pack200.jar) ➜ ./dist/i2pupdate200.zip"/>
<echo message=" updater200Compact Updater (pack200) w/o SAM, DesktopGUI, systray, country/continent lists, docs/proxy, docs/readme"/>
<echo message=" updater200CompactWithDocs Compact updater (pack200) with readme and proxy docs"/>
<echo message=" updater200CompactWithGeoIP Compact updater (pack200) with GeoIP database"/>
<echo message=" updater200WithGeoIP Updater (pack200) + GeoIP files"/>
<echo message=" updater200WithGeoIPAndJbigi Updater (pack200) + GeoIP files + Jbigi"/>
<echo message=" updater200WithJavadoc Updater (pack200) + javadocs (with console link)"/>
<echo message=" updater200WithJavadocAndJetty Updater (pack200) + javadocs (with console link) + Jetty"/>
<echo message=" updater200WithJbigi Updater (pack200) + jBigi library"/>
<echo message=" updater200WithJetty Updater (pack200) + Jetty"/>
<echo message=" updater200WithJettyAndGeoIP Updater (pack200) + Jetty + GeoIP files"/>
<echo message=" updater200WithJettyAndGeoIPAndLicenses Updater (pack200) + Jetty + GeoIP files + licenses"/>
<echo message=" updater200WithJettyFixesAndGeoIP Updater (pack200) + local Jetty patches + GeoIP files"/>
<echo message=" updaterCompact Updater w/o SAM, DesktopGUI, systray, country/continent lists, docs/proxy, docs/readme"/>
<echo message=" updaterCompactRouterConsole Updater with RouterConsole and console/webapp themes only"/>
<echo message=" updaterCompactRouterConsoleNoThemes Updater with RouterConsole only (no themes)"/>
<echo message=" updaterCompactWithDocs Compact updater with readme and proxy docs"/>
<echo message=" updaterCompactWithGeoIP Compact updater with GeoIP database"/>
<echo message=" updaterCompactWithGeoIPAndJbigi Compact updater with GeoIP database and Jbigi"/>
<echo message=" updaterRouter Updater with i2p.jar and router.jar only"/>
<echo message=" updaterSmall Updater with essentials (no SAM/I2PSnark/SusiMail/SusiDNS/history.txt)"/>
<echo message=" updaterWithGeoIP Updater + GeoIP files"/>
<echo message=" updaterWithJavadoc Updater + javadocs (linked in console)"/>
<echo message=" updaterWithJavadocAndJetty Updater + javadocs (linked in console) + Jetty "/>
<echo message=" updaterWithJbigi Updater + jBigi library"/>
<echo message=" updaterWithJetty Updater + Jetty"/>
<echo message=" updaterWithJettyFixes Updater + local Jetty patches"/>
<echo message=" updaterWithJettyFixesAndGeoIP Updater + local Jetty patches + GeoIP files"/>
<echo message=" updaterWithJettyFixesAndJbigi Updater + local Jetty patches + jBigi library"/>
<echo message=" updateTorBlocklist Update Tor blocklist ➜ installer/resources/blocklist_tor.txt"/>
<echo message=" 7zip-freebsd Installation 7zip for FreeBSD without installer ➜ ./dist/i2p-freebsd.7z"/>
<echo message=" 7zip-linux Installation 7zip for Linux without installer ➜ ./dist/i2p-linux.7z"/>
<echo message=" 7zip-macos Installation 7zip for macOS without installer ➜ ./dist/i2p-macos.7z"/>
<echo message=" 7zip-windows Installation 7zip for Windows without installer ➜ ./dist/i2p-windows.7z"/>
<echo message=" 7zip-multiplatform Installation 7zips for FreeBSD, macOS, Linux and Windows ➜ ./dist/"/>
<echo message=" zip-freebsd Installation zip for FreeBSD without installer ➜ ./dist/i2p-freebsd.zip"/>
<echo message=" zip-linux Installation zip for Linux without installer ➜ ./dist/i2p-linux.zip"/>
<echo message=" zip-macos Installation zip for macOS without installer ➜ ./dist/i2p-macos.zip"/>
<echo message=" zip-windows Installation zip for Windows without installer ➜ ./dist/i2p-windows.zip"/>
<!-- <echo message=" translationReport Generate in-console translation status report"/> -->
<!-- <echo message=" debianrepo Build a Debian repository (reprepro required)"/> -->
<!-- <echo message=" syndie Generate a standalone syndie install"/> -->
</target>
<target name="debianhowto">
<echo message="To build debian packages, ensure that you have the necessary build-dependencies installed, "/>
<echo message="indicated in the file 'debian/control' in the 'Build-Depends' field."/>
<echo message=" "/>
<echo message="The following command will install the build dependencies:"/>
<echo message="sudo apt install debhelper ant debconf default-jdk gettext libgmp-dev po-debconf fakeroot \"/>
<echo message=" build-essential quilt dh-apparmor libservice-wrapper-java libjson-simple-java devscripts \"/>
<echo message=" libjetty9-java libtomcat9-java libtaglibs-standard-jstlel-java libgetopt-java"/>
<echo message=" "/>
<echo message="Additionally, for runtime dependencies (console flags and geoip database):"/>
<echo message="sudo apt install geoip-database famfamfam-flag-png"/>
<echo message=" "/>
<echo message="Once the dependencies are installed, run 'ant debian' to patch the source and build packages."/>
</target>
<target name="buildRequirements">
<echo message="To build using ant, there are a few basic requirements:"/>
<echo message=" * Ensure your locale is set to UTF-8"/>
<echo message=" * A Java JDK installation - Oracle, OpenJDK or Microsoft work well"/>
<echo message=" * If you're building updates to be shared, building with Java 8 is recommended, though not required"/>
<echo message=" * The ant-contrib package is a required dependency which supports various ant extensions"/>
<echo message=" * For translation support, GNU gettext is required, and can be installed from repos in most Linux distros"/>
<echo message=" * To enable Javascript compression of the console and webapp scripts, the uglifyjs package is required"/>
<echo message=" * To build pack200 updates, Java 13 or earlier is required; on Linux, the GNU parallel package is also required"/>
<echo message=" * On a Linux system with multiple Java installations, you can configure ant to use a specific version by setting"/>
<echo message=" an alias in your ~/.bashrc file, e.g. alias ant8="JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-amd64 ant""/>
</target>
<property name="gpg" value="gpg"/>
<macrodef name="gpgsign">
<attribute name="file"/>
<sequential>
<delete file="@{file}.sig" quiet="true"/>
<exec executable="${gpg}" failonerror="true">
<arg value="-u"/>
<arg value="${release.gpg.keyid}"/>
<arg value="-b"/>
<arg value="@{file}"/>
</exec>
<chmod type="file" perm="444">
<fileset dir="${basedir}">
<include name="@{file} @{file}.sig"/>
</fileset>
</chmod>
</sequential>
</macrodef>
<macrodef name="gpgsignasc">
<attribute name="file"/>
<sequential>
<delete file="@{file}.asc" quiet="true"/>
<exec executable="${gpg}" failonerror="true">
<arg value="-u"/>
<arg value="${release.gpg.keyid}"/>
<arg value="-ab"/>
<arg value="@{file}"/>
</exec>
<chmod type="file" perm="444">
<fileset dir="${basedir}">
<include name="@{file} @{file}.asc"/>
</fileset>
</chmod>
</sequential>
</macrodef>
<macrodef name="mktorrent">
<attribute name="file"/>
<sequential>
<delete file="@{file}.torrent" quiet="true"/>
<java classname="org.klomp.snark.Storage" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
<pathelement location="build/i2psnark.jar"/>
</classpath>
<arg value="-a"/>
<arg value="http://tracker2.postman.i2p/announce.php"/>
<arg value="-c"/>
<arg value="${build.built-by}"/>
<arg value="-m"/>
<arg value="Official torrent for version ${full.version}"/>
<arg value="@{file}"/>
</java>
</sequential>
</macrodef>
<macrodef name="sha256sum">
<attribute name="file"/>
<sequential>
<!--
Note: "local" only works with ant 1.8+. This limitation shouldn't be
a big deal since this macro is only called by the release target.
-->
<local name="file-sum"/>
<checksum format="MD5SUM" file="@{file}" property="file-sum" algorithm="sha-256"/>
<echo message="${file-sum} @{file}"/>
</sequential>
</macrodef>
<macrodef name="sudsign">
<attribute name="infile"/>
<attribute name="outfile"/>
<sequential>
<input message="Enter sud/su2 private signing key file:" addproperty="release.privkey"/>
<fail message="You must enter an existing file path.">
<condition>
<or>
<equals arg1="${release.privkey}" arg2=""/>
<not>
<length file="${release.privkey}" when="greater" length="0"/>
</not>
</or>
</condition>
</fail>
<echo message="Key file is ${release.privkey}"/>
<java classname="net.i2p.crypto.TrustedUpdate" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<arg value="sign"/>
<arg value="@{infile}"/>
<arg value="@{outfile}"/>
<arg value="${release.privkey}"/>
<arg value="${release.number}"/>
</java>
<echo message="Verify version and VALID signature:"/>
<java classname="net.i2p.crypto.TrustedUpdate" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<arg value="verifysig"/>
<arg value="@{outfile}"/>
</java>
<java classname="net.i2p.crypto.TrustedUpdate" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<arg value="verifyversion"/>
<arg value="@{outfile}"/>
</java>
<java classname="net.i2p.crypto.TrustedUpdate" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<arg value="showversion"/>
<arg value="@{outfile}"/>
</java>
</sequential>
</macrodef>
<macrodef name="su3sign">
<attribute name="infile"/>
<attribute name="outfile"/>
<attribute name="sigtype"/>
<attribute name="su3.ver"/>
<sequential>
<input message="Enter su3 private signing key store:" addproperty="release.privkey.su3"/>
<fail message="You must enter an existing file path.">
<condition>
<or>
<equals arg1="${release.privkey.su3}" arg2=""/>
<not>
<length file="${release.privkey.su3}" when="greater" length="0"/>
</not>
</or>
</condition>
</fail>
<input message="Enter su3 key name ([email protected]):" addproperty="release.signer.su3"/>
<fail message="You must enter a name.">
<condition>
<equals arg1="${release.signer.su3}" arg2=""/>
</condition>
</fail>
<input message="Enter su3 key password for ${release.signer.su3}:" addproperty="release.password.su3"/>
<fail message="You must enter a password.">
<condition>
<equals arg1="${release.password.su3}" arg2=""/>
</condition>
</fail>
<java classname="net.i2p.crypto.SU3File" inputstring="${release.password.su3}" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<arg value="sign"/>
<arg value="-c"/>
<arg value="@{sigtype}"/>
<arg value="-t"/>
<arg value="RSA_SHA512_4096"/>
<arg value="@{infile}"/>
<arg value="@{outfile}"/>
<arg value="${release.privkey.su3}"/>
<arg value="@{su3.ver}"/>
<arg value="${release.signer.su3}"/>
</java>
<echo message="Verify version and VALID signature:"/>
<java classname="net.i2p.crypto.SU3File" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<!-- set base dir so it can find the pubkey cert -->
<jvmarg value="-Di2p.dir.base=installer/resources"/>
<arg value="verifysig"/>
<arg value="@{outfile}"/>
</java>
<java classname="net.i2p.crypto.SU3File" fork="true" failonerror="true">
<classpath>
<pathelement location="build/i2p.jar"/>
</classpath>
<!-- set base dir so it can find the pubkey cert -->
<jvmarg value="-Di2p.dir.base=installer/resources"/>
<arg value="showversion"/>
<arg value="@{outfile}"/>
</java>
</sequential>
</macrodef>
<target name="dist" depends="pkg, javadoc"/>
<target name="dist200" depends="pkg200, javadoc"/>
<target name="build" depends="build2">
<!-- so we don't build standalone for the updater
This builds apps/i2psnark/java/i2psnark-standalone.zip
<ant dir="apps/i2psnark/java/" target="standalone"/>
-->
</target>
<target name="build2" depends="builddep, jar, buildWEB, bundleTranslationReport"/>
<target name="buildSmall" depends="builddepSmall, jarSmall, buildWEB"/>
<target name="buildclean" depends="distclean, build"/>
<target name="builddep" depends="builddepSmall, buildSAM, buildSusiMail, buildSusiDNS, buildI2PSnark, buildI2PControl"/>
<target name="builddepSmall" depends="buildrouter, buildSystray, buildDesktopGui, buildRouterConsole, buildStreaming, buildI2PTunnel, buildAddressbook, buildPack200"/>
<!--
start of buildX, one for each sub-build.xml.
Do not put ant tasks in the sub-build.xmls anymore, so the build will go faster.
-->
<target name="-setepoch">
<exec executable="date" outputproperty="epoch" errorproperty="dc.error" failifexecutionfails="true">
<arg value="+%s"/>
</exec>
<echo message="Epoch is: ${epoch}"/>
</target>
<target name="buildSAM" depends="buildMinistreaming">
<ant dir="apps/sam/java/" target="jar"/>
<copy quiet="true" file="apps/sam/java/build/sam.jar" todir="build/"/>
</target>
<target name="buildSusiMail" depends="buildCore, buildJetty">
<ant dir="apps/susimail/" target="war"/>
<copy quiet="true" file="apps/susimail/susimail.war" todir="build/"/>
</target>
<!-- jar (not war) for testing only -->
<target name="buildSusiMailJar" depends="buildCore, buildJetty">
<ant dir="apps/susimail/" target="jar"/>
<copy quiet="true" file="apps/susimail/susimail.jar" todir="build/"/>
</target>
<target name="buildSusiDNS" depends="buildCore, buildJetty, buildImagegen, buildAddressbook">
<ant dir="apps/susidns/src" target="all"/>
<copy quiet="true" file="apps/susidns/src/susidns.war" todir="build/"/>
</target>
<target name="buildImagegen" depends="buildCore, buildJetty">
<ant dir="apps/imagegen" target="build"/>
<copy quiet="true" file="apps/imagegen/imagegen/build/imagegen.war" todir="build/"/>
</target>
<target name="buildI2PControl" depends="buildRouter, buildJetty">
<ant dir="apps/i2pcontrol" target="war"/>
<copy quiet="true" file="apps/i2pcontrol/build/jsonrpc.war" todir="build/"/>
</target>
<target name="buildI2PSnark" depends="buildMinistreaming, buildJetty, buildSystray">
<ant dir="apps/i2psnark/java/" target="war"/>
<copy quiet="true" file="apps/i2psnark/i2psnark.war" todir="build/"/>
<copy quiet="true" file="apps/i2psnark/java/build/i2psnark.jar" todir="build/"/>
</target>
<!-- jar (not war) for Android -->
<target name="buildAddressbookJar" depends="buildCore">
<ant dir="apps/addressbook/" target="jar"/>
<copy quiet="true" file="apps/addressbook/dist/addressbook.jar" todir="build/"/>
</target>
<target name="buildAddressbook" depends="buildCore">
<ant dir="apps/addressbook/" target="all"/>
<copy quiet="true" file="apps/addressbook/dist/addressbook.jar" todir="build/"/>
<!-- war is empty, only for updates -->
<copy quiet="true" file="apps/addressbook/dist/addressbook.war" todir="build/"/>
</target>
<!-- Both jars and no war, for Android -->
<target name="buildI2PTunnelJars" depends="buildStreaming">
<ant dir="apps/i2ptunnel/java/" target="uiJar"/>
<copy quiet="true" file="apps/i2ptunnel/java/build/i2ptunnel.jar" todir="build/"/>
<copy quiet="true" file="apps/i2ptunnel/java/build/i2ptunnel-ui.jar" todir="build/"/>
</target>
<target name="buildI2PTunnel" depends="buildMinistreaming, buildJetty, buildImagegen">
<ant dir="apps/i2ptunnel/java/" target="build"/>
<copy quiet="true" file="apps/i2ptunnel/java/build/i2ptunnel.jar" todir="build/"/>
<copy quiet="true" file="apps/i2ptunnel/java/build/i2ptunnel.war" todir="build/"/>
</target>
<target name="buildDesktopGui" depends="buildCore, buildrouter, buildSystray">
<ant dir="apps/desktopgui" target="jar"/>
<copy quiet="true" file="apps/desktopgui/dist/desktopgui.jar" todir="build/"/>
</target>
<target name="buildRouterConsole" depends="buildrouter, buildSystray, buildDesktopGui, buildJetty, buildJrobin">
<ant dir="apps/routerconsole/java/" target="jar"/>
</target>
<!-- newsxml.jar only (subset of routerconsole, no war) for Android -->
<target name="buildNewsXMLJar" depends="buildRouter">
<ant dir="apps/routerconsole/java/" target="newsxmljar"/>
</target>
<target name="buildJetty" depends="buildCore">
<ant dir="apps/jetty" target="build"/>
<copy quiet="true" todir="build/">
<fileset dir="apps/jetty/jettylib" excludes="ant.jar,jspc.jar"/>
</copy>
</target>
<target name="buildSystray" depends="buildCore">
<ant dir="apps/systray/java/" target="jar"/>
<copy quiet="true" file="apps/systray/java/build/systray.jar" todir="build/"/>
</target>
<target name="buildStreaming" depends="buildMinistreaming">
<ant dir="apps/streaming/java/" target="jar"/>
<copy quiet="true" file="apps/streaming/java/build/streaming.jar" todir="build/"/>
</target>
<target name="buildMinistreaming" depends="buildCore">
<ant dir="apps/ministreaming/java/" target="jar"/>
<copy quiet="true" file="apps/ministreaming/java/build/mstreaming.jar" todir="build/"/>
</target>
<target name="buildRouter" depends="buildrouter"/>
<target name="buildrouter" depends="buildCore">
<ant dir="router/java/" target="jar"/>
<copy quiet="true" file="router/java/build/router.jar" todir="build/"/>
</target>
<target name="buildCore" depends="buildProperties">
<ant dir="core/java/" target="jar"/>
<copy quiet="true" file="core/java/build/i2p.jar" todir="build/"/>
</target>
<target name="buildJrobin" depends="buildProperties">
<ant dir="apps/jrobin/java/" target="jar"/>
<copy quiet="true" file="apps/jrobin/java/build/jrobin.jar" todir="build/"/>
</target>
<!-- not required, jrobin handles this -->
<target name="buildJFreeSVG" depends="buildProperties">
<ant dir="apps/jrobin/java/src/org/jfree/svg/" target="jar"/>
<copy quiet="true" file="apps/jrobin/java/src/org/jfree/svg/build/jfreesvg.jar" todir="build/"/>
</target>
<target name="buildPack200" depends="buildProperties">
<ant dir="apps/pack200/java/" target="jar"/>
<copy quiet="true" file="apps/pack200/java/build/pack200.jar" todir="build/"/>
</target>
<target name="buildProperties" depends="getGitRev, getReleaseNumber, getBuildNumber, setBuildTimestamp, disableManifestClasspath">
<antversion property="antversion"/>
<fail message="FATAL: Minimum Ant version is ${ant.minimumVersion} - your Ant version is ${antversion}">
<condition>
<not>
<antversion atleast="${ant.minimumVersion}"/>
</not>
</condition>
</fail>
<!-- default if not set above -->
<property name="workspace.version" value="unknown"/>
<!-- default if not set by setBuildTimestamp -->
<property name="build.timestamp" value="reproducible"/>
<!-- default if not set by disableManifestClasspath -->
<property name="manifest.classpath.name" value="Class-Path"/>
<property name="full.version" value="${release.number}-${i2p.build.number}${build.extra}"/>
<echo message="Ant: ${ant.version}"/>
<echo message="JDK: ${java.vendor} ${java.version} (${java.runtime.name} ${java.runtime.version})"/>
<echo message="Build: I2P+ version ${full.version} (revision ${workspace.version})"/>
</target>
<target name="setBuildTimestamp" unless="${build.reproducible}">
<tstamp>
<format property="build.timestamp" pattern="yyyy-MM-dd HH:mm:ss z" timezone="UTC" locale="en"/>
</tstamp>
</target>
<!-- Disable Class-Path in jar manifests by renaming it (Fedora) -->
<target name="disableManifestClasspath" if="${without-manifest-classpath}">
<property name="manifest.classpath.name" value="Disabled-Class-Path"/>
</target>
<target name="buildWEB" depends="buildRouterConsole">
<copy quiet="true" file="apps/routerconsole/java/build/routerconsole.jar" todir="build/"/>
<copy quiet="true" file="apps/routerconsole/java/build/routerconsole.war" todir="build/"/>
</target>
<target name="buildTools" depends="buildrouter">
<ant dir="installer/tools/java" target="jar"/>
<copy quiet="true" file="installer/tools/java/build/tools.jar" todir="build/"/>
</target>
<!-- end of sub-build.xml targets -->
<!-- git targets -->
<target name="checkForGit">
<available property="git.available" file=".git" type="dir"/>
</target>
<target name="getGitRev" depends="checkForGit" if="git.available">
<exec executable="git" outputproperty="workspace.version" errorproperty="git.error1" failifexecutionfails="false">
<arg value="rev-parse"/>
<arg value="--short=8"/>
<arg value="HEAD"/>
</exec>
<echo message="Current I2P+ Git revision in workspace: ${workspace.version}"/>
<echo message="Note: local workspace changes may vary from the latest revision"/>
</target>
<target name="getGitRevLong" depends="checkForGit" if="git.available">
<exec executable="git" outputproperty="workspace.version" errorproperty="git.error1" failifexecutionfails="false">
<arg value="rev-parse"/>
<arg value="HEAD"/>
</exec>
<echo message="Current I2P+ Git revision in workspace: ${workspace.version}"/>
<echo message="Note: local workspace changes may vary from the latest revision"/>
</target>
<target name="checkIfBumpedGit" depends="checkForGit" if="git.available">
<exec executable="git" outputproperty="bumped" errorproperty="git.error2" failifexecutionfails="false">
<arg value="status"/>
<arg value="-s"/>
<arg value="--porcelain"/>
<arg value="router/java/src/net/i2p/router/RouterVersion.java"/>
</exec>
<condition property="bumped.already">
<not>
<equals arg1="${bumped}" arg2=""/>
</not>
</condition>
</target>
<!-- If both present, only mtn will run -->
<target name="checkoutFromGit" depends="checkForGit" if="git.available" unless="mtn.available">
<echo message="Checking out fresh copy into ${checkoutDir}"/>
<delete dir="${checkoutDir}"/>
<exec executable="git" failonerror="true">
<arg value="clone"/>
<arg value="-l"/>
<arg value="."/>
<arg value="${checkoutDir}"/>
</exec>
</target>
<target name="revisionsGit" depends="checkForGit, getReleaseNumber, getBuildNumber" if="git.available" unless="mtn.available">
<!-- git log i2p-0.9.xx | grep '^Author:' | cut -d ' ' -f 2- | sort | uniq -c | sort -rn -->
<exec executable="git" outputproperty="getrevisions1" errorproperty="reverror1" failifexecutionfails="true">
<arg value="log"/>
<arg value="i2p-${release.number}..HEAD"/>
</exec>
<exec executable="grep" inputstring="${getrevisions1}" outputproperty="getrevisions2" failifexecutionfails="true">
<arg value="^Author:"/>
</exec>
<exec executable="cut" inputstring="${getrevisions2}" outputproperty="getrevisions3" failifexecutionfails="true">
<arg value="-d"/>
<arg value=" "/>
<arg value="-f"/>
<arg value="2-"/>
</exec>
<exec executable="sort" inputstring="${getrevisions3}" outputproperty="getrevisions4" failifexecutionfails="true"></exec>
<exec executable="uniq" inputstring="${getrevisions4}" outputproperty="getrevisions5" failifexecutionfails="true">
<arg value="-c"/>
</exec>
<exec executable="sort" inputstring="${getrevisions5}" outputproperty="getrevisions6" failifexecutionfails="true">
<arg value="-rn"/>
</exec>
<echo message="Revisions since ${release.number}:"/>
<echo message="${getrevisions6}"/>
</target>
<!-- end git targets -->
<!-- combined mtn/git targets -->
<target name="checkForVCS" depends="checkForGit"/>
<target name="failIfNoVCS" depends="checkForVCS">
<fail message="This target cannot be used without Monotone or Git!">
<condition>
<not>
<or>
<isset property="git.available"/>
</or>
</not>
</condition>
</fail>
</target>
<target name="trimRev" depends="getGitRev">
<exec executable="cut" inputstring="${workspace.version}" outputproperty="shortHash" errorproperty="cut.error1" failifexecutionfails="true">
<arg value="-c"/>
<arg value="1-8"/>
</exec>
<echo message="Short Git revision is: ${shortHash}"/>
</target>
<target name="checkIfBumped" depends="failIfNoVCS, checkIfBumpedGit"/>
<target name="bump" depends="bumpBuild"/>
<target name="bumpBuild" depends="checkIfBumped, getBuildNumber" unless="bumped.already">
<exec executable="dc" outputproperty="new.i2p.build.number" errorproperty="dc.error" failifexecutionfails="true">
<arg value="-e"/>
<arg value="${i2p.build.number} 1 + n"/>
</exec>
<echo message="Build number is now: ${new.i2p.build.number}${build.extra}"/>
<replaceregexp byline="true" file="router/java/src/net/i2p/router/RouterVersion.java"
match='(^\s+public\s+final\s+static\s+long\s+BUILD\s+=\s+)[0-9]+;' replace='\1${new.i2p.build.number};'/>
</target>
<target name="bumpBuildTime">
<exec executable="date" outputproperty="new.today" errorproperty="bt.error" failifexecutionfails="true">
<arg value="-u"/>
<arg value="+%Y-%m-%d"/>
</exec>
<exec executable="date" outputproperty="new.today.secs" errorproperty="bt.error2" failifexecutionfails="true">
<arg value="-u"/>
<arg value="-d"/>
<arg value="${new.today}"/>
<arg value="+%s"/>
</exec>
<echo message="Today is: ${new.today} ${new.today.secs}"/>
<replaceregexp byline="true" file="core/java/src/net/i2p/time/BuildTime.java"
match='(^\s+private\s+static\s+final\s+String\s+EARLIEST\s+=\s+)"[0-9A-Z: -]+";' replace='\1"${new.today} 12:00:00 UTC";'/>
<replaceregexp byline="true" file="core/java/src/net/i2p/time/BuildTime.java"
match='(^\s+private\s+static\s+final\s+long\s+EARLIEST_LONG\s+=\s+)[0-9]+ \* 1000L;' replace='\1${new.today.secs} * 1000L;'/>
</target>
<!-- If both present, only mtn will run -->
<target name="checkoutFromVCS" depends="failIfNoVCS, checkoutFromGit"/>
<!-- If both present, only mtn will run -->
<target name="revisions" depends="failIfNoVCS, revisionsGit"/>
<!-- end combined mtn/git targets -->
<!-- launch4j targets -->
<condition property="noExe">
<not>
<!-- We only have launch4j binaries for the following systems -->
<and>
<or>
<os arch="x86"/>
<os arch="i386"/>
<os arch="i586"/>
<os arch="i686"/>
<os arch="amd64"/>
<os arch="x86_64"/>
</or>
<or>
<os name="Linux"/>
<os family="windows"/>
</or>
</and>
</not>
</condition>
<!-- this makes an empty build/launchi2p.jar and the build/i2p.exe for the no-wrapper windows startup, if possible -->
<target name="buildexe" depends="buildProperties, launch4j" unless="noExe">
<echo message="See the file 'build.properties' if this step fails."/>
<jar destfile="./build/launchi2p.jar">
<manifest>
<attribute name="Main-Class" value="net.i2p.router.RouterLaunch"/>
<attribute name="Class-Path" value="lib/commons-el.jar lib/desktopgui.jar lib/i2p.jar lib/i2psnark.jar lib/i2ptunnel.jar lib/jasper-runtime.jar lib/javax.servlet.jar lib/jbigi.jar lib/jetty-continuation.jar lib/jetty-deploy.jar lib/jetty-http.jar lib/jetty-i2p.jar lib/jetty-io.jar lib/jetty-rewrite-handler.jar lib/jetty-security.jar lib/jetty-servlet.jar lib/jetty-servlets.jar lib/jetty-start.jar lib/jetty-util.jar lib/jetty-webapp.jar lib/jetty-xml.jar lib/jrobin.jar lib/jstl.jar lib/mstreaming.jar lib/org.mortbay.jetty.jar lib/pack200.jar lib/routerconsole.jar lib/router.jar lib/sam.jar lib/standard.jar lib/streaming.jar lib/systray.jar lib/wrapper.jar"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
</manifest>
</jar>
<!-- now the standalone launcher exe -->
<launch4j configFile="./installer/i2pstandalone.xml"/>
<!-- thazzit -->
</target>
<target name="launch4j">
<taskdef name="launch4j"
classname="net.sf.launch4j.ant.Launch4jTask"
classpath="${basedir}/installer/lib/launch4j/launch4j.jar:${basedir}/installer/lib/launch4j/lib/xstream.jar"/>
</target>
<!-- end launch4j targets -->
<!-- the files are now copied to the build directory in the build* targets -->
<target name="jar" depends="jarSmall"/>
<target name="jarSmall" depends="builddepSmall"/>
<!-- Custom target to collect the jars that I2P-Bote needs to compile, so it can compile from source. -->
<target name="jarBote" depends="buildRouter, buildStreaming, buildJetty">
<copy quiet="true" file="apps/susidns/src/lib/jstl.jar" todir="build/"/>
<copy quiet="true" file="apps/susidns/src/lib/standard.jar" todir="build/"/>
</target>
<!-- jbigi targets -->
<target name="jbigi" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<mkdir dir="./build"/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*.so *.dll *.jnilib"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-nowindows" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<delete file="build/jbigi.jar" failonerror="false" quiet="true"/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*.so *.jnilib"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<!-- Now system-specific jbigis in alphabetical order -->
<target name="jbigi-freebsd-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*bsd*.so"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-linux-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*linux*.so"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-linux-x86-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*linux*.so" excludes="*linux-arm*.so,*linux-ppc*.so"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-linux-x86-64-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*linux*_64.so libjcpuid-x86_64-linux.so" excludes="*linux-arm*.so,*linux-ppc*.so"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-linux-nonx86-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*linux-arm*.so,*linux-ppc*.so"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-osx-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*.jnilib"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<target name="jbigi-windows-only" depends="buildProperties">
<!-- Set if unset -->
<property name="workspace.changes.jbigi.tr" value=""/>
<delete file="build/jbigi.jar" failonerror="false" quiet="true"/>
<jar destfile="build/jbigi.jar" whenmanifestonly="fail">
<fileset dir="installer/lib/jbigi" includes="*windows*.dll"/>
<manifest>
<attribute name="Implementation-Version" value="${full.version}"/>
<attribute name="Built-By" value="${build.built-by}"/>
<attribute name="Build-Date" value="${build.timestamp}"/>
<attribute name="Base-Revision" value="${workspace.version}"/>
<attribute name="Workspace-Changes" value="${workspace.changes.jbigi.tr}"/>
</manifest>
</jar>
</target>
<!-- end jbigi targets -->
<target name="poupdate-source" depends="set-lg2-en, poupdate"/>
<target name="set-lg2-en">
<property name="lg2" value="en"/>
</target>
<!-- the apps need to compile the jsps to poupdate -->
<target name="poupdate" depends="buildRouter, buildStreaming, buildSystray, buildJetty, buildDesktopGui, buildJrobin">
<echo message="Setting environment variable LG2 to a language code (e.g. de)"/>
<echo message="will restrict language update to the language you specified, leaving other languages unchanged."/>
<!-- Set if unset -->
<property name="lg2" value=""/>
<parallel>
<ant dir="core/java/" target="poupdate"/>
<ant dir="router/java/" target="poupdate"/>
<ant dir="apps/routerconsole/java/">
<target name="poupdate"/>
<target name="poupdate-news"/>
<target name="poupdate-countries"/>
</ant>
<ant dir="apps/i2psnark/java/" target="poupdate"/>
<ant dir="apps/i2ptunnel/java/">
<target name="poupdate"/>
<target name="poupdate-proxy"/>
</ant>
<ant dir="apps/susidns/src/" target="poupdate"/>
<ant dir="apps/susimail/" target="poupdate"/>
<ant dir="apps/desktopgui" target="poupdate"/>
<ant dir="installer/resources/locale" target="poupdate"/>
<ant dir="apps/ministreaming/java" target="poupdate"/>
</parallel>
</target>
<condition property="no.bundle">
<isfalse value="${require.gettext}"/>
</condition>
<target name="prep-script-translation" unless="no.bundle">
<!-- script translation added in 0.8.13, enabled in 0.9.5. -->
<ant dir="installer/resources/locale" target="bundle"/>
<copy quiet="true" todir="pkg-temp/locale/">
<fileset dir="installer/resources/locale/mo/"/>
</copy>
</target>
<target name="javadoc" depends="getReleaseNumber, getBuildNumber">
<echo message="JDK: ${java.vendor} ${java.version} (${java.runtime.name} ${java.runtime.version})"/>
<ant dir="apps/jetty" target="ensureJettylib"/>
<mkdir dir="./build"/>
<mkdir dir="./build/javadoc"/>
<copy quiet="true" file="./installer/resources/eepsite/docroot/favicon.ico" tofile="./build/javadoc/favicon.ico"/>
<!-- Set if unset -->
<property name="javac.version" value="1.8"/>
<javadoc access="package"
source="${javac.version}"
destdir="./build/javadoc"
packagenames="*"
use="true"
splitindex="true"
failonerror="false"
charset="utf-8"
additionalparam="-notimestamp -stylesheetFile ./javadoc.css -quiet"
doctitle="I2P+ Javadocs [${release.number}-${i2p.build.number}${build.extra}]"
windowtitle="Javadocs [I2P+ ${release.number}+] - API Version ${api.version}+">
<group title="Core SDK (i2p.jar)" packages="net.i2p:net.i2p.*:net.i2p.client:net.i2p.client.*:net.i2p.internal:net.i2p.internal.*:freenet.support.CPUInformation:gnu.crypto.*:gnu.getopt:gnu.gettext:com.nettgryppa.security:net.i2p.apache.http.conn.ssl:net.i2p.apache.http.conn.util:net.i2p.apache.http.util:org.json.simple:com.southernstorm.noise.crypto.x25519:com.southernstorm.noise.crypto.chacha20:org.minidns:org.minidns.*"/>
<group title="Streaming Library" packages="net.i2p.client.streaming:net.i2p.client.streaming.impl"/>
<group title="Router" packages="net.i2p.router:net.i2p.router.*:net.i2p.data.i2np:net.i2p.data.router:org.cybergarage:org.cybergarage.*:org.freenetproject:org.xlattice.crypto.filters:com.maxmind.*:com.southernstorm.noise.*"/>
<group title="Router Console" packages="net.i2p.router.web:net.i2p.router.web.*:net.i2p.router.update:edu.internet2.ndt:net.i2p.router.news:com.vuze.*"/>
<!-- apps and bridges starting here, alphabetical please -->
<group title="Addressbook Application" packages="net.i2p.addressbook:net.i2p.router.naming:net.metanotion:net.metanotion.*"/>
<group title="Desktopgui Application" packages="net.i2p.desktopgui:net.i2p.desktopgui.*"/>
<group title="I2PControl Application" packages="net.i2p.i2pcontrol:net.i2p.i2pcontrol.*:org.mindrot.jbcrypt:com.thetransactioncompany.jsonrpc2:com.thetransactioncompany.jsonrpc2.*"/>
<group title="I2PSnark Application" packages="org.klomp.snark:org.klomp.snark.*"/>
<group title="I2PTunnel Application" packages="net.i2p.i2ptunnel:net.i2p.i2ptunnel.*"/>
<group title="Imagegen Application" packages="com.docuverse.identicon:com.google.zxing:com.google.zxing.*:net.i2p.imagegen"/>
<group title="Installer Utilities" packages="net.i2p.installer"/>
<group title="Jetty Utilities" packages="net.i2p.jetty:net.i2p.servlet:net.i2p.servlet.*"/>
<group title="RRD4J Library (jrobin.jar)" packages="org.rrd4j:org.rrd4j.*:com.tomgibara.crinch.hashing:eu.bengreen.data.utility"/>
<group title="SAM Bridge" packages="net.i2p.sam"/>
<group title="SAM Demos" packages="net.i2p.sam.client"/>
<group title="SusiDNS Application" packages="i2p.susi.dns:net.i2p.addressbook.servlet"/>
<group title="SusiMail Application" packages="i2p.susi.webmail:i2p.susi.webmail.*:i2p.susi.debug:i2p.susi.util"/>
<group title="Systray Application" packages="net.i2p.apps.systray"/>
<sourcepath>
<pathelement location="apps/addressbook/java/src"/>
<pathelement location="apps/desktopgui/src"/>
<pathelement location="apps/i2pcontrol/java"/>
<pathelement location="apps/i2psnark/java/src"/>
<pathelement location="apps/i2ptunnel/java/src"/>
<pathelement location="apps/imagegen/identicon/core/src/main/java"/>
<pathelement location="apps/imagegen/imagegen/webapp/src/main/java"/>
<pathelement location="apps/imagegen/zxing/core/src/main/java"/>
<pathelement location="apps/imagegen/zxing/javase/src/main/java"/>
<pathelement location="apps/jetty/java/src"/>
<pathelement location="apps/jrobin/java/src"/>
<pathelement location="apps/ministreaming/java/src"/>
<pathelement location="apps/routerconsole/java/src"/>
<pathelement location="apps/sam/java/src"/>
<pathelement location="apps/streaming/java/src"/>
<pathelement location="apps/susidns/src/java/src"/>
<pathelement location="apps/susimail/src/src"/>
<pathelement location="apps/systray/java/src"/>
<pathelement location="core/java/src"/>
<pathelement location="installer/java/src"/>