From 0ee539f31c27eb0382073ba4ddab6bc27fa7e603 Mon Sep 17 00:00:00 2001 From: rofl0r Date: Mon, 30 Jan 2012 18:26:38 +0100 Subject: [PATCH] added support for --sysconfdir --- Makefile | 3 ++- configure | 8 +++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index b5f1447..2078311 100644 --- a/Makefile +++ b/Makefile @@ -11,6 +11,7 @@ bindir = $(exec_prefix)/bin prefix = /usr/local/ includedir = $(prefix)/include libdir = $(prefix)/lib +sysconfdir=$(prefix)/etc SRCS = $(sort $(wildcard src/*.c)) OBJS = $(SRCS:.c=.o) @@ -47,7 +48,7 @@ all: $(ALL_LIBS) $(ALL_TOOLS) install: install $(INSTALL_FLAGS) 755 $(ALL_TOOLS) $(bindir)/ install $(INSTALL_FLAGS) 644 $(ALL_LIBS) $(libdir)/ - install $(INSTALL_FLAGS) 644 src/proxychains.conf $(prefix)/etc/ + install $(INSTALL_FLAGS) 644 src/proxychains.conf $(sysconfdir)/ clean: rm -f $(ALL_LIBS) diff --git a/configure b/configure index 6ce9341..cffb34c 100755 --- a/configure +++ b/configure @@ -11,11 +11,12 @@ spliteq() { parsearg() { case "$1" in - --prefix=*) prefix=$(spliteq "$1");; + --prefix=*) prefix=`spliteq $1`;; --exec_prefix=*) exec_prefix=`spliteq $1`;; --bindir=*) bindir=`spliteq $1`;; --libdir=*) libdir=`spliteq $1`;; --includedir=*) includedir=`spliteq $1`;; + --sysconfdir=*) sysconfdir=`spliteq $1`;; esac } @@ -42,6 +43,10 @@ if [ ! $includedir ] ; then includedir=$prefix/include fi +if [ ! $sysconfdir ] ; then + sysconfdir=$prefix/etc +fi + if [ ! $bindir ] ; then bindir=$exec_prefix/bin fi @@ -58,6 +63,7 @@ echo exec_prefix=$exec_prefix>>config.mak echo bindir=$bindir>>config.mak echo libdir=$libdir>>config.mak echo includedir=$includedir>>config.mak +echo sysconfdir=$sysconfdir>>config.mak if ismac ; then echo LDSO_SUFFIX=dylib>>config.mak echo MAC_CFLAGS+=-DIS_MAC=1>>config.mak