forked from Imagelibrary/rtems
Remove (Obsolete)
This commit is contained in:
@@ -1,29 +0,0 @@
|
|||||||
#
|
|
||||||
# History of the binutils RPMs
|
|
||||||
#
|
|
||||||
# $Id$
|
|
||||||
#
|
|
||||||
|
|
||||||
RPM Version binutils-2.10-3
|
|
||||||
===========================
|
|
||||||
+ Add reloc16.c fix for H8.
|
|
||||||
|
|
||||||
binutils-2.10-rtems-20001102.diff
|
|
||||||
- adds reloc16.c patch from Nick Clifton <nickc@redhat.com>
|
|
||||||
|
|
||||||
RPM Version binutils-2.10-1
|
|
||||||
===========================
|
|
||||||
+ Add initial support for the ARM.
|
|
||||||
+ Adds support for the h8300.
|
|
||||||
|
|
||||||
binutils-2.10-rtems-20000628.diff
|
|
||||||
- adds h8300 support.
|
|
||||||
|
|
||||||
RPM Version binutils-2.9.5.0.24-1
|
|
||||||
=================================
|
|
||||||
+ Corrects the object format for numerous RTEMS targets. Released with
|
|
||||||
RTEMS 4.5.0-beta3a.
|
|
||||||
|
|
||||||
binutils-2.9.5.0.24-rtems-20000207.diff
|
|
||||||
- base line
|
|
||||||
|
|
||||||
@@ -1,74 +0,0 @@
|
|||||||
##
|
|
||||||
## $Id$
|
|
||||||
##
|
|
||||||
|
|
||||||
include $(top_srcdir)/common/common.am
|
|
||||||
|
|
||||||
MKBINUTILSSPEC = $(SHELL) ./mkspec
|
|
||||||
|
|
||||||
SUBPACKAGES = header.add
|
|
||||||
SUBPACKAGES += $(top_builddir)/common/common.add binutils.add
|
|
||||||
SUBPACKAGES += $(top_builddir)/common/clean.add
|
|
||||||
SUBPACKAGES += target-binutils.add
|
|
||||||
SUBPACKAGES += base-binutils.add
|
|
||||||
|
|
||||||
binutils.spec.in: $(SUBPACKAGES)
|
|
||||||
cat $^ > $@
|
|
||||||
CLEANFILES = binutils.spec.in
|
|
||||||
RPM_SPECS_DATA =
|
|
||||||
|
|
||||||
MKBINUTILSSPEC_DEPS = mkspec binutils.spec.in $(top_builddir)/setup.cache
|
|
||||||
|
|
||||||
@rpmprefix@arm-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache arm-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@arm-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@h8300-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache h8300-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@h8300-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@i386-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache i386-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@i386-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@m68k-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache m68k-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@m68k-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@mips-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache mips-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@mips-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@mips64-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache mips64-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@mips64-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@powerpc-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache powerpc-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@powerpc-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@sh-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache sh-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@sh-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@sh-rtemscoff@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache sh-rtemscoff@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@sh-rtemscoff@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@sparc-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache sparc-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@sparc-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@tic4x-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache tic4x-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@tic4x-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
@rpmprefix@avr-rtems@osversion@-binutils.spec: $(MKBINUTILSSPEC_DEPS)
|
|
||||||
$(MKBINUTILSSPEC) -cfg $(top_builddir)/setup.cache avr-rtems@osversion@ > $@
|
|
||||||
RPM_SPECS_DATA += @rpmprefix@avr-rtems@osversion@-binutils.spec
|
|
||||||
|
|
||||||
CLEANFILES += $(RPM_SPECS_DATA)
|
|
||||||
|
|
||||||
EXTRA_DIST = $(SUBPACKAGES)
|
|
||||||
|
|
||||||
include $(top_srcdir)/../automake/local.am
|
|
||||||
@@ -1,56 +0,0 @@
|
|||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
# ==============================================================
|
|
||||||
# rtems-base-binutils
|
|
||||||
# ==============================================================
|
|
||||||
%package -n @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
Summary: base package for rtems binutils
|
|
||||||
Group: %{rpmgroup}
|
|
||||||
Requires(post): /sbin/install-info
|
|
||||||
Requires(preun): /sbin/install-info
|
|
||||||
|
|
||||||
%description -n @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
|
|
||||||
RTEMS is an open source operating system for embedded systems.
|
|
||||||
|
|
||||||
This is the base for binutils regardless of target CPU.
|
|
||||||
|
|
||||||
%post -n @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/as.info.gz
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/bfd.info.gz
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/binutils.info.gz
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/ld.info.gz
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/standards.info.gz
|
|
||||||
%if "%{binutils_version}" < "2.13"
|
|
||||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/gasp.info.gz
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%preun -n @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
if [ $1 -eq 0 ]; then
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/as.info.gz
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/bfd.info.gz
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/binutils.info.gz
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/ld.info.gz
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/standards.info.gz
|
|
||||||
%if "%{binutils_version}" < "2.13"
|
|
||||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gasp.info.gz
|
|
||||||
%endif
|
|
||||||
fi
|
|
||||||
|
|
||||||
%files -n @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
%defattr(-,root,root)
|
|
||||||
%dir %{_infodir}
|
|
||||||
%ghost %{_infodir}/dir
|
|
||||||
%{_infodir}/as.info*
|
|
||||||
%{_infodir}/bfd.info*
|
|
||||||
%{_infodir}/binutils.info*
|
|
||||||
%{_infodir}/ld.info*
|
|
||||||
%{_infodir}/standards.info*
|
|
||||||
|
|
||||||
%if "%{binutils_version}" < "2.13"
|
|
||||||
%{_infodir}/gasp.info*
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%dir %{_prefix}/share
|
|
||||||
%dir %{_prefix}/share/locale
|
|
||||||
%endif
|
|
||||||
|
|
||||||
@@ -1,146 +0,0 @@
|
|||||||
|
|
||||||
%define binutils_version @binutils_version@
|
|
||||||
%define binutils_target @target_alias@
|
|
||||||
|
|
||||||
Name: @rpmprefix@%{binutils_target}-binutils
|
|
||||||
Summary: Binutils for target %{binutils_target}
|
|
||||||
Group: %{rpmgroup}
|
|
||||||
Version: %{binutils_version}
|
|
||||||
Release: @Release@
|
|
||||||
License: GPL/LGPL
|
|
||||||
URL: http://sources.redhat.com/binutils
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
||||||
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
# Required for building the infos
|
|
||||||
BuildRequires: /sbin/install-info
|
|
||||||
BuildRequires: texinfo >= 4.2
|
|
||||||
%endif
|
|
||||||
BuildRequires: flex
|
|
||||||
|
|
||||||
Source0: ftp://ftp.gnu.org/pub/gnu/binutils/binutils-%{binutils_version}@binutils_suffix@
|
|
||||||
@PATCH1@
|
|
||||||
|
|
||||||
#
|
|
||||||
# The original sources are not included in the source RPM.
|
|
||||||
# If we included them, then the source RPMs for each target
|
|
||||||
# would duplicate MBs of source unnecessarily. This is
|
|
||||||
# a duplication of over 30 MBs of source for each of
|
|
||||||
# the more than 10 targets it is possible to build.
|
|
||||||
#
|
|
||||||
# You can get them yourself from the Internet and copy them to
|
|
||||||
# your /usr/src/redhat/SOURCES directory ($RPM_SOURCE_DIR).
|
|
||||||
# Or you can try the ftp options of rpm :-)
|
|
||||||
#
|
|
||||||
%{?!_with_sources:NoSource: 0}
|
|
||||||
|
|
||||||
# %description
|
|
||||||
#
|
|
||||||
# RTEMS is an open source operating system for embedded systems.
|
|
||||||
#
|
|
||||||
# This is binutils sources with patches for RTEMS.
|
|
||||||
|
|
||||||
%prep
|
|
||||||
%setup -q -c -T -n %{name}-%{version}
|
|
||||||
%setup -q -D -T -n %{name}-%{version} -a0
|
|
||||||
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
# Extract %%__os_install_post into os_install_post~
|
|
||||||
cat << \EOF >> os_install_post~
|
|
||||||
%__os_install_post
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# Generate customized brp-*scripts
|
|
||||||
cat os_install_post~ | while read a x y; do
|
|
||||||
case $a in
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
# Fix up brp-compress to handle %%_prefix != /usr
|
|
||||||
*/brp-compress*)
|
|
||||||
b=$(basename $a)
|
|
||||||
sed -e 's,\./usr/,./%{_prefix},' < $a > $b
|
|
||||||
chmod a+x $b
|
|
||||||
;;
|
|
||||||
%endif
|
|
||||||
esac
|
|
||||||
done
|
|
||||||
|
|
||||||
sed -e 's,^[ ]*/usr/lib/rpm.*/brp-compress,./brp-compress,' \
|
|
||||||
< os_install_post~ > os_install_post
|
|
||||||
%define __os_install_post . ./os_install_post
|
|
||||||
%endif
|
|
||||||
|
|
||||||
cd binutils-%{version}
|
|
||||||
%{?PATCH0:%patch0 -p1}
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
%build
|
|
||||||
mkdir -p build
|
|
||||||
cd build
|
|
||||||
CFLAGS="$RPM_OPT_FLAGS" \
|
|
||||||
../binutils-%{binutils_version}/configure \
|
|
||||||
--build=%_build --host=%_host \
|
|
||||||
--target=%{binutils_target} \
|
|
||||||
--verbose --disable-nls \
|
|
||||||
--prefix=%{_prefix} --bindir=%{_bindir} \
|
|
||||||
--includedir=%{_includedir} --libdir=%{_libdir} \
|
|
||||||
--mandir=%{_mandir} --infodir=%{_infodir} \
|
|
||||||
|
|
||||||
make all
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
make info
|
|
||||||
%endif
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
%install
|
|
||||||
rm -rf $RPM_BUILD_ROOT
|
|
||||||
|
|
||||||
cd build
|
|
||||||
make prefix=$RPM_BUILD_ROOT%{_prefix} \
|
|
||||||
bindir=$RPM_BUILD_ROOT%{_bindir} \
|
|
||||||
includedir=$RPM_BUILD_ROOT%{_includedir} \
|
|
||||||
libdir=$RPM_BUILD_ROOT%{_libdir} \
|
|
||||||
infodir=$RPM_BUILD_ROOT%{_infodir} \
|
|
||||||
mandir=$RPM_BUILD_ROOT%{_mandir} \
|
|
||||||
install
|
|
||||||
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
make prefix=$RPM_BUILD_ROOT%{_prefix} \
|
|
||||||
bindir=$RPM_BUILD_ROOT%{_bindir} \
|
|
||||||
includedir=$RPM_BUILD_ROOT%{_includedir} \
|
|
||||||
libdir=$RPM_BUILD_ROOT%{_libdir} \
|
|
||||||
infodir=$RPM_BUILD_ROOT%{_infodir} \
|
|
||||||
mandir=$RPM_BUILD_ROOT%{_mandir} \
|
|
||||||
install-info
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if "%{_prefix}" == "/usr"
|
|
||||||
# Conflict with a native binutils' infos
|
|
||||||
rm -rf $RPM_BUILD_ROOT%{_infodir}
|
|
||||||
%else
|
|
||||||
%if "%{binutils_version}" < "2.9.5"
|
|
||||||
rm -rf $RPM_BUILD_ROOT%{_infodir}/configure.info*
|
|
||||||
%endif
|
|
||||||
|
|
||||||
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
|
|
||||||
touch $RPM_BUILD_ROOT%{_infodir}/dir
|
|
||||||
|
|
||||||
# binutils does not install share/locale, however it uses it
|
|
||||||
mkdir -p $RPM_BUILD_ROOT%{_prefix}/share/locale
|
|
||||||
%endif
|
|
||||||
|
|
||||||
# We don't ship host files
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libiberty*
|
|
||||||
|
|
||||||
# manpages without corresponding tools
|
|
||||||
if test ! -f ${RPM_BUILD_ROOT}%{_bindir}/%{binutils_target}-dlltool%{_exeext}; then
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/%{binutils_target}-dlltool*
|
|
||||||
fi
|
|
||||||
if test ! -f ${RPM_BUILD_ROOT}%{_bindir}/%{binutils_target}-nlmconv%{_exeext}; then
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/%{binutils_target}-nlmconv*
|
|
||||||
fi
|
|
||||||
if test ! -f ${RPM_BUILD_ROOT}%{_bindir}/%{binutils_target}-windres%{_exeext}; then
|
|
||||||
rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/%{binutils_target}-windres*
|
|
||||||
fi
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
#
|
|
||||||
# spec file for building binutils for @target_alias@
|
|
||||||
#
|
|
||||||
# supported --with/--without options:
|
|
||||||
# --with sources build src.rpm instead of nosrc.rpm
|
|
||||||
#
|
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
#
|
|
||||||
# Usage: mkspec CPU
|
|
||||||
#
|
|
||||||
|
|
||||||
RTEMS_DIR=`dirname $0`/@top_srcdir@
|
|
||||||
|
|
||||||
CFG=../setup.cache
|
|
||||||
|
|
||||||
specsrc=${RTEMS_DIR}/binutils/binutils.spec.in
|
|
||||||
|
|
||||||
usage()
|
|
||||||
{
|
|
||||||
echo "$0 [options] <target_alias>"
|
|
||||||
echo " options:"
|
|
||||||
echo " -cfg <setup.cache>"
|
|
||||||
echo " -a <alternate specs.in>"
|
|
||||||
exit 1 ;
|
|
||||||
}
|
|
||||||
|
|
||||||
while test $# -ge 2; do
|
|
||||||
case $1 in
|
|
||||||
-cfg)
|
|
||||||
shift
|
|
||||||
CFG=$1
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
-a)
|
|
||||||
shift
|
|
||||||
specsrc=$1
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
-*)
|
|
||||||
echo "invalid option $1";
|
|
||||||
usage
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
done
|
|
||||||
|
|
||||||
if test ! $# -eq 1;
|
|
||||||
then
|
|
||||||
echo "Invalid number of arguments"
|
|
||||||
usage
|
|
||||||
fi
|
|
||||||
|
|
||||||
# target to build for
|
|
||||||
target_alias=$1
|
|
||||||
|
|
||||||
. ./$CFG
|
|
||||||
|
|
||||||
if test -n "${binutils_patch_version}"; then
|
|
||||||
PATCH1="Patch0: binutils-${binutils_version}-rtems-${binutils_patch_version}.diff"
|
|
||||||
fi
|
|
||||||
|
|
||||||
sed -e "s,@Release\@,${binutils_rpm_release},g" \
|
|
||||||
-e "s,@target_alias\@,${target_alias},g" \
|
|
||||||
-e "s,@prefix\@,@prefix@,g" \
|
|
||||||
-e "s,@rpmprefix\@,@rpmprefix@,g" \
|
|
||||||
-e "s,@rpmgroup\@,@rpmgroup@,g" \
|
|
||||||
-e "s,@osversion\@,@osversion@,g" \
|
|
||||||
-e "s,@binutils_version\@,${binutils_version},g" \
|
|
||||||
-e "s,@binutils_patch_version\@,${binutils_patch_version},g" \
|
|
||||||
-e "s,@binutils_suffix\@,${binutils_suffix},g" \
|
|
||||||
-e "s,@PATCH1\@,${PATCH1}," \
|
|
||||||
< ${specsrc}
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
# ==============================================================
|
|
||||||
# %{binutils_target}-binutils
|
|
||||||
# ==============================================================
|
|
||||||
# %package -n @rpmprefix@%{binutils_target}-binutils
|
|
||||||
# Summary: rtems binutils for %{binutils_target}
|
|
||||||
# Group: %{rpmgroup}
|
|
||||||
# Requires: @rpmprefix@rtems@osversion@-base-binutils
|
|
||||||
|
|
||||||
%description -n @rpmprefix@%{binutils_target}-binutils
|
|
||||||
|
|
||||||
GNU binutils targetting %{binutils_target}.
|
|
||||||
|
|
||||||
%files -n @rpmprefix@%{binutils_target}-binutils
|
|
||||||
%defattr(-,root,root)
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
%dir %{_mandir}
|
|
||||||
%dir %{_mandir}/man1
|
|
||||||
%endif
|
|
||||||
%{_mandir}/man1/%{binutils_target}-*.1*
|
|
||||||
|
|
||||||
%if "%{_prefix}" != "/usr"
|
|
||||||
%dir %{_bindir}
|
|
||||||
%endif
|
|
||||||
%{_bindir}/%{binutils_target}-*
|
|
||||||
|
|
||||||
%dir %{_prefix}/%{binutils_target}
|
|
||||||
%dir %{_prefix}/%{binutils_target}/bin
|
|
||||||
%{_prefix}/%{binutils_target}/bin/*
|
|
||||||
|
|
||||||
%dir %{_prefix}/%{binutils_target}/lib
|
|
||||||
%{_prefix}/%{binutils_target}/lib/ldscripts
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#
|
|
||||||
# $Id$
|
|
||||||
#
|
|
||||||
|
|
||||||
This directory contains RPM-spec file fragments (*.add) which are used to
|
|
||||||
compose the toolchain specs.
|
|
||||||
|
|
||||||
Cf. Makefile.am for details on how the toolchain specs get composed.
|
|
||||||
@@ -1,84 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
#
|
|
||||||
# Usage: mkspec CPU
|
|
||||||
#
|
|
||||||
|
|
||||||
RTEMS_DIR=`dirname $0`/@top_srcdir@
|
|
||||||
|
|
||||||
CFG=../setup.cache
|
|
||||||
|
|
||||||
usage()
|
|
||||||
{
|
|
||||||
echo "$0 [options] <target_alias>"
|
|
||||||
echo " options:"
|
|
||||||
echo " -cfg <setup.cache>"
|
|
||||||
echo " -a <alternate specs.in>"
|
|
||||||
exit 1 ;
|
|
||||||
}
|
|
||||||
|
|
||||||
specsrc=./gccnewlib.spec.in
|
|
||||||
|
|
||||||
while test $# -ge 2; do
|
|
||||||
case $1 in
|
|
||||||
-cfg)
|
|
||||||
shift
|
|
||||||
CFG=$1
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
-a) # alternate specs file
|
|
||||||
shift
|
|
||||||
specsrc=$1
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
-*)
|
|
||||||
echo "invalid option $1";
|
|
||||||
usage
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
done
|
|
||||||
|
|
||||||
if test ! $# -eq 1;
|
|
||||||
then
|
|
||||||
echo "Invalid number of arguments"
|
|
||||||
usage
|
|
||||||
fi
|
|
||||||
|
|
||||||
# target to build for
|
|
||||||
target_alias=$1
|
|
||||||
|
|
||||||
. ./$CFG
|
|
||||||
|
|
||||||
if test -n "${gcc_patch_version}"; then
|
|
||||||
PATCH0="Patch0: gcc-core-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
PATCH1="Patch1: gcc-g++-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
PATCH2="Patch2: gcc-fortran-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
PATCH3="Patch3: gcc-gcj-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
PATCH4="Patch4: gcc-ada-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
PATCH5="Patch5: gcc-objc-${gcc_version}-rtems-${gcc_patch_version}.diff"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test -n "${newlib_patch_version}"; then
|
|
||||||
PATCH50="Patch50: newlib-${newlib_version}-rtems-${newlib_patch_version}.diff"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# note that the variables in the gccnewlib directory are actually the same
|
|
||||||
sed -e "s,@PATCH0\@,${PATCH0}," \
|
|
||||||
-e "s,@PATCH1\@,${PATCH1}," \
|
|
||||||
-e "s,@PATCH2\@,${PATCH2}," \
|
|
||||||
-e "s,@PATCH3\@,${PATCH3}," \
|
|
||||||
-e "s,@PATCH4\@,${PATCH4}," \
|
|
||||||
-e "s,@PATCH5\@,${PATCH5}," \
|
|
||||||
-e "s,@PATCH50\@,${PATCH50}," \
|
|
||||||
-e "s,@Release\@,${gccnewlib_rpm_release},g" \
|
|
||||||
-e "s,@target_alias\@,${target_alias},g" \
|
|
||||||
-e "s,@prefix\@,@prefix@,g" \
|
|
||||||
-e "s,@rpmprefix\@,@rpmprefix@,g" \
|
|
||||||
-e "s,@rpmgroup\@,@rpmgroup@,g" \
|
|
||||||
-e "s,@osversion\@,@osversion@,g" \
|
|
||||||
-e "s,@gcc_version\@,${gcc_version},g" \
|
|
||||||
-e "s,@gcc_patch_version\@,${gcc_patch_version},g" \
|
|
||||||
-e "s,@gcc_suffix\@,${gcc_suffix},g" \
|
|
||||||
-e "s,@newlib_version\@,${newlib_version},g" \
|
|
||||||
-e "s,@newlib_patch_version\@,${newlib_patch_version},g" \
|
|
||||||
-e "s,@newlib_suffix\@,${newlib_suffix},g" \
|
|
||||||
< ${specsrc}
|
|
||||||
Reference in New Issue
Block a user