Accepting request 155152 from home:dimstar:branches:GNOME:Factory

Find the nm-* agents... they don't live in gnome-shell's libexecdir... wanted for 12.3

OBS-URL: https://build.opensuse.org/request/show/155152
OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/gnome-shell?expand=0&rev=145
This commit is contained in:
Marcus Rückert 2013-02-11 20:39:40 +00:00 committed by Git OBS Bridge
parent 2973ec25b9
commit 8e7fd8939c
3 changed files with 82 additions and 0 deletions

View File

@ -0,0 +1,65 @@
commit 75d67086a651a4c46a66c563c8e9618c3a4b2fe2
Author: Dominique Leuenberger <dimstar@opensuse.org>
Date: Mon Feb 11 14:00:52 2013 +0100
networkAgent: Allow NetworkManager to use a different libexecdir path
Introducing a --with-nmlibexecdir parameter to configure allows
distributions to split libexecdir for various packages.
Not specifying it results in no change in behaviour.
diff --git a/configure.ac b/configure.ac
index 0ed832d..d0895f3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -181,6 +181,13 @@ AM_CONDITIONAL(USE_JHBUILD_WRAPPER_SCRIPT, test "x$enable_jhbuild_wrapper_script
BROWSER_PLUGIN_DIR="${BROWSER_PLUGIN_DIR:-"\${libdir}/mozilla/plugins"}"
AC_ARG_VAR([BROWSER_PLUGIN_DIR],[Where to install the plugin to])
+AC_ARG_WITH(nmlibexecdir,
+ AS_HELP_STRING([--with-nmlibexecdir=DIR],
+ [Specify the location where NetworkManager installs its helpers [default=$(libexecdir)]]),
+ [nmlibexecdir="$withval"],
+ [nmlibexecdir="$libexecdir"])
+AC_SUBST(nmlibexecdir)
+
AC_CONFIG_FILES([
Makefile
data/Makefile
diff --git a/js/Makefile.am b/js/Makefile.am
index 323cd1b..5ae77be 100644
--- a/js/Makefile.am
+++ b/js/Makefile.am
@@ -12,6 +12,7 @@ misc/config.js: misc/config.js.in Makefile
-e "s|[@]datadir@|$(datadir)|g" \
-e "s|[@]libexecdir@|$(libexecdir)|g" \
-e "s|[@]sysconfdir@|$(sysconfdir)|g" \
+ -e "s|[@]nmlibexecdir@|$(nmlibexecdir)|g" \
$< > $@
jsdir = $(pkgdatadir)/js
diff --git a/js/misc/config.js.in b/js/misc/config.js.in
index 9769104..192299f 100644
--- a/js/misc/config.js.in
+++ b/js/misc/config.js.in
@@ -13,3 +13,6 @@ const LOCALEDIR = '@datadir@/locale';
/* other standard directories */
const LIBEXECDIR = '@libexecdir@';
const SYSCONFDIR = '@sysconfdir@';
+
+/* Some distros use different libexecdir for NM than for gnome-shell */
+const NMLIBEXECDIR = '@nmlibexecdir@';
diff --git a/js/ui/components/networkAgent.js b/js/ui/components/networkAgent.js
index e214cd8..2602444 100644
--- a/js/ui/components/networkAgent.js
+++ b/js/ui/components/networkAgent.js
@@ -688,7 +688,7 @@ const NetworkAgent = new Lang.Class({
} catch(e) { } // ignore errors if key does not exist
let path = binary;
if (!GLib.path_is_absolute(path)) {
- path = GLib.build_filenamev([Config.LIBEXECDIR, path]);
+ path = GLib.build_filenamev([Config.NMLIBEXECDIR, path]);
}
if (GLib.file_test(path, GLib.FileTest.IS_EXECUTABLE))

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Mon Feb 11 18:41:23 UTC 2013 - dimstar@opensuse.org
- Add gnome-shell-nmlibexecdir.patch: Allow NetworkManager to use
a different libexecdir that gnome-shell.
- Add gnome-common BuildRequires and call to gnome-autogen.sh, as
above patch touches the build system.
- Pass --with-nmlibexecdir=%{_libexecdir} to configure.
-------------------------------------------------------------------
Mon Feb 11 14:45:23 UTC 2013 - badshah400@gmail.com

View File

@ -30,7 +30,11 @@ Patch1: gnome-shell-private-connection.patch
Patch2: g-s-honor-lock-delay-GSettings.patch
# PATCH-FIX-UPSTREAM g-s-use-the-right-getter.patch bgo#691170 zaitor@opensuse.org -- org.gnome.desktop.screensaver lock-delay is an integer, not a boolean, so don't use get_bool() on it.
Patch3: g-s-use-the-right-getter.patch
# PATCH-FIX-UPSTREAM gnome-shell-nmlibexecdir.patch bgo#693590 dimstar@opensuse.org -- Allow NetworkManager installation to use different libexecdir than gnome-shell
Patch4: gnome-shell-nmlibexecdir.patch
BuildRequires: docbook-xsl-stylesheets
# Needed for patch4
BuildRequires: gnome-common
BuildRequires: intltool
BuildRequires: translation-update-upstream
BuildRequires: update-desktop-files
@ -136,13 +140,17 @@ to enable, disable and install them.
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
translation-update-upstream
%build
# Needed for patch4
NOCONFIGURE=1 gnome-autogen.sh
export BROWSER_PLUGIN_DIR=%{_libdir}/browser-plugins
%configure \
--disable-static \
--libexecdir=%{_libexecdir}/%{name} \
--with-nmlibexecdir=%{_libexecdir} \
--disable-schemas-install \
--enable-compile-warnings=no
%__make %{?_smp_mflags} V=1