Integrate lexer and parser files into automake.
[ttfautohint.git] / lib / Makefile.am
blobeb3eae62c5b66d12eb32bc1b64295c29ef8b5226
1 ## Makefile.am
3 # Copyright (C) 2011-2014 by Werner Lemberg.
5 # This file is part of the ttfautohint library, and may only be used,
6 # modified, and distributed under the terms given in `COPYING'.  By
7 # continuing to use, modify, or distribute this file you indicate that you
8 # have read `COPYING' and understand and accept it fully.
10 # The file `COPYING' mentioned in the previous paragraph is distributed
11 # with the ttfautohint library.
13 AM_CPPFLAGS = $(FREETYPE_CPPFLAGS) \
14               $(HARFBUZZ_CFLAGS)
16 noinst_LTLIBRARIES = \
17   libttfautohint.la \
18   libnumberset.la
20 libnumberset_la_SOURCES = \
21   numberset.c numberset.h
23 # We have to bypass automake's default handling of flex (.l) and bison (.y)
24 # files, since such files are always treated as traditional lex and yacc
25 # files, not allowing for flex and bison extensions.  For this reason, we
26 # call our source files `tadeltas.flex' and `tadeltas.bison' and write
27 # explicit dependency rules.
29 libttfautohint_la_SOURCES = \
30   llrb.h \
31   ta.h \
32   tablue.c tablue.h \
33   tabytecode.c tabytecode.h \
34   tacover.h \
35   tacvt.c \
36   tadeltas.c tadeltas.h \
37   tadeltas-flex-wrapper.c tadeltas-flex.h \
38   tadeltas-bison.c tadeltas-bison.h \
39   tadsig.c \
40   tadummy.c tadummy.h \
41   tadump.c \
42   taerror.c \
43   tafile.c \
44   tafont.c \
45   tafpgm.c \
46   tagasp.c \
47   tagloadr.c tagloadr.h \
48   taglobal.c taglobal.h \
49   taglyf.c \
50   tagpos.c \
51   taharfbuzz.c taharfbuzz.h \
52   tahints.c tahints.h \
53   tahmtx.c \
54   talatin.c talatin.h \
55   taloader.c taloader.h \
56   taloca.c \
57   tamaxp.c \
58   taname.c \
59   tapost.c \
60   taprep.c \
61   taranges.c taranges.h \
62   tascript.c \
63   tasfnt.c \
64   tasort.c tasort.h \
65   tastyles.h \
66   tatables.c tatables.h \
67   tatime.c \
68   tattc.c \
69   tattf.c \
70   tatypes.h \
71   tawrtsys.h \
72   ttfautohint.c \
73   ttfautohint.h ttfautohint-errors.h ttfautohint-scripts.h
75 libttfautohint_la_LIBADD = \
76   libnumberset.la \
77   $(LIBM) \
78   $(FREETYPE_LIBS) \
79   $(HARFBUZZ_LIBS)
81 BUILT_SOURCES = \
82   tablue.c tablue.h \
83   tadeltas-flex.c tadeltas-flex.h \
84   tadeltas-bison.c tadeltas-bison.h
86 EXTRA_DIST = \
87   afblue.pl \
88   tablue.cin tablue.hin \
89   tablue.dat \
90   tadeltas.flex tadeltas.bison tadeltas-flex.c
92 tablue.c: tablue.dat tablue.cin
93         $(AM_V_GEN)rm -f $@-t $@ \
94         && perl afblue.pl $(srcdir)/tablue.dat \
95                           < $(srcdir)/tablue.cin \
96                           > $@-t \
97         && mv $@-t $@
99 tablue.h: tablue.dat tablue.hin
100         $(AM_V_GEN)rm -f $@-t $@ \
101         && perl afblue.pl $(srcdir)/tablue.dat \
102                           < $(srcdir)/tablue.hin \
103                           > $@-t \
104         && mv $@-t $@
106 TA_V_FLEX = $(TA_V_FLEX_@AM_V@)
107 TA_V_FLEX_ = $(TA_V_FLEX_@AM_DEFAULT_V@)
108 TA_V_FLEX_0 = @echo "  FLEX    " $@;
110 # we use `touch' to make the created .h file newer than the created .c file
112 tadeltas-flex.c tadeltas-flex.h: tadeltas.flex
113         $(TA_V_FLEX)$(FLEX) tadeltas.flex \
114         && touch tadeltas-flex.h
115 tadeltas-flex.h: tadeltas-flex.c
117 TA_V_BISON = $(TA_V_BISON_@AM_V@)
118 TA_V_BISON_ = $(TA_V_BISON_@AM_DEFAULT_V@)
119 TA_V_BISON_0 = @echo "  BISON   " $@;
121 tadeltas-bison.c tadeltas-bison.h: tadeltas.bison
122         $(TA_V_BISON)$(BISON) tadeltas.bison \
123         && touch tadeltas-bison.h
124 tadeltas-bison.h: tadeltas-bison.c
126 ## end of Makefile.am