Fix inconsistency between --sysconfdir and --with-confdir, deprecate --with-confdir.

The inconsistency was created in
c74836dc4a5bde1e0bf38da58053bf5f28da8ff5 where genssl.sh.in was made
to use sysconfdir while the IRCd and buildsystem still used confdir.
This commit is contained in:
Nathan Phillip Brink 2012-03-02 01:11:42 +00:00 committed by JD Horelick
parent 5a0814763c
commit 68ebdf7f1e
7 changed files with 31 additions and 80 deletions

View File

@ -28,7 +28,7 @@ libdir = @libdir@
pkglibdir = @pkglibdir@
moduledir = @moduledir@
helpdir = @helpdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
logdir = @logdir@
rundir = @rundir@
pkgrundir = @pkgrundir@
@ -129,8 +129,8 @@ install-mkdirs:
-@if test ! -d $(DESTDIR)$(bindir); then \
mkdir -p -m 755 $(DESTDIR)$(bindir); \
fi
-@if test ! -d $(DESTDIR)$(confdir); then \
mkdir -p -m 755 $(DESTDIR)$(confdir); \
-@if test ! -d $(DESTDIR)$(sysconfdir); then \
mkdir -p -m 755 $(DESTDIR)$(sysconfdir); \
fi
-@if test ! -d $(DESTDIR)$(mandir); then \
mkdir -p -m 755 $(DESTDIR)$(mandir); \

View File

@ -23,7 +23,7 @@ bindir = @bindir@
libdir = @libdir@
libexecdir = @libexecdir@
pkglibexecdir = @pkglibexecdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
localstatedir = @localstatedir@
PACKAGE_TARNAME = @PACKAGE_TARNAME@

54
configure vendored
View File

@ -621,7 +621,6 @@ helpdir
HELP_DIR
logdir
LOG_DIR
confdir
ETC_DIR
ZLIB_LD
ENCSPEED
@ -1377,7 +1376,8 @@ Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
--with-zlib-path=DIR Path to libz.so for ziplinks support.
--with-confdir=DIR Directory to install config files.
--with-confdir=DIR Directory to install config files [deprecated, use
--sysconfdir instead].
--with-logdir=DIR Directory where to write logfiles.
--with-helpdir=DIR Directory to install help files.
--with-moduledir=DIR Directory to install modules.
@ -7275,48 +7275,18 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to modify confdir" >&5
$as_echo_n "checking whether to modify confdir... " >&6; }
# Check whether --with-confdir was given.
if test "${with_confdir+set}" = set; then :
withval=$with_confdir; confdir=`echo $withval | sed 's/\/$//'`
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
test "x$prefix" = xNONE && prefix="$ac_default_prefix"
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
last_ac_define_dir=`eval echo $confdir`
ac_define_dir=`eval echo $last_ac_define_dir`
while test "x$last_ac_define_dir" != "x$ac_define_dir"; do
last_ac_define_dir="$ac_define_dir"
ac_define_dir=`eval echo $last_ac_define_dir`
done
ETC_DIR="$ac_define_dir"
cat >>confdefs.h <<_ACEOF
#define ETC_DIR "$ac_define_dir"
_ACEOF
confdir=`(
test "x$prefix" = xNONE && prefix="$ac_default_prefix"
test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
eval echo \""$confdir"\"
)`
withval=$with_confdir; sysconfdir=`echo $withval | sed 's/\/$//'`
else
confdir='${sysconfdir}'
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
test "x$prefix" = xNONE && prefix="$ac_default_prefix"
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
last_ac_define_dir=`eval echo $confdir`
last_ac_define_dir=`eval echo $sysconfdir`
ac_define_dir=`eval echo $last_ac_define_dir`
while test "x$last_ac_define_dir" != "x$ac_define_dir"; do
last_ac_define_dir="$ac_define_dir"
@ -7332,18 +7302,6 @@ _ACEOF
confdir=`(
test "x$prefix" = xNONE && prefix="$ac_default_prefix"
test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
eval echo \""$confdir"\"
)`
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to modify logdir" >&5
$as_echo_n "checking whether to modify logdir... " >&6; }

View File

@ -609,22 +609,15 @@ AC_ARG_ENABLE(epoll, AC_HELP_STRING([--enable-epoll],[Force sys_epoll usage (Lin
],)
dnl **********************************************************************
dnl Check for --with-confdir
dnl Check for --with-confdir [deprecated, use --sysconfdir instead]
dnl **********************************************************************
AC_MSG_CHECKING([whether to modify confdir])
AC_ARG_WITH(confdir,
AC_HELP_STRING([--with-confdir=DIR],
[Directory to install config files.]),
[ confdir=`echo $withval | sed 's/\/$//'`
AC_MSG_RESULT(yes)
AC_DEFINE_DIR(ETC_DIR, confdir, [Prefix where config files are installed.])
AC_SUBST_DIR([confdir]) ],
[ confdir='${sysconfdir}'
AC_MSG_RESULT(no)
AC_DEFINE_DIR(ETC_DIR, confdir, [Prefix where config files are installed.])
AC_SUBST_DIR([confdir])]
)
AC_ARG_WITH([confdir],
[AC_HELP_STRING([--with-confdir=DIR],
[Directory to install config files [deprecated, use --sysconfdir instead].])],
[ sysconfdir=`echo $withval | sed 's/\/$//'` ],
[ confdir='${sysconfdir}' ])
AC_DEFINE_DIR([ETC_DIR], [sysconfdir], [Prefix where config files are installed.])
dnl **********************************************************************
dnl Check for --with-logdir

View File

@ -22,7 +22,7 @@ exec_prefix = @exec_prefix@
exec_suffix = @exec_suffix@
bindir = @bindir@
libexecdir = @libexecdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
localstatedir = @localstatedir@
# Change this later! -- adrian
moduledir = @moduledir@
@ -45,9 +45,9 @@ CPPFLAGS = ${INCLUDES} @CPPFLAGS@
all: build
install-mkdirs:
-@if test ! -d $(DESTDIR)$(confdir); then \
echo "mkdir -p $(confdir)"; \
mkdir -p $(DESTDIR)$(confdir); \
-@if test ! -d $(DESTDIR)$(sysconfdir); then \
echo "mkdir -p $(sysconfdir)"; \
mkdir -p $(DESTDIR)$(sysconfdir); \
fi
-@if test ! -d $(DESTDIR)$(mandir); then \
@ -58,19 +58,19 @@ install-mkdirs:
install: install-mkdirs build
@echo "ircd: installing example config files ($(CONFS))"
@for i in $(CONFS); do \
if test -f $(DESTDIR)$(confdir)/$$i; then \
$(MV) $(DESTDIR)$(confdir)/$$i $(DESTDIR)$(confdir)/$$i.old; \
if test -f $(DESTDIR)$(sysconfdir)/$$i; then \
$(MV) $(DESTDIR)$(sysconfdir)/$$i $(DESTDIR)$(sysconfdir)/$$i.old; \
fi; \
$(INSTALL_DATA) $$i $(DESTDIR)$(confdir); \
$(INSTALL_DATA) $$i $(DESTDIR)$(sysconfdir); \
done
-@if test ! -f $(DESTDIR)$(confdir)/ircd.motd; then \
-@if test ! -f $(DESTDIR)$(sysconfdir)/ircd.motd; then \
echo "ircd: installing motd file (ircd.motd)"; \
$(INSTALL_DATA) ircd.motd $(DESTDIR)$(confdir); \
$(INSTALL_DATA) ircd.motd $(DESTDIR)$(sysconfdir); \
fi
-@if test -f $(DESTDIR)$(confdir)/links.txt; then \
$(RM) $(DESTDIR)$(confdir)/links.txt; \
-@if test -f $(DESTDIR)$(sysconfdir)/links.txt; then \
$(RM) $(DESTDIR)$(sysconfdir)/links.txt; \
fi
@echo "ircd: installing manpage"

View File

@ -23,7 +23,7 @@ bindir = @bindir@
libdir = @libdir@
libexecdir = @libexecdir@
pkglibexecdir = @pkglibexecdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
localstatedir = @localstatedir@
PACKAGE_TARNAME = @PACKAGE_TARNAME@

View File

@ -26,7 +26,7 @@ exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
libexecdir = @libexecdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
localstatedir = @localstatedir@
PROGS = viconf mkpasswd convertilines convertklines genssl.sh
@ -71,7 +71,7 @@ exec_prefix = @exec_prefix@
exec_suffix = @exec_suffix@
bindir = @bindir@
libexecdir = @libexecdir@
confdir = @confdir@
sysconfdir = @sysconfdir@
localstatedir = @localstatedir@
# Change this later! -- adrian
moduledir = @moduledir@