summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2009-06-26 20:49:46 +0000
committerAlexis Ballier <aballier@gentoo.org>2009-06-26 20:49:46 +0000
commit43ca77bf4d4392ed9a9af2deee37910ce5e1ee60 (patch)
tree5217072d473b7fb0492293fe4c99ed20eb80957f /gnome-base/gnome-session
parentNew ebuild, import from scarabeus overlay (diff)
downloadgentoo-2-43ca77bf4d4392ed9a9af2deee37910ce5e1ee60.tar.gz
gentoo-2-43ca77bf4d4392ed9a9af2deee37910ce5e1ee60.tar.bz2
gentoo-2-43ca77bf4d4392ed9a9af2deee37910ce5e1ee60.zip
Add build fix for bsd, check for execinfo and link to it if needed, bug #275524, gnome bug #587088
(Portage version: 2.2_rc33/cvs/Linux x86_64)
Diffstat (limited to 'gnome-base/gnome-session')
-rw-r--r--gnome-base/gnome-session/ChangeLog10
-rw-r--r--gnome-base/gnome-session/files/gnome-session-2.26.1-execinfo.patch81
-rw-r--r--gnome-base/gnome-session/gnome-session-2.26.1-r1.ebuild85
3 files changed, 175 insertions, 1 deletions
diff --git a/gnome-base/gnome-session/ChangeLog b/gnome-base/gnome-session/ChangeLog
index eab8654c541a..037c47879151 100644
--- a/gnome-base/gnome-session/ChangeLog
+++ b/gnome-base/gnome-session/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for gnome-base/gnome-session
# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-session/ChangeLog,v 1.236 2009/05/23 14:54:11 eva Exp $
+# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-session/ChangeLog,v 1.237 2009/06/26 20:49:45 aballier Exp $
+
+*gnome-session-2.26.1-r1 (26 Jun 2009)
+
+ 26 Jun 2009; Alexis Ballier <aballier@gentoo.org>
+ +gnome-session-2.26.1-r1.ebuild,
+ +files/gnome-session-2.26.1-execinfo.patch:
+ Add build fix for bsd, check for execinfo and link to it if needed, bug
+ #275524, gnome bug #587088
23 May 2009; Gilles Dartiguelongue <eva@gentoo.org>
-gnome-session-2.22.3.ebuild, gnome-session-2.26.1.ebuild:
diff --git a/gnome-base/gnome-session/files/gnome-session-2.26.1-execinfo.patch b/gnome-base/gnome-session/files/gnome-session-2.26.1-execinfo.patch
new file mode 100644
index 000000000000..a4903e2cf037
--- /dev/null
+++ b/gnome-base/gnome-session/files/gnome-session-2.26.1-execinfo.patch
@@ -0,0 +1,81 @@
+From 6b551c1c6061fe6431ff265f7acc7ff227236b7d Mon Sep 17 00:00:00 2001
+From: Alexis Ballier <aballier@gentoo.org>
+Date: Fri, 26 Jun 2009 21:42:41 +0200
+Subject: [PATCH] Fix build on systems without execinfo in the libc.
+
+Try to see if we have execinfo.h, and if we need to link to an extra library for using it. For instance FreeBSD does not have execinfo.h but a port has been made and we can use libexecinfo.
+---
+ configure.in | 9 +++++++++
+ gnome-session/Makefile.am | 1 +
+ gnome-session/gdm-signal-handler.c | 6 ++++++
+ 3 files changed, 16 insertions(+), 0 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 1b8067c..55a566c 100644
+--- a/configure.in
++++ b/configure.in
+@@ -253,6 +253,15 @@ AC_HEADER_STDC
+ AC_CHECK_HEADERS(syslog.h tcpd.h sys/param.h)
+
+ dnl ====================================================================
++dnl check for backtrace support
++dnl ====================================================================
++
++AC_CHECK_HEADERS(execinfo.h)
++LIBEXECINFO=""
++AC_CHECK_LIB(execinfo, backtrace, [LIBEXECINFO="-lexecinfo"],[])
++AC_SUBST(LIBEXECINFO)
++
++dnl ====================================================================
+ dnl Check for newish X interface
+ dnl ====================================================================
+ oCFLAGS="$CFLAGS"
+diff --git a/gnome-session/Makefile.am b/gnome-session/Makefile.am
+index d5cb98c..fb81bb8 100644
+--- a/gnome-session/Makefile.am
++++ b/gnome-session/Makefile.am
+@@ -53,6 +53,7 @@ gnome_session_LDADD = \
+ $(POLKIT_GNOME_LIBS) \
+ $(XRENDER_LIBS) \
+ $(XTEST_LIBS) \
++ $(LIBEXECINFO) \
+ $(NULL)
+
+ gnome_session_SOURCES = \
+diff --git a/gnome-session/gdm-signal-handler.c b/gnome-session/gdm-signal-handler.c
+index 58dca7d..353f79f 100644
+--- a/gnome-session/gdm-signal-handler.c
++++ b/gnome-session/gdm-signal-handler.c
+@@ -27,7 +27,9 @@
+ #include <unistd.h>
+ #include <string.h>
+ #include <signal.h>
++#if HAVE_EXECINFO_H
+ #include <execinfo.h>
++#endif
+ #include <syslog.h>
+ #include <sys/wait.h>
+ #include <sys/stat.h>
+@@ -160,6 +162,7 @@ signal_io_watch (GIOChannel *ioc,
+ static void
+ fallback_get_backtrace (void)
+ {
++#if HAVE_EXECINFO_H
+ void * frames[64];
+ size_t size;
+ char ** strings;
+@@ -174,8 +177,11 @@ fallback_get_backtrace (void)
+ free (strings);
+ syslog (LOG_CRIT, "******************* END **********************************");
+ } else {
++#endif
+ g_warning ("GDM crashed, but symbols couldn't be retrieved.");
++#if HAVE_EXECINFO_H
+ }
++#endif
+ }
+
+
+--
+1.6.3.3
+
diff --git a/gnome-base/gnome-session/gnome-session-2.26.1-r1.ebuild b/gnome-base/gnome-session/gnome-session-2.26.1-r1.ebuild
new file mode 100644
index 000000000000..a7516dc04bcf
--- /dev/null
+++ b/gnome-base/gnome-session/gnome-session-2.26.1-r1.ebuild
@@ -0,0 +1,85 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/gnome-base/gnome-session/gnome-session-2.26.1-r1.ebuild,v 1.1 2009/06/26 20:49:45 aballier Exp $
+
+EAPI="2"
+
+inherit eutils gnome2 autotools
+
+DESCRIPTION="Gnome session manager"
+HOMEPAGE="http://www.gnome.org/"
+SRC_URI="${SRC_URI}
+ mirror://gentoo/${P}-gentoo-patches.tar.bz2
+ branding? ( mirror://gentoo/gentoo-splash.png )"
+
+LICENSE="GPL-2 LGPL-2 FDL-1.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+
+IUSE="branding doc ipv6 policykit elibc_FreeBSD"
+
+RDEPEND=">=dev-libs/glib-2.16
+ >=x11-libs/gtk+-2.11.1
+ >=gnome-base/libglade-2.3.6
+ >=dev-libs/dbus-glib-0.76
+ >=gnome-base/gconf-2
+ >=x11-libs/startup-notification-0.9
+ policykit? ( >=gnome-extra/policykit-gnome-0.7 )
+ elibc_FreeBSD? ( dev-libs/libexecinfo )
+
+ x11-libs/libSM
+ x11-libs/libICE
+ x11-libs/libX11
+ x11-libs/libXtst
+ x11-apps/xdpyinfo"
+DEPEND="${RDEPEND}
+ >=dev-lang/perl-5
+ >=sys-devel/gettext-0.10.40
+ >=dev-util/pkgconfig-0.17
+ >=dev-util/intltool-0.40
+ !<gnome-base/gdm-2.20.4
+ doc? (
+ app-text/xmlto
+ dev-libs/libxslt )"
+# gnome-base/gdm does not provide gnome.desktop anymore
+
+DOCS="AUTHORS ChangeLog NEWS README"
+
+pkg_setup() {
+ # TODO: convert libnotify to a configure option
+ G2CONF="${G2CONF}
+ --docdir=/usr/share/doc/${PF}
+ $(use_enable doc docbook-docs)
+ $(use_enable ipv6)
+ $(use_enable policykit polkit)"
+}
+
+src_prepare() {
+ gnome2_src_prepare
+
+ # Patch for Gentoo Branding (bug #42687)
+ use branding && epatch "${FILESDIR}/${PN}-2.17.90.1-gentoo-branding.patch"
+
+ # Fix shutdown/restart capability, upstream bug #549150
+ epatch "${WORKDIR}/${PN}-2.26.1-shutdown.patch"
+
+ # Add "session saving" button back, upstream bug #575544
+ epatch "${WORKDIR}/${PN}-2.26.1-session-saving-button.patch"
+
+ epatch "${FILESDIR}/${P}-execinfo.patch"
+ eautoreconf
+}
+
+src_install() {
+ gnome2_src_install
+
+ dodir /etc/X11/Sessions
+ exeinto /etc/X11/Sessions
+ doexe "${FILESDIR}/Gnome" || die "doexe failed"
+
+ # Our own splash for world domination
+ if use branding ; then
+ insinto /usr/share/pixmaps/splash/
+ doins "${DISTDIR}/gentoo-splash.png" || die "doins failed"
+ fi
+}