めんてなのおしごと

Sat, Jan 27, 2018 in debian

--- configure.ac.orig   2018-01-27 15:56:50.839599352 +0000
+++ configure.ac        2018-01-27 16:24:56.910015986 +0000
@@ -60,11 +60,14 @@
 
 fillupdir=/var/adm/fillup-templates
 
+SYSCONFIG=/etc/sysconfig
+
 AC_ARG_WITH([conf], AC_HELP_STRING([--with-conf], [Use a custom sysconfig directory (default is /etc/sysconfig)]),
        [with_conf=$withval], [with_conf=no])
 
-AS_IF([test "x$with_conf" != xno], [CPPFLAGS="${CPPFLAGS} -DCONFDIR='\"${with_conf}\"'"],
-       [CPPFLAGS="${CPPFLAGS} -DCONFDIR='\"/etc/sysconfig\"'"])
+AS_IF([test "x$with_conf" != xno], [SYSCONFIG="${with_conf}"])
+
+CPPFLAGS="${CPPFLAGS} -DCONFDIR='\"${SYSCONFIG}\"'"
 
 AC_ARG_ENABLE([btrfs], AC_HELP_STRING([--disable-btrfs],[Disable Btrfs internal snapshots support]),
                [with_btrfs=$enableval],[with_btrfs=yes])
@@ -153,6 +156,7 @@
 AC_SUBST(LIBVERSION_MINOR)
 AC_SUBST(LIBVERSION_PATCHLEVEL)
 AC_SUBST(LIBVERSION_INFO)
+AC_SUBST(SYSCONFIG)
 AC_SUBST(docdir)
 AC_SUBST(fillupdir)


diff --git a/doc/snapper.xml.in b/doc/snapper.xml.in
index 1507b5d..9073ab3 100644
--- a/doc/snapper.xml.in
+++ b/doc/snapper.xml.in
@@ -686,7 +686,7 @@
     <title>FILES</title>
     <variablelist>
       <varlistentry>
-       <term><filename>/etc/sysconfig/snapper</filename></term>
+       <term><filename>@SYSCONFIG@/snapper</filename></term>
        <listitem>
          <para>Global configuration file.</para>
        </listitem>