`# $Id: Makefile.host,v 2.14 2012/07/24 23:46:37 ksb Exp $ # platform Makefile for oue, mkcmd version PROG= oue BIN= ${DESTDIR}/usr/local/bin DOC= ${DESTDIR}/usr/local/man/man1 LIB= ${DESTDIR}/usr/local/lib DEBUG= CDEFS= -D'HOSTTYPE`'ifelse(HOSTTYPE,SUN5,` -D_LARGEFILE64_SOURCE=1')` INCLUDE= -I/usr/local/include CFLAGS= ${DEBUG} ${CDEFS} ${INCLUDE} # Hooks for building under ~/usr/local (as well a INCLUDE above) --ksb LIBGDBM= -lgdbm RUN_LIB=${LIB} #LIBGDBM= ${HOME}/usr/local/lib/libgdbm.a #LIBGDBM= -R${HOME}/usr/local/lib libgdbm.so #INCLUDE= -I${HOME}/usr/local/include GEN= dicer.c dicer.h oue.c oue.h SRC= machine.h MAN= oue.man OTHER= README TODO oue.m oue.html ouereg.sh SOURCE= Makefile ITO.spec ${OTHER} ${SRC} ${MAN} all: ${PROG} oue: main.c main.h dicer.h 'ifelse(HOSTTYPE,SUN5,`LD_LIBRARY_PATH=/usr/lib:/usr/local/lib:/usr/ucblib:/usr/openwin/lib ')dnl `${CC} ${CFLAGS} -o $@ main.c 'ifelse(HOSTTYPE,SUN5,`-R/usr/local/lib -R/usr/ucblib')` -L${RUN_LIB}'ifelse(HOSTTYPE,`LINUX',` -Wl,-rpath -Wl,${RUN_LIB}')` ${LIBGDBM} dicer.c dicer.h: explode -s $@ main.h: main.c main.c: oue.m dicer.c mkcmd oue.m -(cmp -s prog.c main.c || (cp prog.c main.c && echo main.c updated)) -(cmp -s prog.h main.h || (cp prog.h main.h && echo main.h updated)) rm -f prog.[ch] clean: FRC rm -f ${GEN} Makefile.bak prog.[ch] main.[cho] ${PROG} a.out core errs lint.out tags deinstall: ${MAN} ${DOC} FRC install -R ${BIN}/${PROG} mkcat -r${DOC} -DDESTDIR=${DESTDIR} ${MAN} depend: FRC dirs: ${BIN} ${DOC} distrib: FRC distrib -c ${BIN}/${PROG} HOST install: all dirs FRC install -c ${PROG} ${BIN}/${PROG} lint: FRC mkcat: ${MAN} ${DOC} FRC mkcat -r${DOC} -DDESTDIR=${DESTDIR} ${MAN} print: source FRC lpr -J"${PROG} source" ${SOURCE} source: ${SOURCE} spotless: clean rcsclean ${SOURCE} tags: FRC ${BIN} ${DOC}: install -dr $@ ${SOURCE}: co -q $@ FRC: # DO NOT DELETE THIS LINE - maketd DEPENDS ON IT main.o: main.c main.h dicer.h # *** Do not add anything here - It will go away. *** 'dnl