Skip to content

Commit

Permalink
Create build_mxe_ffmpeg.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
rodlie committed May 15, 2024
1 parent 0c95802 commit 0aafe67
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions src/scripts/build_mxe_ffmpeg.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/bin/bash
set -e -x

CWD=`pwd`
VERSION=4.2.9
BUILD=${CWD}/ffmpeg-friction-${VERSION}-win64
MXE=${CWD}/usr/x86_64-w64-mingw32.static

if [ ! -f "${CWD}/settings.mk" ]; then
echo "Run script in the MXE folder!"
exit 1
fi

if [ -d "${BUILD}" ]; then
rm -rf ${BUILD}
fi
mkdir -p ${BUILD}/{bin,include}

make

cp -a ${MXE}/include/{libavcodec,libavdevice,libavfilter,libavformat,libavresample,libavutil,libpostproc,libswresample,libswscale} ${BUILD}/include/
cp -a ${MXE}/lib/*.def ${BUILD}/bin/
cp -a ${MXE}/bin/*.{dll,lib} ${BUILD}/bin/

if [ -d "${CWD}/legal" ]; then
cp -a ${CWD}/legal ${BUILD}/
fi

zip -9 -r ${BUILD}.zip ${BUILD}

0 comments on commit 0aafe67

Please sign in to comment.