Add Cmake stuff to the source distribution so more people can try it out.
[obnox/wireshark/wip.git] / epan / wslua / Makefile.am
1 # Makefile.am
2 #
3 # $Id$
4 #
5 # Wireshark - Network traffic analyzer
6 # By Gerald Combs <gerald@wireshark.org>
7 # Copyright 1998 Gerald Combs
8
9 # This program is free software; you can redistribute it and/or
10 # modify it under the terms of the GNU General Public License
11 # as published by the Free Software Foundation; either version 2
12 # of the License, or (at your option) any later version.
13
14 # This program is distributed in the hope that it will be useful,
15 # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 # GNU General Public License for more details.
18
19 # You should have received a copy of the GNU General Public License
20 # along with this program; if not, write to the Free Software
21 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22 #
23
24 if HAVE_WARNINGS_AS_ERRORS
25 AM_CFLAGS = -Werror
26 endif
27
28 INCLUDES = -I$(top_srcdir) @LUA_INCLUDES@
29
30 noinst_LTLIBRARIES = libwslua.la
31
32 wslua_modules =         \
33         $(srcdir)/lua_bitop.c \
34         $(srcdir)/wslua_tvb.c \
35         $(srcdir)/wslua_proto.c \
36         $(srcdir)/wslua_tree.c \
37         $(srcdir)/wslua_pinfo.c \
38         $(srcdir)/wslua_listener.c \
39         $(srcdir)/wslua_gui.c \
40         $(srcdir)/wslua_util.c \
41         $(srcdir)/wslua_field.c \
42         $(srcdir)/wslua_dumper.c
43
44 libwslua_la_SOURCES = \
45         $(wslua_modules) \
46         taps_wslua.c \
47         register_wslua.c \
48         init_wslua.c \
49         wslua.h
50
51 libwslua_la_LIBADD = @LUA_LIBS@
52
53 BUILT_SOURCES = \
54         taps_wslua.c \
55         register_wslua.c \
56         declare_wslua.h
57
58 dist_pkgdata_DATA = \
59         console.lua \
60         dtd_gen.lua
61
62 nodist_pkgdata_DATA = \
63         init.lua
64
65 CLEANFILES = \
66         *~
67
68 DISTCLEANFILES = \
69         $(BUILT_SOURCES) \
70         taps.txt \
71         wslua_register.h \
72         init.lua
73
74 MAINTAINERCLEANFILES = \
75         Makefile.in     \
76         register_wslua.c \
77         declare_wslua.h
78
79 EXTRA_DIST = \
80         declare_wslua.h         \
81         init_wslua.h            \
82         register_wslua.c        \
83         taps                    \
84         make-reg.pl             \
85         template-init.lua       \
86         make-init-lua.pl        \
87         make-taps.pl            \
88         Makefile.nmake          \
89         CMakeLists.txt
90
91 taps_used = \
92         ../dissectors/packet-http.h \
93         ../dissectors/packet-ip.h \
94         ../dissectors/packet-udp.h \
95         ../dissectors/packet-h225.h \
96         ../dissectors/packet-ieee80211.h
97
98 taps: $(taps_used)
99         touch taps
100
101 taps_wslua.c: make-taps.pl taps
102         $(PERL) $(srcdir)/make-taps.pl taps taps_wslua.c taps.txt
103
104 taps.txt: taps_wslua.c
105
106 wslua.h: declare_wslua.h
107
108 register_wslua.c: declare_wslua.h
109
110 declare_wslua.h: make-reg.pl $(wslua_modules) taps_wslua.c
111         $(PERL) $(srcdir)/make-reg.pl $(wslua_modules);
112
113 dummy:
114         touch dummy
115
116 init.lua: template-init.lua make-init-lua.pl ../ftypes/ftypes.h ../../wiretap/wtap.h  ../proto.h ../../stat_menu.h
117         $(PERL) $(srcdir)/make-init-lua.pl $(srcdir) $(srcdir)/template-init.lua > init.lua
118
119 checkapi:
120         $(PERL) ../../tools/checkAPIs.pl -g termoutput \
121         init_wslua.c \
122         register_wslua.c \
123         taps_wslua.c \
124         wslua_dumper.c \
125         wslua_field.c \
126         wslua_gui.c \
127         wslua_pinfo.c \
128         wslua_proto.c \
129         wslua_listener.c \
130         wslua_tree.c \
131         wslua_tvb.c \
132         wslua_util.c