Note that there are some explanatory texts on larger screens.

plurals
  1. POFlex compiler breaking when I use -raw-metadata parameter
    primarykey
    data
    text
    <p>So I have this shell script that compiles my AS3 classes to the SWF format. </p> <p>Today I wanted to add a fancy timestamp to the "date" parameter on the metadata list. I'm trying to use the compiler option <code>-raw-metadata</code> but everytime I try to compile it gives me this error:</p> <pre><code>Adobe Flex Compiler (mxmlc) Version 4.6.0 build 23201 Copyright (c) 2004-2011 Adobe Systems, Inc. All rights reserved. command line: Error: default arguments may not be interspersed with other options Use 'mxmlc -help' for information about using the command line. </code></pre> <p>Do you guys have any idea of why this is happening at all? Am I doing something stupid? It works fine if I don't use <code>-raw-metadata</code> but set every single parameter individually.</p> <p>Here is my build process (Makefile):</p> <pre><code># # Rafael Rinaldi (rafaelrinaldi.com) # Feb 20, 2013 # # Flex compiler. mxmlc=/Users/rafaelrinaldi/Code/Flash/SDK/flex_sdk_4.6/bin/mxmlc # Flash player. player=/Applications/Adobe\ Flash\ CS6/Players/Debug/Flash\ Player\ Debugger.app # Setup. main=./src/Main.as libraries=./libs swc=./swc source-path=./src output=./bin/static/Main.swf run=$(output) # .swf settings. fp=11.1 fps=60 bg=0xFFFFFF dimension=865,720 # Flags. as3=true debug=true strict=true # Application info. title=Main creator=Rafael Rinaldi (rafaelrinaldi.com) publisher=Rafael Rinaldi (rafaelrinaldi.com) description=My application. language=en-US date=$(shell date +'%B %d, %Y') timestamp=$(shell date +'%D %T') # SWF meta data. define swf_metadata &lt;metadata&gt; &lt;title&gt;$(title)&lt;/title&gt; &lt;description&gt;$(description)&lt;/description&gt; &lt;publisher&gt;$(publisher)&lt;/publisher&gt; &lt;creator&gt;$(creator)&lt;/creator&gt; &lt;language&gt;$(language)&lt;/language&gt; &lt;date&gt;$(timestamp)&lt;/date&gt; &lt;/metadata&gt; endef export swf_metadata all: compile run # Compile main file into a .swf compile: @echo "\nCompiling '$(main)'...\n" @$(mxmlc) \ -as3=$(as3) \ -debug=$(debug) \ -strict=$(strict) \ -target-player=$(fp) \ -default-frame-rate=$(fps) \ -default-background-color=$(bg) \ -default-size=$(dimension) \ -static-link-runtime-shared-libraries=true \ -source-path=$(source-path) \ -source-path+=$(libraries) \ -library-path=$(swc) \ $(main) \ -raw-metadata=$$swf_metadata \ -o $(output) @echo "\nCompiled '$(output)' at `date "+%H:%M of %d/%m"`." # Runs the application. run: @echo "\nRunning '$(run)'\n" @open -a $(player) $(run) # Aliases. c: compile r: run .PHONY: all </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload