# $Header: makefile,v 72.2 92/12/18 17:12:24 ssa Exp $

# Common makefile for rcsmerge command of rcs utility

INC	  = ../include
PFLAGS    = -I$(INC)
LIBS	  = ../lib/librcs.a -lBUILD

default:  rcsmerge

metrics:  rcsmerge.M

rcsmerge: rcsmerge.o ../hpux_rel.o
	  $(CC) $(LDFLAGS) rcsmerge.o ../hpux_rel.o $(LIBS) -o rcsmerge

rcsmerge.M: rcsmerge.c ../hpux_rel.c
	  $(METRICS) $(CFLAGS) $(PFLAGS) rcsmerge.c ../hpux_rel.c $(LIBS) -o rcsmerge.M

clean:	
	  rm -f rcsmerge.o

clobber:  clean
	  rm -f rcsmerge rcsmerge.M

rcsmerge.o: $(INC)/system.h $(INC)/bin.h \
	    $(INC)/rcsbase.h $(INC)/copyright.h

# Redefine the .c to .o rule as to include PFLAGS
.c.o:
	$(CC) $(CFLAGS) $(PFLAGS) -c $<
