From ca1a6aa7df6703c10d1cd97afedd9c6838ba425b Mon Sep 17 00:00:00 2001 From: Andreas Stöckel Date: Fri, 6 Mar 2015 23:54:49 +0100 Subject: First commit of the ousia based website architecture --- Makefile | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..8e21c8e --- /dev/null +++ b/Makefile @@ -0,0 +1,41 @@ +# Makefile for compiling the Ousía Homepage +# +# (c) Andreas Stöckel, 2015 +# +# This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 +# International License. + +SOURCE_OSML=$(wildcard *.osml) +TARGET_XML=$(SOURCE_OSML:.osml=.xml) +TARGET_HTML=$(SOURCE_OSML:.osml=.html) + +.PHONY: all +all: style/style.css $(TARGET_XML) $(TARGET_HTML) + +# Build the stylesheet using lessc +# On Fedora you can install lessc using the following commands (as root): +# yum install nodejs npm +# npm install -g less +style/style.css: style/*.less + lessc style/style.less style/style.css #--clean-css="--s1" + +# Compile all osml files to xml +%.xml: %.osml + ousia -F xml -o $@ $< + +# Compile the xml files to html +%.html: %.xml xsl/*.xsl + xsltproc xsl/webpage.xsl $< > $@ + +# Clean script +.PHONY: clean webclean +clean: + rm -f style/*.css + rm -f $(TARGET_HTML) + rm -f $(TARGET_XML) + +webclean: + rm -f style/*.less + rm -f $(TARGET_XML) + rm -f $(SOURCE_OSML) + rm -rf ontology -- cgit v1.2.3