File tree 5 files changed +76
-0
lines changed
5 files changed +76
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ set -ex
3
+ DEPS_DIR=$( dirname ${BASH_SOURCE[0]} )
4
+ cd " $DEPS_DIR "
5
+ . common
6
+ process_args " $@ "
7
+
8
+ VERSION=1.5.0
9
+ FILENAME=dav1d-$VERSION .tar.gz
10
+ PROJECT_DIR=dav1d-$VERSION
11
+ SHA256SUM=78b15d9954b513ea92d27f39362535ded2243e1b0924fde39f37a31ebed5f76b
12
+
13
+ cd " $SOURCES_DIR "
14
+
15
+ if [[ -d " $PROJECT_DIR " ]]
16
+ then
17
+ echo " $PWD /$PROJECT_DIR " found
18
+ else
19
+ get_file " https://code.videolan.org/videolan/dav1d/-/archive/$VERSION /$FILENAME " " $FILENAME " " $SHA256SUM "
20
+ tar xf " $FILENAME " # First level directory is "$PROJECT_DIR"
21
+ fi
22
+
23
+ mkdir -p " $BUILD_DIR /$PROJECT_DIR "
24
+ cd " $BUILD_DIR /$PROJECT_DIR "
25
+
26
+ if [[ -d " $DIRNAME " ]]
27
+ then
28
+ echo " '$PWD /$DIRNAME ' already exists, not reconfigured"
29
+ cd " $DIRNAME "
30
+ else
31
+ mkdir " $DIRNAME "
32
+ cd " $DIRNAME "
33
+
34
+ conf=(
35
+ --prefix=" $INSTALL_DIR /$DIRNAME "
36
+ --libdir=lib
37
+ -Denable_tests=false
38
+ -Denable_tools=false
39
+ # Always build dav1d statically
40
+ --default-library=static
41
+ )
42
+
43
+ if [[ " $BUILD_TYPE " == cross ]]
44
+ then
45
+ case " $HOST " in
46
+ win32)
47
+ conf+=(
48
+ --cross-file=" $SOURCES_DIR /$PROJECT_DIR /package/crossfiles/i686-w64-mingw32.meson"
49
+ )
50
+ ;;
51
+
52
+ win64)
53
+ conf+=(
54
+ --cross-file=" $SOURCES_DIR /$PROJECT_DIR /package/crossfiles/x86_64-w64-mingw32.meson"
55
+ )
56
+ ;;
57
+
58
+ * )
59
+ echo " Unsupported host: $HOST " >&2
60
+ exit 1
61
+ esac
62
+ fi
63
+
64
+ meson setup . " $SOURCES_DIR /$PROJECT_DIR " " ${conf[@]} "
65
+ fi
66
+
67
+ ninja
68
+ ninja install
Original file line number Diff line number Diff line change 43
43
export PKG_CONFIG_PATH=" /opt/homebrew/opt/zlib/lib/pkgconfig"
44
44
fi
45
45
46
+ export PKG_CONFIG_PATH=" $INSTALL_DIR /$DIRNAME /lib/pkgconfig:$PKG_CONFIG_PATH "
47
+
46
48
conf=(
47
49
--prefix=" $INSTALL_DIR /$DIRNAME "
50
+ --pkg-config-flags=" --static"
48
51
--extra-cflags=" -O2 -fPIC"
49
52
--disable-programs
50
53
--disable-doc
57
60
--disable-vaapi
58
61
--disable-vdpau
59
62
--enable-swresample
63
+ --enable-libdav1d
60
64
--enable-decoder=h264
61
65
--enable-decoder=hevc
62
66
--enable-decoder=av1
67
+ --enable-decoder=libdav1d
63
68
--enable-decoder=pcm_s16le
64
69
--enable-decoder=opus
65
70
--enable-decoder=aac
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ LINUX_BUILD_DIR="$WORK_DIR/build-linux-$ARCH"
15
15
16
16
app/deps/adb_linux.sh
17
17
app/deps/sdl.sh linux native static
18
+ app/deps/dav1d.sh linux native static
18
19
app/deps/ffmpeg.sh linux native static
19
20
app/deps/libusb.sh linux native static
20
21
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ MACOS_BUILD_DIR="$WORK_DIR/build-macos-$ARCH"
15
15
16
16
app/deps/adb_macos.sh
17
17
app/deps/sdl.sh macos native static
18
+ app/deps/dav1d.sh macos native static
18
19
app/deps/ffmpeg.sh macos native static
19
20
app/deps/libusb.sh macos native static
20
21
Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ WINXX_BUILD_DIR="$WORK_DIR/build-$WINXX"
22
22
23
23
app/deps/adb_windows.sh
24
24
app/deps/sdl.sh $WINXX cross shared
25
+ app/deps/dav1d.sh $WINXX cross shared
25
26
app/deps/ffmpeg.sh $WINXX cross shared
26
27
app/deps/libusb.sh $WINXX cross shared
27
28
You can’t perform that action at this time.
0 commit comments