mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
mpv: bump version
* enable shared lib * build devel package
This commit is contained in:
@@ -1,155 +0,0 @@
|
||||
SUMMARY="A free, open source, and cross-platform media player"
|
||||
DESCRIPTION="mpv is a media player based on MPlayer and mplayer2. It supports \
|
||||
a wide variety of video file formats, audio and video codecs, and subtitle \
|
||||
types."
|
||||
HOMEPAGE="https://mpv.io/"
|
||||
COPYRIGHT="2013-2018 MPV Developers"
|
||||
LICENSE="GNU GPL v2"
|
||||
REVISION="3"
|
||||
SOURCE_URI="https://github.com/mpv-player/mpv/archive/v$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="2ad104d83fd3b2b9457716615acad57e479fd1537b8fc5e37bfe9065359b50be"
|
||||
SOURCE_FILENAME="mpv-$portVersion.tar.gz"
|
||||
SOURCE_FILENAME_2="waf-1.9.12"
|
||||
SOURCE_URI_2="https://waf.io/$SOURCE_FILENAME_2#noarchive
|
||||
http://www.freehackers.org/~tnagy/release/$SOURCE_FILENAME_2#noarchive"
|
||||
CHECKSUM_SHA256_2="66f3983fcc6dc0d17393514b2b52063702004800428327db3597754dd05c3fbc"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2 x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
commandSuffix=$secondaryArchSuffix
|
||||
commandBinDir=$binDir
|
||||
if [ "$targetArchitecture" = x86_gcc2 ]; then
|
||||
commandSuffix=
|
||||
commandBinDir=$prefix/bin
|
||||
fi
|
||||
|
||||
libVersion="1.25.0"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
mpv$secondaryArchSuffix = $portVersion
|
||||
cmd:mpv$commandSuffix
|
||||
lib:libmpv$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libarchive$secondaryArchSuffix
|
||||
lib:libass$secondaryArchSuffix
|
||||
lib:libavcodec$secondaryArchSuffix
|
||||
lib:libavdevice$secondaryArchSuffix
|
||||
lib:libavformat$secondaryArchSuffix
|
||||
lib:libavfilter$secondaryArchSuffix
|
||||
lib:libavutil$secondaryArchSuffix
|
||||
lib:libbluray$secondaryArchSuffix
|
||||
lib:libdvdnav$secondaryArchSuffix
|
||||
lib:libdvdread$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libjpeg$secondaryArchSuffix
|
||||
lib:liblcms2$secondaryArchSuffix
|
||||
lib:libopenal$secondaryArchSuffix
|
||||
lib:librubberband$secondaryArchSuffix
|
||||
lib:libSDL2_2.0$secondaryArchSuffix
|
||||
lib:libsmbclient$secondaryArchSuffix
|
||||
lib:libswresample$secondaryArchSuffix
|
||||
lib:libswscale$secondaryArchSuffix
|
||||
lib:libuchardet$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
mpv${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libmpv$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES_devel="
|
||||
mpv$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
|
||||
|
||||
BUILD_REQUIRES="
|
||||
devel:libarchive$secondaryArchSuffix
|
||||
devel:libass$secondaryArchSuffix
|
||||
devel:libavcodec$secondaryArchSuffix >= 57
|
||||
devel:libavdevice$secondaryArchSuffix >= 57
|
||||
devel:libavformat$secondaryArchSuffix >= 57
|
||||
devel:libavfilter$secondaryArchSuffix
|
||||
devel:libavutil$secondaryArchSuffix >= 55
|
||||
devel:libbluray$secondaryArchSuffix
|
||||
devel:libcdio$secondaryArchSuffix
|
||||
devel:libdvdcss$secondaryArchSuffix
|
||||
devel:libdvdnav$secondaryArchSuffix
|
||||
devel:libdvdread$secondaryArchSuffix
|
||||
devel:libenca$secondaryArchSuffix
|
||||
devel:libfontconfig$secondaryArchSuffix
|
||||
devel:libfreetype$secondaryArchSuffix
|
||||
devel:libfribidi$secondaryArchSuffix
|
||||
devel:libgl$secondaryArchSuffix
|
||||
devel:libglib_2.0$secondaryArchSuffix
|
||||
devel:libharfbuzz$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libjpeg$secondaryArchSuffix
|
||||
devel:liblcms2$secondaryArchSuffix
|
||||
devel:libmpg123$secondaryArchSuffix
|
||||
devel:libopenal$secondaryArchSuffix
|
||||
devel:librubberband$secondaryArchSuffix
|
||||
devel:libSDL2_2.0$secondaryArchSuffix
|
||||
devel:libsmbclient$secondaryArchSuffix
|
||||
devel:libswresample$secondaryArchSuffix
|
||||
devel:libswscale$secondaryArchSuffix
|
||||
devel:libuchardet$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:perl
|
||||
cmd:python
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:yasm
|
||||
"
|
||||
|
||||
GLOBAL_WRITABLE_FILES="settings/mpv/encoding-profiles.conf keep-old"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
# Do not call "python bootstrap.py" as it (only) downloads waf.
|
||||
# python bootstrap.py
|
||||
# Instead, copy the archive from SOURCE_URI_2.
|
||||
cp $sourceDir2/$SOURCE_FILENAME_2 waf
|
||||
chmod +x waf
|
||||
|
||||
export LDFLAGS=-lnetwork
|
||||
waf configure \
|
||||
--enable-dvdread \
|
||||
--enable-dvdnav \
|
||||
--enable-libarchive \
|
||||
--enable-libsmbclient \
|
||||
--enable-openal \
|
||||
--enable-sdl2 \
|
||||
--disable-gl \
|
||||
--enable-libmpv-shared \
|
||||
--enable-libarchive \
|
||||
--bindir=$commandBinDir \
|
||||
--confdir=$sysconfDir/mpv \
|
||||
--datadir=$dataDir \
|
||||
--prefix=$prefix
|
||||
|
||||
waf build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
waf install
|
||||
rm -rf $dataDir/applications
|
||||
rm -rf $dataDir/icons
|
||||
|
||||
mkdir -p $includeDir
|
||||
mv $prefix/include/* $includeDir
|
||||
rmdir $prefix/include
|
||||
|
||||
prepareInstalledDevelLib libmpv
|
||||
fixPkgconfig
|
||||
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
@@ -7,12 +7,13 @@ COPYRIGHT="2013-2018 MPV Developers"
|
||||
LICENSE="GNU GPL v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/mpv-player/mpv/archive/v$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="aada14e025317b5b3e8e58ffaf7902e8b6e4ec347a93d25a7c10d3579426d795"
|
||||
CHECKSUM_SHA256="772af878cee5495dcd342788a6d120b90c5b1e677e225c7198f1e76506427319"
|
||||
SOURCE_FILENAME="mpv-$portVersion.tar.gz"
|
||||
SOURCE_URI_2="https://waf.io/$SOURCE_FILENAME_2#noarchive
|
||||
http://www.freehackers.org/~tnagy/release/$SOURCE_FILENAME_2#noarchive"
|
||||
CHECKSUM_SHA256_2="66f3983fcc6dc0d17393514b2b52063702004800428327db3597754dd05c3fbc"
|
||||
SOURCE_FILENAME_2="waf-1.9.12"
|
||||
wafVersion="2.0.11"
|
||||
SOURCE_URI_2="https://waf.io/waf-$wafVersion#noarchive"
|
||||
CHECKSUM_SHA256_2="25807bc064dce3fe66eab5977ed5730f3b59af981c028a0dc4f889cd64b80928"
|
||||
SOURCE_FILENAME_2="waf-$wafVersion"
|
||||
PATCHES="mpv-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2 x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
@@ -21,14 +22,13 @@ GLOBAL_WRITABLE_FILES="settings/mpv/encoding-profiles.conf keep-old"
|
||||
|
||||
PROVIDES="
|
||||
mpv$secondaryArchSuffix = $portVersion
|
||||
cmd:mpv$secondaryArchSuffix
|
||||
lib:libmpv$secondaryArchSuffix = 1.101.0 compat >= 1
|
||||
cmd:mpv$secondaryArchSuffix = $portVersion compat >= 0.29
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
# lib:libarchive$secondaryArchSuffix
|
||||
lib:libass$secondaryArchSuffix
|
||||
lib:libavcodec$secondaryArchSuffix
|
||||
# lib:libavdevice$secondaryArchSuffix
|
||||
lib:libavfilter$secondaryArchSuffix
|
||||
lib:libavformat$secondaryArchSuffix
|
||||
lib:libavutil$secondaryArchSuffix
|
||||
@@ -38,7 +38,6 @@ REQUIRES="
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libjpeg$secondaryArchSuffix
|
||||
lib:liblcms2$secondaryArchSuffix
|
||||
lib:libopenal$secondaryArchSuffix
|
||||
lib:librubberband$secondaryArchSuffix
|
||||
lib:libSDL2_2.0$secondaryArchSuffix
|
||||
lib:libsmbclient$secondaryArchSuffix
|
||||
@@ -48,11 +47,18 @@ REQUIRES="
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
mpv${secondaryArchSuffix}_devel = $portVersion compat >= 0.29
|
||||
devel:libmpv$secondaryArchSuffix = 1.101.0 compat >= 1
|
||||
"
|
||||
REQUIRES_devel="
|
||||
mpv$secondaryArchSuffix == $portVersion base
|
||||
haiku$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
# devel:libarchive$secondaryArchSuffix
|
||||
devel:libass$secondaryArchSuffix
|
||||
devel:libavcodec$secondaryArchSuffix
|
||||
# devel:libavdevice$secondaryArchSuffix
|
||||
devel:libavfilter$secondaryArchSuffix
|
||||
devel:libavformat$secondaryArchSuffix
|
||||
devel:libavutil$secondaryArchSuffix
|
||||
@@ -72,7 +78,6 @@ BUILD_REQUIRES="
|
||||
devel:libjpeg$secondaryArchSuffix
|
||||
devel:liblcms2$secondaryArchSuffix
|
||||
devel:libmpg123$secondaryArchSuffix
|
||||
devel:libopenal$secondaryArchSuffix
|
||||
devel:librubberband$secondaryArchSuffix
|
||||
devel:libSDL2_2.0$secondaryArchSuffix
|
||||
devel:libsmbclient$secondaryArchSuffix
|
||||
@@ -99,19 +104,23 @@ BUILD()
|
||||
chmod +x waf
|
||||
|
||||
export LDFLAGS=-lnetwork
|
||||
# --disable-avdeevice added, because lazy to debug.
|
||||
|
||||
waf configure \
|
||||
--enable-dvdread \
|
||||
--enable-dvdnav \
|
||||
--enable-libsmbclient \
|
||||
--disable-libavdevice \
|
||||
--enable-openal \
|
||||
--disable-openal \
|
||||
--disable-libmpv-static \
|
||||
--disable-static-build \
|
||||
--enable-libmpv-shared \
|
||||
--enable-sdl2 \
|
||||
--bindir=$binDir \
|
||||
--confdir=$settingsDir/mpv \
|
||||
--disable-gl \
|
||||
--datadir=$dataDir
|
||||
# --enable-libarchive \
|
||||
--datadir=$dataDir \
|
||||
--libdir=$libDir \
|
||||
--includedir=$includeDir
|
||||
|
||||
waf build
|
||||
}
|
||||
@@ -121,4 +130,11 @@ INSTALL()
|
||||
waf install
|
||||
rm -rf $dataDir/applications
|
||||
rm -rf $dataDir/icons
|
||||
|
||||
prepareInstalledDevelLibs libmpv
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel $developDir
|
||||
}
|
||||
30
media-video/mpv/patches/mpv-0.29.0.patchset
Normal file
30
media-video/mpv/patches/mpv-0.29.0.patchset
Normal file
@@ -0,0 +1,30 @@
|
||||
From eb5d9214f0314a13c7cb245d9950c5c9aa180f61 Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Fri, 7 Sep 2018 22:22:58 +1000
|
||||
Subject: disable setlocale for haiku
|
||||
|
||||
|
||||
diff --git a/player/main.c b/player/main.c
|
||||
index f56191a..89aa0cd 100644
|
||||
--- a/player/main.c
|
||||
+++ b/player/main.c
|
||||
@@ -257,6 +257,7 @@ static bool check_locale(void)
|
||||
|
||||
struct MPContext *mp_create(void)
|
||||
{
|
||||
+#ifndef __HAIKU__
|
||||
if (!check_locale()) {
|
||||
// Normally, we never print anything (except if the "terminal" option
|
||||
// is enabled), so this is an exception.
|
||||
@@ -264,7 +265,7 @@ struct MPContext *mp_create(void)
|
||||
"Call 'setlocale(LC_NUMERIC, \"C\");' in your code.\n");
|
||||
return NULL;
|
||||
}
|
||||
-
|
||||
+#endif
|
||||
char *enable_talloc = getenv("MPV_LEAK_REPORT");
|
||||
if (enable_talloc && strcmp(enable_talloc, "1") == 0)
|
||||
talloc_enable_leak_report();
|
||||
--
|
||||
2.16.4
|
||||
|
||||
Reference in New Issue
Block a user