>Ant is a good choice for java projects, not too bad for c projects
>and will be veru usefull when playing with gcj.

And you could still use ant to call make ;)

>From http://www-106.ibm.com/developerworks/java/library/j-nativegui/?loc=j


=>

<project name="BuildEclipse" default="cleanup">

  <!--
  The following properties can be overridden at the command-line.

    e.g. ant -Declipse_install_dir=/usr/local/eclipse
  -->
  <property name="eclipse_install_dir" value="/usr/local/eclipse"/>
  <property name="temp_dir" value="build_temp"/>
  <property name="shared_object_name" value="swt.so"/>


  <target name="init">
    <mkdir dir="${temp_dir}"/>
  </target>

  <target name="unpack" depends="init">
    <unzip src="${eclipse_install_dir}/plugins/org.eclipse.swt/swtsrc.zip"
           dest="${temp_dir}"/>
    <unjar src="${eclipse_install_dir}/plugins/org.eclipse.swt/swt.jar"
           dest="${temp_dir}"/>
  </target>

  <target name="patch" depends="unpack">
    <patch patchfile="TabFolder.patch"
           originalfile="${temp_dir}/org/eclipse/swt/widgets/TabFolder.java"/>
    <patch patchfile="Widget.patch"
           originalfile="${temp_dir}/org/eclipse/swt/widgets/Widget.java"/>
    <patch patchfile="TreeEditor.patch"/>
    <move file="TreeEditor.java" todir="${temp_dir}/org/eclipse/swt/custom"/>
  </target>

  <target name="make" depends="patch">
    <execon executable="touch">
      <fileset dir="${temp_dir}" includes="**/*.java" excludes="**/*.class"/>
    </execon>
    <execon executable="touch">
      <fileset dir="${temp_dir}" includes="**/*.class" excludes="**/*.java"/>
    </execon>
    <copy file="Makefile" todir="${temp_dir}"/>
    <exec executable="make" dir="${temp_dir}">
      <arg line="-f Makefile"/>
    </exec>
  </target>

  <target name="cleanup" depends="make">
    <move file="${temp_dir}/${shared_object_name}" todir="."/>
    <delete dir="${temp_dir}"/>
  </target>

</project>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to