ok, so don't smack me...

I got it working :).  there were 2 issues.  

    1.  I had the path to the exe wron.. duh.  (see below)
    2.  I had the main flag set to true without having the static main function in the as file.  I set it to false and all ran smoothly.

here is the final build file that works fine:

<?xml version="1.0"?>
<!-- ======================================================================
     Nov 10, 2005 3:42:29 PM                                                       

        
     description
                  
     julian                                                               
     ====================================================================== -->
<project name="Main" >
    <description>
            description
    </description>
    <!-- Declares references to needed directories. -->
            <property name="src.dir" location="../src/"/>
            <property name="build.dir" location="../deploy/"/>
    <!-- Properties for the output movie -->
            <property name="width" value="500"/>
            <property name="height" value="500"/>
            <property name="framerate" value="31"/>
            <property name="bgcolor" value="343499"/>   
    <!-- tool info -->
            <property name="mtasc.exe" location="/opt/mtasc/mtasc"/>
            <property name="plugins" location="/Applications/eclipse/plugins"/>
            <property name="swfmill.exe" location="/usr/local/bin/swfmill"/>   
    <!-- =================================
          target: default             
         ================================= -->
    <!-- Define the MTASC ant task -->
            <taskdef name="mtasc" classname="org.as2lib.ant.Mtasc" classpath="${plugins}"/>
           
            <!-- Target that uses the MTASC Ant Task. -->
            <target name="compile" description="builds sample swf">
                    <mtasc srcdir="${src.dir}" classpath="${src.dir}" swf="${build.dir}/${ant.project.name}.swf"
                           main="false" header="${width}:${height}:${framerate}:${bgcolor}"   mtasc="${mtasc.exe}"/>
            </target>
</project>


thanx again. j


On 27.11.2005, at 23:44, Julian Sander wrote:

Hi HTH,

thanx for this, after adujting and adding the nodes to the build.xml I now get this error:

Buildfile: /Users/julian/Documents/files/workspace/MTASC_learning/build/build.xml
compile:

BUILD FAILED
/Users/julian/Documents/files/workspace/MTASC_learning/build/build.xml:44: The <mtasc> type doesn't support the "mtasc" attribute.

Total time: 1 second

any ideas? j



On 27.11.2005, at 22:45, erixtekila wrote:

<?xml version="1.0"?>
<!-- 
======================================================================
     Nov 10, 2005 3:42:29 PM                                          

           


        

     description

                  

     julian       

     

====================================================================== 
-->
<project name="Main" >
    <description>
            description
    </description>
    <!-- Declares references to needed directories. -->
            <property name="src.dir" location="../src/"/>
            <property name="build.dir" location="../deploy/"/>
    <!-- Properties for the output movie -->
            <property name="width" value="500"/>
            <property name="height" value="500"/>
            <property name="framerate" value="31"/>
            <property name="bgcolor" value="666666"/>
    <!-- =================================
          target: default           
         ================================= -->
    <!-- Define the MTASC ant task -->
            <taskdef name="mtasc" classname="org.as2lib.ant.Mtasc" 
classpath="/Applications/eclipse/plugins"/>

           

            <!-- Target that uses the MTASC Ant Task. -->
            <target name="compile" description="builds sample swf">
                    <mtasc srcdir="${src.dir}" classpath="${src.dir}" 
swf="${build.dir}/${ant.project.name}.swf"
                      main="true" 
header="${width}:${height}:${framerate}:${bgcolor}"/>
            </target>

   


</project>

It's hard to figure but easy to anderstand.
When using Ant by Eclipse, you don't call ~/.profile
In this file, you get your environment variables.

To fix that, just tell mtasc task where to dig for mtasc…
Mine :
<!-- tool info -->
<property name="mtasc.exe" location="/usr/local/bin/mtasc"/>
<property name="swfmill.exe" location="/usr/local/bin/swfmill"/>

<mtasc src="" keep="true" 
swf="${deploy.dir}/testSequence.swf" header="20:20:31" version="8" 
classpath="${classpath1}:${source.dir}" mtasc="${mtasc.exe}"/>

Should do the trick.
HTH

-----------
erixtekila

_______________________________________________
osflash mailing list


_______________________________________________
osflash mailing list


_______________________________________________
osflash mailing list
[email protected]
http://osflash.org/mailman/listinfo/osflash_osflash.org

Reply via email to