1 # $Id: Makefile,v 1.4 2007/06/29 21:43:21 rjones Exp $
3 include Makefile.config
6 CFLAGS := -Wall -Werror
8 all: pa_noexternal.cmo init ocamlbotwrapper xavierbot.pl
10 ocamlbotwrapper: ocamlbotwrapper.o
11 $(CC) $(CFLAGS) $< -o $@
13 ocamlbotwrapper.c: ocamlbotwrapper.c.in Makefile.config
15 -e 's|@OCAML@|$(OCAML)|' \
16 -e 's|@INITSCRIPT@|$(INITSCRIPT)|' \
17 -e 's|@CHROOTDIR@|$(CHROOTDIR)|' \
20 init: init.in Makefile.config
22 -e 's|@OCAMLUSER@|$(OCAMLUSER)|' \
23 -e 's|@CHROOTDIR@|$(CHROOTDIR)|' \
26 xavierbot.pl: xavierbot.pl.in Makefile.config
28 -e 's|@WRAPPER@|$(WRAPPER)|' \
29 -e 's|@VERSION@|$(VERSION)|' \
33 pa_noexternal.cmo: pa_noexternal.ml
35 -pp "camlp4o pa_extend.cmo q_MLast.cmo" -I +camlp4 -c $<
41 rm -f ocamlbotwrapper *.o *.cmo *.cmi *~
43 # Use this if you want to run without installing (see also
44 # instructions in Makefile.config):
47 chown root.root ocamlbotwrapper
48 chmod ug+s ocamlbotwrapper
53 $(MAKE) check-manifest
54 rm -rf $(PACKAGE)-$(VERSION)
55 mkdir $(PACKAGE)-$(VERSION)
56 tar -cf - -T MANIFEST | tar -C $(PACKAGE)-$(VERSION) -xf -
57 tar zcf $(PACKAGE)-$(VERSION).tar.gz $(PACKAGE)-$(VERSION)
58 rm -rf $(PACKAGE)-$(VERSION)
59 ls -l $(PACKAGE)-$(VERSION).tar.gz
62 @for d in `find -type d -name CVS | grep -v '^\./debian/'`; \
65 awk -F/ '$$1 != "D" {print $$2}' $$d/Entries | \
66 sed -e "s|^|$$b|" -e "s|^\./||"; \
67 done | sort > .check-manifest; \
68 sort MANIFEST > .orig-manifest; \
69 diff -u .orig-manifest .check-manifest; rv=$$?; \
70 rm -f .orig-manifest .check-manifest; \
74 .PHONY: depend dist check-manifest dpkg doc print_test
76 .SUFFIXES: .cmo .cmi .cmx .ml .mli