forked from dag/happstack-yui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
40 lines (30 loc) · 766 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
36
37
38
39
40
YUI_VERSION = 3.7.2
PATH := $(PWD)/cabal-dev/bin:$(PATH)
all: install
yui_$(YUI_VERSION).zip:
wget http://yui.zenfs.com/releases/yui3/$@
bundle: yui_$(YUI_VERSION).zip
unzip $< 'yui/build/*'
mv yui/build bundle
rmdir yui
rm -rf bundle/build
bundle.h: bundle
find bundle -type f > $@
happstack-yui.cabal: happstack-yui.cabal.in bundle.h
cpp -P -traditional-cpp -DYUI_VERSION=$(YUI_VERSION) '-DYUI_VERSION_STR="$(YUI_VERSION)"' $< $@
.PHONY: build
build: happstack-yui.cabal
cabal-dev build
.PHONY: install
install: happstack-yui.cabal
cabal-dev install
.PHONY: sdist
sdist: happstack-yui.cabal
cabal sdist
.PHONY: docs
docs: happstack-yui.cabal
cabal haddock
.PHONY: demo
demo: install
cabal-dev install ./demo
cabal-dev/bin/happstack-yui-demo