Makefile.m4 revision 42575
1# 2# This Makefile is designed to work on the old "make" program. 3# 4# @(#)Makefile.m4 8.21 (Berkeley) 7/12/1998 5# 6 7# C compiler 8CC= confCC 9 10# Shell 11SHELL= confSHELL 12 13# use O=-O (usual) or O=-g (debugging) 14O= ifdef(`confOPTIMIZE', `confOPTIMIZE', `-O') 15 16# location of sendmail source directory 17SRCDIR= ifdef(`confSRCDIR', `confSRCDIR', `../../src') 18 19# define the database mechanisms available for map & alias lookups: 20# -DNDBM -- use new DBM 21# -DNEWDB -- use new Berkeley DB 22# The really old (V7) DBM library is no longer supported. 23# 24MAPDEF= ifdef(`confMAPDEF', `confMAPDEF') 25 26# environment definitions (e.g., -D_AIX3) 27ENVDEF= -DNOT_SENDMAIL ifdef(`confENVDEF', `confENVDEF') 28 29# see also conf.h for additional compilation flags 30 31# include directories 32INCDIRS=-I${SRCDIR} confINCDIRS 33 34# loader options 35LDOPTS= ifdef(`confLDOPTS', `confLDOPTS') 36 37# library directories 38LIBDIRS=confLIBDIRS 39 40# libraries required on your system 41LIBS= ifdef(`confLIBS', `confLIBS') 42 43# location of makemap binary (usually /usr/sbin or /usr/etc) 44SBINDIR=${DESTDIR}ifdef(`confSBINDIR', `confSBINDIR', `/usr/sbin') 45 46# additional .o files needed 47OBJADD= ifdef(`confOBJADD', `confOBJADD') 48 49undivert(1) 50 51################### end of user configuration flags ###################### 52 53BUILDBIN=confBUILDBIN 54COPTS= -I. ${INCDIRS} ${MAPDEF} ${ENVDEF} 55CFLAGS= $O ${COPTS} 56 57BEFORE= confBEFORE safefile.c snprintf.c 58OBJS= makemap.o safefile.o snprintf.o ${OBJADD} 59 60NROFF= ifdef(`confNROFF', `confNROFF', `groff -Tascii') 61MANDOC= ifdef(`confMANDOC', `confMANDOC', `-mandoc') 62 63INSTALL=ifdef(`confINSTALL', `confINSTALL', `install') 64BINOWN= ifdef(`confUBINOWN', `confUBINOWN', `bin') 65BINGRP= ifdef(`confUBINGRP', `confUBINGRP', `bin') 66BINMODE=ifdef(`confUBINMODE', `confUBINMODE', `555') 67 68MANOWN= ifdef(`confMANOWN', `confMANOWN', `bin') 69MANGRP= ifdef(`confMANGRP', `confMANGRP', `bin') 70MANMODE=ifdef(`confMANMODE', `confMANMODE', `444') 71 72MANROOT=${DESTDIR}ifdef(`confMANROOT', `confMANROOT', `/usr/share/man/cat') 73MAN8= ${MANROOT}ifdef(`confMAN8', `confMAN8', `8') 74MAN8EXT=ifdef(`confMAN8EXT', `confMAN8EXT', `8') 75MAN8SRC=ifdef(`confMAN8SRC', `confMAN8SRC', `0') 76 77ALL= makemap makemap.${MAN8SRC} 78 79all: ${ALL} 80 81makemap: ${BEFORE} ${OBJS} 82 ${CC} -o makemap ${LDOPTS} ${OBJS} ${LIBDIRS} ${LIBS} 83 84safefile.c: ${SRCDIR}/safefile.c 85 -ln -s ${SRCDIR}/safefile.c safefile.c 86 87snprintf.c: ${SRCDIR}/snprintf.c 88 -ln -s ${SRCDIR}/snprintf.c snprintf.c 89 90undivert(3) 91 92makemap.${MAN8SRC}: makemap.8 93 ${NROFF} ${MANDOC} makemap.8 > makemap.${MAN8SRC} 94 95install: install-makemap install-docs 96 97install-makemap: makemap 98 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} makemap ${SBINDIR} 99 100install-docs: makemap.${MAN8SRC} 101ifdef(`confNO_MAN_INSTALL', `dnl', 102` ${INSTALL} -c -o ${MANOWN} -g ${MANGRP} -m ${MANMODE} makemap.${MAN8SRC} ${MAN8}/makemap.${MAN8EXT}') 103 104clean: 105 rm -f ${OBJS} makemap makemap.${MAN8SRC} 106 107################ Dependency scripts 108include(confBUILDTOOLSDIR/M4/depend/ifdef(`confDEPEND_TYPE', `confDEPEND_TYPE', 109`generic').m4)dnl 110################ End of dependency scripts 111