You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

86 lines
2.1 KiB

  1. noinst_LTLIBRARIES += %D%/libopenocd.la
  2. bin_PROGRAMS += %D%/openocd
  3. %C%_openocd_SOURCES = \
  4. %D%/main.c
  5. %C%_libopenocd_la_SOURCES = \
  6. %D%/hello.c %D%/hello.h \
  7. %D%/openocd.c %D%/openocd.h
  8. %C%_openocd_LDADD = %D%/libopenocd.la
  9. %C%_openocd_LDADD += $(MINGWLDADD)
  10. if INTERNAL_JIMTCL
  11. %C%_openocd_LDADD += $(top_builddir)/jimtcl/libjim.a
  12. else
  13. %C%_openocd_LDADD += -ljim
  14. endif
  15. %C%_libopenocd_la_CPPFLAGS =
  16. # banner output includes RELSTR appended to $VERSION from the configure script
  17. # guess-rev.sh returns either a repository version ID or "-snapshot"
  18. if RELEASE
  19. %C%_libopenocd_la_CPPFLAGS += -DRELSTR=\"\"
  20. %C%_libopenocd_la_CPPFLAGS += -DGITVERSION=\"\"
  21. else
  22. %C%_libopenocd_la_CPPFLAGS += -DRELSTR=\"`$(top_srcdir)/guess-rev.sh $(top_srcdir)`\"
  23. %C%_libopenocd_la_CPPFLAGS += -DGITVERSION=\"`cd $(top_srcdir) && git describe`\"
  24. %C%_libopenocd_la_CPPFLAGS += -DPKGBLDDATE=\"`date +%F-%R`\"
  25. endif
  26. # add default CPPFLAGS
  27. %C%_libopenocd_la_CPPFLAGS += $(AM_CPPFLAGS) $(CPPFLAGS)
  28. # the library search path.
  29. %C%_libopenocd_la_LDFLAGS = $(all_libraries)
  30. if IS_MINGW
  31. MINGWLDADD = -lws2_32
  32. else
  33. MINGWLDADD =
  34. endif
  35. %C%_libopenocd_la_LIBADD = \
  36. %D%/xsvf/libxsvf.la \
  37. %D%/svf/libsvf.la \
  38. %D%/pld/libpld.la \
  39. %D%/jtag/libjtag.la \
  40. %D%/transport/libtransport.la \
  41. %D%/flash/libflash.la \
  42. %D%/target/libtarget.la \
  43. %D%/server/libserver.la \
  44. %D%/rtos/librtos.la \
  45. %D%/helper/libhelper.la
  46. BIN2C = $(srcdir)/%D%/helper/bin2char.sh
  47. STARTUP_TCL_SRCS =
  48. EXTRA_DIST += $(STARTUP_TCL_SRCS)
  49. BUILT_SOURCES += %D%/startup_tcl.inc
  50. # Convert .tcl to c-array
  51. %D%/startup_tcl.inc: $(STARTUP_TCL_SRCS)
  52. cat $^ | $(BIN2C) > $@ || { rm -f $@; false; }
  53. # add generated files to make clean list
  54. CLEANFILES += %D%/startup_tcl.inc
  55. # we do not want generated file in the dist
  56. #dist-hook:
  57. # rm -f $(distdir)/%D%/startup_tcl.inc
  58. include %D%/helper/Makefile.am
  59. include %D%/jtag/Makefile.am
  60. include %D%/transport/Makefile.am
  61. include %D%/xsvf/Makefile.am
  62. include %D%/svf/Makefile.am
  63. include %D%/target/Makefile.am
  64. include %D%/rtos/Makefile.am
  65. include %D%/server/Makefile.am
  66. include %D%/flash/Makefile.am
  67. include %D%/pld/Makefile.am