allow #include directives to use module name
[openocd.git] / src / helper / Makefile.am
1 AM_CPPFLAGS = \
2         -I$(top_srcdir)/src \
3         -I$(top_srcdir)/src/server \
4         -I$(top_srcdir)/src/target \
5         -DPKGDATADIR=\"$(pkgdatadir)\"
6
7 METASOURCES = AUTO
8 noinst_LTLIBRARIES = libhelper.la
9
10 if ECOSBOARD
11 CONFIGFILES =
12 else
13 CONFIGFILES = options.c jim.c jim-eventloop.c
14 endif
15
16
17
18 libhelper_la_SOURCES = \
19         binarybuffer.c \
20         $(CONFIGFILES) \
21         configuration.c \
22         log.c \
23         command.c \
24         time_support.c \
25         replacements.c \
26         fileio.c \
27         membuf.c
28
29 if IOUTIL
30 libhelper_la_SOURCES += ioutil.c
31 else
32 libhelper_la_SOURCES += ioutil_stubs.c
33 endif
34
35 libhelper_la_CFLAGS =
36 if IS_MINGW
37 # FD_* macros are sloppy with their signs on MinGW32 platform
38 libhelper_la_CFLAGS += -Wno-sign-compare
39 endif
40
41 noinst_HEADERS = \
42         binarybuffer.h \
43         configuration.h \
44         ioutil.h \
45         types.h \
46         log.h \
47         command.h \
48         membuf.h \
49         time_support.h \
50         replacements.h \
51         fileio.h \
52         jim.h \
53         jim-eventloop.h \
54         system.h \
55         bin2char.c
56
57 EXTRA_DIST = startup.tcl
58
59 BIN2C = bin2char$(EXEEXT_FOR_BUILD)
60
61 BUILT_SOURCES = $(BIN2C)
62
63 $(BIN2C): bin2char.c
64         ${CC_FOR_BUILD} ${CFLAGS_FOR_BUILD} $(srcdir)/bin2char.c -o $@
65
66 CLEANFILES = bin2char$(EXEEXT_FOR_BUILD)
67
68 MAINTAINERCLEANFILES = $(srcdir)/Makefile.in