[OS-JIRA] Created: (WOL-539) Default build.xml can't compile

From: Chuck Hill (JIRA) ("Chuck)
Date: Wed Jul 11 2007 - 18:59:52 EDT

  • Next message: Chuck Hill: "Re: WOResourceURL"

    Default build.xml can't compile
    -------------------------------

                     Key: WOL-539
                     URL: http://issues.objectstyle.org/jira/browse/WOL-539
                 Project: WOProject/WOLips
              Issue Type: Bug
              Components: wolips
        Affects Versions: 2.0.0.4118
                Reporter: Chuck Hill
                Priority: Critical
             Attachments: NewWOLipsBuild.tgz

    Builds fail as follows:

    Buildfile: /Users/ijohnny/Projects/workspace/MOLContentManager/build.xml
    setProps:
    init.install:
    init.build:
    compile:
        [javac] Compiling 7 source files to /Users/ijohnny/Projects/workspace/MOLContentManager/bin

    BUILD FAILED
    /Users/ijohnny/Projects/workspace/MOLContentManager/build.xml:221: IO error scanning directory /.Spotlight-V100

    Total time: 600 milliseconds

    Problem: using javac and fileset.

    Solution:
    (A) Add this to the end of setProps:

    --------------------
                <!-- woproject.jar needs to be available to Ant for these definitions to work. Here are three ways to do this:
                     1. Copy it into the Ant library (/Developer/Java/Ant/lib/ on OS X)
            
                     2. Specify it on the command line each time you run Ant, for example:
                     ant -lib /Developer/Applications/eclipse/plugins/org.objectstyle.wolips.woproject.ant_2.0.0.4058/lib/ compile
            
                     3. Define the path to woproject.jar in one of your properties files like this:
                     woproject.path=/Developer/Applications/eclipse/plugins/org.objectstyle.wolips.woproject.ant_2.0.0.4058/lib/woproject.jar
                     and add it to the taskdef and typedef like this
                     <taskdef name="wocompile"
                              classname="org.objectstyle.woproject.ant.WOCompile"
                              classpath="${woproject.path}" />
                     <typedef name="wopath"
                                    classname="org.objectstyle.woproject.ant.WOPath"
                                    classpath="${woproject.path}" />
                -->
                <taskdef name="wocompile" classname="org.objectstyle.woproject.ant.WOCompile"/>
                <typedef name="wopath" classname="org.objectstyle.woproject.ant.WOPath" />
                <taskdef name="woframework" classname="org.objectstyle.woproject.ant.WOFramework"/>
                <taskdef name="woapplication" classname="org.objectstyle.woproject.ant.WOApplication"/>
    -------------

    (B) Remove taskdef command from framwork and application tasks. If everyone would do (3) we can eliminate the individual task and type definitions:

    <typedef resource="typedef.properties" classpath="${woproject.path}"/>
    <taskedef resource="taskdef.properties" classpath="${woproject.path}"/>
    (the taskdef.properties is not there now, but I have it locally).

    (C) Change the compile task to:

      <target name = "compile" depends = "setProps,init.build" >
        <mkdir dir = "bin"/>

        <!-- Non-source Classpath for project-->
        <wopath id="project.classpath">
          <path>
             <!-- Define webobjects.extensions=/Library/WebObjects/Extenstions in wobuild.properties
                  if you want those jars included. -->
             <fileset dir="${webobjects.extensions}" />
          </path>

          <frameworks root="${wo.wosystemroot}">
            <patternset>
              <includesfile name="woproject/ant.frameworks.wo.wosystemroot"/>
            </patternset>
          </frameworks>
          <frameworks root="${wo.wolocalroot}">
            <patternset>
              <includesfile name="woproject/ant.frameworks.wo.wolocalroot"/>
            </patternset>
          </frameworks>
          <frameworks root="${user.home}">
            <patternset>
              <includesfile name="woproject/ant.frameworks.user.home"/>
            </patternset>
          </frameworks>
        </wopath>

          <wocompile srcdir="src"
                                destdir="bin">
              <classpath refid="project.classpath"/>
            </wocompile>
      </target>

    -- 
    This message is automatically generated by JIRA.
    -
    If you think it was sent incorrectly contact one of the administrators: http://issues.objectstyle.org/jira/secure/Administrators.jspa
    -
    For more information on JIRA, see: http://www.atlassian.com/software/jira
    



    This archive was generated by hypermail 2.0.0 : Wed Jul 11 2007 - 19:00:47 EDT