1 ## 2 ## $Id: Makefile,v 1.2 2001/06/10 16:32:20 carlos Exp $ 3 ## 4 ## Makefile -- Build procedure for sample sqlinclude Apache module 5 ## Autogenerated via ``apxs -n sqlinclude -g''. 6 ## 7 8 # the used tools 9 APXS=apxs 10 APACHECTL=apachectl 11 12 # additional user defines, includes and libraries 13 #DEF=-Dmy_define=my_value 14 #INC=-Imy/include/dir 15 #LIB=-Lmy/lib/dir -lc -lmylib 16 LIB=-lmysqlclient 17 18 # the default target 19 all: mod_sqlinclude.so 20 21 # compile the DSO file 22 mod_sqlinclude.so: mod_sqlinclude.c 23 $(APXS) -c $(DEF) $(INC) $(LIB) mod_sqlinclude.c 24 25 # install the DSO file into the Apache installation 26 # AND activate it in the Apache configuration 27 install: all 28 $(APXS) -i -a -n 'sqlinclude' mod_sqlinclude.so 29 30 # install the DSO file into the Apache installation 31 copy: all 32 $(APXS) -i -n 'sqlinclude' mod_sqlinclude.so 33 34 # cleanup 35 clean: 36 -rm -f mod_sqlinclude.o mod_sqlinclude.so 37 38 # simple test 39 #test: reload 40 # lynx -mime_header http://localhost/sqlinclude 41 42 # reload the module by installing and restarting Apache 43 reload: install restart 44 45 combo: all copy restart 46 import: 47 mysql -p -u root test <apache_conf.sql 48 49 # the general Apache start/restart/stop procedures 50 start: 51 $(APACHECTL) start 52 restart: 53 $(APACHECTL) restart 54 stop: 55 $(APACHECTL) stop 56