blob: e3f179f5c9611f3784e100d53b0b6ed2ae60e301 (
plain)
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
65
66
67
68
|
## texk/web2c/luatexdir/am/luatex.am: Makefile fragment for luaTeX.
##
## Copyright (C) 2009 Peter Breitenlohner <tex-live@tug.org>
## You may freely use, modify and/or distribute this file.
## luaTeX
##
if LUATEX
bin_PROGRAMS += luatex
endif LUATEX
EXTRA_PROGRAMS += luatex
## Force Automake to use CXXLD for linking
nodist_EXTRA_luatex_SOURCES = dummy.cxx
luatex_tangle = WEBINPUTS=$(srcdir)/luatexdir $(buildenv) $(LUATANGLE)
luatex_CPPFLAGS = $(ZLIB_INCLUDES) $(LIBPNG_INCLUDES) $(XPDF_INCLUDES)
luatex_CPPFLAGS += $(OBSDCOMPAT_INCLUDES) -I$(srcdir)/libmd5
luatex_CPPFLAGS += -Iluatexdir -I$(srcdir)/luatexdir -I$(srcdir)/luatexdir/lua51 -I$(srcdir)/mplibdir
luatex_CPPFLAGS += -Dextra_version_info=`date +-%Y%m%d%H`
luatex_ldadd = libluatex.a libff.a libluamisc.a libzzip.a libluasocket.a liblua51.a
luatex_ldadd += $(LIBPNG_LIBS) $(ZLIB_LIBS) $(XPDF_LIBS)
luatex_ldadd += $(OBSDCOMPAT_LIBS) libmd5.a libmplib.a
luatex_LDADD = $(luatex_ldadd) $(LDADD) $(socketlibs)
luatex_DEPENDENCIES = $(proglib) libluatex.a
luatex_DEPENDENCIES += $(LIBPNG_DEPEND) $(ZLIB_DEPEND) $(XPDF_DEPEND)
luatex_DEPENDENCIES += $(OBSDCOMPAT_DEPEND) libmd5.a libmplib.a
$(luatex_OBJECTS): libluatex.a libmplib.a
luatex_c_h = luatexini.c luatex0.c luatexcoerce.h luatexd.h
nodist_luatex_SOURCES = $(luatex_c_h) luatex-pool.c luatexextra.c luatexdir/luatexextra.h
$(luatex_c_h): luatex-web2c
luatex-web2c: luatex.p $(web2c_texmf) luatexdir/luatex.defines
$(web2c) luatex
echo timestamp >$@
touch $(luatex_c_h)
luatexextra.c: luatexd.h luatexdir/luatexextra.h lib/texmfmp.c
sed s/TEX-OR-MF-OR-MP/luatex/ $(srcdir)/lib/texmfmp.c >$@
luatex_sources = luatexdir/luatex.web luatexdir/luatex.ch
luatex.p luatex.pool: luatex-tangle
luatex-tangle: luatangle$(EXEEXT) $(luatex_sources)
$(luatex_tangle) --underlines luatex luatex
echo timestamp >$@
touch luatex.p luatex.pool
luatex-pool.c: luatex.pool $(makecpool_stamp) luatexdir/ptexlib.h luatexd.h
$(makecpool) luatex.pool luatexdir/ptexlib.h >$@ || rm -f $@
## Extract luatex version
luatexdir/luatex.version: luatexdir/luatex.web
$(mkdir_p) luatexdir
grep '^@d luatex_version_string==' $(srcdir)/luatexdir/luatex.web \
| sed "s/^.*=='//;s/'.*$$//" >luatexdir/luatex.version
luatexdir/luatexextra.h: luatexdir/luatexextra.in luatexdir/luatex.version
sed -e s/LUATEX-VERSION/`cat luatexdir/luatex.version`/ \
$(srcdir)/luatexdir/luatexextra.in >$@
EXTRA_DIST += $(luatex_sources) \
luatexdir/luatex.defines \
luatexdir/luatexextra.in \
luatexdir/ptexlib.h
DISTCLEANFILES += $(nodist_luatex_SOURCES) luatex-web2c \
luatex.p luatex.pool luatex-tangle luatexdir/luatex.version
|