-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathmakefile
35 lines (27 loc) · 833 Bytes
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
DIR=build/local-projects/srcweave
PREFIX?=/usr/local
BUNDLE=${PREFIX}/lib/bundle.lisp
SRC_LISP=$(wildcard *.lisp)
SRC_ASD=$(wildcard *.asd)
.PHONY: all test clean install
all: build bin/srcweave
build: $(SRC_LISP) $(SRC_ASD)
sbcl --noinform --non-interactive --eval '(ql:bundle-systems (list "alexandria" "cl-ppcre" "unix-opts" "uiop") :to "build/")'
mkdir -p ${DIR}
cp *.lisp ${DIR}
cp *.asd ${DIR}
echo "Bundle is built"
bin/srcweave: gen-script.sh
./gen-script.sh "${PREFIX}/lib/srcweave" > bin/srcweave
chmod +x bin/srcweave
test:
./tests/run.sh
clean:
rm -f bin/srcweave
rm -rf build
install:
rm -rf "${PREFIX}/lib/srcweave"
cp -r build "${PREFIX}/lib/srcweave"
install bin/srcweave "${PREFIX}/bin/"
install bin/srcweave-html-styler "${PREFIX}/bin/"
install bin/srcweave-html-styler-init "${PREFIX}/bin/"