[PATCH] Honor sysconfdir when set as an configure option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



./configure can be run with option --sysconfdir=...
and Makefile should respect that choice.

Signed-off-by: Kacper Kornet <draenog@xxxxxxxxxxxxx>
---
 Makefile      |    8 ++++----
 config.mak.in |    2 ++
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/Makefile b/Makefile
index bf912b9..9d6cffa 100644
--- a/Makefile
+++ b/Makefile
@@ -1186,11 +1186,11 @@ endif
 -include config.mak
 
 ifeq ($(prefix),/usr)
-sysconfdir = /etc
-git_etcdir = /etc
+sysconfdir ?= /etc
+git_etcdir ?= /etc
 else
-sysconfdir = $(prefix)/etc
-git_etcdir = etc
+sysconfdir ?= $(prefix)/etc
+git_etcdir ?= etc
 endif
 
 ifdef CHECK_HEADER_DEPENDENCIES
diff --git a/config.mak.in b/config.mak.in
index e378534..ac5912d 100644
--- a/config.mak.in
+++ b/config.mak.in
@@ -15,6 +15,8 @@ TCLTK_PATH = @TCLTK_PATH@
 prefix = @prefix@
 exec_prefix = @exec_prefix@
 bindir = @bindir@
+sysconfdir = @sysconfdir@
+git_etcdir = @sysconfdir@
 gitexecdir = @libexecdir@/git-core
 datarootdir = @datarootdir@
 template_dir = @datadir@/git-core/templates
-- 
1.7.5

-- 
  Kacper Kornet
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]