`# $Id: Makefile.host,v 5.6 2010/12/03 14:48:44 ksb Exp $ # Makefile for distrib, msrc 2008 hosted, KS Braunsdorf, NPCGuild.org SHELL=/bin/sh RUN_LIB=/usr/local/lib/distrib SBIN=${DESTDIR}/usr/local/sbin LIB=${DESTDIR}${RUN_LIB} L=/usr/local/include P= INCLUDE= -I$L DEBUG= 'ifelse(HOSTTYPE,`V386',`',`-O')` CDEFS= -D'HOSTTYPE` -DALT_CONFIG_PATH=\"${RUN_LIB}\" CFLAGS= ${DEBUG} ${CDEFS} ${INCLUDE} 'ifelse(HOSTTYPE,`HPUX9',`CC=gcc ')dnl ` HDR= distrib.h envlist.h machine.h SRC= distrib.c envlist.c GENc= mkdtemp.c main.c GENh= main.h GEN= ${GENc} ${GENh} DEP= ${SRC} ${GENc} OBJ= main.o distrib.o envlist.o'ifelse(HOSTTYPE,SUN5,` mkdtemp.o', HOSTTYPE,HPUX9,` mkdtemp.o', HOSTTYPE,HPUX10,` mkdtemp.o', HOSTTYPE,HPUX11,` mkdtemp.o', HOSTTYPE,AIX,` mkdtemp.o', HOSTTYPE,IBMR2,` mkdtemp.o')` MAN= distrib.man OTHER= INSTALL README TODO distrib.m support.m distrib.html SOURCE= Makefile ITO.spec ${OTHER} ${HDR} ${SRC} ${MAN} 'ifelse(HOSTTYPE,`NEXT2',`.SUFFIXES: .SUFFIXES: .c .h .o .s',`')` all: distrib.x distrib.x: ${OBJ} ${CC} -o $@ ${CFLAGS} ${OBJ}'ifelse(HOSTTYPE,`ETA10',` -lbsd',HOSTTYPE,`SUN5',` -lnsl')`'dnl ifelse( HOSTTYPE,`EPIX',` -lbsd', HOSTTYPE,`V386',` -L/usr/local/lib -lsocket -lbsd')` distrib.o: ${CC} ${CFLAGS} -DDEF_HOSTTYPE=\"'HOSTTYPE`\" -c distrib.c main.h: main.c main.c: distrib.m mkcmd -G distrib.m -(cmp -s prog.c main.c || (mv prog.c main.c && echo main.c updated)) -(cmp -s prog.h main.h || (mv prog.h main.h && echo main.h updated)) rm -rf prog.[ch] mkdtemp.c: explode -u dtemp mk.c boot: all ${SBIN} ${LIB} cp distrib.x ${SBIN}/distrib chmod 0755 ${SBIN}/distrib -[ -f ${LIB}/distrib.cf ] || touch ${LIB}/distrib.cf clean: FRC rm -f Makefile.bak distrib.x ${GEN} *.o a.out core errs tags depend: ${GEN} ${SRC} ${HDR} FRC maketd ${CDEFS} ${INCLUDE} ${DEP} distrib: FRC distrib -c ${SBIN}/distrib HOST install: all ${LIB} ${SBIN} FRC install -c -s distrib.x ${SBIN}/distrib -[ -f ${LIB}/distrib.cf ] || touch ${LIB}/distrib.cf lint: ${GEN} ${HDR} ${SRC} FRC lint -h ${CDEFS} ${INCLUDE} ${DEP} print: source FRC lpr -J"distrib source" ${SOURCE} mkcat: ${MAN} FRC mkcat ${MAN} source: ${SOURCE} spotless: clean rcsclean ${SOURCE} tags: ${SRC} ${GEN} ${HDR} ctags -t ${SRC} ${HDR} ${GEN} ${SOURCE}: co -q $@ ${SBIN} ${LIB}: mkdir -p $@ FRC: # DO NOT DELETE THIS LINE - maketd DEPENDS ON IT distrib.o: distrib.c distrib.h envlist.h machine.h main.h envlist.o: envlist.c envlist.h main.o: distrib.h distrib.m envlist.h main.c mkdtemp.o: mkdtemp.c # *** Do not add anything here - It will go away. *** 'dnl