Merge remote-tracking branch 'oe_21/master' into vuplus-3.0-next
[vuplus_openvuplus_3.0] / meta-openvuplus / recipes-multimedia / gstreamer1.0 / gstreamer1.0-plugins.inc
1 SUMMARY = "Plugins for the GStreamer multimedia framework 1.x"
2 HOMEPAGE = "http://gstreamer.freedesktop.org/"
3 BUGTRACKER = "https://bugzilla.gnome.org/enter_bug.cgi?product=Gstreamer"
4 SECTION = "multimedia"
5 DEPENDS = "gstreamer1.0"
6
7 inherit autotools pkgconfig
8
9 GSTREAMER_1_0_DEBUG ?= "--disable-debug"
10 GSTREAMER_1_0_GIT_BRANCH ?= "master"
11 EXTRA_OECONF = "--disable-valgrind ${GSTREAMER_1_0_DEBUG} --disable-examples "
12
13 acpaths = "-I ${S}/common/m4 -I ${S}/m4"
14
15 LIBV = "1.0"
16 require gst-plugins-package.inc
17
18 PACKAGECONFIG[orc] = "--enable-orc,--disable-orc,orc"
19
20 PACKAGES_DYNAMIC = "^${PN}-.*"
21
22 # apply gstreamer hack after Makefile.in.in in source is replaced by our version from
23 # ${STAGING_DATADIR_NATIVE}/gettext/po/Makefile.in.in, but before configure is executed 
24 # http://lists.linuxtogo.org/pipermail/openembedded-core/2012-November/032233.html
25 oe_runconf_prepend() {
26         if [ -e ${S}/po/Makefile.in.in ]; then
27                 sed -i -e "1a\\" -e 'GETTEXT_PACKAGE = @GETTEXT_PACKAGE@' ${S}/po/Makefile.in.in
28         fi
29 }
30
31 SRC_URI = "${@get_gst_srcuri(d)}"
32
33 def get_gst_srcuri(d):
34     # check if expected prefix is present
35     prefix = "gstreamer1.0-"
36     bpn = d.getVar("BPN", True)
37     if not bpn.startswith(prefix):
38         bb.fatal('Invalid GStreamer 1.0 plugin package name "%s" : must start with "%s"' % (bpn, prefix))
39
40     # replaced prefix with "gst-", which is what is used for the tarball and repository filenames
41     gstpkg_basename = "gst-" + bpn[len(prefix):]
42     pv = d.getVar("PV", True)
43     branch = d.getVar("GSTREAMER_1_0_GIT_BRANCH", True)
44
45     if pv == "git":
46         s = "git://anongit.freedesktop.org/gstreamer/%s;branch=%s" % (gstpkg_basename, branch)
47     else:
48         s = "http://gstreamer.freedesktop.org/src/%s/%s-%s.tar.xz" % (gstpkg_basename, gstpkg_basename, pv)
49     return s
50
51 delete_liblink_m4_file() {
52         # This m4 file contains nastiness which conflicts with libtool 2.2.2
53         rm "${S}/m4/lib-link.m4" || true
54 }
55
56 do_configure[prefuncs] += " delete_liblink_m4_file "
57