42 lines
763 B
Bash
Executable File
42 lines
763 B
Bash
Executable File
export ARCH=$(uname -m)
|
|
# do not use all cpus because my computer dies
|
|
export JOBS=$(awk -v count=$(nproc) 'BEGIN { print ( int( count - 1 ) ) }')
|
|
|
|
while [[ $# -gt 0 ]]; do
|
|
case $1 in
|
|
--arch)
|
|
export ARCH=$2
|
|
shift 2
|
|
;;
|
|
*)
|
|
echo "Usage: $0 --arch [arch]"
|
|
exit 1
|
|
;;
|
|
esac
|
|
done
|
|
|
|
export workDir=$(pwd)/work
|
|
export outDir=$(pwd)/out
|
|
export PREFIX=$workDir/prefix
|
|
|
|
export PKG_CONFIG_DIR=$PREFIX/lib/pkgconfig
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_DIR
|
|
|
|
rm -rf $PREFIX
|
|
mkdir -p $PREFIX
|
|
|
|
mkdir -p $workDir
|
|
mkdir -p $outDir
|
|
|
|
bash scripts/build-iconv.sh
|
|
|
|
case $FFBUILD_PLATFORM in
|
|
win)
|
|
bash scripts/build-ffnvcodec.sh
|
|
# bash scripts/build-libmfx.sh
|
|
;;
|
|
esac
|
|
|
|
bash scripts/build-openh264.sh
|
|
bash scripts/build-ffmpeg.sh
|