From 1c42d2ec9f7fc562444989f619c6eeba80ac7629 Mon Sep 17 00:00:00 2001 From: Guido Berhoerster <gber@opensuse.org> Date: Sat, 12 Feb 2011 17:42:49 +0100 Subject: [PATCH] Allow installation of the helpers in a custom location. --- configure.ac.in | 8 ++++++++ helper-dialog/Makefile.am | 2 +- src/Makefile.am | 2 +- src/terminate.c | 2 +- 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/configure.ac.in b/configure.ac.in index f52ea7fe9..85806e98e 100644 --- a/configure.ac.in +++ b/configure.ac.in @@ -34,6 +34,14 @@ AM_CONFIG_HEADER([config.h]) AM_MAINTAINER_MODE() m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) +dnl set helper path prefix +AC_ARG_WITH([helper-path-prefix], + [AC_HELP_STRING([--with-helper-path-prefix=PATH], + [Path prefix under which helper executables will be installed (default: $libdir)])], + [HELPER_PATH_PREFIX="$withval"], + [HELPER_PATH_PREFIX="$libdir"]) +AC_SUBST([HELPER_PATH_PREFIX]) + dnl check for UNIX variants AC_AIX AC_ISC_POSIX diff --git a/helper-dialog/Makefile.am b/helper-dialog/Makefile.am index 09727c64d..0dd893007 100644 --- a/helper-dialog/Makefile.am +++ b/helper-dialog/Makefile.am @@ -6,7 +6,7 @@ INCLUDES = \ $(LIBX11_CFLAGS) \ -DPACKAGE_LOCALE_DIR=\"$(localedir)\" -helper_dialogdir = $(libdir)/xfce4/xfwm4 +helper_dialogdir = $(HELPER_PATH_PREFIX)/xfce4/xfwm4 helper_dialog_PROGRAMS = \ helper-dialog diff --git a/src/Makefile.am b/src/Makefile.am index 9cf486c43..10280a947 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -92,7 +92,7 @@ xfwm4_CFLAGS = \ $(COMPOSITOR_CFLAGS) \ -DPACKAGE_LOCALE_DIR=\"$(localedir)\" \ -DDATADIR=\"$(datadir)\" \ - -DLIBDIR=\"$(libdir)\" \ + -DHELPERDIR=\"$(HELPER_PATH_PREFIX)\" \ -DPACKAGE_DATADIR=\"$(pkgdatadir)\" \ -DG_LOG_DOMAIN=\"xfwm4\" diff --git a/src/terminate.c b/src/terminate.c index 69692b956..6d18243b0 100644 --- a/src/terminate.c +++ b/src/terminate.c @@ -110,7 +110,7 @@ terminateShowDialog (Client *c) screen_info = c->screen_info; xid = g_strdup_printf ("0x%lx", c->window); - argv[0] = LIBDIR "/xfce4/xfwm4/helper-dialog"; + argv[0] = HELPERDIR "/xfce4/xfwm4/helper-dialog"; argv[1] = xid; argv[2] = c->name; argv[3] = NULL; -- GitLab