Add workaround for new orc break gstreamer ebuilds, bug #533664
authorGilles Dartiguelongue <eva@gentoo.org>
Sun, 28 Dec 2014 22:55:58 +0000 (22:55 +0000)
committerGilles Dartiguelongue <eva@gentoo.org>
Sun, 28 Dec 2014 22:55:58 +0000 (22:55 +0000)
eclass/ChangeLog
eclass/gstreamer.eclass

index 6516dbc3b08d8becbd0e1352b6ec1f6fc934f72b..477270aecac2a79ac160727d492e42797d4b7b61 100644 (file)
@@ -1,6 +1,9 @@
 # ChangeLog for eclass directory
 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1488 2014/12/28 22:50:20 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1489 2014/12/28 22:55:58 eva Exp $
+
+  28 Dec 2014; Gilles Dartiguelongue <eva@gentoo.org> gstreamer.eclass:
+  Add workaround for new orc break gstreamer ebuilds, bug #533664.
 
   28 Dec 2014; Michał Górny <mgorny@gentoo.org> python-single-r1.eclass:
   Add python_gen_usedep, python_gen_useflags and python_gen_cond_dep to
index 424d0fbfca69effb00e5278168e91236b10e15b0..90f6933a699be5c9c88301aae1fb4d0acdfe0dca 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/gstreamer.eclass,v 1.2 2014/06/19 09:28:09 mgorny Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/gstreamer.eclass,v 1.3 2014/12/28 22:55:58 eva Exp $
 
 # @ECLASS: gstreamer.eclass
 # @MAINTAINER:
@@ -125,6 +125,20 @@ fi
 
 DEPEND="${DEPEND} ${RDEPEND}"
 
+# @FUNCTION: gstreamer_environment_reset
+# @INTERNAL
+# @DESCRIPTION:
+# Clean up environment for clean builds.
+# >=dev-lang/orc-0.4.23 rely on environment variables to find a place to
+# allocate files to mmap.
+gstreamer_environment_reset() {
+       export XDG_RUNTIME_DIR="${T}/run"
+       mkdir -p "${XDG_RUNTIME_DIR}"
+       # This directory needs to be owned by the user, and chmod 0700
+       # http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html
+       chmod 0700 "${XDG_RUNTIME_DIR}"
+}
+
 # @FUNCTION: gstreamer_get_plugins
 # @INTERNAL
 # @DESCRIPTION:
@@ -189,6 +203,7 @@ gstreamer_multilib_src_configure() {
        local plugin gst_conf=() ECONF_SOURCE=${ECONF_SOURCE:-${S}}
 
        gstreamer_get_plugins
+       gstreamer_environment_reset
 
        for plugin in ${GST_PLUGINS_LIST} ; do
                if has ${plugin} ${GST_PLUGINS_BUILD} ; then