File: catmake

package info (click to toggle)
ghostscript 8.71~dfsg2-9%2Bsqueeze1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 79,896 kB
  • ctags: 80,654
  • sloc: ansic: 501,432; sh: 25,689; python: 4,853; cpp: 3,633; perl: 3,597; tcl: 1,480; makefile: 1,187; lisp: 407; asm: 284; xml: 263; awk: 66; csh: 17; yacc: 15
file content (15 lines) | stat: -rwxr-xr-x 253 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh
# $Id: catmake 6300 2005-12-28 19:56:24Z giles $
# 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