#!/bin/sh

awk '
BEGIN {
	print "# Generated by ./ocgen called from make dep - DO NOT EDIT THIS FILE"
	print ""
}

function ocgen(o)
{
	c=o
	sub("[.]o$", ".c", c)
	print o ": " c
	print "\t$(CC) $(CFLAGS) -c -o " o, c
	print ""
}

{
	for(n = 1; n <= NF; n++)
		ocgen($n)
}

'