Makefile.in 1.19 KB
Newer Older
Dr. Martin Goik's avatar
Dr. Martin Goik committed
1
SHELL = /bin/bash
Dr. Martin Goik's avatar
Dr. Martin Goik committed
2
DESTDIR=/var/www/html/freedocs
Dr. Martin Goik's avatar
Dr. Martin Goik committed
3

4 5
numCores=$(shell nproc --all)

Dr. Martin Goik's avatar
Dr. Martin Goik committed
6
EXECUTABLES = /usr/share/xmlmind/bin/xxetool javac mvn rsync pdflatex convert figspecial2pdf figspecial2png figspecial2svg fig2dev fig2mpdf fig2msvg fig2pdf pdf2svg pdftoppm \
7
java ffmpeg
8

Dr. Martin Goik's avatar
Dr. Martin Goik committed
9 10 11
K := $(foreach exec,$(EXECUTABLES),\
        $(if $(shell which $(exec)),some string,$(error "No $(exec) in PATH)))

12
REVEALHOME=/usr/share/reveal.js
13 14
K := $(if $(shell ls ${REVEALHOME}),some string,$(error "No ${REVEALHOME} found, please execute git clone https://github.com/hakimel/reveal.js)))

Dr. Martin Goik's avatar
Dr. Martin Goik committed
15
doc:
16
	cd Doc;$(MAKE) -j ${numCores} all
Dr. Martin Goik's avatar
Dr. Martin Goik committed
17 18

all:doc
19 20
#	mvn -T ${numCores} --fail-at-end install || echo
	mvn --fail-at-end install javadoc:javadoc || exit 0
Dr. Martin Goik's avatar
Dr. Martin Goik committed
21
	find P -type f \( -name \*.css -o -name \*.html -o -name \*.js \) -print | tar --files-from=- -c| tar -x -C Doc/target/webhelp
Dr. Martin Goik's avatar
Dr. Martin Goik committed
22 23

clean:
24 25
	cd Doc;$(MAKE) -j ${numCores} clean
	mvn -T ${numCores} clean
Dr. Martin Goik's avatar
Dr. Martin Goik committed
26

Dr. Martin Goik's avatar
Dr. Martin Goik committed
27 28 29 30 31 32
check-install:
ifndef DESTDIR
        $(error DESTDIR is undefined)
endif

install: check-install
33
	rsync -av --exclude \*.jar --exclude \*.war --exclude \*VAADIN\* --exclude \*.class --exclude=__figurelink\* --delete P Doc/target/webhelp/ \
34
          freedocs@prog.mi.hdm-stuttgart.de:${DESTDIR}
Dr. Martin Goik's avatar
Dr. Martin Goik committed
35
#end