summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1999-10-21 15:59:54 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1999-10-21 15:59:54 +0000
commit43e7d103a0aa620f5f75c4ccac2f5b6c3d3f9433 (patch)
tree4ac0457190bb29a927139d9a966ac14c88c2bb61 /scripts
parent8f2cf93145595b8b4359767e5a7922a68af3495d (diff)
downloadrtems-43e7d103a0aa620f5f75c4ccac2f5b6c3d3f9433.tar.bz2
Changes from Ralf with script-19991021-0. He fixed the %files
issue and has mkbspspec in a better state. user.cfg is now gone. There are some miscellaneous changes to buildall done by Joel to clean up the build process.
Diffstat (limited to '')
-rw-r--r--scripts/Makefile.am2
-rw-r--r--scripts/binutils/Makefile.am23
-rw-r--r--scripts/binutils/Makefile.in8
-rw-r--r--scripts/binutils/binutils.spec.in6
-rwxr-xr-xscripts/buildall.in23
-rw-r--r--scripts/configure.in12
-rw-r--r--scripts/gccnewlib/Makefile.am22
-rw-r--r--scripts/gccnewlib/Makefile.in8
-rw-r--r--scripts/gccnewlib/gccnewlib.spec.in56
-rw-r--r--scripts/gdb/Makefile.am21
-rw-r--r--scripts/gdb/Makefile.in8
-rw-r--r--scripts/gdb/gdb.spec.in22
-rwxr-xr-xscripts/mkbinutils_subpackage_version2
-rw-r--r--scripts/mkbinutilspec.in6
-rw-r--r--scripts/mkbspspec.in72
-rw-r--r--scripts/mkgccnewlibspec.in6
-rw-r--r--scripts/mkgdbspec.in7
-rw-r--r--scripts/rtems/Makefile.am53
-rwxr-xr-xscripts/setup9
19 files changed, 231 insertions, 135 deletions
diff --git a/scripts/Makefile.am b/scripts/Makefile.am
index b4af5ddf99..72e6130b51 100644
--- a/scripts/Makefile.am
+++ b/scripts/Makefile.am
@@ -27,5 +27,3 @@ setup.cache: setup.def
cp setup.def $@
DISTCLEANFILES = setup.cache
-
-CLEANFILES = buildall
diff --git a/scripts/binutils/Makefile.am b/scripts/binutils/Makefile.am
index cd387d196c..b586eccebc 100644
--- a/scripts/binutils/Makefile.am
+++ b/scripts/binutils/Makefile.am
@@ -1,32 +1,35 @@
+## $Id$
+
AUTOMAKE_OPTIONS = foreign
-MKBINUTILSSPEC = $(SHELL) $(top_srcdir)/mkbinutilspec
+MKBINUTILSSPEC = $(SHELL) $(top_builddir)/mkbinutilspec
-MKBINUTILSSPEC_DEPS = ../mkbinutilspec binutils.spec.in ../setup.cache
+MKBINUTILSSPEC_DEPS = \
+$(top_builddir)/mkbinutilspec binutils.spec.in $(top_builddir)/setup.cache
i386-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . i386-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . i386-rtems
sh-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . sh-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . sh-rtems
powerpc-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . powerpc-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . powerpc-rtems
sparc-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . sparc-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . sparc-rtems
m68k-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . m68k-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . m68k-rtems
mips64orion-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . mips64orion-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . mips64orion-rtems
i960-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . i960-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . i960-rtems
hppa1.1-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
- $(MKBINUTILSSPEC) -cfg ../setup.cache -o . hppa1.1-rtems
+ $(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache -o . hppa1.1-rtems
TEMPLATES = \
binutils.spec.in
diff --git a/scripts/binutils/Makefile.in b/scripts/binutils/Makefile.in
index db2758c7d4..fc6640b762 100644
--- a/scripts/binutils/Makefile.in
+++ b/scripts/binutils/Makefile.in
@@ -76,7 +76,7 @@ MKBINUTILSSPEC_DEPS = ../mkbinutilspec binutils.spec.in ../setup.cache
TEMPLATES = binutils.spec.in
-RPM_SPECS_DATA = i386-rtems-$(BINUTILSVERS).spec sh-rtems-$(BINUTILSVERS).spec powerpc-rtems-$(BINUTILSVERS).spec sparc-rtems-$(BINUTILSVERS).spec m68k-rtems-$(BINUTILSVERS).spec mips64orion-rtems-$(BINUTILSVERS).spec i960-rtems-$(BINUTILSVERS).spec hppa1.1-rtems-$(BINUTILSVERS).spec
+RPM_SPECS_DATA = i386-rtems-$(BINUTILSVERS).spec sh-rtems-$(BINUTILSVERS).spec sh-rtemself-$(BINUTILSVERS).spec powerpc-rtems-$(BINUTILSVERS).spec sparc-rtems-$(BINUTILSVERS).spec m68k-rtems-$(BINUTILSVERS).spec m68k-rtemself-$(BINUTILSVERS).spec mips64orion-rtems-$(BINUTILSVERS).spec i960-rtems-$(BINUTILSVERS).spec hppa1.1-rtems-$(BINUTILSVERS).spec
noinst_DATA = $(TEMPLATES)
@@ -218,6 +218,9 @@ i386-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
sh-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
$(MKBINUTILSSPEC) -cfg ../setup.cache -o . sh-rtems
+sh-rtemself-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
+ $(MKBINUTILSSPEC) -cfg ../setup.cache -o . sh-rtemself
+
powerpc-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
$(MKBINUTILSSPEC) -cfg ../setup.cache -o . powerpc-rtems
@@ -227,6 +230,9 @@ sparc-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
m68k-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
$(MKBINUTILSSPEC) -cfg ../setup.cache -o . m68k-rtems
+m68k-rtemself-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
+ $(MKBINUTILSSPEC) -cfg ../setup.cache -o . m68k-rtemself
+
mips64orion-rtems-$(BINUTILSVERS).spec: $(MKBINUTILSSPEC_DEPS)
$(MKBINUTILSSPEC) -cfg ../setup.cache -o . mips64orion-rtems
diff --git a/scripts/binutils/binutils.spec.in b/scripts/binutils/binutils.spec.in
index bc0a5b8837..bbcad0e7bd 100644
--- a/scripts/binutils/binutils.spec.in
+++ b/scripts/binutils/binutils.spec.in
@@ -93,7 +93,7 @@ echo RPM_BUILD_ROOT=${RPM_BUILD_ROOT}
fi
%files -f files
-%dir /opt/rtems/info
+%docdir /opt/rtems/info
%doc /opt/rtems/info/dir
%doc /opt/rtems/info/as.info.gz
%doc /opt/rtems/info/as.info-?.gz
@@ -106,8 +106,8 @@ echo RPM_BUILD_ROOT=${RPM_BUILD_ROOT}
%doc /opt/rtems/info/gasp.info.gz
%doc /opt/rtems/info/standards.info.gz
-%dir /opt/rtems/man
-%dir /opt/rtems/man/man1
+%docdir /opt/rtems/man
+%docdir /opt/rtems/man/man1
%doc /opt/rtems/man/man1/@target_alias@-*.1
%dir /opt/rtems/bin
diff --git a/scripts/buildall.in b/scripts/buildall.in
index 5e5d741f23..7aa8d8dc9e 100755
--- a/scripts/buildall.in
+++ b/scripts/buildall.in
@@ -4,14 +4,14 @@
#
RTEMS_DIR=`dirname $0`
-CFG=./user.cfg
+CFG=./setup.cache
dst=@RPM_SPECSdir@
usage()
{
echo "$0 [options] <target_alias>"
echo " options:"
- echo " -cfg <user.cfg>"
+ echo " -cfg <setup.cache>"
echo " -o <rpm-spec-dir>"
exit 1 ;
}
@@ -60,12 +60,12 @@ gcc=${gcc_version}
gdb=${gdb_version}
newlib=${newlib_version}
# also use binutils_rpm_release
-buildroot=/opt/tmp
+buildroot=/tmp
testing=no
-do_binutils=yes
-do_gdb=yes
-do_gccnewlib=yes
+do_binutils=no
+do_gdb=no
+do_gccnewlib=no
#
# Now get started
@@ -100,6 +100,10 @@ if [ ${testing} = no ] ; then
for target in ${TARGETS}
do
tspecs=`find . -name "${target}*"`
+ if [ "X${tspecs}" = "X" ] ; then
+ echo RPM specifications were not generated for ${tspec}.
+ exit 1
+ fi
${ECHO} cp -r ${tspecs} ${dst}
done
fi
@@ -119,7 +123,7 @@ do
rpm -ba ${specfile} >${logfile} 2>&1
fi
${ECHO} rm -rf ${dst}/../BUILD/${target}-binutils*
- ${ECHO} rm -rf ${buildroot}/opt
+ ${ECHO} rm -rf ${buildroot}/opt/rtems
else
echo Skipping binutils for ${target}
fi
@@ -144,9 +148,10 @@ do
echo "rpm -ba ${specfile} >${logfile} 2>&1"
if [ ${testing} = no ] ; then
rpm -ba ${specfile} >${logfile} 2>&1
+exit 0
fi
${ECHO} rm -rf ${dst}/../BUILD/${target}-gcc*
- ${ECHO} rm -rf ${buildroot}/opt
+ ${ECHO} rm -rf ${buildroot}/opt/rtems
echo uninstalling binutils for ${target}
if [ ${testing} = no ] ; then
@@ -169,7 +174,7 @@ do
rpm -ba ${specfile} >${logfile} 2>&1
fi
${ECHO} rm -rf ${dst}/../BUILD/${target}-gdb*
- ${ECHO} rm -rf ${buildroot}/opt
+ ${ECHO} rm -rf ${buildroot}/opt/rtems
else
echo Skipping gdb for ${target}
fi
diff --git a/scripts/configure.in b/scripts/configure.in
index aaa3f10221..be20f53271 100644
--- a/scripts/configure.in
+++ b/scripts/configure.in
@@ -1,7 +1,11 @@
+## $Id$
+
AC_INIT(binutils)
-AM_INIT_AUTOMAKE(scripts,19991020-1,no)
+AM_INIT_AUTOMAKE(scripts,19991021-0,no)
+
+RTEMS_CHECK_VERSION(..)
-test -f ./setup.cache || cp ./setup.def ./setup.cache
+test -f ./setup.cache || cp ${srcdir}/setup.def ./setup.cache
. ./setup.cache
# Some linux distributions use /usr/src/packages
@@ -18,7 +22,7 @@ elif test -d /usr/src/SPECS/;
then
RPM_SPECSdir=/usr/src/SPECS;
fi
-if test x"$RPM_SPECSdir" = x; then
+if test x"$RPM_SPECSdir" = x"" ; then
AC_MSG_ERROR(not found)
fi
AC_MSG_RESULT($RPM_SPECSdir)
@@ -30,7 +34,7 @@ BINUTILSVERS="binutils-${binutils_version}"
AC_SUBST(BINUTILSVERS)
GDBVERS="gdb-${gdb_version}"
AC_SUBST(GDBVERS)
-BSPVERS="RTEMS-no_version_yet"
+BSPVERS="${RTEMS_VERSION}"
AC_SUBST(BSPVERS)
AC_OUTPUT(
diff --git a/scripts/gccnewlib/Makefile.am b/scripts/gccnewlib/Makefile.am
index 21d17de771..c3f6f467d7 100644
--- a/scripts/gccnewlib/Makefile.am
+++ b/scripts/gccnewlib/Makefile.am
@@ -1,33 +1,35 @@
+## $Id$
+
AUTOMAKE_OPTIONS = foreign
-MKGCCNEWLIBSPEC = $(SHELL) ../mkgccnewlibspec
+MKGCCNEWLIBSPEC = $(SHELL) $(top_builddir)/mkgccnewlibspec
MKGCCNEWLIBSPEC_DEPS = \
- ../mkgccnewlibspec gccnewlib.spec.in ../setup.cache
+ $(top_builddir)/mkgccnewlibspec gccnewlib.spec.in $(top_builddir)/setup.cache
i386-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . i386-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . i386-rtems
sh-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . sh-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . sh-rtems
powerpc-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . powerpc-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . powerpc-rtems
sparc-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . sparc-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . sparc-rtems
m68k-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . m68k-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . m68k-rtems
mips64orion-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . mips64orion-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . mips64orion-rtems
i960-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . i960-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . i960-rtems
hppa1.1-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
- $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . hppa1.1-rtems
+ $(MKGCCNEWLIBSPEC) -cfg $(top_builddir)/setup.cache -o . hppa1.1-rtems
TEMPLATES = \
gccnewlib.spec.in
diff --git a/scripts/gccnewlib/Makefile.in b/scripts/gccnewlib/Makefile.in
index ca3c797e44..3491b8bb2b 100644
--- a/scripts/gccnewlib/Makefile.in
+++ b/scripts/gccnewlib/Makefile.in
@@ -77,7 +77,7 @@ MKGCCNEWLIBSPEC_DEPS = ../mkgccnewlibspec gccnewlib.spec.in ../setup.cache
TEMPLATES = gccnewlib.spec.in
-RPM_SPECS_DATA = i386-rtems-$(GCCNEWLIBVERS).spec sh-rtems-$(GCCNEWLIBVERS).spec powerpc-rtems-$(GCCNEWLIBVERS).spec sparc-rtems-$(GCCNEWLIBVERS).spec m68k-rtems-$(GCCNEWLIBVERS).spec mips64orion-rtems-$(GCCNEWLIBVERS).spec i960-rtems-$(GCCNEWLIBVERS).spec hppa1.1-rtems-$(GCCNEWLIBVERS).spec
+RPM_SPECS_DATA = i386-rtems-$(GCCNEWLIBVERS).spec sh-rtems-$(GCCNEWLIBVERS).spec sh-rtemself-$(GCCNEWLIBVERS).spec powerpc-rtems-$(GCCNEWLIBVERS).spec sparc-rtems-$(GCCNEWLIBVERS).spec m68k-rtems-$(GCCNEWLIBVERS).spec m68k-rtemself-$(GCCNEWLIBVERS).spec mips64orion-rtems-$(GCCNEWLIBVERS).spec i960-rtems-$(GCCNEWLIBVERS).spec hppa1.1-rtems-$(GCCNEWLIBVERS).spec
noinst_DATA = $(TEMPLATES)
@@ -219,6 +219,9 @@ i386-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
sh-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
$(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . sh-rtems
+sh-rtemself-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
+ $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . sh-rtemself
+
powerpc-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
$(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . powerpc-rtems
@@ -228,6 +231,9 @@ sparc-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
m68k-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
$(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . m68k-rtems
+m68k-rtemself-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
+ $(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . m68k-rtemself
+
mips64orion-rtems-$(GCCNEWLIBVERS).spec: $(MKGCCNEWLIBSPEC_DEPS)
$(MKGCCNEWLIBSPEC) -cfg ../setup.cache -o . mips64orion-rtems
diff --git a/scripts/gccnewlib/gccnewlib.spec.in b/scripts/gccnewlib/gccnewlib.spec.in
index f2bc2ce252..8394c7bd9c 100644
--- a/scripts/gccnewlib/gccnewlib.spec.in
+++ b/scripts/gccnewlib/gccnewlib.spec.in
@@ -74,17 +74,46 @@ echo RPM_BUILD_ROOT=${RPM_BUILD_ROOT}
make prefix=$RPM_BUILD_ROOT/opt/rtems install
cd @target_alias@/newlib
make prefix=$RPM_BUILD_ROOT/opt/rtems install-info
-# gzip info files
+
+ # cd back to build/
+ cd ../..
+
+ # gzip info files
gzip -f $RPM_BUILD_ROOT/opt/rtems/info/*.info 2>/dev/null
gzip -f $RPM_BUILD_ROOT/opt/rtems/info/*.info-? 2>/dev/null
gzip -f $RPM_BUILD_ROOT/opt/rtems/info/*.info-?? 2>/dev/null
-
+
+ rm -f files
+
+ # collect c++ headers
+ if test -d $RPM_BUILD_ROOT/opt/rtems/include/g++-3; then
+ find $RPM_BUILD_ROOT/opt/rtems/include/g++-3 \
+ -type d | \
+ sed -e "s,^$RPM_BUILD_ROOT,%dir ,g" >> files
+ find $RPM_BUILD_ROOT/opt/rtems/include/g++-3 \
+ \( -type f -o -type l \) | \
+ sed -e "s,^$RPM_BUILD_ROOT,,g" >> files
+ fi
+
+ # collect target gcc-lib
if test -d "$RPM_BUILD_ROOT/opt/rtems/lib/gcc-lib/@target_alias@/@gcc_version@"; \
then
- find "$RPM_BUILD_ROOT/opt/rtems/lib/gcc-lib/@target_alias@/@gcc_version@" -type d | \
- sed -e "s,^$RPM_BUILD_ROOT,%dir ,g" > files.gcc-lib
- find "$RPM_BUILD_ROOT/opt/rtems/lib/gcc-lib/@target_alias@/@gcc_version@" -type f | \
- sed -e "s,^$RPM_BUILD_ROOT,,g" >> files.gcc-lib
+ find "$RPM_BUILD_ROOT/opt/rtems/lib/gcc-lib/@target_alias@/@gcc_version@" \
+ -type d | sed -e "s,^$RPM_BUILD_ROOT,%dir ,g" >> files
+ find "$RPM_BUILD_ROOT/opt/rtems/lib/gcc-lib/@target_alias@/@gcc_version@" \
+ \( -type f -o -type l \) \
+ | sed -e "s,^$RPM_BUILD_ROOT,,g" >> files
+ fi
+
+ # collect target files
+ if test -d "$RPM_BUILD_ROOT/opt/rtems/@target_alias@"; \
+ then
+ find "$RPM_BUILD_ROOT/opt/rtems/@target_alias@" \
+ -type d | \
+ sed -e "s,^$RPM_BUILD_ROOT,%dir ,g" >> files
+ find "$RPM_BUILD_ROOT/opt/rtems/@target_alias@" \
+ \( -type f -o -type l \) | \
+ sed -e "s,^$RPM_BUILD_ROOT,,g" >> files
fi
%post
@@ -107,7 +136,7 @@ echo RPM_BUILD_ROOT=${RPM_BUILD_ROOT}
done
fi
-%files -f files.g++ -f files.gcc-lib
+%files -f build/files
%docdir /opt/rtems/info
%doc /opt/rtems/info/dir
%doc /opt/rtems/info/chill.info*
@@ -126,18 +155,23 @@ echo RPM_BUILD_ROOT=${RPM_BUILD_ROOT}
%dir /opt/rtems/bin
/opt/rtems/bin/cpp
+/opt/rtems/bin/jv-scan
+/opt/rtems/bin/gcov
+/opt/rtems/bin/jcf-dump
+/opt/rtems/bin/gcjh
/opt/rtems/bin/@target_alias@-c++
/opt/rtems/bin/@target_alias@-g++
/opt/rtems/bin/@target_alias@-gcc
/opt/rtems/bin/@target_alias@-gcj
+/opt/rtems/bin/@target_alias@-chill
+/opt/rtems/bin/@target_alias@-g77
+/opt/rtems/bin/@target_alias@-protoize
+/opt/rtems/bin/@target_alias@-unprotoize
%dir /opt/rtems/lib
/opt/rtems/lib/libiberty*
-%dir /opt/rtems/lib/include
+%dir /opt/rtems/include
%dir /opt/rtems/lib/gcc-lib
%dir /opt/rtems/lib/gcc-lib/@target_alias@
-# /opt/rtems/@target_alias@/include
-# /opt/rtems/@target_alias@/sys-include
-/opt/rtems/@target_alias@/lib
diff --git a/scripts/gdb/Makefile.am b/scripts/gdb/Makefile.am
index 01d23117a6..ed3f51d7a9 100644
--- a/scripts/gdb/Makefile.am
+++ b/scripts/gdb/Makefile.am
@@ -1,32 +1,33 @@
AUTOMAKE_OPTIONS = foreign
-MKGDBSPEC = $(SHELL) $(top_srcdir)/mkgdbspec
+MKGDBSPEC = $(SHELL) $(top_builddir)/mkgdbspec
-MKGDBSPEC_DEPS = ../mkgdbspec gdb.spec.in ../setup.cache
+MKGDBSPEC_DEPS = \
+$(top_builddir)/mkgdbspec gdb.spec.in $(top_builddir)/setup.cache
i386-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . i386-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . i386-rtems
sh-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . sh-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . sh-rtems
powerpc-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . powerpc-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . powerpc-rtems
sparc-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . sparc-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . sparc-rtems
m68k-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . m68k-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . m68k-rtems
mips64orion-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . mips64orion-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . mips64orion-rtems
i960-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . i960-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . i960-rtems
hppa1.1-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
- $(MKGDBSPEC) -cfg ../setup.cache -o . hppa1.1-rtems
+ $(MKGDBSPEC) -cfg $(top_builddir)/setup.cache -o . hppa1.1-rtems
TEMPLATES = \
gdb.spec.in
diff --git a/scripts/gdb/Makefile.in b/scripts/gdb/Makefile.in
index a3dbc7ee22..07c4e73b64 100644
--- a/scripts/gdb/Makefile.in
+++ b/scripts/gdb/Makefile.in
@@ -76,7 +76,7 @@ MKGDBSPEC_DEPS = ../mkgdbspec gdb.spec.in ../setup.cache
TEMPLATES = gdb.spec.in
-RPM_SPECS_DATA = i386-rtems-$(GDBVERS).spec sh-rtems-$(GDBVERS).spec powerpc-rtems-$(GDBVERS).spec sparc-rtems-$(GDBVERS).spec m68k-rtems-$(GDBVERS).spec mips64orion-rtems-$(GDBVERS).spec i960-rtems-$(GDBVERS).spec hppa1.1-rtems-$(GDBVERS).spec
+RPM_SPECS_DATA = i386-rtems-$(GDBVERS).spec sh-rtems-$(GDBVERS).spec sh-rtemself-$(GDBVERS).spec powerpc-rtems-$(GDBVERS).spec sparc-rtems-$(GDBVERS).spec m68k-rtems-$(GDBVERS).spec m68k-rtemself-$(GDBVERS).spec mips64orion-rtems-$(GDBVERS).spec i960-rtems-$(GDBVERS).spec hppa1.1-rtems-$(GDBVERS).spec
noinst_DATA = $(TEMPLATES)
@@ -218,6 +218,9 @@ i386-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
sh-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
$(MKGDBSPEC) -cfg ../setup.cache -o . sh-rtems
+sh-rtemself-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
+ $(MKGDBSPEC) -cfg ../setup.cache -o . sh-rtemself
+
powerpc-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
$(MKGDBSPEC) -cfg ../setup.cache -o . powerpc-rtems
@@ -227,6 +230,9 @@ sparc-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
m68k-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
$(MKGDBSPEC) -cfg ../setup.cache -o . m68k-rtems
+m68k-rtemself-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
+ $(MKGDBSPEC) -cfg ../setup.cache -o . m68k-rtemself
+
mips64orion-rtems-$(GDBVERS).spec: $(MKGDBSPEC_DEPS)
$(MKGDBSPEC) -cfg ../setup.cache -o . mips64orion-rtems
diff --git a/scripts/gdb/gdb.spec.in b/scripts/gdb/gdb.spec.in
index fdec2c6810..c08e71bcba 100644
--- a/scripts/gdb/gdb.spec.in
+++ b/scripts/gdb/gdb.spec.in
@@ -49,11 +49,6 @@ test -d build || mkdir build
../gdb-@gdb_version@/configure --target=@target_alias@ \
--verbose --prefix=/opt/rtems
- test -d $RPM_BUILD_ROOT/opt \
- || mkdir $RPM_BUILD_ROOT/opt
- test -d $RPM_BUILD_ROOT/opt/rtems \
- || mkdir $RPM_BUILD_ROOT/opt/rtems
-
make all
make info
@@ -83,22 +78,25 @@ test -d build || mkdir build
fi
%files
-%dir /opt/rtems/info
+%docdir /opt/rtems/info
%doc /opt/rtems/info/gdb.info*
%doc /opt/rtems/info/mmalloc.info*
%doc /opt/rtems/info/readline.info*
-%dir /opt/rtems/man
-%dir /opt/rtems/man/man1
+%docdir /opt/rtems/man
+%docdir /opt/rtems/man/man1
%doc /opt/rtems/man/man1/@target_alias@-gdb.1
%dir /opt/rtems/include
-/opt/rtems/include/bfd.h
-/opt/rtems/include/bfdlink.h
+# We install libbfd from binutils
+# /opt/rtems/include/bfd.h
+# /opt/rtems/include/bfdlink.h
%dir /opt/rtems/lib
-/opt/rtems/lib/libbfd*
-/opt/rtems/lib/libiberty*
+# We install libbfd from binutils
+# /opt/rtems/lib/libbfd*
+# We use libiberty from gcc
+# /opt/rtems/lib/libiberty*
%dir /opt/rtems/bin
/opt/rtems/bin/@target_alias@-gdb
diff --git a/scripts/mkbinutils_subpackage_version b/scripts/mkbinutils_subpackage_version
index ea2dcef272..00f42fe928 100755
--- a/scripts/mkbinutils_subpackage_version
+++ b/scripts/mkbinutils_subpackage_version
@@ -61,7 +61,7 @@ echo "Summary: binutils for RTEMS"
echo "Source0: binutils-990901.tar.gz"
echo "Patch0: binutils-990901-rtems-19991015.diff"
echo ""
-echo "Buildroot: /opt/tmp"
+echo "Buildroot: /tmp"
echo "# Patch:"
echo "%description"
echo "RTEMS is an open source operating system for embedded systems."
diff --git a/scripts/mkbinutilspec.in b/scripts/mkbinutilspec.in
index 18c087f200..05a38bf853 100644
--- a/scripts/mkbinutilspec.in
+++ b/scripts/mkbinutilspec.in
@@ -3,16 +3,16 @@
# Usage: mkbinutilspec CPU
#
-RTEMS_DIR=`dirname $0`
+RTEMS_DIR=`dirname $0`/@top_srcdir@
-CFG=user.cfg
+CFG=setup.cache
dst=@RPM_SPECSdir@
usage()
{
echo "$0 [options] <target_alias>"
echo " options:"
- echo " -cfg <user.cfg>"
+ echo " -cfg <setup.cache>"
echo " -o <rpm-spec-dir>"
exit 1 ;
}
diff --git a/scripts/mkbspspec.in b/scripts/mkbspspec.in
index 49dbf459ac..5cc5cb82c3 100644
--- a/scripts/mkbspspec.in
+++ b/scripts/mkbspspec.in
@@ -1,31 +1,59 @@
#!/bin/sh
#
-RTEMS_DIR=`dirname $0`
-RTEMS_VERSION=`grep Version ${RTEMS_DIR}/../VERSION | \
-sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
-
-bsp=$1
-target_alias=$2
-release=0
-
-# Some linux distributions use /usr/src/packages
-# redhat uses /usr/src/redhat
-# others might use /usr/src
-if test -d /usr/src/packages/SPECS;
-then
-dst=/usr/src/packages/SPECS;
-elif test -d /usr/src/redhat/SPECS;
- then
-dst=/usr/src/redhat/SPECS;
-elif test -d /usr/src/SPECS/;
+RTEMS_DIR=`dirname $0`/@top_srcdir@
+RTEMS_VERSION=@RTEMS_VERSION@
+
+CFG=setup.cache
+dst=@RPM_SPECSdir@
+
+usage()
+{
+ echo "$0 [options] <target_alias> <bsp>"
+ echo " options:"
+ echo " -cfg <setup.cache>"
+ echo " -o <rpm-spec-dir>"
+ exit 1 ;
+}
+
+while test $# -ge 3; do
+case $1 in
+-cfg)
+ shift
+ CFG=$1
+ shift
+ ;;
+-o)
+ shift
+ dst=$1
+ shift
+ ;;
+-*)
+ echo "invalid option $1";
+ usage
+ ;;
+esac
+done
+
+if test ! $# -eq 2;
then
-dst=/usr/src/SPECS;
+ echo "Invalid number of arguments"
+ usage
fi
+# target to build for
+target_alias=$1
+bsp=$2
+
+. ./$CFG
+
+specfile=${dst}/$target_alias-$bsp-$RTEMS_VERSION.spec
+
sed -e "s%@Version@%${RTEMS_VERSION}%g" \
-e "s%@bsp@%${bsp}%g" \
--e "s%@Release@%${release}%g" \
+-e "s%@Release@%${rtems_release}%g" \
-e "s%@target_alias@%${target_alias}%g" \
-< ${RTEMS_DIR}/rtems.spec.in \
-> ${dst}/rtems-$target_alias-$bsp.spec
+< ${RTEMS_DIR}/rtems/rtems.spec.in \
+> ${specfile}
+
+echo Generated ${specfile}
diff --git a/scripts/mkgccnewlibspec.in b/scripts/mkgccnewlibspec.in
index d9abb70558..aaf0f3d5cd 100644
--- a/scripts/mkgccnewlibspec.in
+++ b/scripts/mkgccnewlibspec.in
@@ -3,16 +3,16 @@
# Usage: mktoolspec CPU
#
-RTEMS_DIR=`dirname $0`
+RTEMS_DIR=`dirname $0`/@top_srcdir@
-CFG=user.cfg
+CFG=setup.cache
dst=@RPM_SPECSdir@
usage()
{
echo "$0 [options] <target_alias>"
echo " options:"
- echo " -cfg <user.cfg>"
+ echo " -cfg <setup.cache>"
echo " -o <rpm-spec-dir>"
exit 1 ;
}
diff --git a/scripts/mkgdbspec.in b/scripts/mkgdbspec.in
index 0b4cfbdfd0..c86537528d 100644
--- a/scripts/mkgdbspec.in
+++ b/scripts/mkgdbspec.in
@@ -3,15 +3,16 @@
# Usage: mkgdbspec CPU
#
-RTEMS_DIR=`dirname $0`
-CFG=user.cfg
+RTEMS_DIR=`dirname $0`/@top_srcdir@
+
+CFG=setup.cache
dst=@RPM_SPECSdir@
usage()
{
echo "$0 [options] <target_alias>"
echo " options:"
- echo " -cfg <user.cfg>"
+ echo " -cfg <setup.cache>"
echo " -o <rpm-spec-dir>"
exit 1 ;
}
diff --git a/scripts/rtems/Makefile.am b/scripts/rtems/Makefile.am
index 53239483a6..94ff330145 100644
--- a/scripts/rtems/Makefile.am
+++ b/scripts/rtems/Makefile.am
@@ -1,46 +1,45 @@
AUTOMAKE_OPTIONS = foreign
-# MKBSPSPEC = $(SHELL) $(top_srcdir)/mkbspspec
-MKBSPSPEC = @echo $(top_srcdir)/mkbspspec
+MKBSPSPEC = $(SHELL) $(top_builddir)/mkbspspec
-MKBSPSPEC_DEPS = ../mkbspspec rtems.spec.in ../setup.cache
+MKBSPSPEC_DEPS = $(top_builddir)/mkbspspec rtems.spec.in $(top_builddir)/setup.cache
-i386-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . i386-rtems
+i386-rtems-pc386-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . i386-rtems pc386
-sh-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . sh-rtems
+sh-rtems-gensh1-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . sh-rtems gensh1
-powerpc-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . powerpc-rtems
+powerpc-rtems-mcp750-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . powerpc-rtems mcp750
-sparc-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . sparc-rtems
+sparc-rtems-erc32-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . sparc-rtems erc32
-m68k-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . m68k-rtems
+m68k-rtems-gen68360-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . m68k-rtems gen68360
-mips64orion-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . mips64orion-rtems
+mips64orion-rtems-p4600-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . mips64orion-rtems p4600
-i960-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . i960-rtems
+i960-rtems-cvme961-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . i960-rtems cvme961
-hppa1.1-rtems-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
- $(MKBSPSPEC) -cfg ../setup.cache -o . hppa1.1-rtems
+hppa1.1-rtems-simhppa-$(BSPVERS).spec: $(MKBSPSPEC_DEPS)
+ $(MKBSPSPEC) -cfg $(top_builddir)/setup.cache -o . hppa1.1-rtems simhppa
TEMPLATES = \
rtems.spec.in
RPM_SPECS_DATA = \
-i386-rtems-$(BSPVERS).spec \
-sh-rtems-$(BSPVERS).spec \
-powerpc-rtems-$(BSPVERS).spec \
-sparc-rtems-$(BSPVERS).spec \
-m68k-rtems-$(BSPVERS).spec \
-mips64orion-rtems-$(BSPVERS).spec \
-i960-rtems-$(BSPVERS).spec \
-hppa1.1-rtems-$(BSPVERS).spec
+i386-rtems-pc386-$(BSPVERS).spec \
+sh-rtems-gensh1-$(BSPVERS).spec \
+powerpc-rtems-mcp750-$(BSPVERS).spec \
+sparc-rtems-erc32-$(BSPVERS).spec \
+m68k-rtems-gen68360-$(BSPVERS).spec \
+mips64orion-rtems-p4600-$(BSPVERS).spec \
+i960-rtems-cvme961-$(BSPVERS).spec \
+hppa1.1-rtems-simhppa-$(BSPVERS).spec
noinst_DATA = \
$(TEMPLATES)
diff --git a/scripts/setup b/scripts/setup
index 7477f80887..11d5712757 100755
--- a/scripts/setup
+++ b/scripts/setup
@@ -4,11 +4,16 @@ CFG=setup.cache
# RTEMS tools setup
-test -f ./CFG || echo "restoring default setup.cache" && cp ./setup.def ./$CFG
+if test ! -f ./$CFG;
+then
+ echo -n "restoring default setup.cache .."
+ cp ./setup.def ./$CFG
+ echo " done"
+fi
echo -n "loading setup from ./$CFG .."
. ./$CFG
-echo "done"
+echo " done"
echo
menu_setup()