]> git.alsa-project.org Git - alsa-plugins.git/commitdiff
configure: use $sysconfdir instead of /etc
authorAlex Ivanov <gnidorah@ya.ru>
Sat, 23 Mar 2019 05:20:57 +0000 (08:20 +0300)
committerTakashi Iwai <tiwai@suse.de>
Wed, 27 Mar 2019 11:30:27 +0000 (12:30 +0100)
Use $sysconfdir as prefix for ALSA_LCONF_DIR by default. Otherwise install
fails on non-FHS distros.

Signed-off-by: Alex Ivanov <gnidorah@ya.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
configure.ac

index 5b80585fa54257266de4c59adcfd7858156f9abd..1be4a70c803c367528aaf07839430801bc7f0c78 100644 (file)
@@ -237,7 +237,12 @@ AC_ARG_WITH(alsalconfdir,
        [path where ALSA local add-on config files are stored]),
     alsalconfdir="$withval", alsalconfdir="")
 if test -z "$alsalconfdir"; then
-    alsalconfdir="/etc/alsa/conf.d"
+    eval dir="$sysconfdir"
+    case "$dir" in
+    /*) ;;
+    *) dir="$dir"
+    esac
+    alsalconfdir="$dir/alsa/conf.d"
 fi
 AC_DEFINE_UNQUOTED(ALSA_LCONF_DIR, "$alsalconfdir", [directory containing local ALSA add-on config files])
 ALSA_LCONF_DIR="$alsalconfdir"