diff options
author | Emmanuel Dreyfus <manu@netbsd.org> | 2012-09-02 07:11:04 +0200 |
---|---|---|
committer | Vijay Bellur <vbellur@redhat.com> | 2012-09-05 07:47:50 -0700 |
commit | e1d24d45c56fd841c0a9a0a2ad32b08ebb2cd5b1 (patch) | |
tree | 669a8b6bb6c3bf43f9249342d0c8d8a07e9c32c2 | |
parent | 9d0da50fdeb8ae235d34d7990a2bc28adf52434c (diff) |
Honour configure --localstatedir and --sysconfdir
Makes sure /etc/glusterd to /var/lib/glusterd migration does nonour
configure --localstatedir and --sysconfdir.
BUG: 764655
Change-Id: I65a5f96424d67531e81e75b084265bd4e6e30f29
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org>
Reviewed-on: http://review.gluster.org/3890
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/Makefile.am | 7 |
2 files changed, 5 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index fbaf7b9f9a1..5dae93d8778 100644 --- a/configure.ac +++ b/configure.ac @@ -566,7 +566,7 @@ AC_SUBST(INCLUDES) AM_CONDITIONAL([GF_DARWIN_HOST_OS], test "${GF_HOST_OS}" = "GF_DARWIN_HOST_OS") -AM_CONDITIONAL([GF_INSTALL_VAR_LIB_GLUSTERD], test ! -d /var/lib/glusterd && test -d /etc/glusterd ) +AM_CONDITIONAL([GF_INSTALL_VAR_LIB_GLUSTERD], test ! -d ${localstatedir}/lib/glusterd && test -d ${sysconfdir}/glusterd ) AC_OUTPUT diff --git a/xlators/mgmt/glusterd/src/Makefile.am b/xlators/mgmt/glusterd/src/Makefile.am index 485350b3d1e..79e10a3459e 100644 --- a/xlators/mgmt/glusterd/src/Makefile.am +++ b/xlators/mgmt/glusterd/src/Makefile.am @@ -34,7 +34,8 @@ CLEANFILES = install-data-hook: if GF_INSTALL_VAR_LIB_GLUSTERD - $(mkdir_p) /var/lib/ - (stat /etc/glusterd && mv /etc/glusterd /var/lib/) || true; - (ln -sf /var/lib/glusterd /etc/glusterd) || true; + $(mkdir_p) $(localstatedir)/lib/ + (stat $(sysconfdir)/glusterd && \ + mv $(sysconfdir)/glusterd $(localstatedir)/lib/) || true; + (ln -sf $(localstatedir)/lib/glusterd $(sysconfdir)/glusterd) || true; endif |