ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/build.xml
(Generate patch)

Comparing jsr166/build.xml (file contents):
Revision 1.60 by tim, Mon Dec 8 03:10:54 2003 UTC vs.
Revision 1.63 by tim, Sat Dec 13 20:45:41 2003 UTC

# Line 43 | Line 43
43    <property name="src.dir"              location="${basedir}/src/main"/>
44    <property name="test.src.dir"         location="${basedir}/src/test"/>
45    <property name="tck.src.dir"          location="${test.src.dir}/tck"/>
46 +  <property name="jtreg.src.dir"        location="${test.src.dir}/jtreg"/>
47    <property name="ant.src.dir"          location="${basedir}/etc/ant"/>
48    <property name="stylesheet.dir"       location="${basedir}/etc/xsl"/>
49    <property name="lib.dir"              location="${basedir}/lib"/>
# Line 65 | Line 66
66    </path>
67  
68  
68
69    <!-- Main targets -->
70  
71  
# Line 251 | Line 251
251      <echo>java.home is ${java.home}</echo>
252  
253    </target>
254 <
255 <
254 >  
255 >  
256    <target name="dist-jar"
257            depends="clean, jar">
258  
# Line 410 | Line 410
410  
411      </javac>
412  
413 + <!--
414 +    <javac srcdir="${jtreg.src.dir}"
415 +          destdir="${build.testcases.dir}"
416 +            debug="${build.debug}"
417 +       debuglevel="${build.debuglevel}"
418 +      deprecation="${build.deprecation}"
419 +           source="${build.sourcelevel}"
420 +             fork="true">
421 +
422 +      <compilerarg value="${bootclasspath.args}"/>
423 +      <compilerarg line="${build.args}"/>
424 +      
425 +      <classpath refid="test.classpath"/>
426 +
427 +    </javac>
428 + -->
429 +
430    </target>
431  
432  
# Line 434 | Line 451
451  
452        <formatter type="xml"/>
453  
454 <      <batchtest todir="${build.reports.dir}">
454 >      <batchtest todir="${build.reports.dir}" unless="no.test.tck">
455          <fileset dir="${tck.src.dir}">
456            <include name="**/${testcase}Test.java"/>
457          </fileset>
458 +      </batchtest>
459 +      
460 +      <batchtest todir="${build.reports.dir}" if="do.test.old">
461          <fileset dir="${test.src.dir}">
462            <include name="jsr166/test/**/${testcase}Test.java"/>
463          </fileset>
464        </batchtest>
465  
466 + <!--      
467 +      <batchtest todir="${build.reports.dir}" if="do.test.jtreg">
468 +        <fileset dir="${jtreg.src.dir}">
469 +          <include name="**/${testcase}Test.java"/>
470 +        </fileset>
471 +      </batchtest>
472 + -->
473 +
474      </junit>
475  
476    </target>
# Line 562 | Line 590
590    </target>
591  
592  
593 <
594 <  <!-- Backward compatibility, work in progress (some files not checked in) -->
595 <
568 <
569 <  <target name="compat" depends="jar">
593 >  <!-- Standalone sample program -->
594 >  
595 >  <target name="sample" depends="jar">
596    
597      <mkdir dir="${build.testcases.dir}"/>
598      
# Line 583 | Line 609
609        
610        <classpath refid="test.classpath"/>
611        
612 <      <include name="Compatibility.java"/>
612 >      <include name="jsr166/test/Sample.java"/>
613        
614      </javac>
615      
616              
617 <    <java classname="Compatibility" fork="true">
617 >    <java classname="jsr166.test.Sample" fork="true">
618        <jvmarg value="${bootclasspath.args}"/>
619        <classpath refid="test.classpath"/>
620      </java>
621    </target>
622  
623 +  
624 +  
625 +  <!-- C++ and JNI definitions and demos -->
626 +  
627 +  <target name="configure-cpp">
628 +
629 +    <!-- Define tasks and types -->
630 +    
631 +    <path id="cpptasks.path">
632 +      <pathelement location="${lib.dir}/cpptasks.jar"/>
633 +    </path>
634 +    <taskdef resource="cpptasks.tasks" classpathref="cpptasks.path"/>
635 +    <typedef resource="cpptasks.types" classpathref="cpptasks.path"/>
636 +    
637 +    <!-- Set platform property for JNI includes -->
638 +    
639 +    <condition property="platform" value="linux">
640 +      <os name="Linux"/>
641 +    </condition>
642 +    <condition property="platform" value="win32">
643 +      <os family="windows"/>
644 +    </condition>
645 +    <condition property="platform" value="solaris">
646 +      <os name="SunOS"/>
647 +    </condition>
648 +    
649 +  </target>
650 +  
651 +  
652 +  <target name="cppdemo" depends="configure-cpp">
653 +  
654 +    <mkdir dir="${build.dir}"/>
655 +    
656 +    <cc multithreaded="true"
657 +                 name="g++"
658 +               objdir="${build.dir}"
659 +              outfile="${build.dir}/CppDemo">
660 +      <fileset dir="${test.src.dir}" includes="CppDemo.cpp"/>
661 +      <libset libs="stdc++"/>
662 +    </cc>
663 +    
664 +    <exec executable="${build.dir}/CppDemo">
665 +      <arg line="count in word frequency of word in command line count"/>
666 +    </exec>
667 +    
668 +  </target>
669 +  
670 +  
671 +  <target name="jnidemo" depends="init, configure-compiler, configure-cpp">
672 +  
673 +    <mkdir dir="${build.testcases.dir}"/>
674 +    
675 +    <javac srcdir="${test.src.dir}"
676 +          destdir="${build.testcases.dir}"
677 +            debug="${build.debug}"
678 +       debuglevel="${build.debuglevel}"
679 +      deprecation="${build.deprecation}"
680 +           source="${build.sourcelevel}"
681 +             fork="true">
682 +      <compilerarg value="${bootclasspath.args}"/>
683 +      <compilerarg line="${build.args}"/>
684 +      <classpath refid="test.classpath"/>
685 +      <include name="JniDemo.java"/>
686 +    </javac>
687 +    
688 +    <javah destdir="${build.testcases.dir}"
689 +      classpathref="test.classpath">
690 +      <class name="JniDemo"/>
691 +    </javah>
692 +    
693 +    <cc multithreaded="true"
694 +                 name="g++"
695 +               objdir="${build.dir}"
696 +              outfile="${build.dir}/JniDemo"
697 +              outtype="shared">
698 +              
699 +      <compiler>
700 +        <defineset>
701 +          <define name="__int64" value="long long"/>
702 +        </defineset>
703 +        <includepath location="${java.home}/../include"/>
704 +        <includepath location="${java.home}/../include/${platform}"/>
705 +        <compilerarg value="-mno-cygwin"/>
706 +      </compiler>
707 +      
708 +      <linker>
709 +        <linkerarg value="--add-stdcall-alias"/>
710 +      </linker>
711 +      
712 +      <includepath location="${build.testcases.dir}"/>
713 +      
714 +      <fileset dir="${test.src.dir}" includes="JniDemo.cpp"/>
715 +      
716 +      <libset libs="stdc++"/>
717 +      
718 +    </cc>
719 +    
720 +    <!-- Necessary if windows, harmless if not -->
721 +    <copy file="${build.dir}/libJniDemo.so" tofile="${build.dir}/JniDemo.dll"/>
722 +    
723 +    <java classname="JniDemo" fork="true">
724 +      <!-- Watch out: path separator hardwired to semicolon here! -->
725 +      <sysproperty key="java.library.path" path="${java.library.path};${build.dir}"/>
726 +      <classpath refid="test.classpath"/>
727 +    </java>
728 +    
729 +  </target>
730 +
731 +
732 +
733 +  <!-- Backward compatibility, work in progress (some files not checked in) -->
734 +
735  
736  
737    <property name="pretiger.src.dir"     location="${build.dir}/pretiger/src"/>

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines