summaryrefslogtreecommitdiff
path: root/src/Makefile.am
diff options
context:
space:
mode:
authorZachary T Welch <zw@superlucidity.net>2009-11-17 08:30:51 -0800
committerZachary T Welch <zw@superlucidity.net>2009-11-18 03:59:14 -0800
commit903daa796a226152fe56245758c8388b79d12988 (patch)
tree53a4fda27a227ec08010c3da56bb02df4b8d0e14 /src/Makefile.am
parent59f32cbe53ccd8725e01968fcbc716cc5768a36b (diff)
downloadopenocd+libswd-903daa796a226152fe56245758c8388b79d12988.tar.gz
openocd+libswd-903daa796a226152fe56245758c8388b79d12988.tar.bz2
openocd+libswd-903daa796a226152fe56245758c8388b79d12988.tar.xz
openocd+libswd-903daa796a226152fe56245758c8388b79d12988.zip
move startup.c to libopenocd
Moves the creation of startup_tcl.c from src/helper/ to src/. Prepares to split the startup.tcl file into its per-module parts.
Diffstat (limited to 'src/Makefile.am')
-rw-r--r--src/Makefile.am23
1 files changed, 22 insertions, 1 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 77ae5ae2..2f17ba4d 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -14,7 +14,8 @@ openocd_LDADD = libopenocd.la
libopenocd_la_SOURCES = \
hello.c \
- openocd.c
+ openocd.c \
+ startup_tcl.c
noinst_HEADERS = \
openocd.h
@@ -97,6 +98,26 @@ if HTTPD
libopenocd_la_LIBADD += -lmicrohttpd
endif
+STARTUP_TCL_SRCS = \
+ $(srcdir)/helper/startup.tcl
+
+EXTRA_DIST = $(STARTUP_TCL_SRCS)
+
+BUILT_SOURCES = startup.tcl
+
+startup.tcl: $(STARTUP_TCL_SRCS)
+ cat $^ > $@
+
+BIN2C = $(builddir)/helper/bin2char$(EXEEXT_FOR_BUILD)
+
+# Convert .tcl to cfile
+startup_tcl.c: startup.tcl $(BIN2C)
+ $(BIN2C) startup_tcl < $< > $@ || rm -f $@
+
+# add startup_tcl.c to make clean list
+CLEANFILES = startup.tcl startup_tcl.c
+
+
MAINTAINERCLEANFILES = $(srcdir)/Makefile.in
# The "quick" target builds executables & reinstalls the executables