mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-24 13:24:56 +08:00
Update build environment:
default sysconfdir subdirectory is openldap instead of ldap. This removes conflicts with other ldap subsystems. Should be configure option. *.conf files are now preserved. A *.conf.default are always created with the latest conf. *.help and ldapfriendly are now placed in $(datadir)/$(ldap_subdir) updated man pages to reflect changes.
This commit is contained in:
parent
9aa2cd646b
commit
edd464ee8f
@ -13,6 +13,7 @@ install-common: FORCE
|
||||
$(SED) -e "s%LDVERSION%$$VERSION%" \
|
||||
-e 's%ETCDIR%$(sysconfdir)%' \
|
||||
-e 's%SYSCONFDIR%$(sysconfdir)%' \
|
||||
-e 's%DATADIR%$(datadir)%' \
|
||||
-e 's%SBINDIR%$(sbindir)%' \
|
||||
-e 's%BINDIR%$(bindir)%' \
|
||||
-e 's%LIBDIR%$(libdir)%' \
|
||||
|
20
build/top.mk
20
build/top.mk
@ -18,16 +18,16 @@ prefix = @prefix@
|
||||
exec_prefix = @exec_prefix@
|
||||
|
||||
bindir = @bindir@
|
||||
sbindir = @sbindir@
|
||||
libexecdir = @libexecdir@
|
||||
datadir = @datadir@
|
||||
sysconfdir = @sysconfdir@/ldap
|
||||
sharedstatedir = @sharedstatedir@
|
||||
localstatedir = @localstatedir@
|
||||
libdir = @libdir@
|
||||
infodir = @infodir@
|
||||
mandir = @mandir@
|
||||
datadir = @datadir@/@ldap_subdir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localstatedir = @localstatedir@
|
||||
mandir = @mandir@
|
||||
sbindir = @sbindir@
|
||||
sharedstatedir = @sharedstatedir@
|
||||
sysconfdir = @sysconfdir@/@ldap_subdir@
|
||||
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
@ -58,7 +58,7 @@ HOSTNAME = uname -n
|
||||
BASENAME = basename
|
||||
PWD = pwd
|
||||
CAT = cat
|
||||
MKDIR = mkdir
|
||||
MKDIR = mkdir -p
|
||||
CHMOD = chmod
|
||||
|
||||
# Misc UNIX commands used in programs
|
||||
|
@ -32,7 +32,7 @@ fax5version.c: ${FAX5OBJS} $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: $(PROGRAMS) xrpcomp FORCE
|
||||
-$(MKDIR) -p $(libexecdir)
|
||||
-$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 rp500 $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 fax500 $(libexecdir)
|
||||
$(SED) -e 's%LIBEXECDIR%$(libexecdir)%' $(srcdir)/xrpcomp > /tmp/xrpcomp.tmp
|
||||
|
@ -18,5 +18,5 @@ version.c: ${OBJS} ${LDAP_LIBDEPEND}
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: $(PROGRAMS) FORCE
|
||||
-$(MKDIR) -p $(libexecdir)
|
||||
-$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 in.xfingerd $(libexecdir)
|
||||
|
@ -36,8 +36,8 @@ gwversion.c: ${GWOBJS} $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Versiongw.c > $@)
|
||||
|
||||
install-local: $(PROGRAMS) go500gw.help FORCE
|
||||
-$(MKDIR) -p $(libexecdir) $(sysconfdir)
|
||||
-$(MKDIR) $(libexecdir) $(datadir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 go500 $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 go500gw $(libexecdir)
|
||||
-$(MV) $(sysconfdir)/go500gw.help $(sysconfdir)/go500gw.help-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 go500gw.help $(sysconfdir)
|
||||
-$(MV) $(datadir)/go500gw.help $(datadir)/go500gw.help-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 go500gw.help $(datadir)
|
||||
|
@ -19,5 +19,5 @@ version.c: ${OBJS} $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: $(PROGRAMS) FORCE
|
||||
-$(MKDIR) -p $(libexecdir)
|
||||
-$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 mail500 $(libexecdir)
|
||||
|
@ -19,7 +19,7 @@ version.c: ${OBJS} $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: $(PROGRAMS) rcpt500.help FORCE
|
||||
-$(MKDIR) -p $(libexecdir) $(sysconfdir)
|
||||
-$(MKDIR) $(libexecdir) $(datadir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 rcpt500 $(libexecdir)
|
||||
-$(MV) $(sysconfdir)/rcpt500.help $(sysconfdir)/rcpt500.help-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 rcpt500.help $(sysconfdir)
|
||||
-$(MV) $(datadir)/rcpt500.help $(datadir)/rcpt500.help-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 rcpt500.help $(datadir)
|
||||
|
@ -62,7 +62,7 @@ ldrversion.c: ldapmodrdn.o $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Versionldr.c > $@)
|
||||
|
||||
install-local: FORCE
|
||||
-$(MKDIR) -p $(bindir)
|
||||
-$(MKDIR) $(bindir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapsearch $(bindir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapmodify $(bindir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapdelete $(bindir)
|
||||
|
@ -23,6 +23,6 @@ version.c: ${OBJS} $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: FORCE
|
||||
-$(MKDIR) -p $(bindir)
|
||||
-$(MKDIR) $(bindir)
|
||||
-mv -f $(bindir)/ud $(bindir)/ud-
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 775 ud $(bindir)
|
||||
|
@ -26,6 +26,9 @@ AC_PREFIX_DEFAULT(/usr/local)
|
||||
top_builddir=`pwd`
|
||||
AC_SUBST(top_builddir)dnl
|
||||
|
||||
ldap_subdir="openldap"
|
||||
AC_SUBST(ldap_subdir)dnl
|
||||
|
||||
OL_ARG_ENABLE(debug,[ --enable-debug enable debugging], yes)dnl
|
||||
dnl OL_ARG_ENABLE(syslog,[ --enable-syslog enable syslog support], auto)dnl
|
||||
OL_ARG_ENABLE(proctitle,[ --enable-proctitle enable proctitle support], yes)dnl
|
||||
|
@ -43,7 +43,7 @@ For example:
|
||||
FriendlyMap *map = NULL;
|
||||
|
||||
printf( "unfriendly %s => friendly %s\\n", name,
|
||||
ldap_friendly_name( "ETCDIR/ldapfriendly", name, &map ) );
|
||||
ldap_friendly_name( "DATADIR/ldapfriendly", name, &map ) );
|
||||
.ft
|
||||
.fi
|
||||
.LP
|
||||
@ -63,7 +63,7 @@ NULL is returned by
|
||||
if there is an error opening \fIfilename\fP, or if the file has a bad
|
||||
format, or if the \fImap\fP parameter is NULL.
|
||||
.SH FILES
|
||||
ETCDIR/ldapfriendly.conf
|
||||
DATADIR/ldapfriendly.conf
|
||||
.SH SEE ALSO
|
||||
.BR ldap (3)
|
||||
.SH ACKNOWLEDGEMENTS
|
||||
|
@ -1,16 +1,16 @@
|
||||
.TH LDAPFRIENDLY 5 "22 September 1998" "OpenLDAP LDVERSION"
|
||||
.SH NAME
|
||||
ldapfriendly \- configuration file for LDAP friendly routines
|
||||
ldapfriendly \- data file for LDAP friendly routines
|
||||
.SH SYNOPSIS
|
||||
ETCDIR/ldapfriendly
|
||||
DATADIR/ldapfriendly
|
||||
.SH DESCRIPTION
|
||||
.LP
|
||||
The file ETCDIR/ldapfriendly contains simple mapping information
|
||||
The file DATADIR/ldapfriendly contains simple mapping information
|
||||
used by the
|
||||
.BR ldap_friendly_name (3)
|
||||
routine. Blank lines and
|
||||
lines that have a first character of `#' are treated as comments and
|
||||
ignored. The configuration information consists of lines that contain
|
||||
ignored. The information consists of lines that contain
|
||||
an "unfriendly" name, a tab, and a "friendly" name.
|
||||
.LP
|
||||
Other friendly mapping files can be created and used by
|
||||
@ -20,7 +20,7 @@ above and include the file name in the
|
||||
.B ldap_friendly_name()
|
||||
call.
|
||||
.SH FILES
|
||||
ETCDIR/ldapfriendly
|
||||
DATADIR/ldapfriendly
|
||||
.SH SEE ALSO
|
||||
.BR ldap (3),
|
||||
.BR ldap_friendly_name (3)
|
||||
|
@ -77,7 +77,7 @@ for your site.
|
||||
.SH FILES
|
||||
.PD 0
|
||||
.TP 20
|
||||
.B ETCDIR/rcpt500.help
|
||||
.B DATADIR/rcpt500.help
|
||||
help file
|
||||
.PD
|
||||
.SH "SEE ALSO"
|
||||
|
@ -33,6 +33,7 @@ ldapconfig.h: $(srcdir)/ldapconfig.h.edit Makefile
|
||||
echo "" >> $@; \
|
||||
$(SED) \
|
||||
-e 's;%SYSCONFDIR%;$(sysconfdir);' \
|
||||
-e 's;%DATADIR%;$(datadir);' \
|
||||
-e 's;%BINDIR%;$(bindir);' \
|
||||
-e 's;%SBINDIR%;$(sbindir);' \
|
||||
-e 's;%LIBEXECDIR%;$(libexecdir);' \
|
||||
|
@ -24,6 +24,7 @@
|
||||
*/
|
||||
#define DEFAULT_BINDIR "%BINDIR%"
|
||||
#define DEFAULT_SBINDIR "%SBINDIR%"
|
||||
#define DEFAULT_DATADIR "%DATADIR%"
|
||||
#define DEFAULT_SYSCONFDIR "%SYSCONFDIR%"
|
||||
#define DEFAULT_LIBEXECDIR "%LIBEXECDIR%"
|
||||
|
||||
@ -49,7 +50,7 @@
|
||||
#define FILTERFILE "%SYSCONFDIR%/ldapfilter.conf"
|
||||
#define TEMPLATEFILE "%SYSCONFDIR%/ldaptemplates.conf"
|
||||
#define SEARCHFILE "%SYSCONFDIR%/ldapsearchprefs.conf"
|
||||
#define FRIENDLYFILE "%SYSCONFDIR%/ldapfriendly"
|
||||
#define FRIENDLYFILE "%DATADIR%/ldapfriendly"
|
||||
|
||||
/*
|
||||
* FINGER DEFINITIONS
|
||||
@ -110,7 +111,7 @@ Please try again later.\r\n"
|
||||
* GO500GW GOPHER GATEWAY DEFINITIONS
|
||||
*/
|
||||
/* where the helpfile lives */
|
||||
#define GO500GW_HELPFILE "%SYSCONFDIR%/go500gw.help"
|
||||
#define GO500GW_HELPFILE "%DATADIR%/go500gw.help"
|
||||
/* port on which to listen */
|
||||
#define GO500GW_PORT 7777
|
||||
/* timeout on all searches */
|
||||
@ -131,7 +132,7 @@ Please try again later.\r\n"
|
||||
* RCPT500 MAIL RESPONDER GATEWAY DEFINITIONS
|
||||
*/
|
||||
/* where the helpfile lives */
|
||||
#define RCPT500_HELPFILE "%SYSCONFDIR%/rcpt500.help"
|
||||
#define RCPT500_HELPFILE "%DATADIR%/rcpt500.help"
|
||||
/* maximum number of matches returned */
|
||||
#define RCPT500_SIZELIMIT 50
|
||||
/* address replies will appear to come from */
|
||||
|
@ -23,6 +23,6 @@ idtest: $(LIBRARY) idtest.o
|
||||
$(LTLINK) $(LDFLAGS) -o $@ idtest.o $(LIBS)
|
||||
|
||||
install-local: FORCE
|
||||
-$(MKDIR) -p $(libdir)
|
||||
-$(MKDIR) $(libdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 644 $(LIBRARY) $(libdir)
|
||||
|
||||
|
@ -31,18 +31,23 @@ ltest: $(LIBRARY) test.o $(LDAP_LIBLBER_DEPEND)
|
||||
ttest: $(LIBRARY) tmpltest.o $(LDAP_LIBLBER_DEPEND)
|
||||
$(LTLINK) $(LDFLAGS) -o $@ tmpltest.o $(LIBS)
|
||||
|
||||
CFFILES= ldap.conf ldapfilter.conf ldapfriendly \
|
||||
ldaptemplates.conf ldapsearchprefs.conf
|
||||
CFFILES=ldap.conf ldapfilter.conf ldaptemplates.conf ldapsearchprefs.conf
|
||||
|
||||
install-local: $(CFFILES) FORCE
|
||||
-$(MKDIR) -p $(libdir)
|
||||
-$(MKDIR) $(libdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 644 $(LIBRARY) $(libdir)
|
||||
-$(MKDIR) -p $(sysconfdir)
|
||||
-$(MKDIR) $(sysconfdir)
|
||||
@for i in $(CFFILES); do \
|
||||
echo "installing $$i in $(sysconfdir)"; \
|
||||
if test -f $(sysconfdir)/$$i; then \
|
||||
$(MV) $(sysconfdir)/$$i $(sysconfdir)/$$i-; \
|
||||
if test ! -f $(sysconfdir)/$$i; then \
|
||||
echo "installing $$i in $(sysconfdir)"; \
|
||||
echo "$(INSTALL) $(INSTALLFLAGS) -m 644 $$i $(sysconfdir)/$$i"; \
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 $$i $(sysconfdir)/$$i; \
|
||||
else \
|
||||
echo "PRESERVING EXISTING CONFIGURATION FILE $(sysconfdir)/$$i" ; \
|
||||
fi; \
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 $$i $(sysconfdir); \
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 $$i $(sysconfdir)/$$i.default; \
|
||||
done
|
||||
-$(MKDIR) $(datadir)
|
||||
-$(MV) $(datadir)/ldapfriendly $(datadir)/ldapfriendly-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 ldapfriendly $(datadir)/ldapfriendly
|
||||
|
||||
|
@ -45,6 +45,6 @@ LDAP_tables.c: ldap.py
|
||||
|
||||
LDAP-types.h: LDAP_tables.c
|
||||
|
||||
install-local: FORCE
|
||||
@$(MKDIR) -p $(libexecdir)
|
||||
install-srv: FORCE
|
||||
@$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapd $(LDAP_LIBEXECDIR)
|
||||
|
@ -116,16 +116,23 @@ install-slapd: FORCE
|
||||
@-$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 slapd $(libexecdir)
|
||||
|
||||
CFFILES=slapd.conf slapd.at.conf slapd.oc.conf
|
||||
|
||||
install-conf: FORCE
|
||||
@-$(MKDIR) -p $(sysconfdir)
|
||||
$(SED) -e 's;%SYSCONFDIR%;$(sysconfdir);' slapd.conf > /tmp/slapd.$$
|
||||
-$(MV) $(sysconfdir)/slapd.conf $(sysconfdir)/slapd.conf-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 /tmp/slapd.$$ $(sysconfdir)/slapd.conf
|
||||
$(RM) -f /tmp/slapd.$$
|
||||
-$(MV) $(sysconfdir)/slapd.at.conf $(sysconfdir)/slapd.at.conf-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 slapd.at.conf $(sysconfdir)
|
||||
-$(MV) $(sysconfdir)/slapd.oc.conf $(sysconfdir)/slapd.oc.conf-
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 slapd.oc.conf $(sysconfdir)
|
||||
@-$(MKDIR) $(sysconfdir)
|
||||
@for i in $(CFFILES); do \
|
||||
tmpcf=/tmp/$$i.$$ ; \
|
||||
$(SED) -e 's;%SYSCONFDIR%;$(sysconfdir);' $$i > $$tmpcf ; \
|
||||
if test ! -f $(sysconfdir)/$$i; then \
|
||||
echo "installing $$i in $(sysconfdir)"; \
|
||||
echo "$(INSTALL) $(INSTALLFLAGS) -m 644 $$tmpcf $(sysconfdir)/$$i"; \
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 $$tmpcf $(sysconfdir)/$$i; \
|
||||
else \
|
||||
echo "PRESERVING EXISTING CONFIGURATION FILE $(sysconfdir)/$$i" ; \
|
||||
fi; \
|
||||
$(INSTALL) $(INSTALLFLAGS) -m 644 $$tmpcf $(sysconfdir)/$$i.default; \
|
||||
$(RM) -f /tmp/slapd.$$ ; \
|
||||
done
|
||||
|
||||
install-tools: FORCE
|
||||
@-$(MKDIR) $(sbindir)
|
||||
|
@ -128,7 +128,7 @@ depend-local: FORCE
|
||||
install-local: install-ldbm install-isode FORCE
|
||||
|
||||
install-ldbm: FORCE
|
||||
@-$(MKDIR) -p $(sbindir)
|
||||
@-$(MKDIR) $(sbindir)
|
||||
@if [ "$(BUILD_LDBM)" = "yes" ]; then \
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldif2ldbm $(sbindir) ; \
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 ldif2index $(sbindir) ; \
|
||||
@ -143,7 +143,7 @@ install-ldbm: FORCE
|
||||
fi
|
||||
|
||||
install-isode: FORCE
|
||||
@-$(MKDIR) -p $(sbindir)
|
||||
@-$(MKDIR) $(sbindir)
|
||||
@if [ "$(HAVE_ISODE)" = "yes" ]; then \
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 edb2ldif $(sbindir); \
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 chlog2replog $(sbindir); \
|
||||
|
@ -41,5 +41,5 @@ version.c: $(OBJS) $(LDAP_LIBDEPEND)
|
||||
< $(srcdir)/Version.c > $@)
|
||||
|
||||
install-local: FORCE
|
||||
@-$(MKDIR) -p $(libexecdir)
|
||||
@-$(MKDIR) $(libexecdir)
|
||||
$(LTINSTALL) $(INSTALLFLAGS) -m 755 slurpd $(libexecdir)
|
||||
|
Loading…
Reference in New Issue
Block a user