source: rtems/scripts/gdb/gdb.add @ 90357e29

4.104.114.84.95
Last change on this file since 90357e29 was 90357e29, checked in by Joel Sherrill <joel.sherrill@…>, on 02/17/04 at 19:09:57

2004-02-17 RTEMS

  • setup.def, gdb/base-gdb.add, gdb/gdb.add: Building a gcc 3.2.3 i960 gcc and updating gdb to 5.3.
  • Property mode set to 100644
File size: 2.9 KB
Line 
1
2%define gdb_version     @gdb_version@
3%define gdb_target      @target_alias@
4
5Name:         %{rpmprefix}%{gdb_target}-gdb-collection
6Release:      @Release@
7License:      GPL/LGPL
8Group:        %{rpmgroup}
9
10Autoreqprov:  on
11Packager:     corsepiu@faw.uni-ulm.de and joel@OARcorp.com
12
13Version:      %{gdb_version}
14Summary:      gdb for target %{gdb_version}
15Source0:      ftp://ftp.gnu.org/pub/gnu/gdb-%{gdb_version}.tar.gz
16Patch0:       gdb-%{gdb_version}-rtems-@gdb_patch_version@.diff
17# Patch0:             gdb-%{gdb_version}-rtems-base-@gdb_patch_version@.diff
18# Patch1:             gdb-%{gdb_version}-rtems-cg-@gdb_patch_version@.diff
19# Patch2:             gdb-%{gdb_version}-rtems-rdbg-@gdb_patch_version@.diff
20
21%if "%{_vendor}" == "redhat"
22BuildPreReq:    ncurses-devel
23%endif
24
25#
26# The original sources are not included in the source RPM.
27# If we included them, then the source RPMs for each target
28# would duplicate MBs of source unnecessarily.  This is
29# a duplication of over 30 MBs of source for each of
30# the more than 10 targets it is possible to build.
31#
32# You can get them yourself from the Internet and copy them to
33# your /usr/src/redhat/SOURCES directory ($RPM_SOURCE_DIR).
34# Or you can try the ftp options of rpm :-)
35#
36NoSource:      0
37
38#  Account as best possible for targets without simulators
39#  and targets which require extra arguments.
40%define _sim    1
41
42%if "%{gdb_target}" == "m68k-rtems@osversion@"
43%define _sim    0
44%endif
45%if "%{gdb_target}" == "i386-rtems@osversion@"
46%define _sim    0
47%endif
48
49
50%description
51RTEMS is an open source operating system for embedded systems.
52
53This is the GNU gdb for RTEMS targetting %{gdb_version}.
54
55%prep
56%setup -c -n %{name}-%{version} -a 0
57
58cd gdb-%{gdb_version}
59%patch0 -p1
60# %patch1 -p1
61# %patch2 -p1
62
63%build
64%if "%_sim" == "1"
65 simargs="--enable-sim"
66%endif
67
68%if "%{gdb_target}" == "powerpc-rtems@osversion@"
69 simargs="$simargs --enable-sim-timebase --enable-sim-hardware"
70 #  Enabling this causes the program image to be huge and causes
71 #  some gcc/hosts combinations to run out of memory.
72 # simargs="$simargs --enable-sim-inline"
73%endif
74
75test -d build || mkdir build
76  cd build
77  export PATH="%{_bindir}:${PATH}"
78  ../gdb-%{gdb_version}/configure \
79    --build=%_build --host=%_host \
80    --target=%{gdb_target} \
81    --verbose --prefix=%{_prefix} $simargs \
82    --disable-nls
83
84  make all
85  make info
86
87%install
88  cd build
89  make prefix=$RPM_BUILD_ROOT%{_prefix} install
90  make prefix=$RPM_BUILD_ROOT%{_prefix} install-info
91
92  # host files
93  rm -rf $RPM_BUILD_ROOT%{_prefix}/include/*.h
94  rm -rf $RPM_BUILD_ROOT%{_prefix}/lib/lib*a
95
96  # These come from other packages
97  rm -rf $RPM_BUILD_ROOT%{_prefix}/info/bfd*
98  rm -rf $RPM_BUILD_ROOT%{_prefix}/info/configure*
99  rm -rf $RPM_BUILD_ROOT%{_prefix}/info/standards*
100 
101  # gzip info files
102  gzip -f $RPM_BUILD_ROOT%{_prefix}/info/*.info 2>/dev/null
103  gzip -f $RPM_BUILD_ROOT%{_prefix}/info/*.info-? 2>/dev/null
104  gzip -f $RPM_BUILD_ROOT%{_prefix}/info/*.info-?? 2>/dev/null
Note: See TracBrowser for help on using the repository browser.