]> git.draconx.ca Git - gob-dx.git/blob - src/Makefile.am
Release 2.0.7
[gob-dx.git] / src / Makefile.am
1 #YACCFLAGS += -d -t
2 AM_YFLAGS = -d -t
3 SUBDIRS = .
4
5 #GCC specific, should not be in distributed files
6 #AM_CFLAGS = \
7 #       -Wall                   \
8 #       -Wpointer-arith         \
9 #       -Wmissing-prototypes    \
10 #       -Wmissing-declarations
11
12 DEFS = @DEFS@ \
13         -DPKGDATADIR=\"$(pkgdatadir)\"
14
15 INCLUDES = \
16         $(GLIB_CFLAGS)          \
17         -I$(top_builddir)       \
18         -I$(top_builddir)/src   \
19         -I$(top_srcdir)         \
20         -I$(top_srcdir)/src     \
21         -I$(includedir)
22
23 bin_PROGRAMS = @DOINSTGOB@
24 noinst_PROGRAMS = @NOINSTGOB@
25 EXTRA_PROGRAMS = gob2
26
27 BUILT_SOURCES = parse.h parse.c lexer.c
28
29 gob2_SOURCES =  \
30         main.c          \
31         main.h          \
32         treefuncs.c     \
33         treefuncs.h     \
34         out.c           \
35         out.h           \
36         util.c          \
37         util.h          \
38         checks.c        \
39         checks.h        \
40         parse.y         \
41         lexer.l
42
43 gob2_LDADD = \
44         -lm \
45         $(GLIB_LIBS) \
46         @LEXLIB@
47
48 # we might want popt back in the future
49 #       @POPT_LIB@
50
51 CLEANFILES = @CLEANFILES@ $(BUILT_SOURCES) test-object.* test-object-private.h
52
53 EXTRA_DIST = $(BUILT_SOURCES) test.gob generate_treefuncs.pl treefuncs.def
54
55 # parse.h parse.c: parse.y
56 #       $(YACC) $(YFLAGS) $<
57 #       test -f y.tab.c && mv -f y.tab.c parse.c
58 #       test -f y.tab.h && mv -f y.tab.h parse.h
59
60 test: test-object.c test-object.h
61         $(CC) -g -Wall `pkg-config --cflags gobject-2.0 gtk+-2.0` -c test-object.c
62
63 test-object.c test-object.h: test.gob gob2
64         ./gob2 test.gob
65
66 # can't depend on the header file as that would break the above rule
67 # since it's just for testing, who cares
68 testcpp: test-object.cc
69         g++ -g -Wall `pkg-config --cflags gobject-2.0 gtk+-2.0` -c test-object.cc
70
71 test-object.cc: test.gob gob2
72         ./gob2 --for-cpp test.gob