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'.
git-svn-id: svn://svn.berlios.de/openocd/trunk@1918 b42882b7-edfa-0310-969c-e2dbd0fdcd60
This commit is contained in:
23
Makefile.am
23
Makefile.am
@@ -29,6 +29,29 @@ doxygen::
|
||||
$(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
|
||||
|
||||
|
||||
Reference in New Issue
Block a user