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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download)
Thu Sep 14 21:16:37 2006 UTC (11 years, 3 months ago) by zaheerm
Branch: MAIN
Changes since 1.5: +2 -2 lines
Set package origin and name

1 # Copyright 1999-2006 Gentoo Foundation
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 $
4
5 #
6 # Original Author: Saleem Abdulrasool <compnerd@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
9 # plugin rather than in a single package.
10 #
11
12 my_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"
13 #qtdemux spped tta
14
15 inherit eutils gst-plugins10
16
17 MY_PN="gst-plugins-bad"
18 MY_P=${MY_PN}-${PV}
19
20 SRC_URI="http://gstreamer.freedesktop.org/src/gst-plugins-bad/${MY_P}.tar.bz2"
21
22 # added to remove circular deps
23 # 6/2/2006 - zaheerm
24 if [ "${PN}" != "${MY_PN}" ]; then
25 RDEPEND="=media-libs/gstreamer-0.10*
26 =media-libs/gst-plugins-base-0.10*
27 >=dev-libs/glib-2.6
28 >=dev-libs/liboil-0.3"
29 DEPEND="${RDEPEND}
30 sys-apps/sed
31 sys-devel/gettext"
32 fi
33 S=${WORKDIR}/${MY_P}
34
35 gst-plugins-bad_src_unpack() {
36 local makefiles
37
38 unpack ${A}
39
40 gst-plugins10_find_plugin_dir
41 cd ${S}
42
43 # Remove generation of any other Makefiles except the plugin's Makefile
44 if [[ -d "${S}/sys/${GST_PLUGINS_BUILD_DIR}" ]] ; then
45 makefiles="Makefile sys/Makefile sys/${GST_PLUGINS_BUILD_DIR}/Makefile"
46 elif [[ -d "${S}/ext/${GST_PLUGINS_BUILD_DIR}" ]] ; then
47 makefiles="Makefile ext/Makefile ext/${GST_PLUGINS_BUILD_DIR}/Makefile"
48 fi
49
50 sed -e "s:ac_config_files=.*:ac_config_files='${makefiles}':" \
51 -i ${S}/configure
52 }
53
54 gst-plugins-bad_src_configure() {
55 local plugin gst_conf
56
57 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
63 for plugin in ${my_gst_plugins_bad} ; do
64 gst_conf="${gst_conf} --disable-${plugin}"
65 done
66
67 for plugin in ${GST_PLUGINS_BUILD} ; do
68 gst_conf="${gst_conf} --enable-${plugin}"
69 done
70
71 cd ${S}
72 econf ${@} --with-package-name="Gentoo GStreamer Ebuild" --with-package-origin="http://www.gentoo.org" ${gst_conf} || die "configure failed"
73 }
74
75 gst-plugins-bad_src_compile() {
76 gst-plugins-bad_src_configure ${@}
77
78 gst-plugins10_find_plugin_dir
79 emake || die "compile failure"
80 }
81
82 gst-plugins-bad_src_install() {
83 gst-plugins10_find_plugin_dir
84 einstall || die "install failed"
85
86 dodoc README
87 }
88
89 EXPORT_FUNCTIONS src_unpack src_compile src_install

  ViewVC Help
Powered by ViewVC 1.1.20