# Makefile for Shared X library
# Copyright 1990, Digital Equipment Corporation

        CPP = cc -E	# Note: an alternative is  CPP = /lib/cpp
       MAKE = make	# BSD doesn't have it as a default.


#  Don't change below this line
#

all: xmakefile doall m.h config.h

doall:
	$(MAKE) -f xmakefile $(MFLAGS) all

clean:
	rm -f xmakefile *.BAK *.bak *.o core *~ TAGS \#*

veryclean: clean
	rm -f m.h config.h *.a

xmakefile: ymakefile config.h
	rm -f xmakefile
	cp ymakefile junk.c
	$(CPP) junk.c | sed -e 's/^#.*//' -e 's/^[ \f\t][ \f\t]*$$//' -e 's/^ /	/' | \
	sed -n -e '/^..*$$/p' > xmakefile
	rm -f junk.c

tags:
	etags *.c
