forked from jung-kurt/luahpdf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.mingw
64 lines (49 loc) · 1.36 KB
/
Makefile.mingw
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# NOTE: This makefile has not been tested recently. If you can get it to work,
# please report changes to the issues forum for this project.
# --- Change the settings below to suit your environment ---
MINGW=/usr/i686-pc-mingw32/sys-root/mingw
LUALIB=$(MINGW)/bin/lua51.dll
HPDFLIB=$(MINGW)/bin/libhpdf.dll
DOCDIR=/win32/doc
PREFIX=/win32
# --- End of user settings, no need to change anything below this line ---
PACKAGE=luahpdf-1.0
TARGET=hpdf.dll
PDF = \
demo/arc_demo.pdf \
demo/encryption_demo.pdf \
demo/ext_gstate_demo.pdf \
demo/font_demo.pdf \
demo/grid_demo.pdf \
demo/hello_demo.pdf \
demo/line_demo.pdf \
demo/link_demo.pdf \
demo/logo_demo.pdf \
demo/outline_demo.pdf \
demo/permission_demo.pdf \
demo/slide_show_demo.pdf \
demo/text_demo.pdf
HTML = \
doc/html/binding-changes.html \
doc/html/binding-notes.html \
doc/html/build.html \
doc/html/change-log.html \
doc/html/demos.html \
doc/html/index.html \
doc/html/license.html
%.o : %.c
gcc -DHPDF_SHARED -shared -c $^ -o $@
$(TARGET) : hpdf.o
gcc -Wall -shared -o $@ $< $(LUALIB) $(HPDFLIB)
strip --strip-unneeded $@
all : $(TARGET) doc
doc : $(HTML)
demo : $(PDF)
clean :
rm -f $(PDF) $(HTML) $(TARGET) $(TAR) $(ZIP) *.o
.PHONY : all doc demo clean
$(HTML): doc/html/%.html: doc/text/%.txt
lua doc/txt2html.lua < $< > $@
$(PDF): %.pdf: %.lua
@luac -l -p $< | grep SETGLOBAL; true
lua $<