1<?xml version="1.0"?> 2 3<project name="j3d-1.5.2" default="jar-debug" basedir="."> 4 5 <!-- 6 ********************************************************************* 7 * 8 * The following properties may be set on the command line to 9 * specify the compiler used or the renderer to be built. They are 10 * specified using "ant -Dprop.name=value", where the actual 11 * property and and value are substituted for "prop.name" and 12 * "value" 13 * 14 * build.comp=gcc Use GCC compilers (default, all platforms) 15 * build.comp=forte Use Forte compilers (Solaris only) 16 * build.comp=vc Use Visual C++ compilers (Windows only) 17 * 18 * build.rend=ogl build OpenGL native library (default) 19 * build.rend=d3d build DirectX (D3D) native library 20 * 21 * For example: 22 * 23 * ant -Dbuild.comp=vc -Dbuild.rend=d3d ... 24 * 25 ********************************************************************* 26 --> 27 28 <!-- *************************************** --> 29 <!-- *** Begin build-specific properties *** --> 30 <!-- *************************************** --> 31 32 <!-- 33 * The following property specifies the build number of the current 34 * version of 3D being built. This build number is a monotonically 35 * increasing number that is incremented for each new stable, beta, 36 * fcs, or patch build. Each non-daily build will have a unique 37 * build number that is greater than the previous build's build 38 * number. 39 --> 40 <property name="version_buildnum" value="4"/> 41 42 <!-- 43 * The following property specifies the beta revision of the current 44 * version of 3D being built. It is ignored for non-beta builds. 45 --> 46 <property name="version_betastr" value="beta3"/> 47 48 <!-- 49 * The following property specifies the patch revision of the current 50 * version of 3D being built. It is ignored for non-beta builds. 51 --> 52 <property name="version_patchstr" value="01"/> 53 54 <!-- 55 * The following properties specify the current version of 3D. 56 * The "version_base" property specifies the dot-dot base version 57 * number of 3D; it must contain exactly three integer numbers 58 * separated by "periods ("."). The version_base_file property must 59 * be the same version number as version_base with "_" replacing ".". 60 --> 61 <property name="version_base" value="1.5.2"/> 62 <property name="version_base_file" value="1_5_2"/> 63 64 65 <!-- ************************************* --> 66 <!-- *** End build-specific properties *** --> 67 <!-- ************************************* --> 68 69 <!-- 70 ********************************************************************* 71 * 72 * A build of j3d is one of the following five types: daily 73 * build, stable build, beta build (or release candidate), fcs build, 74 * patch build. Daily builds are identified with a "-preN-YYMMDDHHMM" 75 * suffix; stable builds are identified with a "-buildN" suffix; beta 76 * builds are identified with a "-betaN" or "-rcN" suffix; fcs builds 77 * have no suffix; and patch builds are identified with an "_N" 78 * suffix. 79 * 80 * The default is to do a daily build. This may be overriden by setting 81 * the build.type property on the command line to do a different kind 82 * of build: 83 * 84 * build.type=daily Do a daily build (default) 85 * build.type=stable Do a stable build : -buildN 86 * build.type=beta Do a beta or RC production build : -betaN or -rcN 87 * build.type=fcs Do an FCS production build : [no suffix] 88 * build.type=patch Do an FCS+patch production build : _PP 89 * 90 * For example: 91 * 92 * ant -Dbuild.type=stable ... 93 * 94 ********************************************************************* 95 --> 96 97 <!-- Set global properties for this build --> 98 <property name="vecmath_home" location="../vecmath"/> 99 <property name="core_utils_home" location="../j3d-core-utils"/> 100 101 <property name="src" location="src"/> 102 <property name="vecmath_src" location="${vecmath_home}/src"/> 103 <property name="core_utils_src" location="${core_utils_home}/src"/> 104 <property name="build-tools" location="build-tools"/> 105 <property name="build" location="build"/> 106 <property name="dist" location="dist"/> 107 <property name="build.comp" value="gcc"/> 108 <property name="build.rend" value="ogl"/> 109 110 <property name="build.spec.title" value="3D Graphics API for the Java Platform"/> 111 <property name="build.impl.title" value="3D Graphics API for the Java Platform"/> 112 <property name="build.spec.vendor" value=""/> 113 <property name="build.impl.vendor" value=""/> 114 <property name="build.impl.vendor.id" value=""/> 115 <property name="build.javadoc.name" value="3D"/> 116 <property name="build.relprefix" value="j3d"/> 117 118 <target name="echo" depends="setupPlatform"> 119 <echo message="platform = ${platform}"/> 120 <echo message="wstype = ${wstype}"/> 121 <echo message="os.arch = ${os.arch}"/> 122 <echo message="os.name = ${os.name}"/> 123 <echo message="ant.home = ${ant.home}"/> 124 <echo message="java.home = ${java.home}"/> 125 <echo message="core_utils_home = ${core_utils_home}"/> 126 <echo message="vecmath_home = ${vecmath_home}"/> 127 <echo message="user.name = ${user.name}"/> 128 <echo message="user.home = ${user.home}"/> 129 130 <echo message=""/> 131 <echo message="build.type = ${build.type}"/> 132 <echo message="build.rend = ${build.rend}"/> 133 <echo message="build.comp = ${build.comp}"/> 134 <echo message="is_dev_phase = ${is_dev_phase}"/> 135 <echo message="is_production = ${is_production}"/> 136 <echo message="use_verbose_buildtime = ${use_verbose_buildtime}"/> 137 138 <echo message="version_build = ${version_build}"/> 139 <echo message="version_suffix = ${version_suffix}"/> 140 141 <echo message="version = ${version}"/> 142 <echo message="version_file = ${version_file}"/> 143 </target> 144 145 <target name="setupFreeBSD" if="isDragonFly"> 146 <property name="isUnix" value="true"/> 147 <property name="shell" value="/bin/sh"/> 148 <property name="wstype" value="x11"/> 149 <property name="platformname" value="freebsd-${os.arch}"/> 150 <property name="platform" value="freebsd"/> 151 <property name="install.bin" value="lib/${os.arch}"/> 152 <property name="ports.localbase" value="/usr/local"/> 153 </target> 154 155 <target name="setupSolaris" if="isSolarisOnSparc"> 156 <property name="isUnix" value="true"/> 157 <property name="shell" value="/usr/bin/ksh"/> 158 <property name="wstype" value="x11"/> 159 <property name="platformname" value="solaris-sparc"/> 160 <property name="platform" value="solaris-sparc-${build.comp}"/> 161 <property name="install.bin" value="lib/sparc"/> 162 </target> 163 164 <target name="setupSolarisX86" if="isSolarisOnX86"> 165 <property name="isUnix" value="true"/> 166 <property name="shell" value="/usr/bin/ksh"/> 167 <property name="wstype" value="x11"/> 168 <property name="platformname" value="solaris-x86"/> 169 <property name="platform" value="solaris-x86-${build.comp}"/> 170 <property name="install.bin" value="lib/i386"/> 171 </target> 172 173 <target name="setupLinux" if="isLinuxOnX86"> 174 <property name="isUnix" value="true"/> 175 <property name="shell" value="/bin/sh"/> 176 <property name="wstype" value="x11"/> 177 <property name="platformname" value="linux-i586"/> 178 <property name="platform" value="linux-i586"/> 179 <property name="install.bin" value="lib/i386"/> 180 </target> 181 182 <target name="setupLinuxAmd64" if="isLinuxOnAmd64"> 183 <property name="isUnix" value="true"/> 184 <property name="shell" value="/bin/sh"/> 185 <property name="wstype" value="x11"/> 186 <property name="platformname" value="linux-amd64"/> 187 <property name="platform" value="linux-amd64"/> 188 <property name="install.bin" value="lib/amd64"/> 189 </target> 190 191 <target name="setupLinuxIA64" if="isLinuxOnIA64"> 192 <property name="isUnix" value="true"/> 193 <property name="shell" value="/bin/sh"/> 194 <property name="wstype" value="x11"/> 195 <property name="platformname" value="linux-ia64"/> 196 <property name="platform" value="linux-ia64"/> 197 <property name="install.bin" value="lib/ia64"/> 198 </target> 199 200 <target name="setupLinuxPPC" if="isLinuxOnPPC"> 201 <property name="isUnix" value="true"/> 202 <property name="shell" value="/bin/sh"/> 203 <property name="wstype" value="x11"/> 204 <property name="platformname" value="linux-ppc"/> 205 <property name="platform" value="linux-ppc"/> 206 <property name="install.bin" value="lib/ppc"/> 207 </target> 208 209 <!-- win32 should be rename as windows --> 210 <target name="setupWindows" if="isWindowsOnX86"> 211 <property name="isWindows" value="true"/> 212 <property name="wstype" value="win32"/> 213 <property name="platformname" value="windows-i586"/> 214 <property name="platform" value="windows-i586-${build.comp}"/> 215 <property name="install.bin" value="bin"/> 216 </target> 217 218 <target name="setupWindowsAmd64" if="isWindowsOnAmd64"> 219 <property name="isWindows" value="true"/> 220 <property name="wstype" value="win32"/> 221 <property name="platformname" value="windows-amd64"/> 222 <property name="platform" value="windows-amd64-${build.comp}"/> 223 <property name="install.bin" value="bin"/> 224 </target> 225 226 <target name="setupMacOSX" if="isMacOSX"> 227 <property name="wstype" value="jogl"/> 228 <property name="platformname" value="macosx"/> 229 <property name="platform" value="macosx"/> 230 </target> 231 232 <target name="init-jogl" if="build.jogl"> 233 <property name="jogl.pipeline.srcdir" location="${src}/classes/jogl"/> 234 <echo message="Building JoglPipeline"/> 235 </target> 236 237 <target name="init-no-jogl" unless="build.jogl"> 238 <property name="jogl.pipeline.srcdir" value=""/> 239 </target> 240 241 <target name="setupJogl" depends="init-jogl,init-no-jogl"> 242 </target> 243 244 <target name="setupPlatform" 245 depends="init, setupBuildType, setupFreeBSD, setupSolaris, setupSolarisX86, setupLinux, setupLinuxAmd64, setupLinuxIA64, setupLinuxPPC, setupWindows, setupWindowsAmd64, setupMacOSX, setupJogl"> 246 <property name="build-debug-gen" location="${build}/${platform}/debug/gen"/> 247 <property name="build-opt-gen" location="${build}/${platform}/opt/gen"/> 248 <property name="docname" value="${build.relprefix}-${version_file}-doc"/> 249 </target> 250 251 252 <target name="setupBuildType" depends="initBuildType, setupBuildPatch, setupBuildFcs, setupBuildBeta, setupBuildStable, setupBuildDaily, checkBuildType"> 253 <echo message="build.type = ${build.type}"/> 254 </target> 255 256 <target name="initBuildType"> 257 <!-- Default value is "daily", overridden on command line --> 258 <property name="build.type" value="daily"/> 259 <property name="buildType_${build.type}" value="true"/> 260 </target> 261 262 263 <!-- Set properties for PATCH build --> 264 <target name="setupBuildPatch" if="buildType_patch"> 265 <property name="buildTypeSet" value="true"/> 266 267 <property name="releaseType_final" value="true"/> 268 <property name="is_dev_phase" value="false"/> 269 <property name="is_production" value="true"/> 270 <property name="use_verbose_buildtime" value="false"/> 271 272 <property name="version_build" value="build${version_buildnum}"/> 273 <property name="version_suffix" value="${version_patchstr}"/> 274 275 <property name="version" value="${version_base}_${version_suffix}"/> 276 <property name="version_file" value="${version_base_file}_${version_suffix}"/> 277 </target> 278 279 280 <!-- Set properties for FCS build --> 281 <target name="setupBuildFcs" if="buildType_fcs"> 282 <property name="buildTypeSet" value="true"/> 283 284 <property name="releaseType_final" value="true"/> 285 <property name="is_dev_phase" value="false"/> 286 <property name="is_production" value="true"/> 287 <property name="use_verbose_buildtime" value="false"/> 288 289 <property name="version_build" value="build${version_buildnum}"/> 290 <property name="version_suffix" value=""/> 291 292 <property name="version" value="${version_base}"/> 293 <property name="version_file" value="${version_base_file}"/> 294 </target> 295 296 297 <!-- Set properties for BETA build --> 298 <target name="setupBuildBeta" if="buildType_beta"> 299 <property name="buildTypeSet" value="true"/> 300 301 <property name="releaseType_milestone" value="true"/> 302 <property name="releaseType_dailyOrMilestone" value="true"/> 303 <property name="is_dev_phase" value="false"/> 304 <property name="is_production" value="true"/> 305 <property name="use_verbose_buildtime" value="true"/> 306 307 <property name="version_build" value="build${version_buildnum}"/> 308 <property name="version_suffix" value="${version_betastr}"/> 309 310 <property name="version" value="${version_base}-${version_suffix}"/> 311 <property name="version_file" value="${version_base_file}-${version_suffix}"/> 312 </target> 313 314 315 <!-- Set properties for STABLE build --> 316 <target name="setupBuildStable" if="buildType_stable"> 317 <property name="buildTypeSet" value="true"/> 318 319 <property name="releaseType_milestone" value="true"/> 320 <property name="releaseType_dailyOrMilestone" value="true"/> 321 <property name="is_dev_phase" value="true"/> 322 <property name="is_production" value="false"/> 323 <property name="use_verbose_buildtime" value="true"/> 324 325 <property name="version_build" value="build${version_buildnum}"/> 326 <property name="version_suffix" value="${version_build}"/> 327 328 <property name="version" value="${version_base}-${version_suffix}"/> 329 <property name="version_file" value="${version_base_file}-${version_suffix}"/> 330 </target> 331 332 333 <!-- Set properties for DAILY build --> 334 <target name="setupBuildDaily" if="buildType_daily"> 335 <property name="buildTypeSet" value="true"/> 336 337 <property name="releaseType_daily" value="true"/> 338 <property name="releaseType_dailyOrMilestone" value="true"/> 339 <property name="is_dev_phase" value="true"/> 340 <property name="is_production" value="false"/> 341 <property name="use_verbose_buildtime" value="true"/> 342 343 <property name="version_build" value="pre${version_buildnum}"/> 344 <property name="version_suffix" value="${version_build}"/> 345 346 <property name="version" value="${version_base}-${version_suffix}-${buildtime}"/> 347 <property name="version_file" value="${version_base_file}-${version_suffix}-${buildtime}"/> 348 </target> 349 350 351 <!-- Check buildType --> 352 <target name="checkBuildType" unless="buildTypeSet"> 353 <fail message="Unknown build.type = ${build.type}"/> 354 </target> 355 356 357 <target name="init"> 358 <!-- Create the time stamp --> 359 <tstamp> 360 <format property="buildtime_verbose" pattern="dd MMM yyyy HH:mm:ss z"/> 361 <format property="buildtime" pattern="yyMMddHHmm"/> 362 </tstamp> 363 364 <echo message="buildtime = ${buildtime_verbose}"/> 365 366 <!-- Create the base build directory --> 367 <mkdir dir="${build}"/> 368 369 <!-- ========== determine platform ========== --> 370 <condition property="isWindowsOnX86"> 371 <os family="windows" arch="x86"/> 372 </condition> 373 374 375 <condition property="isWindowsOnAmd64"> 376 <os family="windows" arch="amd64"/> 377 </condition> 378 379 <condition property="isLinuxOnX86"> 380 <os name="linux" arch="i386"/> 381 </condition> 382 383 <condition property="isLinuxOnAmd64"> 384 <os name="linux" arch="amd64"/> 385 </condition> 386 387 <condition property="isLinuxOnIA64"> 388 <os name="linux" arch="ia64"/> 389 </condition> 390 391 <condition property="isLinuxOnPPC"> 392 <os name="linux" arch="ppc"/> 393 </condition> 394 395 <condition property="isSolarisOnSparc"> 396 <os name="SunOS" arch="sparc"/> 397 </condition> 398 399 <condition property="isSolarisOnX86"> 400 <os name="SunOS" arch="x86"/> 401 </condition> 402 403 <condition property="isa_amd64"> 404 <contains string="${sun.cpu.isalist}" substring="amd64"/> 405 </condition> 406 407 <condition property="isMacOSX"> 408 <and> 409 <os family="mac"/> 410 <os family="unix"/> 411 </and> 412 </condition> 413 414 <available file="${java.home}/lib/amd64/libjawt.so" property="jre_amd64_present"/> 415 416 <!-- flag indicating that a 64-bit JVM is available for Solaris/x86 --> 417 <condition property="isSolarisOnX86_64"> 418 <and> 419 <isset property="isSolarisOnX86"/> 420 <isset property="isa_amd64"/> 421 <isset property="jre_amd64_present"/> 422 </and> 423 </condition> 424 425 </target> 426 427 <target name="compile-debug" depends="setupPlatform"> 428<!-- <ant dir="${vecmath_home}" target="jar-debug"/>--> 429 <ant dir="src/classes" target="compile-debug"/> 430 <antcall target="compile-debug-native"/> 431 </target> 432 433 <target name="compile-debug-native" unless="build.javaonly"> 434 <ant dir="src/native" target="compile-debug"/> 435 </target> 436 437 <target name="compile-opt" depends="setupPlatform"> 438<!-- <ant dir="${vecmath_home}" target="jar-opt"/>--> 439 <ant dir="src/classes" target="compile-opt"/> 440 <antcall target="compile-opt-native"/> 441 </target> 442 443 <target name="compile-opt-native" unless="build.javaonly"> 444 <ant dir="src/native" target="compile-opt"/> 445 </target> 446 447 <target name="compile" depends="compile-debug,compile-opt" /> 448 449 <target name="jar-debug" depends="compile-debug"> 450 <ant dir="src/classes" target="jar-debug"/> 451 </target> 452 453 <target name="jar-debug-javaonly"> 454 <property name="build.javaonly" value="true"/> 455 <antcall target="jar-debug"/> 456 </target> 457 458 <target name="jar-opt" depends="compile-opt"> 459 <ant dir="src/classes" target="jar-opt"/> 460 </target> 461 462 <target name="jar-opt-javaonly"> 463 <property name="build.javaonly" value="true"/> 464 <antcall target="jar-opt"/> 465 </target> 466 467 <target name="jar" depends="jar-debug,jar-opt" /> 468 469 <target name="docs-jcp" depends="setupPlatform"> 470 <ant dir="src/classes" target="docs-jcp"/> 471 </target> 472 473 <target name="docs-public" depends="setupPlatform" unless="nojavadoc"> 474 <ant dir="src/classes" target="docs-public"/> 475 </target> 476 477 <target name="docs-private" depends="setupPlatform"> 478 <ant dir="src/classes" target="docs-private"/> 479 </target> 480 481 <target name="docs" depends="setupPlatform"> 482 <ant dir="src/classes" target="docs"/> 483 </target> 484 485 <target name="setupCheckBuild" depends="setupPlatform"> 486 <available file="${build}/linux-i586/opt/lib/ext/j3dcore.jar" property="buildLinuxFilesExist"/> 487 <available file="${build}/windows-i586-vc/opt/lib/ext/j3dcore.jar" property="buildWindowsFilesExist"/> 488 </target> 489 490 <target name="checkBuildLinux" unless="buildLinuxFilesExist"> 491 <fail message="You must run the jar-opt target on Linux before running dist-common" /> 492 </target> 493 494 <target name="checkBuildWindows" unless="buildWindowsFilesExist"> 495 <fail message="You must run the jar-opt target on Windows before running dist-common" /> 496 </target> 497 498 <target name="checkBuildPlatform" unless="isLinuxOnX86"> 499 <fail message="You must run the dist-common target on linux-i586 platform" /> 500 </target> 501 502 <target name="checkBuild" depends="setupCheckBuild,checkBuildPlatform,checkBuildLinux,checkBuildWindows"> 503 </target> 504 505 <target name="dist-common" depends="setupPlatform,checkBuild"> 506 <ant dir="src/classes" target="dist-common"/> 507 </target> 508 509 <target name="setupCheckDist" depends="setupPlatform"> 510 <available file="${dist}/common/lib/ext/j3dcore.jar" property="distCommonFilesExist"/> 511 </target> 512 513 <target name="checkDistCommon" unless="distCommonFilesExist"> 514 <fail message="You must run the dist-common target before running dist" /> 515 </target> 516 517 <target name="checkDist" depends="setupCheckDist,checkDistCommon"> 518 </target> 519 520 <!-- NOTE: the dist target no longer depends on jar-opt; you must run the 521 jar-opt and dist-common (linux-only) targets prior to dist --> 522 <target name="dist" depends="setupPlatform,checkDist,src"> 523 <ant dir="src/classes" target="dist"/> 524 <ant dir="src/native" target="dist"/> 525 </target> 526 527 <!-- NOTE: the all target no longer depends on dist, which must be run separately --> 528 <target name="all" depends="jar,docs"/> 529 530 <target name="release" description="Package distribution for release" 531 depends="dist,init-release,release-daily,release-milestone,release-final"> 532 </target> 533 534 <target name="init-release"> 535 <property name="platformTmp" location="${dist}/${platform}/tmp"/> 536 <property name="platformTmpBund" location="${platformTmp}/bund"/> 537 <property name="platformTmpInst" location="${platformTmp}/inst"/> 538 <property name="release_name" value="${build.relprefix}-${version_file}-${platformname}"/> 539 <property name="inst_name" value="j3d-instfiles-${version_file}-${platformname}"/> 540 <mkdir dir="${dist}/release"/> 541 </target> 542 543 <target name="release-daily" depends="init-release,release-zip-bund-pre" if="releaseType_daily"> 544 </target> 545 546 <target name="release-zip-bund-pre" if="releaseType_dailyOrMilestone"> 547 <mkdir dir="${platformTmpBund}/${release_name}"/> 548 549 <zip destfile="${platformTmpBund}/${release_name}/j3d-jre.zip"> 550 <fileset dir="${dist}/${platform}" 551 includes="lib/**" 552 /> 553 <fileset dir="${dist}/${platform}" 554 includes="bin/**" 555 /> 556 </zip> 557 <copy todir="${platformTmpBund}/${release_name}"> 558 <fileset dir="." includes="COPYRIGHT.txt"/> 559 <fileset dir="release-info/pre-release" 560 includes="LICENSE*.txt README*.txt README-unzip.html" 561 /> 562 </copy> 563 <zip destfile="${dist}/release/${release_name}.zip"> 564 <fileset dir="${platformTmpBund}" 565 includes="${release_name}/**" 566 /> 567 </zip> 568 </target> 569 570 <target name="release-milestone" depends="init-release,release-zip-bund-pre,release-zip-inst-pre" if="releaseType_milestone"> 571 </target> 572 573 <target name="release-zip-inst-pre" if="releaseType_milestone"> 574 <antcall target="release-zip-inst-pre-unix"/> 575 <antcall target="release-zip-inst-pre-windows"/> 576 </target> 577 578 <target name="release-zip-inst-pre-unix" if="isUnix"> 579 <mkdir dir="${platformTmpInst}/${release_name}"/> 580 581 <copy todir="${platformTmpInst}/${release_name}"> 582 <fileset dir="${dist}/${platform}" 583 includes="lib/**"/> 584 <fileset dir="${dist}/${platform}" 585 includes="bin/**"/> 586 </copy> 587 588 <copy tofile="${platformTmpInst}/${release_name}/LICENSE.txt"> 589 <fileset dir="release-info/pre-release" 590 includes="LICENSE*.txt"/> 591 </copy> 592 593 <chmod dir="${platformTmpInst}/${release_name}" perm="755" 594 includes="**/*.so"/> 595 596 <copy todir="${platformTmpInst}"> 597 <fileset dir="${build-tools}/${platformname}" 598 includes="script*.txt, unzipsfx"/> 599 </copy> 600 601 <exec dir="${platformTmpInst}/${release_name}" executable="${shell}"> 602 <arg line="${build-tools}/genzip ${release_name} LICENSE.txt lib"/> 603 </exec> 604 605 <copy file="${platformTmpInst}/${release_name}.bin" todir="${dist}/release"/> 606 607 <chmod file="${dist}/release/${release_name}.bin" perm="755"/> 608 </target> 609 610 <target name="release-zip-inst-pre-windows" if="isWindows"> 611 <property name="tmpInstDir" location="${platformTmpInst}/${inst_name}"/> 612 <mkdir dir="${tmpInstDir}/j3d-binaries"/> 613 614 <copy todir="${tmpInstDir}"> 615 <fileset dir="release-info/pre-release" 616 includes="LICENSE*.rtf README.html"/> 617 </copy> 618 619 <copy todir="${tmpInstDir}/j3d-binaries"> 620 <fileset dir="${dist}/${platform}" 621 includes="lib/**"/> 622 <fileset dir="${dist}/${platform}" 623 includes="bin/**"/> 624 </copy> 625 626 <chmod dir="${tmpInstDir}/j3d-binaries" perm="755" 627 includes="**/*.dll"/> 628 629 <zip destfile="${dist}/release/${inst_name}.zip"> 630 <fileset dir="${platformTmpInst}" 631 includes="${inst_name}/**"/> 632 </zip> 633 </target> 634 635 <target name="release-final" depends="init-release,release-zip-bund-final,release-zip-inst-final" if="releaseType_final"> 636 </target> 637 638 <target name="release-zip-bund-final" if="releaseType_final"> 639 <mkdir dir="${platformTmpBund}/${release_name}"/> 640 641 <zip destfile="${platformTmpBund}/${release_name}/j3d-jre.zip"> 642 <fileset dir="${dist}/${platform}" 643 includes="lib/**" 644 /> 645 <fileset dir="${dist}/${platform}" 646 includes="bin/**" 647 /> 648 </zip> 649 <copy todir="${platformTmpBund}/${release_name}"> 650 <fileset dir="." includes="COPYRIGHT.txt"/> 651 <fileset dir="release-info/fcs-${version_base_file}" 652 includes="LICENSE*.txt README*.txt README-unzip.html" 653 /> 654 </copy> 655 <zip destfile="${dist}/release/${release_name}.zip"> 656 <fileset dir="${platformTmpBund}" 657 includes="${release_name}/**" 658 /> 659 </zip> 660 </target> 661 662 <target name="release-zip-inst-final" if="releaseType_final"> 663 <antcall target="release-zip-inst-final-unix"/> 664 <antcall target="release-zip-inst-final-windows"/> 665 </target> 666 667 <target name="release-zip-inst-final-unix" if="isUnix"> 668 <mkdir dir="${platformTmpInst}/${release_name}"/> 669 670 <copy todir="${platformTmpInst}/${release_name}"> 671 <fileset dir="${dist}/${platform}" 672 includes="lib/**"/> 673 <fileset dir="${dist}/${platform}" 674 includes="bin/**"/> 675 </copy> 676 677 <copy tofile="${platformTmpInst}/${release_name}/LICENSE.txt"> 678 <fileset dir="release-info/fcs-${version_base_file}" 679 includes="LICENSE*.txt"/> 680 </copy> 681 682 <chmod dir="${platformTmpInst}/${release_name}" perm="755" 683 includes="**/*.so"/> 684 685 <copy todir="${platformTmpInst}"> 686 <fileset dir="${build-tools}/${platformname}" 687 includes="script*.txt, unzipsfx"/> 688 </copy> 689 690 <exec dir="${platformTmpInst}/${release_name}" executable="${shell}"> 691 <arg line="${build-tools}/genzip ${release_name} LICENSE.txt lib"/> 692 </exec> 693 694 <copy file="${platformTmpInst}/${release_name}.bin" todir="${dist}/release"/> 695 696 <chmod file="${dist}/release/${release_name}.bin" perm="755"/> 697 </target> 698 699 <target name="release-zip-inst-final-windows" if="isWindows"> 700 <property name="tmpInstDir" location="${platformTmpInst}/${inst_name}"/> 701 <mkdir dir="${tmpInstDir}/j3d-binaries"/> 702 703 <copy todir="${tmpInstDir}"> 704 <fileset dir="release-info/fcs-${version_base_file}" 705 includes="LICENSE*.rtf README.html"/> 706 </copy> 707 708 <copy todir="${tmpInstDir}/j3d-binaries"> 709 <fileset dir="${dist}/${platform}" 710 includes="lib/**"/> 711 <fileset dir="${dist}/${platform}" 712 includes="bin/**"/> 713 </copy> 714 715 <chmod dir="${tmpInstDir}/j3d-binaries" perm="755" 716 includes="**/*.dll"/> 717 718 <zip destfile="${dist}/release/${inst_name}.zip"> 719 <fileset dir="${platformTmpInst}" 720 includes="${inst_name}/**"/> 721 </zip> 722 </target> 723 724 <target name="initSrc" depends="setupPlatform"> 725 <property name="platformSrc" location="${dist}/${platform}/src"/> 726 <property name="j3dZip" value="j3d-${version_file}-src.zip"/> 727 <property name="vecmathZip" value="vecmath-${version_file}-src.zip"/> 728 729 <property name="j3dZipFile" location="${platformSrc}/${j3dZip}"/> 730 <property name="vecmathZipFile" location="${platformSrc}/${vecmathZip}"/> 731 <property name="cvsRootDir" location=".."/> 732 733 <mkdir dir="${platformSrc}"/> 734 </target> 735 736 <target name="echoSrc"> 737 <echo message="j3dZipFile = ${j3dZipFile}"/> 738 <echo message="vecmathZipFile = ${vecmathZipFile}"/> 739 <echo message="cvsRootDir = ${cvsRootDir}"/> 740 </target> 741 742 <target name="src" depends="initSrc, echoSrc, j3dSrc, vecmathSrc"> 743 </target> 744 745 <target name="j3dSrc"> 746 <zip destfile="${j3dZipFile}"> 747 748 <fileset dir="${cvsRootDir}/j3d-core/release-info/src-release/j3d" 749 includes="README.txt"/> 750 751 <zipfileset dir="${cvsRootDir}/j3d-core" prefix="javax" 752 includes="COPYRIGHT.txt *LICENSE*.*"/> 753 754 <fileset dir="${cvsRootDir}/j3d-core/src/classes/share" 755 includes="*/**" 756 excludes="**/doc-files/** **/package.html"/> 757 758 <fileset dir="${cvsRootDir}/j3d-core/src/classes/jogl" 759 includes="*/**" 760 excludes="**/doc-files/** **/package.html"/> 761 762<!-- We will not include platform specific source files in this release 763 764 <fileset dir="${cvsRootDir}/j3d-core/src/classes/win32" 765 includes="*/**" 766 excludes="**/doc-files/** **/package.html"/> 767 <fileset dir="${cvsRootDir}/j3d-core/src/classes/x11" 768 includes="*/**" 769 excludes="**/doc-files/** **/package.html"/> 770--> 771 772 <zipfileset dir="${cvsRootDir}/j3d-core-utils" prefix="com" 773 includes="COPYRIGHT.txt *LICENSE*.*"/> 774 775 <fileset dir="${cvsRootDir}/j3d-core-utils/src/classes/share" 776 includes="*/**" 777 excludes="**/doc-files/** **/package.html"/> 778 </zip> 779 </target> 780 781 <target name="vecmathSrc"> 782 <zip destfile="${vecmathZipFile}"> 783 784 <fileset dir="${cvsRootDir}/j3d-core/release-info/src-release/vecmath" 785 includes="README.txt"/> 786 787 <zipfileset dir="${cvsRootDir}/vecmath" prefix="javax" 788 includes="COPYRIGHT.txt *LICENSE*.*"/> 789 790 <fileset dir="${cvsRootDir}/vecmath/src" 791 includes="*/**" 792 excludes="*/doc-files/** **/package.html VECMATH.MF"/> 793 </zip> 794 </target> 795 796 <target name="clean-dist"> 797 <!-- Delete the ${dist} directory tree --> 798 <delete dir="${dist}"/> 799 </target> 800 801 <target name="clean-default" unless="build.concurrent"> 802 <delete dir="${build}/default"/> 803 </target> 804 805 <target name="clean-dist-common" if="isLinuxOnX86"> 806 <delete dir="${dist}/common"/> 807 </target> 808 809 <target name="clean" depends="setupPlatform,clean-default,clean-dist-common"> 810 <!-- Delete the ${build}, and ${dist} directory trees for current platform --> 811 <delete dir="${build}/${platform}"/> 812 <delete dir="${dist}/${platform}"/> 813 </target> 814 815 <target name="clean-all"> 816 <!-- Delete the ${build}, and ${dist} directory trees --> 817 <delete dir="${build}"/> 818 <delete dir="${dist}"/> 819 </target> 820 821 <target name="clean-javaonly" depends="setupPlatform"> 822 <!-- Delete only the java portions of $[build} for the current platform --> 823 <delete dir="${build}/${platform}/debug/classes"/> 824 <delete dir="${build}/${platform}/debug/lib/ext"/> 825 <delete dir="${build}/${platform}/opt/classes"/> 826 <delete dir="${build}/${platform}/opt/lib/ext"/> 827 </target> 828 829 <target name="install-debug" depends="jar-debug"> 830 <ant dir="src/classes" target="install-debug"/> 831 </target> 832 833 <target name="install-opt" depends="jar-opt"> 834 <ant dir="src/classes" target="install-opt"/> 835 </target> 836 837 <target name="uninstall" depends="setupPlatform"> 838 <ant dir="src/classes" target="uninstall"/> 839 </target> 840 841 <description> 842The following ant targets are available ("jar-opt" is the default): 843 844 all - execute targets jar-debug and dist. 845 846 clean - removes build/ and dist/ for current platform 847 848 clean-all - removes build/ and dist/ for all platforms 849 850 clean-dist - removes dist. 851 852 clean-javaonly - removes java portion of build for current platform 853 854 compile - execute targets compile-debug and compile-opt. 855 856 compile-debug - builds all classes and native layer in src into 857 class files under build/${platform}/debug/classes/ and 858 native files under build/${platform}/debug/native/ 859 860 compile-opt - builds all classes and native layer in src into 861 class files under build/${platform}/opt/classes/ and 862 native files under build/${platform}/opt/native/ 863 864 dist - THIS TARGET IS FOR RELEASE ENGINEERING ONLY; DEVELOPERS NEED NOT 865 USE THIS TARGET. 866 Copies the shared jars, and the platform-specific native 867 libraries, src files, and javadoc to dist/${platform}. 868 The dist-common target must be run first. 869 870 dist-common - THIS TARGET IS FOR RELEASE ENGINEERING ONLY; DEVELOPERS NEED NOT 871 USE THIS TARGET. 872 This target must be run on a 32-bit Linux-x86 system. 873 Creates the shared jar from the linux-i586 and 874 windows-i586-vc build directories. 875 The jar-opt target must be run first. 876 877 docs - builds all classes in src into javadoc under 878 build/javadocs. 879 880 docs-jcp - builds JCP docs of all classes in src into javadoc 881 under build/javadocs/docs-jcp. 882 883 docs-private - builds private docs of all classes in src into javadoc 884 under build/javadocs/docs-private. 885 886 docs-public - builds public docs of all classes in src into javadoc 887 under build/javadocs/docs-public. 888 889 echo - echo some useful information, such as user.home, 890 ant.home, java.home and platform. 891 892 jar - execute targets jar-debug and jar-opt. 893 894 jar-debug - creates build/${platform}/debug/lib for all jar 895 files and libraries from class and native code files under 896 build/${platform}/debug/classes and 897 build/${platform}/debug/native. 898 899 jar-debug-javaonly 900 - compiles only the java portion of j3d and builds 901 jars in same locations as jar-debug 902 903 jar-opt - creates build/${platform}/opt/lib for all jar 904 files and libraries from class and native code files under 905 build/${platform}/opt/classes and 906 build/${platform}/opt/native. 907 908 jar-opt-javaonly 909 - compiles only the java portion of j3d and builds 910 jars in same location as jar-opt 911 912 install-debug - installs the debug build into the JDK pointed to by JAVA_HOME 913 914 src - generate a zip file j3d project source code. 915 916 uninstall - uninstalls j3d from the JDK pointed to by JAVA_HOME 917 </description> 918</project> 919