compiling actionscript in linux

萝らか妹 提交于 2019-12-12 12:03:05

问题


I'm working on a website that requires a flash mp3 player. I have absolutely no idea the procedures from messing with flash/actionscript/flex etc., however I need to edit the flash very slightly (I need to add two lines of code). There are a multitude of tutorials out there for setting up a flash (or flex or whatever) development environment but, as my needs are so simple, I'd like to go a little more light-weight than that (also, many seem outdated). I guess what I'm saying is I'm looking for a simple way to recompile some existing actionscript (command line is a plus!). Does anyone have a trick up their sleeve to accomplish this?


回答1:


Download the free/opensource Flex 3 SDK. This includes an ActionScript3 compiler. Run the compiler like this:

mxmlc MyAs3File.as



回答2:


There's MTASC for ActionScript 2.




回答3:


You can compile it online here: http://wonderfl.kayac.com/. No mess that way.




回答4:


I also wanted to say that swftools has exactly what you need. There is a swfc compiler which will compile as2 files. I would really recommend updating the source though. AS3 is much faster than AS2 and there are a lot of tools out there for example mxmlc and fcsh included in the open source Flex sdk. If you are looking for a full blown IDE there is a linux version of Flash Builder that was released as an open source port ... there are a couple other ones out there as well.




回答5:


General Linux

On linux you can get the source from swftools.org.

Debian / Ubuntu

On debian / ubuntu you can run

apt-get install swftools

Mac OS X

Not exactly 'linux' but on mac OS X if you have homebrew installed you can do:

brew install swftools

Great, but how do I compile the code?

One this is installed you should have a new utility that you can use to do:

as3compile MyAs3File.as

Gotchas

Please note this is not a 1:1 replacement for Adobe's compiler - there are some things that it does not support ( see documentation, FAQ, changelog at swftools.org ) but it worked well for compiling my simple actionscript.



来源:https://stackoverflow.com/questions/775526/compiling-actionscript-in-linux

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!