2 Replies Latest reply on Aug 29, 2008 12:54 AM by EmmiDeluxe

    Compiling / documenting flex applications with Flex 3 SDK and ASDoc failes

    EmmiDeluxe
      In order to include our Flash applications in our company's continuous integration environment,
      I try to compile our Flash app (created with Flex Builder 3) from command line. In the same course,
      the current API doc of the projects should be automatically created via ASDoc.

      When I tried to compile with the mxmlc.exe, I received lots of error messages about
      invalid embed directives to images in some stylesheets. The paths were correct,
      and Flex Builder compiles without problems. So I googled about this error but
      didn't find anything about a bug or what else could be wrong.
      But the paths were relative (../swf/SkinStandard.swf) and in other examples the path
      always started with "/assets/skins/standard/swf/SkinStandard.swf" so I changed each
      reference and these errors disappeared.
      And now I receive another error:

      ***************
      Error: E:\dev\flex\src\assets\skins\standard\css (Access is denied)
      ***************

      I also tried compiling with the configuration used by Flex Builder,
      (Project->Felx Compiler->Additional compiler arguments += "-dump-config=E:\FlexBuilderCompilerConfig.xml")
      but same errors occur.

      I have administrative rights on my computer, so my Windows user has all access rights to the directory mentioned above. I've got no idea what to do, because the error message is very unspecific about what cannot be accessed in that directory.

      When I try to generate the API documentation via ASDoc, I get the same kind of errors as I had with mxmlc before I switched the embed paths to start with "/assets/...". Unfortunately, changing the paths does not work here. I tried out every possibility: relative paths starting with "../assets", relative paths with starting "/assets/...", and absolute paths, but the identical error message appears all the time.

      ***************
      E:\dev\flex\src\assets\skins\standard\css\SkinExtension.css(1298):
      Error: Invalid Embed directive in stylesheet - can't resolve source
      'Embed(source = "/assets/skins/standard/swf/SkinStandard.swf", symbol = "toolbar_backgroundImage")'.

      backgroundImage: Embed(source="/assets/skins/standard/swf/SkinStandard.swf", symbol="toolbar_backgroundImage");
      ***************

      I cannot believe that compiling / documenting on the command line could be that difficult,
      so I think there must be an argument to set the application root directory or something
      like. In addition, I think there must be a special clue about those embed directives - what has to be
      considered so that the resources embedded in an SWF file can be accessed?
      More general: what is the difference between compiling within the Flex Builder and from command line,
      or how can I set up compiler settings so that I am sure that both methods work identically?

      Did anyone experience similar problems and found a solution?