Chris Johns 0328944c57 NIOS2 Tools based on Altera's 4.11 tool set.
Add support for building the NIOS2 tool set. The source
is based on the Altera 4.11 src package. This package has been
split up and placed on the rtems.org server.
2013-02-12 11:46:29 +11:00

73 lines
1.6 KiB
INI

#
# GDB 7.xx Version 1.
#
# This configuration file configure's, make's and install's gdb.
#
%include %{_configdir}/checks.cfg
Name: %{_target}-gdb-%{gdb_version}-%{release}
Summary: GDB v%{gdb_version} for target %{_target} on host %{_host}
Version: %{gdb_version}
Release: %{release}
URL: http://www.gnu.org/software/gdb/
BuildRoot: %{_tmppath}/%{name}-root-%(%{__id_u} -n)
#
# Source
#
%ifn %{defined Source0}
Source0: http://ftp.gnu.org/gnu/gdb/gdb-%{gdb_version}.tar.bz2
VersionControl0 git clone git://sourceware.org/git/gdb.git
%endif
#
# Prepare the source code.
#
%prep
%setup -q -c -T -n %{name}-%{version}
cd gdb-%{gdb_version}
%{?patch0:%patch0 -p1}
cd ..
%build
export PATH="%{_bindir}:${PATH}"
mkdir -p build
cd build
%if "%{_build}" != "%{_host}"
CFLAGS_FOR_BUILD="-g -O2 -Wall" \
%endif
CFLAGS="$SB_OPT_FLAGS" \
../gdb-%{gdb_version}/configure \
--build=%{_build} --host=%{_host} \
--target=%{_target} \
--verbose --disable-nls \
--without-included-gettext \
--disable-win32-registry \
--disable-werror \
--enable-sim \
--with-expat \
--with-python \
--prefix=%{_prefix} --bindir=%{_bindir} \
--exec-prefix=%{_exec_prefix} \
--includedir=%{_includedir} --libdir=%{_libdir} \
--mandir=%{_mandir} --infodir=%{_infodir}
%{__make} %{?_smp_mflags} all
cd ..
%install
export PATH="%{_bindir}:${PATH}"
rm -rf $SB_BUILD_ROOT
cd build
%{__make} DESTDIR=$SB_BUILD_ROOT install
# Dropped in FSF-binutils-2.9.5, but Cygwin still ships it.
rm -rf $SB_BUILD_ROOT%{_infodir}/configure.info*
rm -f $SB_BUILD_ROOT%{_infodir}/dir
touch $SB_BUILD_ROOT%{_infodir}/dir
cd ..