Skip to content

Commit 7f8aa25

Browse files
committed
add libdvdnav
1 parent a06fe21 commit 7f8aa25

File tree

3 files changed

+143
-26
lines changed

3 files changed

+143
-26
lines changed

README.md

Lines changed: 28 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,16 @@
66

77
MRFFToolChain products was built for [fsplayer](https://github.com/debugly/fsplayer)[ijkplayer](https://github.com/debugly/ijkplayer)[FFmpegTutorial](https://github.com/debugly/FFmpegTutorial).
88

9-
At present MRFFToolChain contained `ass、bluray、dav1d、dvdread、ffmpeg、freetype、fribidi、harfbuzz、openssl、opus、unibreak、uavs3d、smb2、yuv、soundtouch、xml2`.
9+
At present MRFFToolChain contained `ass、bluray、dav1d、dvdread、dvdnav、ffmpeg、freetype、fribidi、harfbuzz、openssl、opus、unibreak、uavs3d、smb2、yuv、soundtouch、xml2`.
1010

1111
## Supported Plat
1212

13-
| platform | architectures | minimum deployment target |
14-
| ----- | --------------------------------------|---------------------------- |
15-
| iOS | arm64、arm64_simulator、x86_64_simulator | 11.0 |
16-
| tvOS | arm64、arm64_simulator、x86_64_simulator | 12.0 |
17-
| macOS | arm64、x86_64 | 10.11 |
18-
| Android | arm64、armv7a、x86_64、x86 | 21 |
13+
| platform | architectures | minimum deployment target |
14+
| -------- | -------------------------------------- | ------------------------- |
15+
| iOS | arm64、arm64_simulator、x86_64_simulator | 11.0 |
16+
| tvOS | arm64、arm64_simulator、x86_64_simulator | 12.0 |
17+
| macOS | arm64、x86_64 | 10.11 |
18+
| Android | arm64、armv7a、x86_64、x86 | 21 |
1919

2020
## News
2121

@@ -33,6 +33,7 @@ At present MRFFToolChain contained `ass、bluray、dav1d、dvdread、ffmpeg、fr
3333
- Ass for Android: harfbuzz,fribidi,unibreak,fontconfig
3434
- FFmpeg for Appple: openssl,opus,dav1d,dvdread,uavs3d,smb2
3535
- FFmpeg for Android: openssl,opus,dav1d,dvdread,uavs3d,smb2,soundtouch
36+
- FFmpeg7 for Appple: openssl,opus,dav1d,dvdread,dvdnav,uavs3d,smb2
3637

3738
Tips:
3839

@@ -113,25 +114,26 @@ The order of these parameters does not matter; they can be arranged in any seque
113114

114115
If cloning repositories from GitHub is slow, or if you need to use an internal private repository, you can declare the corresponding environment variables before running the compilation script!
115116

116-
| Lib Name | Current Version | Repository URL | Mirror Repository URL |
117-
| ----------- | -------| ------------------------------------------------------- | -------------------------------------------------------- |
118-
| FFmpeg | 6.1.2 | https://github.com/FFmpeg/FFmpeg.git | export GIT_FFMPEG_UPSTREAM = git@xx:yy/FFmpeg.git |
119-
| ass | 0.17.3 | https://github.com/libass/libass.git | export GIT_ASS_UPSTREAM = git@xx:yy/libass.git |
120-
| bluray | 1.3.4 | https://code.videolan.org/videolan/libbluray.git | export GIT_BLURAY_UPSTREAM = git@xx:yy/libbluray.git |
121-
| dav1d | 1.5.1 | https://code.videolan.org/videolan/dav1d.git | export GIT_DAV1D_UPSTREAM = git@xx:yy/dav1d.git |
122-
| dvdread | 6.1.3 | https://code.videolan.org/videolan/libdvdread.git | export GIT_DVDREAD_UPSTREAM = git@xx:yy/libdvdread.git |
123-
| fontconfig | 2.16.0 | https://gitlab.freedesktop.org/fontconfig/fontconfig.git| export GIT_FONTCONFIG_UPSTREAM=git@xx:yy/fontconfig.git |
124-
| freetype | 2.13.3 | https://gitlab.freedesktop.org/freetype/freetype.git | export GIT_FREETYPE_UPSTREAM = git@xx:yy/freetype.git |
125-
| fribidi | 1.0.16 | https://github.com/fribidi/fribidi.git | export GIT_FRIBIDI_UPSTREAM = git@xx:yy/fribidi.git |
126-
| harfbuzz | 10.2.0 | https://github.com/harfbuzz/harfbuzz.git | export GIT_HARFBUZZ_UPSTREAM = git@xx:yy/harfbuzz.git |
127-
| openssl | 1.1.1w | https://github.com/openssl/openssl.git | export GIT_OPENSSL_UPSTREAM = git@xx:yy/openssl.git |
128-
| opus | 1.5.2 | https://gitlab.xiph.org/xiph/opus.git | export GIT_OPUS_UPSTREAM = git@xx:yy/opus.git |
129-
| smb2 | 6.2 | https://github.com/sahlberg/libsmb2.git | export GIT_SMB2_UPSTREAM=git@xx:yy/libsmb2.git |
130-
| soundtouch | 2.3.3 | https://codeberg.org/soundtouch/soundtouch.git | export GIT_SOUNDTOUCH_UPSTREAM=git@xx:yy/soundtouch.git |
131-
| unibreak | 6.1 | https://github.com/adah1972/libunibreak.git | export GIT_UNIBREAK_UPSTREAM = git@xx:yy/libunibreak.git |
132-
| uavs3d | 1.2.1 | https://github.com/uavs3/uavs3d.git | export GIT_UAVS3D_UPSTREAM=git@xx:yy/UAVS3D.git |
133-
| xml2 | 2.13.6 | https://github.com/GNOME/libxml2.git | export GIT_FONTCONFIG_UPSTREAM=git@xx:yy/fontconfig.git |
134-
| yuv | stable-eb6e7bb | https://github.com/debugly/libyuv.git | export GIT_YUV_UPSTREAM=git@xx:yy/yuv.git |
117+
| Lib Name | Current Version | Repository URL | Mirror Repository URL |
118+
| ---------- | --------------- | -------------------------------------------------------- | -------------------------------------------------------- |
119+
| FFmpeg | 6.1.2 | https://github.com/FFmpeg/FFmpeg.git | export GIT_FFMPEG_UPSTREAM = git@xx:yy/FFmpeg.git |
120+
| ass | 0.17.3 | https://github.com/libass/libass.git | export GIT_ASS_UPSTREAM = git@xx:yy/libass.git |
121+
| bluray | 1.3.4 | https://code.videolan.org/videolan/libbluray.git | export GIT_BLURAY_UPSTREAM = git@xx:yy/libbluray.git |
122+
| dav1d | 1.5.1 | https://code.videolan.org/videolan/dav1d.git | export GIT_DAV1D_UPSTREAM = git@xx:yy/dav1d.git |
123+
| dvdread | 6.1.3 | https://code.videolan.org/videolan/libdvdread.git | export GIT_DVDREAD_UPSTREAM = git@xx:yy/libdvdread.git |
124+
| dvdnav | master-9831fe01 | https://code.videolan.org/videolan/libdvdnav.git | export GIT_DVDNAV_UPSTREAM = git@xx:yy/libdvdnav.git |
125+
| fontconfig | 2.16.0 | https://gitlab.freedesktop.org/fontconfig/fontconfig.git | export GIT_FONTCONFIG_UPSTREAM=git@xx:yy/fontconfig.git |
126+
| freetype | 2.13.3 | https://gitlab.freedesktop.org/freetype/freetype.git | export GIT_FREETYPE_UPSTREAM = git@xx:yy/freetype.git |
127+
| fribidi | 1.0.16 | https://github.com/fribidi/fribidi.git | export GIT_FRIBIDI_UPSTREAM = git@xx:yy/fribidi.git |
128+
| harfbuzz | 10.2.0 | https://github.com/harfbuzz/harfbuzz.git | export GIT_HARFBUZZ_UPSTREAM = git@xx:yy/harfbuzz.git |
129+
| openssl | 1.1.1w | https://github.com/openssl/openssl.git | export GIT_OPENSSL_UPSTREAM = git@xx:yy/openssl.git |
130+
| opus | 1.5.2 | https://gitlab.xiph.org/xiph/opus.git | export GIT_OPUS_UPSTREAM = git@xx:yy/opus.git |
131+
| smb2 | 6.2 | https://github.com/sahlberg/libsmb2.git | export GIT_SMB2_UPSTREAM=git@xx:yy/libsmb2.git |
132+
| soundtouch | 2.3.3 | https://codeberg.org/soundtouch/soundtouch.git | export GIT_SOUNDTOUCH_UPSTREAM=git@xx:yy/soundtouch.git |
133+
| unibreak | 6.1 | https://github.com/adah1972/libunibreak.git | export GIT_UNIBREAK_UPSTREAM = git@xx:yy/libunibreak.git |
134+
| uavs3d | 1.2.1 | https://github.com/uavs3/uavs3d.git | export GIT_UAVS3D_UPSTREAM=git@xx:yy/UAVS3D.git |
135+
| xml2 | 2.13.6 | https://github.com/GNOME/libxml2.git | export GIT_FONTCONFIG_UPSTREAM=git@xx:yy/fontconfig.git |
136+
| yuv | stable-eb6e7bb | https://github.com/debugly/libyuv.git | export GIT_YUV_UPSTREAM=git@xx:yy/yuv.git |
135137

136138
## Tips
137139

configs/libs/dvdnav.sh

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
#! /usr/bin/env bash
2+
#
3+
# Copyright (C) 2021 Matt Reach<qianlongxu@gmail.com>
4+
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
#
17+
#
18+
#
19+
# brew install nasm
20+
# If you really want to compile without asm, configure with --disable-asm.
21+
22+
# LIB_DEPENDS_BIN using string because bash can't export array chttps://stackoverflow.com/questions/5564418/exporting-an-array-in-bash-script
23+
# configure: error: Package requirements (openssl) were not met
24+
25+
export LIB_NAME='dvdnav'
26+
export LIPO_LIBS="libdvdnav"
27+
export LIB_DEPENDS_BIN="automake autoconf libtool"
28+
export REPO_DIR=dvdnav
29+
export GIT_LOCAL_REPO=extra/$REPO_DIR
30+
export GIT_COMMIT=9831fe01
31+
export GIT_REPO_VERSION=9831fe01
32+
33+
# you can export GIT_DVDNAV_UPSTREAM=git@xx:yy/opusfile.git use your mirror
34+
if [[ "$GIT_DVDNAV_UPSTREAM" != "" ]] ;then
35+
export GIT_UPSTREAM="$GIT_DVDNAV_UPSTREAM"
36+
else
37+
export GIT_UPSTREAM=https://code.videolan.org/videolan/libdvdnav.git
38+
fi
39+
40+
# pre compiled
41+
export PRE_COMPILE_TAG=
42+
export PRE_COMPILE_TAG_TVOS=
43+
export PRE_COMPILE_TAG_MACOS=
44+
export PRE_COMPILE_TAG_IOS=
45+
export PRE_COMPILE_TAG_ANDROID=

do-compile/apple/dvdnav.sh

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
#! /usr/bin/env bash
2+
#
3+
# Copyright (C) 2021 Matt Reach<qianlongxu@gmail.com>
4+
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
#
17+
18+
set -e
19+
20+
THIS_DIR=$(DIRNAME=$(dirname "$0"); cd "$DIRNAME"; pwd)
21+
cd "$THIS_DIR"
22+
23+
# prepare build config
24+
CFG_FLAGS="--prefix=$MR_BUILD_PREFIX --disable-dependency-tracking --disable-silent-rules --disable-apidoc --enable-static --disable-shared"
25+
CFLAGS="$MR_DEFAULT_CFLAGS"
26+
27+
if [[ "$MR_DEBUG" == "debug" ]];then
28+
CFG_FLAGS="${CFG_FLAGS} use_examples=yes"
29+
fi
30+
31+
# for cross compile
32+
if [[ $(uname -m) != "$MR_ARCH" || "$MR_FORCE_CROSS" ]];then
33+
echo "[*] cross compile, on $(uname -m) compile $MR_PLAT $MR_ARCH."
34+
# https://www.gnu.org/software/automake/manual/html_node/Cross_002dCompilation.html
35+
CFLAGS="$CFLAGS -isysroot $MR_SYS_ROOT"
36+
CFG_FLAGS="$CFG_FLAGS --host=$MR_ARCH-apple-darwin --with-sysroot=$MR_SYS_ROOT"
37+
fi
38+
39+
echo "----------------------"
40+
echo "[*] configurate $LIB_NAME"
41+
echo "----------------------"
42+
43+
cd $MR_BUILD_SOURCE
44+
45+
if [[ -f 'configure' ]]; then
46+
echo "reuse configure"
47+
else
48+
echo "auto generate configure"
49+
autoreconf -if >/dev/null
50+
fi
51+
52+
53+
echo
54+
echo "CC: $MR_CC"
55+
echo "CFG_FLAGS: $CFG_FLAGS"
56+
echo "CFLAGS: $CFLAGS"
57+
echo
58+
59+
./configure $CFG_FLAGS \
60+
CC="$MR_CC" \
61+
CFLAGS="$CFLAGS" \
62+
LDFLAGS="$CFLAGS" \
63+
>/dev/null
64+
65+
#----------------------
66+
echo "----------------------"
67+
echo "[*] compile $LIB_NAME"
68+
echo "----------------------"
69+
70+
make install -j$MR_HOST_NPROC >/dev/null

0 commit comments

Comments
 (0)