X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2FMakefile.am;h=913118f25cfa67c561d23b4a7a2dd967559442a0;hb=7609e1091abfacfc1b62aca06c642e42003aa444;hp=a223f9512fcef2a694d4c66790bf413bec62c41e;hpb=55f4e430e8c1c7382d27695c56e8ca95ba7b7dec;p=openocd.git diff --git a/src/Makefile.am b/src/Makefile.am index a223f9512f..913118f25c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -12,7 +12,14 @@ endif openocd_SOURCES = $(MAINFILE) openocd_LDADD = libopenocd.la -libopenocd_la_SOURCES = openocd.c +libopenocd_la_SOURCES = \ + hello.c \ + openocd.c \ + startup_tcl.c + +noinst_HEADERS = \ + openocd.h + # set the include path found by configure AM_CPPFLAGS = \ @@ -43,7 +50,7 @@ libopenocd_la_CPPFLAGS += $(AM_CPPFLAGS) $(CPPFLAGS) libopenocd_la_LDFLAGS = $(all_libraries) if IS_MINGW -MINGWLDADD = -lwsock32 +MINGWLDADD = -lws2_32 else MINGWLDADD = endif @@ -91,6 +98,30 @@ if HTTPD libopenocd_la_LIBADD += -lmicrohttpd endif +STARTUP_TCL_SRCS = \ + $(srcdir)/helper/startup.tcl \ + $(srcdir)/jtag/startup.tcl \ + $(srcdir)/target/startup.tcl \ + $(srcdir)/flash/startup.tcl \ + $(srcdir)/server/startup.tcl + +EXTRA_DIST = $(STARTUP_TCL_SRCS) + +BUILT_SOURCES = startup.tcl + +startup.tcl: $(STARTUP_TCL_SRCS) + cat $^ > $@ + +BIN2C = $(top_builddir)/src/helper/bin2char$(EXEEXT_FOR_BUILD) + +# Convert .tcl to cfile +startup_tcl.c: startup.tcl $(BIN2C) + $(BIN2C) openocd_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