diff options
author | James Le Cuirot <chewi@gentoo.org> | 2015-12-27 12:05:23 +0000 |
---|---|---|
committer | James Le Cuirot <chewi@gentoo.org> | 2015-12-27 12:09:49 +0000 |
commit | a7865d18b3ecb8fd9fd7da9dc2ad0aba73795d60 (patch) | |
tree | 6af1e97c67efb752ae24ab7c37b1800d59fc7552 /media-video | |
parent | app-text/docbook-xsl-stylesheets: Bump to version 1.79.1 (diff) | |
download | gentoo-a7865d18b3ecb8fd9fd7da9dc2ad0aba73795d60.tar.gz gentoo-a7865d18b3ecb8fd9fd7da9dc2ad0aba73795d60.tar.bz2 gentoo-a7865d18b3ecb8fd9fd7da9dc2ad0aba73795d60.zip |
media-video/makemkv: Add Qt5 support, closes bug #569768
Qt5 always trumps Qt4 if it is available. There are no configure
options or variables to control this and there is no publicly
available configure.ac either so we have to selectively patch the raw
configure script directly.
Also make a couple of simplifications. src_configure checked for a
configure script even though there is always one there now. I also
couldn't see any reason for having virtual/opengl as a dependency.
Package-Manager: portage-2.2.26
Diffstat (limited to 'media-video')
-rw-r--r-- | media-video/makemkv/files/makemkv-qt4.patch | 34 | ||||
-rw-r--r-- | media-video/makemkv/files/makemkv-qt5.patch | 28 | ||||
-rw-r--r-- | media-video/makemkv/makemkv-1.9.8-r1.ebuild (renamed from media-video/makemkv/makemkv-1.9.8.ebuild) | 31 |
3 files changed, 86 insertions, 7 deletions
diff --git a/media-video/makemkv/files/makemkv-qt4.patch b/media-video/makemkv/files/makemkv-qt4.patch new file mode 100644 index 000000000000..cbc2fa08f1ad --- /dev/null +++ b/media-video/makemkv/files/makemkv-qt4.patch @@ -0,0 +1,34 @@ +--- makemkv-oss-1.9.8/configure.orig 2015-12-20 16:22:19.000000000 +0000 ++++ makemkv-oss-1.9.8/configure 2015-12-26 23:59:44.601387071 +0000 +@@ -5048,6 +5048,7 @@ + if test "$enable_gui" != "no"; then + + ++: ' + pkg_failed=no + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for qt5" >&5 + $as_echo_n "checking for qt5... " >&6; } +@@ -5105,6 +5106,7 @@ + fi + # Put the nasty error message in config.log where it belongs + echo "$qt5_PKG_ERRORS" >&5 ++' + + + +@@ -5271,6 +5273,7 @@ + + fi + ++: ' + else + qt5_CFLAGS=$pkg_cv_qt5_CFLAGS + qt5_LIBS=$pkg_cv_qt5_LIBS +@@ -5283,6 +5286,7 @@ + QT_MOC="$qt5_host_bins/moc"; + + fi ++' + + QT_INC=$QT_INC + diff --git a/media-video/makemkv/files/makemkv-qt5.patch b/media-video/makemkv/files/makemkv-qt5.patch new file mode 100644 index 000000000000..58b5e4145a4b --- /dev/null +++ b/media-video/makemkv/files/makemkv-qt5.patch @@ -0,0 +1,28 @@ +--- makemkv-oss-1.9.8/configure.orig 2015-12-20 16:22:19.000000000 +0000 ++++ makemkv-oss-1.9.8/configure 2015-12-27 00:05:18.659860655 +0000 +@@ -5108,6 +5108,7 @@ + + + ++: ' + pkg_failed=no + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for qt4" >&5 + $as_echo_n "checking for qt4... " >&6; } +@@ -5257,7 +5258,9 @@ + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 + $as_echo "no" >&6; } + ++' + as_fn_error $? "Qt library (version 5 or 4) is required to build GUI" "$LINENO" 5 ++: ' + + else + qt4_CFLAGS=$pkg_cv_qt4_CFLAGS +@@ -5270,6 +5273,7 @@ + QT_MOC=`$PKG_CONFIG --variable moc_location "QtCore" 2>/dev/null`; + + fi ++' + + else + qt5_CFLAGS=$pkg_cv_qt5_CFLAGS diff --git a/media-video/makemkv/makemkv-1.9.8.ebuild b/media-video/makemkv/makemkv-1.9.8-r1.ebuild index 74150adfc94b..252dc7308f67 100644 --- a/media-video/makemkv/makemkv-1.9.8.ebuild +++ b/media-video/makemkv/makemkv-1.9.8-r1.ebuild @@ -16,7 +16,8 @@ SRC_URI="http://www.makemkv.com/download/${MY_P}.tar.gz LICENSE="LGPL-2.1 MPL-1.1 MakeMKV-EULA openssl" SLOT="0" KEYWORDS="~amd64 ~x86" -IUSE="libav multilib qt4" +IUSE="libav multilib qt4 qt5" +REQUIRED_USE="?? ( qt4 qt5 )" QA_PREBUILT="opt/bin/makemkvcon opt/bin/mmdtsdec" @@ -26,11 +27,16 @@ RDEPEND=" dev-libs/openssl:0 sys-libs/zlib qt4? ( - virtual/opengl dev-qt/qtcore:4 dev-qt/qtdbus:4 dev-qt/qtgui:4 ) + qt5? ( + dev-qt/qtcore:5 + dev-qt/qtdbus:5 + dev-qt/qtgui:5 + dev-qt/qtwidgets:5 + ) !libav? ( >=media-video/ffmpeg-1.0.0:0= ) libav? ( >=media-video/libav-0.8.9:0= ) " @@ -40,14 +46,25 @@ S=${WORKDIR}/makemkv-oss-${PV} src_prepare() { epatch "${FILESDIR}"/${PN}-{makefile,path}.patch + + # Qt5 always trumps Qt4 if it is available. There are no configure + # options or variables to control this and there is no publicly + # available configure.ac either. + if use qt4; then + epatch "${FILESDIR}"/${PN}-qt4.patch + elif use qt5; then + epatch "${FILESDIR}"/${PN}-qt5.patch + fi } src_configure() { + # See bug #439380. replace-flags -O* -Os - local args="" - use qt4 || args="--disable-gui" - if [[ -x ${ECONF_SOURCE:-.}/configure ]] ; then - econf $args + + if use qt4 || use qt5; then + econf --enable-gui + else + econf --disable-gui fi } @@ -68,7 +85,7 @@ src_install() { dosym libmmbd.so.0 /usr/$(get_libdir)/libmmbd.so.0.${PV} into /opt - if use qt4; then + if use qt4 || use qt5; then dobin out/makemkv local res |