From: <zw...@ma...> - 2009-05-27 08:44:58
|
Author: zwelch Date: 2009-05-27 08:44:43 +0200 (Wed, 27 May 2009) New Revision: 1918 Added: trunk/src/tcl/board/ trunk/src/tcl/interface/ trunk/src/tcl/target/ trunk/src/tcl/test/ Removed: trunk/src/target/board/ trunk/src/target/interface/ trunk/src/target/target/ trunk/src/target/test/ Modified: trunk/Makefile.am trunk/configure.in trunk/src/Makefile.am trunk/src/target/Makefile.am Log: Move TCL script files -- Step 1 of 2: - Move src/target/{interface,target,board,test}/ into src/tcl/ - Remove existing rules in src/Makefile.am and src/target/Makefile.am. - Add Makefile.am handling of *.cfg and *.tcl files in top Makefile.am: - Add dist-hook to include such files under src/tcl in the distribution. - Add install-data-hook to install contents of '$(top_srcdir)/src/tcl/'. - Add uninstall-hook to remove the installed script files. - Change paths to (un)install script files in '$(pkgdatadir)/scripts'. Modified: trunk/Makefile.am =================================================================== --- trunk/Makefile.am 2009-05-27 02:01:15 UTC (rev 1917) +++ trunk/Makefile.am 2009-05-27 06:44:43 UTC (rev 1918) @@ -29,6 +29,29 @@ $(MAKE) Doxyfile doxygen Doxyfile 2>&1 | perl $(srcdir)/tools/logger.pl > doxygen.log +TCL_PATH = src/tcl +# command to find paths of script files, relative to TCL_PATH +TCL_FILES := find $(srcdir)/$(TCL_PATH) -name '*.cfg' -o -name '*.tcl' | \ + sed -e 's,^$(srcdir)/$(TCL_PATH),,' + +dist-hook: + for i in $$($(TCL_FILES)); do \ + j="$(distdir)/$(TCL_PATH)/$$i" && \ + mkdir -p "$$(dirname $$j)" && \ + $(INSTALL_DATA) $(srcdir)/$(TCL_PATH)/$$i $$j; \ + done + +install-data-hook: + for i in $$($(TCL_FILES)); do \ + j="$(DESTDIR)$(pkgdatadir)/scripts/$$i" && \ + mkdir -p "$$(dirname $$j)" && \ + $(INSTALL_DATA) $(srcdir)/$(TCL_PATH)/$$i $$j; \ + done + +uninstall-hook: + rm -rf $(DESTDIR)$(pkgdatadir)/scripts + + distclean-local: rm -rf Doxyfile doxygen Modified: trunk/configure.in =================================================================== --- trunk/configure.in 2009-05-27 02:01:15 UTC (rev 1917) +++ trunk/configure.in 2009-05-27 06:44:43 UTC (rev 1918) @@ -834,6 +834,7 @@ AM_PROG_CC_C_O AC_PROG_RANLIB AC_PROG_LIBTOOL +AC_PROG_INSTALL dnl configure checks required for Jim files (these are obsolete w/ C99) AC_C_CONST Modified: trunk/src/Makefile.am =================================================================== --- trunk/src/Makefile.am 2009-05-27 02:01:15 UTC (rev 1917) +++ trunk/src/Makefile.am 2009-05-27 06:44:43 UTC (rev 1918) @@ -92,24 +92,4 @@ libopenocd_la_LIBADD += -lmicrohttpd endif -nobase_dist_pkglib_DATA = \ - tcl/bitsbytes.tcl \ - tcl/chip/atmel/at91/aic.tcl \ - tcl/chip/atmel/at91/at91sam7x128.tcl \ - tcl/chip/atmel/at91/at91sam7x256.tcl \ - tcl/chip/atmel/at91/pmc.tcl \ - tcl/chip/atmel/at91/rtt.tcl \ - tcl/chip/atmel/at91/usarts.tcl \ - tcl/chip/st/stm32/stm32.tcl \ - tcl/chip/st/stm32/stm32_rcc.tcl \ - tcl/chip/st/stm32/stm32_regs.tcl \ - tcl/cpu/arm/arm7tdmi.tcl \ - tcl/cpu/arm/arm920.tcl \ - tcl/cpu/arm/arm946.tcl \ - tcl/cpu/arm/arm966.tcl \ - tcl/cpu/arm/cortex_m3.tcl \ - tcl/memory.tcl \ - tcl/mmr_helpers.tcl \ - tcl/readable.tcl - MAINTAINERCLEANFILES = Makefile.in Modified: trunk/src/target/Makefile.am =================================================================== --- trunk/src/target/Makefile.am 2009-05-27 02:01:15 UTC (rev 1917) +++ trunk/src/target/Makefile.am 2009-05-27 06:44:43 UTC (rev 1918) @@ -26,14 +26,5 @@ nobase_dist_pkglib_DATA = nobase_dist_pkglib_DATA += xscale/debug_handler.bin nobase_dist_pkglib_DATA += ecos/at91eb40a.elf -# Various chip targets -nobase_dist_pkglib_DATA += $(wildcard $(srcdir)/target/*.cfg) -# Various jtag interfaces -nobase_dist_pkglib_DATA += $(wildcard $(srcdir)/interface/*.cfg) -# Various preconfigured boards -nobase_dist_pkglib_DATA += $(wildcard $(srcdir)/board/*.cfg) -# test files -nobase_dist_pkglib_DATA += $(wildcard $(srcdir)/test/*.cfg) - MAINTAINERCLEANFILES = Makefile.in Copied: trunk/src/tcl/board (from rev 1917, trunk/src/target/board) Copied: trunk/src/tcl/interface (from rev 1917, trunk/src/target/interface) Copied: trunk/src/tcl/target (from rev 1917, trunk/src/target/target) Copied: trunk/src/tcl/test (from rev 1917, trunk/src/target/test) |