Commit 4a572a82 authored by Jerome Wu's avatar Jerome Wu

Add freetype2 build script

parent 77bd1a2f
...@@ -9,7 +9,7 @@ FLAGS=( ...@@ -9,7 +9,7 @@ FLAGS=(
-I. -I./fftools -I$BUILD_DIR/include -I. -I./fftools -I$BUILD_DIR/include
-Llibavcodec -Llibavdevice -Llibavfilter -Llibavformat -Llibavresample -Llibavutil -Llibpostproc -Llibswscale -Llibswresample -L$BUILD_DIR/lib -Llibavcodec -Llibavdevice -Llibavfilter -Llibavformat -Llibavresample -Llibavutil -Llibpostproc -Llibswscale -Llibswresample -L$BUILD_DIR/lib
-Wno-deprecated-declarations -Wno-pointer-sign -Wno-implicit-int-float-conversion -Wno-switch -Wno-parentheses -Qunused-arguments -Wno-deprecated-declarations -Wno-pointer-sign -Wno-implicit-int-float-conversion -Wno-switch -Wno-parentheses -Qunused-arguments
-lavdevice -lavfilter -lavformat -lavcodec -lswresample -lswscale -lavutil -lpostproc -lm -lx264 -lx265 -lvpx -lwavpack -lmp3lame -lfdk-aac -lvorbis -lvorbisenc -lvorbisfile -logg -ltheora -ltheoraenc -ltheoradec -lz -pthread -lavdevice -lavfilter -lavformat -lavcodec -lswresample -lswscale -lavutil -lpostproc -lm -lx264 -lx265 -lvpx -lwavpack -lmp3lame -lfdk-aac -lvorbis -lvorbisenc -lvorbisfile -logg -ltheora -ltheoraenc -ltheoradec -lz -lfreetype -pthread
fftools/ffmpeg_opt.c fftools/ffmpeg_filter.c fftools/ffmpeg_hw.c fftools/cmdutils.c fftools/ffmpeg.c fftools/ffmpeg_opt.c fftools/ffmpeg_filter.c fftools/ffmpeg_hw.c fftools/cmdutils.c fftools/ffmpeg.c
-o wasm/dist/ffmpeg-core.js -o wasm/dist/ffmpeg-core.js
-s USE_SDL=2 # use SDL2 -s USE_SDL=2 # use SDL2
......
#!/bin/bash
set -euo pipefail
source $(dirname $0)/var.sh
LIB_PATH=third_party/freetype2
CFLAGS="-s USE_PTHREADS=1 $OPTIM_FLAGS"
CONF_FLAGS=(
--prefix=$BUILD_DIR # install library in a build directory for FFmpeg to include
--host=i686-gnu # use i686 linux
--enable-shared=no # not to build shared library
)
echo "CONF_FLAGS=${CONF_FLAGS[@]}"
(cd $LIB_PATH && \
emconfigure ./autogen.sh && \
CFLAGS=$CFLAGS emconfigure ./configure "${CONF_FLAGS[@]}")
emmake make -C $LIB_PATH clean
emmake make -C $LIB_PATH install -j
...@@ -16,6 +16,7 @@ FLAGS=( ...@@ -16,6 +16,7 @@ FLAGS=(
--enable-libfdk-aac # enable libfdk-aac --enable-libfdk-aac # enable libfdk-aac
--enable-libtheora # enable libtheora --enable-libtheora # enable libtheora
--enable-libvorbis # enable libvorbis --enable-libvorbis # enable libvorbis
--enable-libfreetype # enable freetype
# --enable-libaom # enable libaom # --enable-libaom # enable libaom
) )
echo "FFMPEG_CONFIG_FLAGS=${FLAGS[@]}" echo "FFMPEG_CONFIG_FLAGS=${FLAGS[@]}"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment