Help Compiling Modules + Interfaces + Ant

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Help Compiling Modules + Interfaces + Ant

luchi_bustos
Hi list!.
I was developing a modular application and I decide to switch to
compile with Apache Ant, since a modular application is a good candidate.

This is the project structure.
moduleTest/
 src/
  com/
   riaevolution/
    modules/
     IModuleInterface.as
     ModuleForm.mxml
 build/
  buil.properties
  build.xml
 lib/
  flextask.jar
  cairngorm.swc
  others....

The ModuleForm.mxml implements the IModuleInterface.as and it has a
simple UI (2 text inputs, 2 comboboxes).
I´m getting the same error with different ant and command line
options. I'm staked. I' can't make it work :(.
Help appreciated.

Description of errors.
----------------
---- Option 1
----------------
Error:
ModuleForm.mxml(2):  Error: Interface IModuleInterface was not found.

This is the Antbuild.xml where variables are
$src.dir = $basedir/src/
$modules.dir = $basedir/src/com/riaevolution/modules/
$deploy.dir = $basedir/deploy/

<target name="compile-module" description="generar el modulo">
 <mxmlc file="${modules.dir}/EmailForm.mxml"
output="${deploy.dir}/modules/EmailForm.swf">
 <source-path path-element ="${src.dir}"/>
 </mxmlc>
</target>
Nothing more, but it fails. MXMLC Can't find the classes.

----------------
---- Option 2
----------------

Error:
IModuleInterface.as: Error: A file found in a source-path must have
the same package structure '', as the definition's package,
'com.riaevolution.modules'.

Antbuild variables are the same

build.xml now is.
<target name="compile-module" description="generar el modulo">
 <mxmlc file="${modules.dir}/EmailForm.mxml"
output="${deploy.dir}/modules/EmailForm.swf">
 <source-path path-element ="${modules.dir}"/>
 </mxmlc>
</target>
It fail again, MXMLC find the interface but the package is wrong.!

----------------
---- Option 3
----------------
I made others test to find a solution, but nothing.
I think if I change the package inside the interface.as they should
work, but NOT.
Error: Interface IModuleInterface was not found.

The interface is.
package com.riaevolution.modules {
 public interface IModuleInterface(){
  function getModuleName():String
 }
}

I´m on Windowx XP sp2 eng, running Eclipse, Flex 2.01.
Workspace path D:\apps\.

Thanks a lot.!!

Luchyx - currently discouraged.



Reply | Threaded
Open this post in threaded view
|

Re: Help Compiling Modules + Interfaces + Ant

davidcoleman
This post has NOT been accepted by the mailing list yet.
Have you ever got an answer?  I have the same problem.  Flex SDK 4.5.1A