/[gentoo-x86]/eclass/gst-plugins-bad.eclass
Gentoo

Diff of /eclass/gst-plugins-bad.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.5 Revision 1.30
1# Copyright 1999-2006 Gentoo Foundation 1# Copyright 1999-2009 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-bad.eclass,v 1.5 2006/05/10 11:50:14 zaheerm Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/gst-plugins-bad.eclass,v 1.30 2010/07/28 05:17:58 leio Exp $
4 4
5# 5#
6# Original Author: Saleem Abdulrasool <compnerd@gentoo.org> 6# Original Author: Saleem Abdulrasool <compnerd@gentoo.org>
7# Based on the work of foser <foser@gentoo.org> and zaheerm <zaheerm@gentoo.org> 7# Based on the work of foser <foser@gentoo.org> and zaheerm <zaheerm@gentoo.org>
8# Purpose: This elcass is designed to help package external gst-plugins per 8# Purpose: This elcass is designed to help package external gst-plugins per
9# plugin rather than in a single package. 9# plugin rather than in a single package.
10# 10#
11 11
12my_gst_plugins_bad="amrwb bz2 directfb dts divx faac faad gsm gst_v4l2 ivorbis libmms musepack musicbrainz neon opengl sdl sdltest soundtouch swfdec theoradec wavpack xvid" 12inherit eutils gst-plugins10 versionator
13#qtdemux spped tta
14 13
15inherit eutils gst-plugins10 14# This list is current for gst-plugins-bad-0.10.18.
15my_gst_plugins_bad="directsound directdraw osx_video quicktime vcd
16alsa assrender amrwb apexsink bz2 cdaudio celt cog directfb dirac dts divx
17dvdnav metadata faac faad fbdev flite gsm jack jp2k kate ladspa lv2 libmms
18modplug mimic mpeg2enc mplex musepack musicbrainz mythtv nas neon ofa rsvg
19timidity wildmidi sdl sdltest sndfile soundtouch spc gme swfdec theoradec xvid
20dvb oss4 wininet acm vdpau schro zbar"
21
22# When adding conditionals like this, be careful about having leading spaces
23if version_is_at_least "0.10.19"; then
24 my_gst_plugins_bad+=" vp8"
25fi
26
27# ivorbis gone since 0.10.18 (moved to -base-0.10.27 as part of vorbis plugin)
28if ! version_is_at_least "0.10.18"; then
29 my_gst_plugins_bad+=" ivorbis"
30fi
16 31
17MY_PN="gst-plugins-bad" 32MY_PN="gst-plugins-bad"
18MY_P=${MY_PN}-${PV} 33MY_P=${MY_PN}-${PV}
19 34
20SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-bad/${MY_P}.tar.bz2" 35SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-bad/${MY_P}.tar.bz2"
36if [ ${PV} == "0.10.14" ]; then
37 SRC_URI="${SRC_URI} http://dev.gentoo.org/~leio/distfiles/gst-plugins-bad-0.10.14-kate-configure-fix.patch.bz2"
38fi
21 39
22# added to remove circular deps 40# added to remove circular deps
23# 6/2/2006 - zaheerm 41# 6/2/2006 - zaheerm
24if [ "${PN}" != "${MY_PN}" ]; then 42if [ "${PN}" != "${MY_PN}" ]; then
25RDEPEND="=media-libs/gstreamer-0.10* 43RDEPEND="=media-libs/gstreamer-0.10*
26 =media-libs/gst-plugins-base-0.10* 44 =media-libs/gst-plugins-base-0.10*
27 >=dev-libs/glib-2.6 45 >=dev-libs/glib-2.6
28 >=dev-libs/liboil-0.3" 46 >=dev-libs/liboil-0.3"
29DEPEND="${RDEPEND} 47DEPEND="${RDEPEND}
30 sys-apps/sed 48 sys-apps/sed
49 dev-util/pkgconfig
31 sys-devel/gettext" 50 sys-devel/gettext"
51RESTRICT=test
32fi 52fi
33S=${WORKDIR}/${MY_P} 53S=${WORKDIR}/${MY_P}
34 54
35gst-plugins-bad_src_unpack() { 55gst-plugins-bad_src_unpack() {
36 local makefiles 56# local makefiles
37 57
38 unpack ${A} 58 unpack ${A}
39 59
60 # Link with the syswide installed gst-libs if needed
40 gst-plugins10_find_plugin_dir 61 gst-plugins10_find_plugin_dir
62 sed -e "s:\$(top_builddir)/gst-libs/gst/interfaces/libgstphotography:${ROOT}/usr/$(get_libdir)/libgstphotography:" \
63 -e "s:\$(top_builddir)/gst-libs/gst/signalprocessor/libgstsignalprocessor:${ROOT}/usr/$(get_libdir)/libgstsignalprocessor:" \
64 -e "s:\$(top_builddir)/gst-libs/gst/video/libgstbasevideo:${ROOT}/usr/$(get_libdir)/libgstbasevideo:" \
65 -i Makefile.in
66
67 # 0.10.14 configure errors when --disable-kate is passed:
68 # configure: error: conditional "USE_TIGER" was never defined.
69 # Fix it - this has to stay until any 0.10.14 split or main is in tree:
70 if [ ${PV} == "0.10.14" ]; then
41 cd ${S} 71 cd ${S}
72 epatch "${WORKDIR}/gst-plugins-bad-0.10.14-kate-configure-fix.patch"
73 fi
42 74
43 # Remove generation of any other Makefiles except the plugin's Makefile 75 # Remove generation of any other Makefiles except the plugin's Makefile
44 if [[ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]] ; then 76# if [[ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]] ; then
45 makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile" 77# makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
46 elif [[ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]] ; then 78# elif [[ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]] ; then
47 makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile" 79# makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
48 fi 80# fi
49 81
50 sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \ 82# sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
51 -i ${S}/configure 83# -i ${S}/configure
52} 84}
53 85
54gst-plugins-bad_src_configure() { 86gst-plugins-bad_src_configure() {
55 local plugin gst_conf 87 local plugin gst_conf
56 88
57 einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..." 89 einfo "Configuring to build ${GST_PLUGINS_BUILD} plugin(s) ..."
58
59 for plugin in ${GST_PLUGINS_BUILD} ; do
60 my_gst_plugins_bad="${my_gst_plugins_bad/${plugin}/}"
61 done
62 90
63 for plugin in ${my_gst_plugins_bad} ; do 91 for plugin in ${my_gst_plugins_bad} ; do
64 gst_conf="${gst_conf} --disable-${plugin}" 92 gst_conf="${gst_conf} --disable-${plugin}"
65 done 93 done
66 94
67 for plugin in ${GST_PLUGINS_BUILD} ; do 95 for plugin in ${GST_PLUGINS_BUILD} ; do
68 gst_conf="${gst_conf} --enable-${plugin}" 96 gst_conf="${gst_conf} --enable-${plugin}"
69 done 97 done
70 98
71 cd ${S} 99 cd ${S}
72 econf ${@} ${gst_conf} || die "configure failed" 100 econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf} || die "configure failed"
73} 101}
74 102
75gst-plugins-bad_src_compile() { 103gst-plugins-bad_src_compile() {
76 gst-plugins-bad_src_configure ${@} 104 gst-plugins-bad_src_configure ${@}
77 105
81 109
82gst-plugins-bad_src_install() { 110gst-plugins-bad_src_install() {
83 gst-plugins10_find_plugin_dir 111 gst-plugins10_find_plugin_dir
84 einstall || die "install failed" 112 einstall || die "install failed"
85 113
86 dodoc README 114 [[ -e README ]] && dodoc README
87} 115}
88 116
89EXPORT_FUNCTIONS src_unpack src_compile src_install 117EXPORT_FUNCTIONS src_unpack src_compile src_install

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.30

  ViewVC Help
Powered by ViewVC 1.1.20