SHELL=/bin/sh
.SUFFIXES:
.SUFFIXES: .c .o .pl .pm .pod .html .man

PERL = @PERL@

CC = @CC@
CFLAGS = @CFLAGS@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@
MKDIR = @top_srcdir@/mkinstalldirs

RM = rm -f

prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = $(exec_prefix)/bin
infodir = $(prefix)/info


all::
	@echo making $@ in `basename \`pwd\``

update::
	@echo making $@ in `basename \`pwd\``

update:: squidGuardRobot

squidGuardRobot:: squidGuardRobot/squidGuardRobot.in squidGuardRobot/RobotUserAgent.pm

squidGuardRobot/squidGuardRobot.in: @SQUIDGUARDROBOT@
	@echo making $@ in `basename \`pwd\``
	@$(MKDIR) squidGuardRobot
	cp -p $? $@
	chmod 660 $@
	$(PERL) -0777 -pi -e 's;^#!\s?/\S*perl;#! \100PERL\100;' $@

squidGuardRobot/RobotUserAgent.pm: @SQUIDGUARDROBOTUA@
	@echo making $@ in `basename \`pwd\``
	@$(MKDIR) squidGuardRobot
	cp -p $? $@
	chmod 660 $@

clean::
	@echo making $@ in `basename \`pwd\``
	$(RM) *~ *.bak core *.log *.error

realclean:: clean
	@echo making $@ in `basename \`pwd\``
	$(RM) TAGS *.orig

distclean:: realclean
	@echo making $@ in `basename \`pwd\``
	$(RM) Makefile
	$(RM) squidGuardRobot/squidGuardRobot
	$(RM) sgclean/sgclean
	$(RM) hostbyname/hostbyname
