old-website/Makefile

29 lines
1.4 KiB
Makefile
Raw Normal View History

INPUTS = index.xml footer.xml
2006-10-12 08:38:32 -04:00
SUBDIRS = about events docs office news users clubs media robocode
2002-03-11 15:39:54 -05:00
# the following two rules are there so cow gets built first.
2006-05-19 22:46:54 -04:00
cow-first: recurse-cow books.xml members.xml menu.xml all
recurse-cow:
cd cow && $(MAKE) && cd ..
2002-04-15 18:31:30 -04:00
members.xml:
echo '<?xml version='\''1.0'\''?>' > $@
echo '<memberlist>' >> $@
2002-04-22 21:02:42 -04:00
ceoquery memberlist | awk -F \| '{ id = $$1; name = $$2; program = $$3; gsub(/&/, "\\&amp;", name); gsub(/&/, "\\&amp;", program); gsub(/"/, "\\&quot;", name); gsub(/"/, "\\&quot;", program); print "<member id=\"" id "\" name=\"" name "\" program=\"" program "\" />"; }' >> $@
2002-04-15 18:31:30 -04:00
echo '</memberlist>' >> $@
2002-04-22 21:02:42 -04:00
books.xml:
echo '<?xml version='\''1.0'\'' encoding="ISO-8859-1"?>' > $@
echo '<booklist>' >> $@
ceoquery booklist | awk -F \| '{ isbn = $$1; title = $$2; author = $$3; edition = $$4; published = $$5; gsub(/&/, "\\&amp;", title); gsub(/&/, "\\&amp;", author); gsub(/&/, "\\&amp;", published); gsub(/&/, "\\&amp;", edition); gsub(/"/, "\\&quot;", title); gsub(/"/, "\\&quot;", author); gsub(/"/, "\\&quot;", published); gsub(/"/, "\\&quot;", edition); print "<book isbn=\"" isbn "\" title=\"" title "\" author=\"" author "\" edition=\"" edition "\" published=\"" published "\"/>"; }' >> $@
echo '</booklist>' >> $@
2002-03-11 15:39:54 -05:00
include default.mk
default.mk: default.mk.in
echo 'ROOT = '`pwd` > $@
cat $< >> $@
2002-04-22 21:02:42 -04:00
.PHONY: members.xml books.xml