add multilib aware gst-plugins
git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/linamh@2776 6952d904-891a-0410-993b-d76249ca496b
This commit is contained in:
127
eclass/gst-plugins-bad.eclass
Normal file
127
eclass/gst-plugins-bad.eclass
Normal file
@@ -0,0 +1,127 @@
|
||||
# Copyright 1999-2009 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-bad.eclass,v 1.34 2010/07/30 12:00:43 leio Exp $
|
||||
|
||||
#
|
||||
# Original Author: Saleem Abdulrasool <compnerd@gentoo.org>
|
||||
# Based on the work of foser <foser@gentoo.org> and zaheerm <zaheerm@gentoo.org>
|
||||
# Purpose: This elcass is designed to help package external gst-plugins per
|
||||
# plugin rather than in a single package.
|
||||
#
|
||||
|
||||
inherit eutils versionator gst-plugins10
|
||||
|
||||
# This list is current for gst-plugins-bad-0.10.18.
|
||||
my_gst_plugins_bad="directsound directdraw osx_video quicktime vcd
|
||||
alsa assrender amrwb apexsink bz2 cdaudio celt cog dc1394 directfb dirac dts divx
|
||||
metadata faac faad fbdev flite gsm jack jp2k kate ladspa lv2 libmms
|
||||
modplug mimic mpeg2enc mplex musepack musicbrainz mythtv nas neon ofa rsvg
|
||||
timidity wildmidi sdl sdltest sndfile soundtouch spc gme swfdec theoradec xvid
|
||||
dvb wininet acm vdpau schro zbar"
|
||||
|
||||
# When adding conditionals like below, be careful about having leading spaces
|
||||
|
||||
# Changes in 0.10.19:
|
||||
# dvdnav configure option changed from --enable-dvdnav to --enable-resindvd
|
||||
if version_is_at_least "0.10.19"; then
|
||||
my_gst_plugins_bad+=" resindvd vp8"
|
||||
fi
|
||||
|
||||
# dvdnav configure option changed from --enable-dvdnav to --enable-resindvd
|
||||
# oss4 moved to -good
|
||||
if ! version_is_at_least "0.10.19"; then
|
||||
my_gst_plugins_bad+=" dvdnav oss4"
|
||||
fi
|
||||
|
||||
# Changes in 0.10.18:
|
||||
# ivorbis gone (moved to -base-0.10.27 as part of vorbis plugin)
|
||||
if ! version_is_at_least "0.10.18"; then
|
||||
my_gst_plugins_bad+=" ivorbis"
|
||||
fi
|
||||
|
||||
MY_PN="gst-plugins-bad"
|
||||
MY_P=${MY_PN}-${PV}
|
||||
|
||||
SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-bad/${MY_P}.tar.bz2"
|
||||
if [ ${PV} == "0.10.14" ]; then
|
||||
SRC_URI="${SRC_URI} http://dev.gentoo.org/~leio/distfiles/gst-plugins-bad-0.10.14-kate-configure-fix.patch.bz2"
|
||||
fi
|
||||
|
||||
# added to remove circular deps
|
||||
# 6/2/2006 - zaheerm
|
||||
if [ "${PN}" != "${MY_PN}" ]; then
|
||||
RDEPEND="=media-libs/gstreamer-0.10*
|
||||
=media-libs/gst-plugins-base-0.10*
|
||||
>=dev-libs/glib-2.6
|
||||
>=dev-libs/liboil-0.3.8"
|
||||
DEPEND="${RDEPEND}
|
||||
sys-apps/sed
|
||||
dev-util/pkgconfig
|
||||
sys-devel/gettext"
|
||||
RESTRICT=test
|
||||
fi
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
gst-plugins-bad_src_unpack() {
|
||||
# local makefiles
|
||||
|
||||
unpack ${A}
|
||||
|
||||
# Link with the syswide installed gst-libs if needed
|
||||
gst-plugins10_find_plugin_dir
|
||||
sed -e "s:\$(top_builddir)/gst-libs/gst/interfaces/libgstphotography-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstphotography-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/signalprocessor/libgstsignalprocessor-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstsignalprocessor-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/video/libgstbasevideo-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstbasevideo-\$(GST_MAJORMINOR).so:" \
|
||||
-i Makefile.in
|
||||
|
||||
# 0.10.14 configure errors when --disable-kate is passed:
|
||||
# configure: error: conditional "USE_TIGER" was never defined.
|
||||
# Fix it - this has to stay until any 0.10.14 split or main is in tree:
|
||||
if [ ${PV} == "0.10.14" ]; then
|
||||
cd ${S}
|
||||
epatch "${WORKDIR}/gst-plugins-bad-0.10.14-kate-configure-fix.patch"
|
||||
fi
|
||||
|
||||
# Remove generation of any other Makefiles except the plugin's Makefile
|
||||
# if [[ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]] ; then
|
||||
# makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# elif [[ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]] ; then
|
||||
# makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# fi
|
||||
|
||||
# sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
|
||||
# -i ${S}/configure
|
||||
}
|
||||
|
||||
gst-plugins-bad_src_configure() {
|
||||
local plugin gst_conf
|
||||
|
||||
einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..."
|
||||
|
||||
for plugin in ${my_gst_plugins_bad} ; do
|
||||
gst_conf="${gst_conf} --disable-${plugin}"
|
||||
done
|
||||
|
||||
for plugin in ${GST_PLUGINS_BUILD} ; do
|
||||
gst_conf="${gst_conf} --enable-${plugin}"
|
||||
done
|
||||
|
||||
cd ${S}
|
||||
econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf} || die "configure failed"
|
||||
}
|
||||
|
||||
gst-plugins-bad_src_compile() {
|
||||
gst-plugins-bad_src_configure ${@}
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
emake || die "compile failure"
|
||||
}
|
||||
|
||||
gst-plugins-bad_src_install() {
|
||||
gst-plugins10_find_plugin_dir
|
||||
einstall || die "install failed"
|
||||
|
||||
[[ -e README ]] && dodoc README
|
||||
}
|
||||
|
||||
EXPORT_FUNCTIONS src_unpack src_compile src_install
|
||||
143
eclass/gst-plugins-base.eclass
Normal file
143
eclass/gst-plugins-base.eclass
Normal file
@@ -0,0 +1,143 @@
|
||||
# Copyright 1999-2004 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-base.eclass,v 1.18 2010/08/12 10:53:57 pva Exp $
|
||||
|
||||
# Author : foser <foser@gentoo.org>
|
||||
|
||||
# gst-plugins eclass
|
||||
#
|
||||
# eclass to make external gst-plugins emergable on a per-plugin basis
|
||||
# to solve the problem with gst-plugins generating far too much unneeded deps
|
||||
#
|
||||
# 3rd party applications using gstreamer now should depend on a set of plugins as
|
||||
# defined in the source, in case of spider usage obtain recommended plugins to use from
|
||||
# Gentoo developers responsible for gstreamer <gnome@gentoo.org>, the application developer
|
||||
# or the gstreamer team.
|
||||
|
||||
inherit eutils gst-plugins10
|
||||
|
||||
GST_EXPF="src_unpack src_compile src_install"
|
||||
case ${EAPI:-0} in
|
||||
2|3) GST_EXPF="${GST_EXPF} src_prepare src_configure" ;;
|
||||
1|0) ;;
|
||||
*) die "Unknown EAPI" ;;
|
||||
esac
|
||||
EXPORT_FUNCTIONS ${GST_EXPF}
|
||||
|
||||
###
|
||||
# variable declarations
|
||||
###
|
||||
|
||||
MY_PN=gst-plugins-base
|
||||
MY_P=${MY_PN}-${PV}
|
||||
# All relevant configure options for gst-plugins
|
||||
# need a better way to extract these
|
||||
# gst-plugins-base 0.9
|
||||
my_gst_plugins_base="x xvideo xshm gst_v4l alsa cdparanoia gnome_vfs
|
||||
gio libvisual ogg oggtest theora ivorbis vorbis vorbistest examples
|
||||
freetypetest pango"
|
||||
|
||||
#SRC_URI="mirror://gnome/sources/gst-plugins/${PV_MAJ_MIN}/${MY_P}.tar.bz2"
|
||||
SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-base/${MY_P}.tar.bz2"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
# added to remove circular deps
|
||||
# 6/2/2006 - zaheerm
|
||||
if [ "${PN}" != "${MY_PN}" ]; then
|
||||
RDEPEND=">=media-libs/gst-plugins-base-${PV}"
|
||||
DEPEND="${RDEPEND}
|
||||
~media-libs/gst-plugins-base-${PV}
|
||||
>=sys-apps/sed-4
|
||||
dev-util/pkgconfig"
|
||||
RESTRICT=test
|
||||
fi
|
||||
|
||||
###
|
||||
# public functions
|
||||
###
|
||||
|
||||
gst-plugins-base_src_configure() {
|
||||
|
||||
# disable any external plugin besides the plugin we want
|
||||
local plugin gst_conf
|
||||
|
||||
einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..."
|
||||
|
||||
for plugin in ${my_gst_plugins_base}; do
|
||||
gst_conf="${gst_conf} --disable-${plugin} "
|
||||
done
|
||||
|
||||
for plugin in ${GST_PLUGINS_BUILD}; do
|
||||
gst_conf="${gst_conf} --enable-${plugin} "
|
||||
done
|
||||
|
||||
cd "${S}"
|
||||
econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf}
|
||||
|
||||
}
|
||||
|
||||
###
|
||||
# public inheritable functions
|
||||
###
|
||||
|
||||
gst-plugins-base_src_unpack() {
|
||||
|
||||
unpack ${A}
|
||||
|
||||
cd "${S}"
|
||||
has src_prepare ${GST_EXPF} || gst-plugins-base_src_prepare
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-base_src_prepare() {
|
||||
|
||||
# Link with the syswide installed gst-libs if needed
|
||||
gst-plugins10_find_plugin_dir
|
||||
sed -e "s:\$(top_builddir)/gst-libs/gst/interfaces/libgstinterfaces-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstinterfaces-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/interfaces/libgstinterfaces-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstinterfaces-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/audio/libgstaudio-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstaudio-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/audio/libgstaudio-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstaudio-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/cdda/libgstcdda-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstcdda-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/cdda/libgstcdda-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstcdda-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/riff/libgstriff-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstriff-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/riff/libgstriff-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstriff-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/tag/libgsttag-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgsttag-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/tag/libgsttag-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgsttag-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/video/libgstvideo-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstvideo-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/video/libgstvideo-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstvideo-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/netbuffer/libgstnetbuffer-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstnetbuffer-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/netbuffer/libgstnetbuffer-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstnetbuffer-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\$(top_builddir)/gst-libs/gst/rtp/libgstrtp-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstrtp-\$(GST_MAJORMINOR).so:" \
|
||||
-e "s:\${top_builddir}/gst-libs/gst/rtp/libgstrtp-\$(GST_MAJORMINOR).la:${ROOT}/usr/$(get_libdir)/libgstrtp-\$(GST_MAJORMINOR).so:" \
|
||||
-i Makefile.in
|
||||
# cd ${S}
|
||||
|
||||
# Remove generation of any other Makefiles except the plugin's Makefile
|
||||
# if [ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# elif [ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# fi
|
||||
# sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
|
||||
# -i ${S}/configure
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
gst-plugins-base_src_compile() {
|
||||
|
||||
has src_configure ${GST_EXPF} || gst-plugins-base_src_configure ${@}
|
||||
gst-plugins10_find_plugin_dir
|
||||
emake || die "compile failure"
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-base_src_install() {
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
einstall || die
|
||||
|
||||
[[ -e README ]] && dodoc README
|
||||
}
|
||||
127
eclass/gst-plugins-good.eclass
Normal file
127
eclass/gst-plugins-good.eclass
Normal file
@@ -0,0 +1,127 @@
|
||||
# Copyright 1999-2004 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-good.eclass,v 1.21 2010/07/30 11:08:44 leio Exp $
|
||||
|
||||
# Author : foser <foser@gentoo.org>, zaheerm <zaheerm@gentoo.org>
|
||||
|
||||
# gst-plugins-good eclass
|
||||
#
|
||||
# eclass to make external gst-plugins emergable on a per-plugin basis
|
||||
# to solve the problem with gst-plugins generating far too much unneeded deps
|
||||
#
|
||||
# 3rd party applications using gstreamer now should depend on a set of plugins as
|
||||
# defined in the source, obtain recommended plugins to use from
|
||||
# Gentoo developers responsible for gstreamer <gnome@gentoo.org>, the application developer
|
||||
# or the gstreamer team.
|
||||
|
||||
inherit eutils versionator gst-plugins10
|
||||
|
||||
|
||||
###
|
||||
# variable declarations
|
||||
###
|
||||
|
||||
MY_PN=gst-plugins-good
|
||||
MY_P=${MY_PN}-${PV}
|
||||
# All relevant configure options for gst-plugins
|
||||
# need a better way to extract these
|
||||
|
||||
# First line for non-plugin build related configure options; second line for
|
||||
# sys/ plugins; rest is split plugin options in order of ./configure --help output.
|
||||
# Good ways of validation are seeing diff of old and new configure.ac, and ./configure --help
|
||||
#
|
||||
# This list is current to gst-plugins-good-0.10.23:
|
||||
my_gst_plugins_good="gconftool zlib bz2
|
||||
directsound oss sunaudio osx_audio osx_video gst_v4l2 x xshm xvideo
|
||||
aalib aalibtest annodex cairo esd esdtest flac gconf gdk_pixbuf hal jpeg
|
||||
libcaca libdv libpng pulse dv1394 shout2 shout2test soup speex taglib wavpack"
|
||||
|
||||
# When adding conditionals like below, be careful about having leading spaces in concat
|
||||
|
||||
# sys/oss4 moved here since 0.10.23
|
||||
if version_is_at_least "0.10.23"; then
|
||||
my_gst_plugins_good+=" oss4"
|
||||
fi
|
||||
|
||||
|
||||
#SRC_URI="mirror://gnome/sources/gst-plugins/${PV_MAJ_MIN}/${MY_P}.tar.bz2"
|
||||
SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-good/${MY_P}.tar.bz2"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
# added to remove circular deps
|
||||
# 6/2/2006 - zaheerm
|
||||
if [ "${PN}" != "${MY_PN}" ]; then
|
||||
RDEPEND="=media-libs/gst-plugins-base-0.10*"
|
||||
DEPEND="${RDEPEND}
|
||||
>=sys-apps/sed-4
|
||||
dev-util/pkgconfig"
|
||||
RESTRICT=test
|
||||
fi
|
||||
|
||||
###
|
||||
# public functions
|
||||
###
|
||||
|
||||
gst-plugins-good_src_configure() {
|
||||
|
||||
# disable any external plugin besides the plugin we want
|
||||
local plugin gst_conf
|
||||
|
||||
einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..."
|
||||
|
||||
for plugin in ${my_gst_plugins_good}; do
|
||||
gst_conf="${gst_conf} --disable-${plugin} "
|
||||
done
|
||||
|
||||
for plugin in ${GST_PLUGINS_BUILD}; do
|
||||
gst_conf="${gst_conf} --enable-${plugin} "
|
||||
done
|
||||
|
||||
cd ${S}
|
||||
econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf} || die "./configure failure"
|
||||
|
||||
}
|
||||
|
||||
###
|
||||
# public inheritable functions
|
||||
###
|
||||
|
||||
gst-plugins-good_src_unpack() {
|
||||
|
||||
# local makefiles
|
||||
|
||||
unpack ${A}
|
||||
|
||||
# Link with the syswide installed gst-libs if needed
|
||||
# gst-plugins10_find_plugin_dir
|
||||
# cd ${S}
|
||||
|
||||
# Remove generation of any other Makefiles except the plugin's Makefile
|
||||
# if [ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# elif [ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# fi
|
||||
# sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
|
||||
# -i ${S}/configure
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-good_src_compile() {
|
||||
|
||||
gst-plugins-good_src_configure ${@}
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
emake || die "compile failure"
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-good_src_install() {
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
einstall || die
|
||||
|
||||
[[ -e README ]] && dodoc README
|
||||
}
|
||||
|
||||
EXPORT_FUNCTIONS src_unpack src_compile src_install
|
||||
118
eclass/gst-plugins-ugly.eclass
Normal file
118
eclass/gst-plugins-ugly.eclass
Normal file
@@ -0,0 +1,118 @@
|
||||
# Copyright 1999-2004 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-ugly.eclass,v 1.19 2010/07/28 06:24:44 leio Exp $
|
||||
|
||||
# Author : foser <foser@gentoo.org>
|
||||
|
||||
# gst-plugins-ugly eclass
|
||||
#
|
||||
# eclass to make external gst-plugins emergable on a per-plugin basis
|
||||
# to solve the problem with gst-plugins generating far too much unneeded deps
|
||||
#
|
||||
# 3rd party applications using gstreamer now should depend on a set of plugins as
|
||||
# defined in the source, in case of spider usage obtain recommended plugins to use from
|
||||
# Gentoo developers responsible for gstreamer <gnome@gentoo.org>, the application developer
|
||||
# or the gstreamer team.
|
||||
|
||||
inherit eutils versionator gst-plugins10
|
||||
|
||||
|
||||
###
|
||||
# variable declarations
|
||||
###
|
||||
|
||||
MY_PN=gst-plugins-ugly
|
||||
MY_P=${MY_PN}-${PV}
|
||||
# All relevant configure options for gst-plugins-ugly
|
||||
# need a better way to extract these.
|
||||
my_gst_plugins_ugly="a52dec amrnb amrwb cdio dvdread lame mad mpeg2dec sidplay
|
||||
twolame x264"
|
||||
|
||||
# dvdnav and id3tag disabled/removed since -ugly-0.10.13
|
||||
if ! version_is_at_least "0.10.13"; then
|
||||
my_gst_plugins_bad+=" dvdnav id3tag"
|
||||
fi
|
||||
|
||||
#SRC_URI="mirror://gnome/sources/gst-plugins/${PV_MAJ_MIN}/${MY_P}.tar.bz2"
|
||||
SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-ugly/${MY_P}.tar.bz2"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
# added to remove circular deps
|
||||
# 6/2/2006 - zaheerm
|
||||
if [ "${PN}" != "${MY_PN}" ]; then
|
||||
RDEPEND="=media-libs/gst-plugins-base-0.10*"
|
||||
DEPEND="${RDEPEND}
|
||||
>=sys-apps/sed-4
|
||||
dev-util/pkgconfig"
|
||||
RESTRICT=test
|
||||
fi
|
||||
|
||||
###
|
||||
# public functions
|
||||
###
|
||||
|
||||
gst-plugins-ugly_src_configure() {
|
||||
|
||||
# disable any external plugin besides the plugin we want
|
||||
local plugin gst_conf
|
||||
|
||||
einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..."
|
||||
|
||||
for plugin in ${my_gst_plugins_ugly}; do
|
||||
gst_conf="${gst_conf} --disable-${plugin} "
|
||||
done
|
||||
|
||||
for plugin in ${GST_PLUGINS_BUILD}; do
|
||||
gst_conf="${gst_conf} --enable-${plugin} "
|
||||
done
|
||||
|
||||
cd ${S}
|
||||
econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf} || die "./configure failure"
|
||||
|
||||
}
|
||||
|
||||
###
|
||||
# public inheritable functions
|
||||
###
|
||||
|
||||
gst-plugins-ugly_src_unpack() {
|
||||
|
||||
# local makefiles
|
||||
|
||||
unpack ${A}
|
||||
|
||||
# Link with the syswide installed gst-libs if needed
|
||||
# gst-plugins10_find_plugin_dir
|
||||
# cd ${S}
|
||||
|
||||
# Remove generation of any other Makefiles except the plugin's Makefile
|
||||
# if [ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# elif [ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]; then
|
||||
# makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
|
||||
# fi
|
||||
# sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
|
||||
# -i ${S}/configure
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-ugly_src_compile() {
|
||||
|
||||
gst-plugins-ugly_src_configure ${@}
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
emake || die "compile failure"
|
||||
|
||||
}
|
||||
|
||||
gst-plugins-ugly_src_install() {
|
||||
|
||||
gst-plugins10_find_plugin_dir
|
||||
einstall || die
|
||||
|
||||
[[ -e README ]] && dodoc README
|
||||
}
|
||||
|
||||
|
||||
EXPORT_FUNCTIONS src_unpack src_compile src_install
|
||||
17
eclass/gst-plugins.eclass
Normal file
17
eclass/gst-plugins.eclass
Normal file
@@ -0,0 +1,17 @@
|
||||
# Copyright 1999-2009 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins.eclass,v 1.35 2009/11/30 04:19:36 abcd Exp $
|
||||
|
||||
# @DEAD
|
||||
# To be removed on 2011/11/30.
|
||||
ewarn "Please fix your package (${CATEGORY}/${PF}) to not use ${ECLASS}.eclass"
|
||||
|
||||
PVP=(${PV//[-\._]/ })
|
||||
PV_MAJ_MIN=${PVP[0]}.${PVP[1]}
|
||||
SLOT=${PV_MAJ_MIN}
|
||||
|
||||
gst-plugins_pkg_postrm() {
|
||||
gst-register-${SLOT}
|
||||
}
|
||||
|
||||
EXPORT_FUNCTIONS pkg_postrm
|
||||
81
eclass/gst-plugins10.eclass
Normal file
81
eclass/gst-plugins10.eclass
Normal file
@@ -0,0 +1,81 @@
|
||||
# Copyright 1999-2004 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins10.eclass,v 1.3 2010/08/12 10:48:59 pva Exp $
|
||||
|
||||
# Author : foser <foser@gentoo.org>
|
||||
|
||||
# gst-plugins eclass
|
||||
#
|
||||
# eclass to make external gst-plugins emergable on a per-plugin basis
|
||||
# to solve the problem with gst-plugins generating far too much unneeded deps
|
||||
#
|
||||
# 3rd party applications using gstreamer now should depend on a set of plugins as
|
||||
# defined in the source, in case of spider usage obtain recommended plugins to use from
|
||||
# Gentoo developers responsible for gstreamer <gnome@gentoo.org>, the application developer
|
||||
# or the gstreamer team.
|
||||
|
||||
inherit eutils
|
||||
|
||||
|
||||
###
|
||||
# variable declarations
|
||||
###
|
||||
|
||||
# Create a major/minor combo for our SLOT and executables suffix
|
||||
PVP=(${PV//[-\._]/ })
|
||||
#PV_MAJ_MIN=${PVP[0]}.${PVP[1]}
|
||||
PV_MAJ_MIN=0.10
|
||||
|
||||
# Extract the plugin to build from the ebuild name
|
||||
# May be set by an ebuild and contain more than one indentifier, space seperated
|
||||
# (only src_configure can handle mutiple plugins at this time)
|
||||
GST_PLUGINS_BUILD=${PN/gst-plugins-/}
|
||||
|
||||
# Actual build dir, is the same as the configure switch name most of the time
|
||||
GST_PLUGINS_BUILD_DIR=${PN/gst-plugins-/}
|
||||
|
||||
# general common gst-plugins ebuild entries
|
||||
DESCRIPTION="${BUILD_GST_PLUGINS} plugin for gstreamer"
|
||||
HOMEPAGE="http://gstreamer.freedesktop.org/"
|
||||
LICENSE="GPL-2"
|
||||
|
||||
#SRC_URI="mirror://gnome/sources/gst-plugins/${PV_MAJ_MIN}/${MY_P}.tar.bz2"
|
||||
SLOT=${PV_MAJ_MIN}
|
||||
###
|
||||
# internal functions
|
||||
###
|
||||
|
||||
gst-plugins10_find_plugin_dir() {
|
||||
|
||||
if [[ ! -d ${S}/ext/${GST_PLUGINS_BUILD_DIR} ]]; then
|
||||
if [[ ! -d ${S}/sys/${GST_PLUGINS_BUILD_DIR} ]]; then
|
||||
ewarn "No such plugin directory"
|
||||
die
|
||||
fi
|
||||
einfo "Building system plugin ..."
|
||||
cd "${S}"/sys/${GST_PLUGINS_BUILD_DIR}
|
||||
else
|
||||
einfo "Building external plugin ..."
|
||||
cd "${S}"/ext/${GST_PLUGINS_BUILD_DIR}
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
###
|
||||
# public functions
|
||||
###
|
||||
|
||||
gst-plugins10_remove_unversioned_binaries() {
|
||||
|
||||
# remove the unversioned binaries gstreamer provide
|
||||
# this is to prevent these binaries to be owned by several SLOTs
|
||||
|
||||
cd ${D}/usr/bin
|
||||
for gst_bins in `ls *-${PV_MAJ_MIN}`
|
||||
do
|
||||
rm ${gst_bins/-${PV_MAJ_MIN}/}
|
||||
einfo "Removed ${gst_bins/-${PV_MAJ_MIN}/}"
|
||||
done
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user