##
##  Makefile -- Build procedure for sample bbs Apache module
##  Autogenerated via ``apxs -n bbs -g''.
##

#   the used tools
APXS=/usr/local/apache/bin/apxs
APACHECTL=/usr/local/apache/bin/apachectl

#   additional user defines, includes and libraries
#DEF=-Dmy_define=my_value
#INC=-Imy/include/dir
#LIB=-Lmy/lib/dir -lmylib



#   the default target
all: mod_bbs.so

#   compile the DSO file
mod_bbs.so: mod_bbs.c
	$(APXS) -c $(DEF) $(INC) $(LIB) mod_bbs.c

#   install the DSO file into the Apache installation
#   and activate it in the Apache configuration
install: all
	$(APXS) -i -a -n 'bbs' mod_bbs.so

#   cleanup
clean:
	-rm -f mod_bbs.o mod_bbs.so

#   simple test
test: reload
	lynx -mime_header http://localhost/bbs

#   reload the module by installing and restarting Apache
reload: install restart

#   the general Apache start/restart/stop procedures
start:
	$(APACHECTL) start
restart:
	$(APACHECTL) stop
	$(APACHECTL) start
stop:
	$(APACHECTL) stop

