#!/bin/sh

#
# Modify the macros.mk make include files to compile on solaris
#

exec perl -pi \
	-e 's/^# (\S+ \+= xnet)$/$1/;' \
	-e 's/^# (GETOPT := getopt)$/$1/;' \
	-e 's/^# (\S+ \+= -DNEEDS_GETOPT=1)$/$1/;' \
	-e 's/^(\S+ \+= -DNEEDS_SNPRINTF=1)$/# $1/;' \
	-e 's/^(\S+ \+= -DPID_DIR)=.*$/$1=\\"\/var\/pid\\"/;' \
	`find . -name macros.mk`
