summaryrefslogtreecommitdiffstats
path: root/tools/build/scripts
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1999-04-19 13:35:24 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1999-04-19 13:35:24 +0000
commitb6529a34fd5a3b821bfef0cdecea8106a8487ef0 (patch)
tree2d93d2d9b757dbaa87aecd8cf5d8d9c7285bbeb6 /tools/build/scripts
parent183fa829dbc9b8f887c9a97c06da33931da6ea69 (diff)
downloadrtems-b6529a34fd5a3b821bfef0cdecea8106a8487ef0.tar.bz2
Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de> to reorganize
the build-tools layout to simplify it. This script reorganizes and simpilfies the build-tools subdirectories. It moves all source-files and scripts to c/build-tools/. This will enable use to use this directory directly to refer to the build-tools instead of copying them around in a "preinstall" step in future. However, RTEMS's autoconf Makefile.ins and *.cfg files are not yet prepared to apply this approach and therefore require additional work.
Diffstat (limited to 'tools/build/scripts')
-rw-r--r--tools/build/scripts/Makefile.am25
-rw-r--r--tools/build/scripts/Makefile.in258
-rw-r--r--tools/build/scripts/README24
-rw-r--r--tools/build/scripts/install-if-change.in142
-rw-r--r--tools/build/scripts/lock-directory.in43
-rw-r--r--tools/build/scripts/rcs-clean.in73
-rw-r--r--tools/build/scripts/search-id.sh15
-rw-r--r--tools/build/scripts/unlock-directory.in41
8 files changed, 0 insertions, 621 deletions
diff --git a/tools/build/scripts/Makefile.am b/tools/build/scripts/Makefile.am
deleted file mode 100644
index dd931ca957..0000000000
--- a/tools/build/scripts/Makefile.am
+++ /dev/null
@@ -1,25 +0,0 @@
-#
-# $Id$
-#
-
-AUTOMAKE_OPTIONS = foreign
-
-bin_SCRIPTS=\
-install-if-change \
-lock-directory \
-unlock-directory \
-rcs-clean
-
-noinst_SCRIPTS = search-id.sh
-
-#
-# HACK: install to the build-tree
-#
-install-exec-local: $(bin_SCRIPTS)
- $(mkinstalldirs) $(PROJECT_ROOT)/${RTEMS_BSP}/build-tools
- $(INSTALL_SCRIPT) $(bin_SCRIPTS) \
- $(PROJECT_ROOT)/${RTEMS_BSP}/build-tools
-
-preinstall: install-exec-local
-
-include $(top_srcdir)/../../automake/local.am
diff --git a/tools/build/scripts/Makefile.in b/tools/build/scripts/Makefile.in
deleted file mode 100644
index 1a1795a6c1..0000000000
--- a/tools/build/scripts/Makefile.in
+++ /dev/null
@@ -1,258 +0,0 @@
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
-
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-#
-# $Id$
-#
-
-
-
-SHELL = @SHELL@
-
-srcdir = @srcdir@
-top_srcdir = @top_srcdir@
-VPATH = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-sbindir = @sbindir@
-libexecdir = @libexecdir@
-datadir = @datadir@
-sysconfdir = @sysconfdir@
-sharedstatedir = @sharedstatedir@
-localstatedir = @localstatedir@
-libdir = @libdir@
-infodir = @infodir@
-mandir = @mandir@
-includedir = @includedir@
-oldincludedir = /usr/include
-
-DESTDIR =
-
-pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-
-top_builddir = ..
-
-ACLOCAL = @ACLOCAL@
-AUTOCONF = @AUTOCONF@
-AUTOMAKE = @AUTOMAKE@
-AUTOHEADER = @AUTOHEADER@
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-transform = @program_transform_name@
-
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-host_alias = @host_alias@
-host_triplet = @host@
-CC = @CC@
-EXEEXT = @EXEEXT@
-KSH = @KSH@
-MAKEINFO = @MAKEINFO@
-PACKAGE = @PACKAGE@
-PROJECT_ROOT = @PROJECT_ROOT@
-RTEMS_ROOT = @RTEMS_ROOT@
-RTEMS_TOPdir = @RTEMS_TOPdir@
-VERSION = @VERSION@
-
-AUTOMAKE_OPTIONS = foreign
-
-bin_SCRIPTS = install-if-change lock-directory unlock-directory rcs-clean
-
-
-noinst_SCRIPTS = search-id.sh
-mkinstalldirs = $(SHELL) $(top_srcdir)/../../mkinstalldirs
-CONFIG_HEADER = ../src/config.h
-CONFIG_CLEAN_FILES = install-if-change lock-directory rcs-clean \
-unlock-directory
-SCRIPTS = $(bin_SCRIPTS) $(noinst_SCRIPTS)
-
-DIST_COMMON = README Makefile.am Makefile.in install-if-change.in \
-lock-directory.in rcs-clean.in unlock-directory.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-TAR = tar
-GZIP_ENV = --best
-all: all-redirect
-.SUFFIXES:
-$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) $(top_srcdir)/../../automake/local.am
- cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-install-if-change: $(top_builddir)/config.status install-if-change.in
- cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-lock-directory: $(top_builddir)/config.status lock-directory.in
- cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-rcs-clean: $(top_builddir)/config.status rcs-clean.in
- cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-unlock-directory: $(top_builddir)/config.status unlock-directory.in
- cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-install-binSCRIPTS: $(bin_SCRIPTS)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(bindir)
- @list='$(bin_SCRIPTS)'; for p in $$list; do \
- if test -f $$p; then \
- echo " $(INSTALL_SCRIPT) $$p $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`"; \
- $(INSTALL_SCRIPT) $$p $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`; \
- else if test -f $(srcdir)/$$p; then \
- echo " $(INSTALL_SCRIPT) $(srcdir)/$$p $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`"; \
- $(INSTALL_SCRIPT) $(srcdir)/$$p $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`; \
- else :; fi; fi; \
- done
-
-uninstall-binSCRIPTS:
- @$(NORMAL_UNINSTALL)
- list='$(bin_SCRIPTS)'; for p in $$list; do \
- rm -f $(DESTDIR)$(bindir)/`echo $$p|sed '$(transform)'`; \
- done
-tags: TAGS
-TAGS:
-
-
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = scripts
-
-distdir: $(DISTFILES)
- here=`cd $(top_builddir) && pwd`; \
- top_distdir=`cd $(top_distdir) && pwd`; \
- distdir=`cd $(distdir) && pwd`; \
- cd $(top_srcdir) \
- && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --foreign scripts/Makefile
- @for file in $(DISTFILES); do \
- d=$(srcdir); \
- if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
-info-am:
-info: info-am
-dvi-am:
-dvi: dvi-am
-check-am: all-am
-check: check-am
-installcheck-am:
-installcheck: installcheck-am
-install-exec-am: install-binSCRIPTS install-exec-local
-install-exec: install-exec-am
-
-install-data-am:
-install-data: install-data-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-am
-uninstall-am: uninstall-binSCRIPTS
-uninstall: uninstall-am
-all-am: Makefile $(SCRIPTS)
-all-redirect: all-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs:
- $(mkinstalldirs) $(DESTDIR)$(bindir)
-
-
-mostlyclean-generic:
-
-clean-generic:
-
-distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
-
-maintainer-clean-generic:
-mostlyclean-am: mostlyclean-generic
-
-mostlyclean: mostlyclean-am
-
-clean-am: clean-generic mostlyclean-am
-
-clean: clean-am
-
-distclean-am: distclean-generic clean-am
-
-distclean: distclean-am
-
-maintainer-clean-am: maintainer-clean-generic distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
-
-maintainer-clean: maintainer-clean-am
-
-.PHONY: uninstall-binSCRIPTS install-binSCRIPTS tags distdir info-am \
-info dvi-am dvi check check-am installcheck-am installcheck \
-install-exec-local install-exec-am install-exec install-data-am \
-install-data install-am install uninstall-am uninstall all-redirect \
-all-am all installdirs mostlyclean-generic distclean-generic \
-clean-generic maintainer-clean-generic clean mostlyclean distclean \
-maintainer-clean
-
-
-#
-# HACK: install to the build-tree
-#
-install-exec-local: $(bin_SCRIPTS)
- $(mkinstalldirs) $(PROJECT_ROOT)/${RTEMS_BSP}/build-tools
- $(INSTALL_SCRIPT) $(bin_SCRIPTS) \
- $(PROJECT_ROOT)/${RTEMS_BSP}/build-tools
-
-preinstall: install-exec-local
-
-debug-am:
-
-debug: debug-am
-
-debug_install-am:
-
-debug_install: debug_install-am
-
-.PHONY: debug debug_install debug-am
-
-profile-am:
-
-profile: profile-am
-
-profile_install-am:
-
-profile_install: profile_install-am
-
-.PHONY: profile profile_install profile-am
-
-preinstall-am:
-
-preinstall: preinstall-am
-
-.PHONY: preinstall preinstall-am
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/tools/build/scripts/README b/tools/build/scripts/README
deleted file mode 100644
index 0738a5830e..0000000000
--- a/tools/build/scripts/README
+++ /dev/null
@@ -1,24 +0,0 @@
-#
-# $Id$
-#
-
-Misc. support tools for RTEMS workspaces.
-More will be added later as they are converted from Teamware
-to CVS.
-
-install-if-change
- Smart install script that also can append suffixes as it
- installs (suffixes used for debug and profile variants).
- Requires bash or ksh.
-
-rcs-clean
- deletes all files from the current directory that can be
- re-created from RCS. Careful to not delete locked files.
- May be used by 'gmake clobber'
-
-lock-directory
-unlock-directory
- traverse a directory structure making it unwritable.
- Useful to keep people from accidentally overwriting
- "released" trees if they get confused about which
- module they have loaded.
diff --git a/tools/build/scripts/install-if-change.in b/tools/build/scripts/install-if-change.in
deleted file mode 100644
index b2f3cb04bb..0000000000
--- a/tools/build/scripts/install-if-change.in
+++ /dev/null
@@ -1,142 +0,0 @@
-#!@KSH@ -p
-#
-# Either bash or ksh will be ok for this; requires (( )) arithmetic
-# (-p above just says to not parse $ENV file; makes it faster for
-# those of us who set $ENV)
-#
-# install files if they have changed by running 'cmp', then 'install'
-# as necessary.
-#
-# Optionally, can append a suffix before last existing suffix (if any)
-#
-# NOTE
-# We avoid using typical install(1M) programs since they have
-# large variability across systems and we also need to support ou
-# -V option.
-# So we just copy and chmod by hand.
-#
-# $Id$
-#
-
-progname=`basename $0`
-#progname=${0##*/} # fast basename hack for ksh, bash
-
-USAGE=\
-"usage: $progname [ -vmV ] file [ file ... ] dest-directory-or-file
- -v -- verbose
- -V suffix -- suffix to append to targets (before any . suffix)
- eg: -V _g would change 'foo' to 'foo_g' and
- 'libfoo.a' to 'libfoo_g.a'
- -m mode -- mode for new file(s)"
-
-fatal() {
- if [ "$1" ]
- then
- echo $* >&2
- fi
- echo "$USAGE" 1>&2
- exit 1
-}
-
-#
-# process the options
-#
-
-verbose=""
-suffix=""
-mode=""
-
-while getopts vm:V: OPT
-do
- case "$OPT" in
- v)
- verbose="yes";;
- V)
- eval suffix=$OPTARG;;
- m)
- mode="$OPTARG";;
- *)
- fatal
- esac
-done
-
-shiftcount=`expr $OPTIND - 1`
-shift $shiftcount
-
-args=$*
-
-#
-# Separate source file(s) from dest directory or file
-#
-
-files=""
-dest=""
-for d in $args
-do
- files="$files $dest"
- dest=$d
-done
-
-if [ ! "$files" ] || [ ! "$dest" ]
-then
- fatal "missing files or invalid destination"
-fi
-
-#
-# Process the arguments
-#
-
-targets=""
-for f in $files
-do
- # leaf=`basename $f`
- leaf=${f##*/} # fast basename hack for ksh, bash
-
- target=$dest
- if [ -d $dest ]
- then
- # if we were given a suffix, then add it as appropriate
- if [ "$suffix" ]
- then
- case $f in
- *.*)
- # leaf=`echo $leaf |
- # /bin/sed "s/\([~\.]*\)\.\(.*\)$/\1$suffix.\2/"`
- # ksh,bash hack for above sed script
- leaf=${leaf%%.*}$suffix.${leaf#*.}
-
- [ "$verbose" = "yes" ] &&
- echo "$progname: $f will be installed as $leaf"
- ;;
- *)
- leaf=$leaf$suffix;;
- esac
- fi
- target=$target/$leaf
- fi
-
- [ ! -r $f ] && fatal "can not read $f"
-
- if cmp -s $f $target
- then
- [ "$verbose" = "yes" ] && echo "'$f' not newer than '$target'"
- else
- [ "$verbose" = "yes" ] && echo "rm -f $target"
- rm -f $target
- echo "cp -p $f $target"
- cp -p $f $target || exit 1
- targets="$targets $target" # keep list for chmod below
- fi
-done
-
-if [ "$mode" -a "$targets" ]
-then
- [ "$verbose" = "yes" ] && echo "chmod $mode $targets"
- chmod $mode $targets
-fi
-
-exit 0
-
-# Local Variables: ***
-# mode:ksh ***
-# End: ***
diff --git a/tools/build/scripts/lock-directory.in b/tools/build/scripts/lock-directory.in
deleted file mode 100644
index 1c205cdec0..0000000000
--- a/tools/build/scripts/lock-directory.in
+++ /dev/null
@@ -1,43 +0,0 @@
-#!@KSH@
-#
-# $Id$
-#
-# Make a directory write protected
-# Used to write protect the install point after a build
-# to prevent inadvertant overwriting.
-#
-
-# is a particular command available on this machine?
-#
-cmd_avail()
-{
- set -- `type $1 2>&1`
- if [ "$2" = "not" -a "$3" = "found" ] || [ "$3" = "not" -a "$4" = "found" ]
- then
- return 1
- else
- return 0
- fi
-}
-
-lock_directory() {
- l_dir=$1/. # get any symlink out of the way using '.'
- if [ -d $l_dir ]
- then
- find $l_dir -type d -perm -0200 -print | $XARGS chmod -w
- fi
-}
-
-# Use gnu xargs if available; faster, more reliable in general
-XARGS=xargs
-cmd_avail gxargs && XARGS=gxargs
-
-for dir
-do
- lock_directory $dir
-done
-
-# Local Variables: ***
-# mode:ksh ***
-# End: ***
-
diff --git a/tools/build/scripts/rcs-clean.in b/tools/build/scripts/rcs-clean.in
deleted file mode 100644
index 83fed05128..0000000000
--- a/tools/build/scripts/rcs-clean.in
+++ /dev/null
@@ -1,73 +0,0 @@
-#!@KSH@ -p
-#
-# $Id$
-#
-# Delete all files from the current directory that can be recreated
-# via RCS 'co' commonds
-# Used by 'make clobber'
-#
-
-progname=${0##*/} # fast basename hack for ksh, bash
-
-USAGE=\
-"usage: $progname [ -v ]"
-
-fatal() {
- if [ "$1" ]
- then
- echo $* >&2
- fi
- echo "$USAGE" 1>&2
- exit 1
-}
-
-#
-# process the options
-#
-
-verbose=""
-
-while getopts v OPT
-do
- case "$OPT" in
- v)
- verbose="yes";;
- *)
- fatal
- esac
-done
-
-let $((shiftcount = $OPTIND - 1))
-shift $shiftcount
-
-args=$*
-[ "$args" ] && fatal
-
-[ -d RCS/. ] || exit 0
-
-# there is probably a better way to do this
-
-rcs_files=`echo RCS/*,v | sed -e 's?RCS/??g' -e's/,v//g'`
-
-kills=""
-for f in $rcs_files
-do
- # build list of all files in RCS/*,v that are *not* locked
- if [ -f $f ] && [ ! -w $f ] && [ -f RCS/$f,v ]
- then
- locked=`rlog -L -R $f`
- [ "$locked" = "" ] && kills="$kills $f"
- fi
-done
-
-if [ "$kills" ]
-then
- [ "$verbose" ] && echo rm -f $kills
- rm -f $kills
-fi
-
-exit 0
-
-# Local Variables: ***
-# mode:ksh ***
-# End: ***
diff --git a/tools/build/scripts/search-id.sh b/tools/build/scripts/search-id.sh
deleted file mode 100644
index a94d2d7cc9..0000000000
--- a/tools/build/scripts/search-id.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/sh
-#
-# $Id$
-#
-
-find $1 -type f -a ! -name "*.scn" -a ! -name "bsp_specs" -a \
- -print > /tmp/$$.0
-find $1 -type f -a ! -name "*.scn" -a ! -name "bsp_specs" -a \
- -exec grep -l '$Id' {} \; > /tmp/$$.1
-
-diff /tmp/$$.0 /tmp/$$.1 > /tmp/$$.2
-
-grep "<" /tmp/$$.2 | sed 's/< //' >&1
-
-rm -f /tmp/$$*
diff --git a/tools/build/scripts/unlock-directory.in b/tools/build/scripts/unlock-directory.in
deleted file mode 100644
index c63ceff881..0000000000
--- a/tools/build/scripts/unlock-directory.in
+++ /dev/null
@@ -1,41 +0,0 @@
-#!@KSH@
-#
-# $Id$
-#
-# Unlock a directory processed by lock_directory
-#
-
-# is a particular command available on this machine?
-#
-cmd_avail()
-{
- set -- `type $1 2>&1`
- if [ "$2" = "not" -a "$3" = "found" ] || [ "$3" = "not" -a "$4" = "found" ]
- then
- return 1
- else
- return 0
- fi
-}
-
-unlock_directory() {
- ul_dir=$1/. # get any symlink out of the way using '.'
- if [ -d $ul_dir ]
- then
- find $ul_dir -type d ! -perm -0222 -print | $XARGS -t chmod +w
- fi
-}
-
-# Use gnu xargs if available; faster, more reliable in general
-XARGS=xargs
-cmd_avail gxargs && XARGS=gxargs
-
-for dir
-do
- unlock_directory $dir
-done
-
-# Local Variables: ***
-# mode:ksh ***
-# End: ***
-