blob: b940dccbe8a8cb2f1c8ba45cc36c635ce423d10f (
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/mpdir/am/mp.am: Makefile fragment for MetaPost.
##
## Copyright (C) 2009 Peter Breitenlohner <tex-live@tug.org>
## You may freely use, modify and/or distribute this file.
## MetaPost
##
if MP
bin_PROGRAMS += oldmpost
endif MP
EXTRA_PROGRAMS += oldmpost
oldmpost_CPPFLAGS = -I$(srcdir)/mpdir
oldmpost_LDADD = liboldmpost.a $(LDADD)
oldmpost_c_h = mpini.c mp0.c mp1.c mp2.c mpcoerce.h mpd.h
nodist_oldmpost_SOURCES = $(oldmpost_c_h) mp-pool.c mpextra.c
$(oldmpost_c_h): mp-web2c
mp-web2c: mp.p $(web2c_texmf) mpdir/mp.defines web2c/cvtmf1.sed web2c/cvtmf2.sed
$(web2c) mp
echo timestamp >$@
touch $(oldmpost_c_h)
EXTRA_DIST += mp.web mp.ch lib/texmfmp.c mpdir/mp.defines mpdir/mplib.h
mpextra.c: lib/texmfmp.c mpd.h
sed s/TEX-OR-MF-OR-MP/mp/ $(srcdir)/lib/texmfmp.c >$@
mp.p mp.pool: mp-tangle
mp-tangle: tangle$(EXEEXT) mp.web mp.ch
$(tangle) mp mp
echo timestamp >$@
touch mp.p mp.pool
mp-pool.c: mp.pool $(makecpool_stamp) mpdir/mplib.h
$(makecpool) mp.pool $(srcdir)/mpdir/mplib.h >$@ || rm -f $@
DISTCLEANFILES += $(nodist_oldmpost_SOURCES) mp-web2c \
mp.p mp.pool mp-tangle
## liboldmpost
##
EXTRA_LIBRARIES += liboldmpost.a
liboldmpost_a_CPPFLAGS = -I$(srcdir)/mpdir
liboldmpost_a_SOURCES = \
mpdir/avl.c \
mpdir/avl.h \
mpdir/avlstuff.c \
mpdir/avlstuff.h \
mpdir/mapfile.c \
mpdir/mpmac.h \
mpdir/turningnumber.c \
mpdir/utils.c \
mpdir/writeenc.c \
mpdir/writefont.c \
mpdir/writet1.c
# We must create mpd.h before building the liboldmpost_a_OBJECTS.
$(liboldmpost_a_OBJECTS): mpd.h
# Double-colon rule since we do something similar in luatexdir (maybe others).
install-exec-hook::
cd $(DESTDIR)$(bindir) && rm -f dvitomp$(EXEEXT) \
&& ln -s mpost$(EXEEXT) dvitomp$(EXEEXT)
## Eventually delete these files
##
EXTRA_DIST += \
metapost.mk \
mpdir/Makefile.in.orig \
mpdir/mpostlib.mk
|