Open amwujetuu opened 7 years ago
这是要改 compile_ffmpeg.sh
添加 do_lipo_x264() { LIB_FILE=$1 LIPO_FLAGS= for ARCH in $FF_ALL_ARCHS do ARCH_LIB_FILE="$UNI_BUILD_ROOT/build/X264-$ARCH/output/lib/$LIB_FILE" if [ -f "$ARCH_LIB_FILE" ]; then LIPO_FLAGS="$LIPO_FLAGS $ARCH_LIB_FILE" cp -R $UNI_BUILD_ROOT/build/X264-$ARCH/output/include $UNI_BUILD_ROOT/build/universal/ else echo "skip $LIB_FILE of $ARCH"; fi done
if [ "$LIPO_FLAGS" != "" ]; then xcrun lipo -create $LIPO_FLAGS -output $UNI_BUILD_ROOT/build/universal/lib/$LIB_FILE xcrun lipo -info $UNI_BUILD_ROOT/build/universal/lib/$LIB_FILE fi }
2.和 修改 do-compile-ffmpeg.sh if [ -f "${FFMPEG_DEP_X264_LIB}/libx264.a" ]; then FFMPEG_CFG_FLAGS="$FFMPEG_CFG_FLAGS --enable-libx264" FFMPEG_CFG_FLAGS="$FFMPEG_CFG_FLAGS --enable-encoder=libx264" FFMPEG_CFLAGS="$FFMPEG_CFLAGS -I${FFMPEG_DEP_X264_INC}" FFMPEG_DEP_LIBS="$FFMPEG_DEP_LIBS -L${FFMPEG_DEP_X264_LIB} -lx264" export PKG_CONFIG_PATH="$FFMPEG_DEP_X264_LIB/pkgconfig":$PKG_CONFIG_PATH echo $PKG_CONFIG_PATH fi
3.然后在xcode 项目linked Frameworks and Libraries 添加进 libx264.a
@peterhuang007 有具体的脚本吗,求一个,66187737@qq.com
参考openssl编译,我发现一个很好的交流群,547962153,加入交流
@peterhuang007 有具体的脚本吗,求一个,307509256@qq.com
我现在已经编译好了一个libx264,我想让ijkplayer添加libx264.我该怎么做。