close


Gnash 可使用的Video Handler有兩種,擇一使用即可。

上次已分享使用Gstreamer,這次要分享使用FFmpeg 來Build Gnash。

那前面所需要的很多哩哩扣扣的library,請參考 Gnash Cross Compile with GStreamer



FFmpeg-0.5update )
這裡有修改一些檔案,因為在make的時候會發生一些asm指令找不到的問題。

diff -r ffmpeg-0.5/libavcodec/arm/asm.S ffmpeg_modify-0.5/libavcodec/arm/asm.S
24c24
<         .eabi_attribute 24, \val
---
>         @.eabi_attribute 24, \val
28c28
<         .eabi_attribute 25, \val
---
>         @.eabi_attribute 25, \val

diff -r ffmpeg-0.5/libavcodec/arm/dsputil_arm_s.S ffmpeg_modify-0.5/libavcodec/arm/dsputil_arm_s.S
641c641
<         push            {r4-r10}
---
>         stmfd           sp!, {r4-r10} @ push            {r4-r10}
724c724
<         pop             {r4-r10}
---
>         ldmfd           sp!, {r4-r10} @ pop             {r4-r10}

diff -r ffmpeg-0.5/libavcodec/arm/mpegvideo_armv5te_s.S ffmpeg_modify-0.5/libavcodec/arm/mpegvideo_armv5te_s.S
39c39
<         push            {r4-r9,lr}
---
>         stmfd           sp!,  {r4-r9,lr} @ push            {r4-r9,lr}
102c102
<         pople           {r4-r9,pc}
---
>         ldmlefd         sp!, {r4-r9,pc} @ pople           {r4-r9,pc}
116c116
<         pop             {r4-r9,pc}
---
>         ldmfd           sp!, {r4-r9,pc} @ pop             {r4-r9,pc}

./configure --prefix="/opt/crosstool/gcc-3.4.2-glibc-2.3.3/arm-linux-gnu/arm-linux-gnu" --enable-cross-compile --enable-swscale --enable-gpl
--enable-shared --disable-static --cross-prefix=$CROSS_COMPILE --arch=arm --cpu=armv5te
make;make install;


Gnash-0.8.5 ( update )
./configure --prefix=/opt/crosstool/gcc-3.4.2-glibc-2.3.3/arm-linux-gnu/arm-linux-gnu/ --host=arm-linux-gnu --with-gnu-ld --enable-gui=fb --enable-media=ffmpeg --with-agg-incl=/opt/crosstool/gcc-3.4.2-glibc-2.3.3/arm-linux-gnu/arm-linux-gnu/include/agg --with-agg-lib=/opt/crosstool/gcc-3.4.2-glibc-2.3.3/arm-linux-gnu/arm-linux-gnu/lib --with-ffmpeg-lib=/opt/crosstool/gcc-3.4.2-glibc-2.3.3/arm-linux-gnu/arm-linux-gnu/lib
make;make install;

 



在bin資料夾下會有三個執行檔 => gnash / fb-gnash / ffmpeg

將這三個執行檔copy到板子上,並修改權限。

修改gnash檔,找到 THIS_DIR=" ' dirname $0 ' "  修改成
THIS_DIR="."

執行: $./gnash


依照訊息將之前build出來的library copy到板子上即可。

執行$./gnash -v clip_as_button2.swf 

就可以觀看到結果了。

arrow
arrow
    全站熱搜

    DelionDan 發表在 痞客邦 留言(0) 人氣()