linux下編譯flash

來源:互聯網
上載者:User

一、安裝java

http://download.chinaunix.net/download.php?id=28692&ResourceID=12304

1.mkdir /usr/java

2.chmod  +x  jdk-6u16-dlj-linux-amd64.bin

3../jdk-6u16-dlj-linux-amd64.bin

4.cd  /usr/java/jdk1.6.0_16/jre/lib

5.unpack200   rt.packrt.jar

6.cd  /usr/java/jdk1.6.0_16/lib

7.unpack200   tools.packtools.jar

8.vi   /etc/profile

添加如下3個環境變數

exportJAVA_HOME=/usr/java/jdk1.6.0_16

exportCLASSPATH=.:$JAVA_HOME/jre/lib/rt.jar:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar

exportPATH=$PATH:$JAVA_HOME/bin

9.source /etc/profile

二、安裝flex

http://www.adobe.com/devnet/flex/flex-sdk-download.html

1.unzip    flex_sdk_4.6.zip

最好建立個目錄/data/flex, 這個解壓後是檔案散開的。

其實這樣就可以用了,

/data/flex/bin/mxmlc helloworld.as

不過用的不爽,稍作配置

2.修改 frameworks/flex-config.xml檔案中

<static-link-runtime-shared-libraries>false</static-link-runtime-shared-libraries>

為<static-link-runtime-shared-libraries>true</static-link-runtime-shared-libraries>

3.將bin/mxmlc命令設為全域,和上面添加java命令類似(假設flex_sdk解壓在/data/flex目錄)

vi /etc/profile

修改

exportCLASSPATH=.:$JAVA_HOME/jre/lib/rt.jar:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:/data/flex/lib

exportPATH=$PATH:$JAVA_HOME/bin:/data/flex/bin

然後運行

source /etc/profile

4. mxmlc helloworld.as

即可編譯出helloworld.swf

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.