#!/bin/sh
# $RCSfile: catmake,v $ $Revision: 1.1.2.1 $
# Expand 'includes' in makefiles.  Usage:
#	catmake orig.mak > makefile

awk '
/^include / {
	print "# INCLUDE OF", $2
	while (getline x <$2 > 0)
		if(x !~ /^#/)
			print x
	next
}
{print}
' $1
