diff options
author | Karlson2k (Evgeny Grin) <k2k@narod.ru> | 2020-08-03 18:20:54 +0300 |
---|---|---|
committer | Craig Andrews <candrews@gentoo.org> | 2020-08-13 16:50:42 -0400 |
commit | 70fedb745cb43cbcf5b14b23da7ffe046333ca43 (patch) | |
tree | 419b7429e077a51cba4606f7d3c03bb8e0f47d08 /media-video | |
parent | media-plugins/kodi-inputstream-rtmp: fixed deps, corrected licence pkg-config... (diff) | |
download | gentoo-70fedb745cb43cbcf5b14b23da7ffe046333ca43.tar.gz gentoo-70fedb745cb43cbcf5b14b23da7ffe046333ca43.tar.bz2 gentoo-70fedb745cb43cbcf5b14b23da7ffe046333ca43.zip |
media-video/rtmpdump: Updated, added USE flags to build lib only Updated to the latest patch Minor ebuild files improvements Added use flags descriptions to metadata.xml
Signed-off-by: Karlson2k (Evgeny Grin) <k2k@narod.ru>
Closes: https://github.com/gentoo/gentoo/pull/16975
Signed-off-by: Craig Andrews <candrews@gentoo.org>
Diffstat (limited to 'media-video')
-rw-r--r-- | media-video/rtmpdump/Manifest | 1 | ||||
-rw-r--r-- | media-video/rtmpdump/metadata.xml | 7 | ||||
-rw-r--r-- | media-video/rtmpdump/rtmpdump-2.4_p20190330.ebuild | 98 | ||||
-rw-r--r-- | media-video/rtmpdump/rtmpdump-9999.ebuild | 47 |
4 files changed, 127 insertions, 26 deletions
diff --git a/media-video/rtmpdump/Manifest b/media-video/rtmpdump/Manifest index 9a19ee5b2cbd..544f56a93968 100644 --- a/media-video/rtmpdump/Manifest +++ b/media-video/rtmpdump/Manifest @@ -1 +1,2 @@ DIST rtmpdump-2.4_p20161210.tar.gz 142837 BLAKE2B 412a7c3b21738db643042e51e03b11e115ae1d68214e644374e8c10f3b2ab3f659ce1af884135d0e89f2e0ba44ebdf41937bc0f02d875c463ca711d9ae95698c SHA512 76617f02c13d7e8e3a7cf2734c6174e56fb321a881c9e4869bf6393786b193e0c01a8c530ecbf0679cc888c523af5712f2dcb2031fbd09729b7ddeebc3a4b133 +DIST rtmpdump-2.4_p20190330.tar.gz 143037 BLAKE2B ab0edbca444fc71034a1c6386f304d8f49f92075f6d4ca87992a7b9c4b4058f84333011e86cf38470f7b1dbf5e69f27e8b1fe34267104191c447342a03c18e3c SHA512 5357d01b51d3ec8c3c584c4e5aa9720a4c04b86573bc6cb7d724d660937b04b6dd35338b17721d6521fde2627e83763ed3b7c010f959bd72573016f3c47480b0 diff --git a/media-video/rtmpdump/metadata.xml b/media-video/rtmpdump/metadata.xml index b36893c1b2a1..77d74434352c 100644 --- a/media-video/rtmpdump/metadata.xml +++ b/media-video/rtmpdump/metadata.xml @@ -9,5 +9,12 @@ rtmpdump is a toolkit for RTMP streams. All forms of RTMP are supported, including rtmp://, rtmpt://, rtmpe://, rtmpte://, and rtmps://. + Includes librtmp library. </longdescription> + <use> + <flag name="ssl">Enable Cryptographic features</flag> + <flag name="gnutls">Use GnuTLS instead of OpenSSL for Cryptography</flag> + <flag name="libressl">Use LibreSSL instead of OpenSSL for Cryptography</flag> + <flag name="tools">Enable installation of various binary tools in addition to librtmp library</flag> + </use> </pkgmetadata> diff --git a/media-video/rtmpdump/rtmpdump-2.4_p20190330.ebuild b/media-video/rtmpdump/rtmpdump-2.4_p20190330.ebuild new file mode 100644 index 000000000000..c5698f9c7a33 --- /dev/null +++ b/media-video/rtmpdump/rtmpdump-2.4_p20190330.ebuild @@ -0,0 +1,98 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit multilib toolchain-funcs multilib-minimal flag-o-matic + +DESCRIPTION="RTMP client, librtmp library intended to stream audio or video flash content" +HOMEPAGE="https://rtmpdump.mplayerhq.hu/" + +# the library is LGPL-2.1, the command is GPL-2 +LICENSE="LGPL-2.1 tools? ( GPL-2 )" +SLOT="0" +IUSE="gnutls ssl static-libs +tools libressl" + +REQUIRED_USE="?? ( gnutls libressl )" + +DEPEND="ssl? ( + gnutls? ( + >=net-libs/gnutls-2.12.23-r6[${MULTILIB_USEDEP},nettle(+)] + dev-libs/nettle:0=[${MULTILIB_USEDEP}] + ) + libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP}] ) + !gnutls? ( !libressl? ( dev-libs/openssl:0=[${MULTILIB_USEDEP}] ) ) + >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] + )" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-swf_vertification_type_2.patch" + "${FILESDIR}/${PN}-swf_vertification_type_2_part_2.patch" +) + +if [[ ${PV} == *9999 ]] ; then + SRC_URI="" + EGIT_REPO_URI="https://git.ffmpeg.org/rtmpdump.git" + inherit git-r3 +else + KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" + SRC_URI="http://git.ffmpeg.org/gitweb/rtmpdump.git/snapshot/c5f04a58fc2aeea6296ca7c44ee4734c18401aa3.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${PN}-c5f04a5" +fi + +pkg_setup() { + if ! use ssl; then + if use gnutls; then + ewarn "USE='gnutls' is ignored without USE='ssl'." + ewarn "Please review the local USE flags for this package." + fi + if use libressl; then + ewarn "USE='libressl' is ignored without USE='ssl'." + ewarn "Please review the local USE flags for this package." + fi + fi +} + +src_prepare() { + # fix #571106 by restoring pre-GCC5 inline semantics + append-cflags -std=gnu89 + # fix Makefile ( bug #298535 , bug #318353 and bug #324513 ) + sed -i 's/\$(MAKEFLAGS)//g' Makefile \ + || die "failed to fix Makefile" + sed -i -e 's:OPT=:&-fPIC :' \ + -e 's:OPT:OPTS:' \ + -e 's:CFLAGS=.*:& $(OPT):' librtmp/Makefile \ + || die "failed to fix Makefile" + use ssl && use !gnutls && use !libressl && eapply "${FILESDIR}/${PN}-openssl-1.1-v2.patch" + default + multilib_copy_sources +} + +multilib_src_compile() { + if use ssl ; then + if use gnutls ; then + crypto="GNUTLS" + else + crypto="OPENSSL" + fi + fi + if ! multilib_is_native_abi || ! use tools ; then + cd librtmp || die + fi + emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" \ + OPT="${CFLAGS}" XLDFLAGS="${LDFLAGS}" CRYPTO="${crypto}" SYS=posix +} + +multilib_src_install() { + mkdir -p "${ED}"/usr/$(get_libdir) || die + if multilib_is_native_abi && use tools ; then + dodoc README ChangeLog rtmpdump.1.html rtmpgw.8.html + else + cd librtmp || die + fi + emake DESTDIR="${D}" prefix="${EPREFIX}/usr" mandir='$(prefix)/share/man' \ + CRYPTO="${crypto}" libdir="${EPREFIX}/usr/$(get_libdir)" install + find "${D}" -name '*.la' -delete || die + use static-libs || find "${D}" -name '*.a' -delete || die +} diff --git a/media-video/rtmpdump/rtmpdump-9999.ebuild b/media-video/rtmpdump/rtmpdump-9999.ebuild index 4e6b50ef0fc2..c5698f9c7a33 100644 --- a/media-video/rtmpdump/rtmpdump-9999.ebuild +++ b/media-video/rtmpdump/rtmpdump-9999.ebuild @@ -5,23 +5,23 @@ EAPI="7" inherit multilib toolchain-funcs multilib-minimal flag-o-matic -DESCRIPTION="RTMP client intended to stream audio or video flash content" +DESCRIPTION="RTMP client, librtmp library intended to stream audio or video flash content" HOMEPAGE="https://rtmpdump.mplayerhq.hu/" # the library is LGPL-2.1, the command is GPL-2 -LICENSE="GPL-2 LGPL-2.1" +LICENSE="LGPL-2.1 tools? ( GPL-2 )" SLOT="0" -IUSE="gnutls ssl static-libs libressl" +IUSE="gnutls ssl static-libs +tools libressl" + +REQUIRED_USE="?? ( gnutls libressl )" DEPEND="ssl? ( gnutls? ( >=net-libs/gnutls-2.12.23-r6[${MULTILIB_USEDEP},nettle(+)] dev-libs/nettle:0=[${MULTILIB_USEDEP}] ) - !gnutls? ( - !libressl? ( dev-libs/openssl:0=[${MULTILIB_USEDEP}] ) - libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP}] ) - ) + libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP}] ) + !gnutls? ( !libressl? ( dev-libs/openssl:0=[${MULTILIB_USEDEP}] ) ) >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )" RDEPEND="${DEPEND}" @@ -37,23 +37,20 @@ if [[ ${PV} == *9999 ]] ; then inherit git-r3 else KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" - SRC_URI="https://dev.gentoo.org/~hwoarang/distfiles/${P}.tar.gz" + SRC_URI="http://git.ffmpeg.org/gitweb/rtmpdump.git/snapshot/c5f04a58fc2aeea6296ca7c44ee4734c18401aa3.tar.gz -> ${P}.tar.gz" + S="${WORKDIR}/${PN}-c5f04a5" fi pkg_setup() { - if ! use ssl && use gnutls ; then - ewarn "USE='gnutls' is ignored without USE='ssl'." - ewarn "Please review the local USE flags for this package." - fi -} - -src_unpack() { - if [[ ${PV} == *9999 ]] ; then - git-r3_src_unpack - else - mkdir -p "${S}" || die "Can't create source directory" - cd "${S}" || die - unpack ${A} + if ! use ssl; then + if use gnutls; then + ewarn "USE='gnutls' is ignored without USE='ssl'." + ewarn "Please review the local USE flags for this package." + fi + if use libressl; then + ewarn "USE='libressl' is ignored without USE='ssl'." + ewarn "Please review the local USE flags for this package." + fi fi } @@ -80,9 +77,7 @@ multilib_src_compile() { crypto="OPENSSL" fi fi - #fix multilib-script support. Bug #327449 - sed -i "/^libdir/s:lib$:$(get_libdir):" librtmp/Makefile || die - if ! multilib_is_native_abi; then + if ! multilib_is_native_abi || ! use tools ; then cd librtmp || die fi emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" \ @@ -91,13 +86,13 @@ multilib_src_compile() { multilib_src_install() { mkdir -p "${ED}"/usr/$(get_libdir) || die - if multilib_is_native_abi; then + if multilib_is_native_abi && use tools ; then dodoc README ChangeLog rtmpdump.1.html rtmpgw.8.html else cd librtmp || die fi emake DESTDIR="${D}" prefix="${EPREFIX}/usr" mandir='$(prefix)/share/man' \ - CRYPTO="${crypto}" install + CRYPTO="${crypto}" libdir="${EPREFIX}/usr/$(get_libdir)" install find "${D}" -name '*.la' -delete || die use static-libs || find "${D}" -name '*.a' -delete || die } |