From d37b40dc073d6f9a884f2317fc48bc83a98ff921 Mon Sep 17 00:00:00 2001 From: matt335672 <30179339+matt335672@users.noreply.github.com> Date: Thu, 4 Nov 2021 13:55:53 +0000 Subject: Make xdgautostartdir configurable --- configure.ac | 10 ++++++++++ instfiles/Makefile.am | 4 ---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index d4090b4..f4bf72d 100644 --- a/configure.ac +++ b/configure.ac @@ -28,6 +28,9 @@ PA_LIBDIR=`$PKG_CONFIG --variable=libdir libpulse` PA_MODDIR=`$PKG_CONFIG --variable=modlibexecdir libpulse` PA_PREFIX=`$PKG_CONFIG --variable=prefix libpulse` +# Default system-wide autostart directory from XDG autostart specification +m4_define([XDG_AUTOSTART_DIR], /etc/xdg/autostart) + AC_SUBST([PA_MAJOR], [pa_major]) AC_SUBST([PA_MINOR], [pa_minor]) AC_SUBST([PA_MAJORMINOR], [pa_major].[pa_minor]) @@ -68,6 +71,13 @@ AC_ARG_WITH( [modlibexecdir=$withval], [modlibexecdir="${PA_MODDIR}"]) AC_SUBST(modlibexecdir) +AC_ARG_WITH( + [xdgautostart-dir], + [AS_HELP_STRING([--with-xdgautostart-dir], + Directory to install the desktop file (defaults to XDG_AUTOSTART_DIR))], + [xdgautostartdir=$withval], [xdgautostartdir=XDG_AUTOSTART_DIR]) +AC_SUBST(xdgautostartdir) + # Checks for header files. AC_CHECK_HEADERS([fcntl.h limits.h netinet/in.h stdlib.h string.h sys/ioctl.h sys/socket.h unistd.h]) diff --git a/instfiles/Makefile.am b/instfiles/Makefile.am index 9c281fe..59a1508 100644 --- a/instfiles/Makefile.am +++ b/instfiles/Makefile.am @@ -22,10 +22,6 @@ SUFFIXES = .in # # files for all platforms # - -# Don't use sysconfdir for this one as it won't work! -xdgautostartdir=/etc/xdg/autostart - xdgautostart_DATA = \ pulseaudio-xrdp.desktop -- cgit v1.2.3