Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Get Apache Flex 4.9 working in FB. (I tried it with FB 4.7, but not FB 4.6)
  2. Shut down FB
  3. Install Google Closure library. You can get a zip from: http://code.google.com/p/closure-library/downloads/list
  4. Set the environment variable GOOG_HOME to point to the closure/goog folder"library" folder that contains the closure and third_party folders.
  5. Unzip FlexJSOverlay.zip from http://people.apache.org/~aharui/FlexJS/ into a some other folder.
  6. Change to that folder and run deploy.sh or deploy.bat <path to Apache Flex 4.9 folder> <path to where the script should make a copy of Apache Flex 4.9 folder>
    Note that the deploy script will neuter the Flex aspects of this folder and replace it with FlexJS stuff.
  7. Run Flash Builder
  8. In the Flash Builder Preferences menu add this new folder as a Flex SDK.
  9. Choose from the File menu, Import, Run/Debug, Launch Configurations
  10. Choose the ide/flashbuilder folder from this copy of Apache Flex 4.9 we are mucking with.
    There should now be four three new configs in the Run menu under External Tools

...

As you edit the code, the regular Flex compiler is compiling and reporting errors, but it only knows how to build Flex SWFs so the output SWF probably won’t run. So, before you debug, select the main MXML file from the Package Explorer and choose from the Run menu the new External Tool: “FlexJS (Debug Build)”. This will run the Falcon compiler with the right options to generate a SWF in the bin-debug folder that overwrites the one that is there. Then you should be able to set breakpoints and debug.

Once you have your app working as a SWF, try one of the FalconJS toolsFalconJX tool. It will output by default a debug version to the binjsbin/js-debug or binjsand a minified version to the bin/js-release folder. If you run the FalconJS debug configuration, see the console output for instructions on how to copy the goog and FlexJS source folders into your binjs-debug folderRun the index.html in a browser.

I’m sure there’ll be lots of issues, but feel free to comment or contribute. Remember, this is in its infancy so it will likely fall down easily and poop unexpectedly.