[bf862710] | 1 | # |
---|
| 2 | # Please send bugfixes or comments to |
---|
| 3 | # http://www.rtems.org/bugzilla |
---|
| 4 | # |
---|
| 5 | |
---|
| 6 | %define _prefix /opt/rtems-4.11 |
---|
| 7 | %define _exec_prefix %{_prefix} |
---|
| 8 | %define _bindir %{_exec_prefix}/bin |
---|
| 9 | %define _sbindir %{_exec_prefix}/sbin |
---|
| 10 | %define _libexecdir %{_exec_prefix}/libexec |
---|
| 11 | %define _datarootdir %{_prefix}/share |
---|
| 12 | %define _datadir %{_datarootdir} |
---|
| 13 | %define _sysconfdir %{_prefix}/etc |
---|
| 14 | %define _sharedstatedir %{_prefix}/com |
---|
| 15 | %define _localstatedir %{_prefix}/var |
---|
| 16 | %define _includedir %{_prefix}/include |
---|
| 17 | %define _libdir %{_exec_prefix}/%{_lib} |
---|
| 18 | %define _mandir %{_datarootdir}/man |
---|
| 19 | %define _infodir %{_datarootdir}/info |
---|
| 20 | %define _localedir %{_datarootdir}/locale |
---|
| 21 | |
---|
| 22 | %ifos cygwin cygwin32 mingw mingw32 |
---|
| 23 | %define _exeext .exe |
---|
| 24 | %define debug_package %{nil} |
---|
| 25 | %define _libdir %{_exec_prefix}/lib |
---|
| 26 | %else |
---|
| 27 | %define _exeext %{nil} |
---|
| 28 | %endif |
---|
| 29 | |
---|
| 30 | %ifos cygwin cygwin32 |
---|
| 31 | %define optflags -O3 -pipe -march=i486 -funroll-loops |
---|
| 32 | %endif |
---|
| 33 | |
---|
| 34 | %ifos mingw mingw32 |
---|
| 35 | %if %{defined _mingw32_cflags} |
---|
| 36 | %define optflags %{_mingw32_cflags} |
---|
| 37 | %else |
---|
| 38 | %define optflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -mms-bitfields |
---|
| 39 | %endif |
---|
| 40 | %endif |
---|
| 41 | |
---|
| 42 | %if "%{_build}" != "%{_host}" |
---|
| 43 | %define _host_rpmprefix %{_host}- |
---|
| 44 | %else |
---|
| 45 | %define _host_rpmprefix %{nil} |
---|
| 46 | %endif |
---|
| 47 | |
---|
| 48 | |
---|
[65357b7] | 49 | %define gcc_pkgvers 4.5.0 |
---|
[0e5e088] | 50 | %define gcc_version 4.5.0 |
---|
| 51 | %define gcc_rpmvers %{expand:%(echo "4.5.0" | tr - _ )} |
---|
[bf862710] | 52 | |
---|
| 53 | %define newlib_pkgvers 1.18.0 |
---|
| 54 | %define newlib_version 1.18.0 |
---|
| 55 | |
---|
| 56 | Name: rtems-4.11-i386-rtems4.11-gcc |
---|
| 57 | Summary: i386-rtems4.11 gcc |
---|
| 58 | |
---|
| 59 | Group: Development/Tools |
---|
| 60 | Version: %{gcc_rpmvers} |
---|
[e2e8537] | 61 | Release: 10%{?dist} |
---|
[bf862710] | 62 | License: GPL |
---|
| 63 | URL: http://gcc.gnu.org |
---|
| 64 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
---|
| 65 | |
---|
| 66 | %define _use_internal_dependency_generator 0 |
---|
| 67 | |
---|
| 68 | BuildRequires: %{_host_rpmprefix}gcc |
---|
| 69 | |
---|
[e7a21fe0] | 70 | # FIXME: Disable lto for now, to avoid dependencies on libelf |
---|
[9e84c716] | 71 | %bcond_with lto |
---|
| 72 | |
---|
[b2c76e9] | 73 | # FIXME: Disable python gdb scripts |
---|
[e7a21fe0] | 74 | # ATM, no idea how to package them |
---|
[9e84c716] | 75 | %bcond_with pygdb |
---|
| 76 | |
---|
[e7a21fe0] | 77 | # FIXME: Disable GCC-plugin |
---|
| 78 | # Bug in gcc-4.5-20100318, doesn't build them on x86_84 hosts. |
---|
| 79 | %bcond_with plugin |
---|
| 80 | |
---|
[9e84c716] | 81 | # versions of libraries, we conditionally bundle if necessary |
---|
| 82 | %global mpc_version 0.8.1 |
---|
| 83 | %global mpfr_version 2.4.1 |
---|
| 84 | %global gmp_version 4.3.2 |
---|
| 85 | %global libelf_version 0.8.13 |
---|
| 86 | |
---|
| 87 | # versions of libraries these distros are known to ship |
---|
| 88 | %if 0%{?fc13} |
---|
| 89 | %global mpc_provided 0.8.1 |
---|
| 90 | %global mpfr_provided 2.4.1 |
---|
| 91 | %global gmp_provided 4.3.1 |
---|
[bf862710] | 92 | %endif |
---|
[9e84c716] | 93 | |
---|
| 94 | %if 0%{?fc12} |
---|
| 95 | %global mpc_provided 0.8 |
---|
| 96 | %global mpfr_provided 2.4.1 |
---|
| 97 | %global gmp_provided 4.3.1 |
---|
[bf862710] | 98 | %endif |
---|
| 99 | |
---|
[9e84c716] | 100 | %if 0%{?fc11} |
---|
| 101 | %global mpc_provided %{nil} |
---|
| 102 | %global mpfr_provided 2.4.1 |
---|
| 103 | %global gmp_provided 4.2.4 |
---|
| 104 | %endif |
---|
| 105 | |
---|
[b2c76e9] | 106 | %if 0%{?el6} |
---|
[10612755] | 107 | %global mpc_provided %{nil} |
---|
[2733f477] | 108 | %global mpfr_provided 2.4.1 |
---|
[10612755] | 109 | %global gmp_provided 4.3.1 |
---|
| 110 | %endif |
---|
| 111 | |
---|
[b2c76e9] | 112 | %if 0%{?el5} |
---|
[9e84c716] | 113 | %global mpc_provided %{nil} |
---|
| 114 | %global mpfr_provided %{nil} |
---|
| 115 | %global gmp_provided 4.1.4 |
---|
[bf862710] | 116 | %endif |
---|
[9e84c716] | 117 | |
---|
| 118 | %if 0%{?suse11_0} |
---|
| 119 | %global mpc_provided %{nil} |
---|
| 120 | %global mpfr_provided 2.3.1 |
---|
| 121 | %global gmp_provided 4.2.2 |
---|
[bf862710] | 122 | %endif |
---|
| 123 | |
---|
[9e84c716] | 124 | %if 0%{?suse11_1} |
---|
| 125 | %global mpc_provided %{nil} |
---|
| 126 | %global mpfr_provided 2.3.2 |
---|
| 127 | %global gmp_provided 4.2.3 |
---|
[bf862710] | 128 | %endif |
---|
| 129 | |
---|
[9e84c716] | 130 | %if 0%{?suse11_2} |
---|
| 131 | %global mpc_provided 0.7 |
---|
| 132 | %global mpfr_provided 2.4.1 |
---|
| 133 | %global gmp_provided 4.3.1 |
---|
| 134 | %endif |
---|
| 135 | |
---|
| 136 | %if 0%{?cygwin} |
---|
[bba6a24] | 137 | %global mpc_provided 0.8 |
---|
[9e84c716] | 138 | %global mpfr_provided 2.4.1 |
---|
| 139 | %global gmp_provided 4.3.1 |
---|
| 140 | %endif |
---|
| 141 | |
---|
| 142 | %if 0%{?mingw32} |
---|
[afcb8775] | 143 | %global mpc_provided 0.8.1 |
---|
| 144 | %global mpfr_provided 2.4.1 |
---|
| 145 | %global gmp_provided 4.3.2 |
---|
[bf862710] | 146 | %endif |
---|
| 147 | |
---|
| 148 | %if "%{gcc_version}" >= "4.2.0" |
---|
| 149 | %endif |
---|
[9e84c716] | 150 | |
---|
| 151 | %if "%{gcc_version}" >= "4.3.0" |
---|
| 152 | %define gmp_required 4.1 |
---|
| 153 | %define mpfr_required 2.3.1 |
---|
[bf862710] | 154 | %endif |
---|
[9e84c716] | 155 | |
---|
| 156 | %if "%{gcc_version}" >= "4.3.3" |
---|
| 157 | %define cloog_required 0.15 |
---|
[bf862710] | 158 | %endif |
---|
| 159 | |
---|
[9e84c716] | 160 | %if "%{gcc_version}" >= "4.4.0" |
---|
| 161 | %define mpfr_required 2.3.2 |
---|
| 162 | %endif |
---|
[bf862710] | 163 | |
---|
[9e84c716] | 164 | %if "%{gcc_version}" >= "4.5.0" |
---|
| 165 | %define mpc_required 0.8 |
---|
| 166 | %if %{with lto} |
---|
| 167 | %define libelf_required 0.8.12 |
---|
| 168 | %endif |
---|
| 169 | %endif |
---|
| 170 | |
---|
| 171 | %if %{defined mpc_required} |
---|
| 172 | %if "%{mpc_provided}" >= "%{mpc_required}" |
---|
| 173 | %{?fedora:BuildRequires: libmpc-devel >= %{mpc_required}} |
---|
| 174 | %{?suse:BuildRequires: mpc-devel >= %{mpc_required}} |
---|
| 175 | %if "%{_build}" != "%{_host}" |
---|
| 176 | BuildRequires: %{_host_rpmprefix}mpc-devel >= %{mpc_required} |
---|
| 177 | %endif |
---|
[bf862710] | 178 | %else |
---|
[9e84c716] | 179 | %define _build_mpc 1 |
---|
[4bb28d4] | 180 | %define gmp_required 4.2 |
---|
[9e84c716] | 181 | %endif |
---|
| 182 | %endif |
---|
| 183 | |
---|
| 184 | %if %{defined gmp_required} |
---|
| 185 | %if "%{gmp_provided}" >= "%{gmp_required}" |
---|
| 186 | BuildRequires: gmp-devel >= %{gmp_required} |
---|
[bf862710] | 187 | %if "%{_build}" != "%{_host}" |
---|
[9e84c716] | 188 | BuildRequires: %{_host_rpmprefix}gmp-devel >= %{gmp_required} |
---|
| 189 | %endif |
---|
[bf862710] | 190 | %else |
---|
[9e84c716] | 191 | %define _build_gmp 1 |
---|
[bf862710] | 192 | %endif |
---|
| 193 | %endif |
---|
[9e84c716] | 194 | |
---|
| 195 | %if %{defined libelf_required} |
---|
| 196 | %if "%{libelf_provided}" >= "%{libelf_required}" |
---|
| 197 | BuildRequires: libelf-devel >= %{libelf_required} |
---|
| 198 | %if "%{_build}" != "%{_host}" |
---|
| 199 | BuildRequires: %{_host_rpmprefix}libelf-devel >= %{libelf_required} |
---|
| 200 | %endif |
---|
[bf862710] | 201 | %else |
---|
[9e84c716] | 202 | %define _build_libelf 1 |
---|
| 203 | %endif |
---|
[bf862710] | 204 | %endif |
---|
| 205 | |
---|
[9e84c716] | 206 | |
---|
| 207 | %if %{defined cloog_required} |
---|
| 208 | %{?fc11:BuildRequires: cloog-ppl-devel >= %cloog_required} |
---|
| 209 | %{?fc12:BuildRequires: cloog-ppl-devel >= %cloog_required} |
---|
| 210 | %{?fc13:BuildRequires: cloog-ppl-devel >= %cloog_required} |
---|
[2733f477] | 211 | %{?el6:BuildRequires: cloog-ppl-devel >= %cloog_required} |
---|
[9e84c716] | 212 | %{?suse11_2:BuildRequires: cloog-devel >= %cloog_required, ppl-devel} |
---|
| 213 | %{?suse11_1:BuildRequires: cloog-devel >= %cloog_required, ppl-devel} |
---|
| 214 | %endif |
---|
| 215 | |
---|
| 216 | |
---|
| 217 | %if %{defined mpfr_required} |
---|
| 218 | %if "%{mpfr_provided}" >= "%{mpfr_required}" |
---|
| 219 | BuildRequires: mpfr-devel >= %{mpfr_required} |
---|
| 220 | %if "%{_build}" != "%{_host}" |
---|
| 221 | BuildRequires: %{_host_rpmprefix}mpfr-devel >= %{mpfr_required} |
---|
| 222 | %endif |
---|
| 223 | %else |
---|
| 224 | %define _build_mpfr 1 |
---|
| 225 | %endif |
---|
[bf862710] | 226 | %endif |
---|
| 227 | |
---|
| 228 | %if "%{_build}" != "%{_host}" |
---|
| 229 | BuildRequires: rtems-4.11-i386-rtems4.11-gcc = %{gcc_rpmvers} |
---|
| 230 | %endif |
---|
| 231 | |
---|
| 232 | %if "%{gcc_version}" >= "4.2.0" |
---|
| 233 | BuildRequires: flex bison |
---|
| 234 | %endif |
---|
| 235 | |
---|
| 236 | |
---|
| 237 | BuildRequires: texinfo >= 4.2 |
---|
| 238 | BuildRequires: rtems-4.11-i386-rtems4.11-binutils |
---|
| 239 | |
---|
| 240 | Requires: rtems-4.11-gcc-common |
---|
| 241 | Requires: rtems-4.11-i386-rtems4.11-binutils |
---|
| 242 | Requires: rtems-4.11-i386-rtems4.11-gcc-libgcc = %{gcc_rpmvers}-%{release} |
---|
[e2e8537] | 243 | Requires: rtems-4.11-i386-rtems4.11-newlib = %{newlib_version}-10%{?dist} |
---|
[bf862710] | 244 | |
---|
[9e84c716] | 245 | %if "%{gcc_version}" >= "4.5.0" |
---|
| 246 | BuildRequires: zlib-devel |
---|
[afcb8775] | 247 | %if "%{_build}" != "%{_host}" |
---|
| 248 | BuildRequires: %{_host_rpmprefix}zlib-devel |
---|
| 249 | %endif |
---|
[9e84c716] | 250 | %else |
---|
| 251 | %endif |
---|
[bf862710] | 252 | |
---|
[9e84c716] | 253 | %global _gcclibdir %{_prefix}/lib |
---|
[bf862710] | 254 | |
---|
[92143267] | 255 | %if "%{gcc_version}" == "4.5.0" |
---|
[65357b7] | 256 | Source0: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2 |
---|
| 257 | Patch0: ftp://ftp.rtems.org/pub/rtems/SOURCES/4.11/gcc-core-4.5.0-rtems4.11-20100414.diff |
---|
[92143267] | 258 | %endif |
---|
[bf862710] | 259 | %if "%{gcc_version}" == "4.4.3" |
---|
| 260 | Source0: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2 |
---|
[92143267] | 261 | Patch0: ftp://ftp.rtems.org/pub/rtems/SOURCES/4.10/gcc-core-4.4.3-rtems4.10-20100315.diff |
---|
[bf862710] | 262 | %endif |
---|
| 263 | %{?_without_sources:NoSource: 0} |
---|
| 264 | |
---|
[92143267] | 265 | %if "%{gcc_version}" == "4.5.0" |
---|
[65357b7] | 266 | Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-g++-%{gcc_pkgvers}.tar.bz2 |
---|
[92143267] | 267 | %endif |
---|
[bf862710] | 268 | %if "%{gcc_version}" == "4.4.3" |
---|
| 269 | Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-g++-%{gcc_pkgvers}.tar.bz2 |
---|
| 270 | %endif |
---|
| 271 | %{?_without_sources:NoSource: 1} |
---|
| 272 | |
---|
| 273 | %if "%{newlib_version}" == "1.18.0" |
---|
| 274 | Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_pkgvers}.tar.gz |
---|
[e2e8537] | 275 | Patch50: ftp://ftp.rtems.org/pub/rtems/SOURCES/4.10/newlib-1.18.0-rtems4.11-20100423.diff |
---|
[bf862710] | 276 | %endif |
---|
| 277 | %{?_without_sources:NoSource: 50} |
---|
| 278 | |
---|
[9e84c716] | 279 | %if 0%{?_build_mpfr} |
---|
[bf862710] | 280 | Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2 |
---|
| 281 | %endif |
---|
| 282 | |
---|
[9e84c716] | 283 | %if 0%{?_build_mpc} |
---|
| 284 | Source61: http://www.multiprecision.org/mpc/download/mpc-%{mpc_version}.tar.gz |
---|
| 285 | %endif |
---|
| 286 | |
---|
| 287 | %if 0%{?_build_gmp} |
---|
| 288 | Source62: ftp://ftp.gnu.org/gnu/gmp/gmp-%{gmp_version}.tar.bz2 |
---|
| 289 | %endif |
---|
| 290 | |
---|
| 291 | %if 0%{?_build_libelf} |
---|
| 292 | Source63: http://www.mr511.de/software/libelf-%{libelf_version}.tar.gz |
---|
| 293 | %endif |
---|
| 294 | |
---|
[bf862710] | 295 | %description |
---|
| 296 | Cross gcc for i386-rtems4.11. |
---|
| 297 | |
---|
| 298 | %prep |
---|
| 299 | %setup -c -T -n %{name}-%{version} |
---|
| 300 | |
---|
| 301 | %setup -q -T -D -n %{name}-%{version} -a0 |
---|
[4b747a21] | 302 | cd gcc-%{gcc_pkgvers} |
---|
| 303 | %{?PATCH0:%patch0 -p1} |
---|
| 304 | cd .. |
---|
[bf862710] | 305 | |
---|
| 306 | %setup -q -T -D -n %{name}-%{version} -a1 |
---|
[4b747a21] | 307 | cd gcc-%{gcc_pkgvers} |
---|
| 308 | %{?PATCH1:%patch1 -p1} |
---|
| 309 | cd .. |
---|
[bf862710] | 310 | |
---|
| 311 | |
---|
| 312 | |
---|
| 313 | |
---|
| 314 | |
---|
| 315 | %setup -q -T -D -n %{name}-%{version} -a50 |
---|
| 316 | cd newlib-%{newlib_version} |
---|
| 317 | %{?PATCH50:%patch50 -p1} |
---|
| 318 | cd .. |
---|
| 319 | # Copy the C library into gcc's source tree |
---|
| 320 | ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers} |
---|
| 321 | |
---|
| 322 | %if 0%{?_build_mpfr} |
---|
| 323 | %setup -q -T -D -n %{name}-%{version} -a60 |
---|
| 324 | %{?PATCH60:%patch60 -p1} |
---|
| 325 | # Build mpfr one-tree style |
---|
| 326 | ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr |
---|
| 327 | %endif |
---|
| 328 | |
---|
[9e84c716] | 329 | %if 0%{?_build_mpc} |
---|
| 330 | %setup -q -T -D -n %{name}-%{version} -a61 |
---|
| 331 | %{?PATCH61:%patch61 -p1} |
---|
| 332 | # Build mpc one-tree style |
---|
| 333 | ln -s ../mpc-%{mpc_version} gcc-%{gcc_pkgvers}/mpc |
---|
| 334 | %endif |
---|
| 335 | |
---|
| 336 | %if 0%{?_build_gmp} |
---|
| 337 | %setup -q -T -D -n %{name}-%{version} -a62 |
---|
| 338 | %{?PATCH62:%patch62 -p1} |
---|
| 339 | # Build gmp one-tree style |
---|
| 340 | ln -s ../gmp-%{gmp_version} gcc-%{gcc_pkgvers}/gmp |
---|
| 341 | %endif |
---|
| 342 | |
---|
| 343 | %if 0%{?_build_libelf} |
---|
| 344 | %setup -q -T -D -n %{name}-%{version} -a63 |
---|
| 345 | %{?PATCH63:%patch63 -p1} |
---|
| 346 | # Build libelf one-tree style |
---|
| 347 | ln -s ../libelf-%{libelf_version} gcc-%{gcc_pkgvers}/libelf |
---|
| 348 | %endif |
---|
| 349 | |
---|
[e2e8537] | 350 | echo "RTEMS gcc-%{gcc_version}-10%{?dist}/newlib-%{newlib_version}-10%{?dist}" > gcc-%{gcc_pkgvers}/gcc/DEV-PHASE |
---|
[bf862710] | 351 | |
---|
| 352 | |
---|
| 353 | # Fix timestamps |
---|
| 354 | cd gcc-%{gcc_pkgvers} |
---|
| 355 | contrib/gcc_update --touch |
---|
| 356 | cd .. |
---|
| 357 | %build |
---|
| 358 | mkdir -p build |
---|
| 359 | |
---|
| 360 | cd build |
---|
| 361 | |
---|
| 362 | languages="c" |
---|
| 363 | languages="$languages,c++" |
---|
| 364 | export PATH="%{_bindir}:${PATH}" |
---|
| 365 | %if "%{_build}" != "%{_host}" |
---|
| 366 | CFLAGS_FOR_BUILD="-g -O2 -Wall" \ |
---|
| 367 | CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \ |
---|
| 368 | %else |
---|
| 369 | # gcc is not ready to be compiled with -std=gnu99 |
---|
| 370 | CC=$(echo "%{__cc} ${RPM_OPT_FLAGS}" | sed -e 's,-std=gnu99 ,,') \ |
---|
| 371 | %endif |
---|
| 372 | ../gcc-%{gcc_pkgvers}/configure \ |
---|
| 373 | --prefix=%{_prefix} \ |
---|
| 374 | --bindir=%{_bindir} \ |
---|
| 375 | --exec_prefix=%{_exec_prefix} \ |
---|
| 376 | --includedir=%{_includedir} \ |
---|
| 377 | --libdir=%{_gcclibdir} \ |
---|
| 378 | --libexecdir=%{_libexecdir} \ |
---|
| 379 | --mandir=%{_mandir} \ |
---|
| 380 | --infodir=%{_infodir} \ |
---|
| 381 | --datadir=%{_datadir} \ |
---|
| 382 | --build=%_build --host=%_host \ |
---|
| 383 | --target=i386-rtems4.11 \ |
---|
| 384 | --disable-libstdcxx-pch \ |
---|
| 385 | --with-gnu-as --with-gnu-ld --verbose \ |
---|
| 386 | --with-newlib \ |
---|
| 387 | --with-system-zlib \ |
---|
| 388 | --disable-nls --without-included-gettext \ |
---|
| 389 | --disable-win32-registry \ |
---|
| 390 | --enable-version-specific-runtime-libs \ |
---|
| 391 | --enable-threads \ |
---|
[9e84c716] | 392 | %{?with_lto:--enable-lto}%{!?with_lto:--disable-lto} \ |
---|
[e7a21fe0] | 393 | %{?with_plugin:--enable-plugin}%{!?with_plugin:--disable-plugin} \ |
---|
[bf862710] | 394 | --enable-newlib-io-c99-formats \ |
---|
| 395 | --enable-languages="$languages" $optargs |
---|
| 396 | |
---|
| 397 | %if "%_host" != "%_build" |
---|
| 398 | # Bug in gcc-3.2.1: |
---|
| 399 | # Somehow, gcc doesn't get syslimits.h right for Cdn-Xs |
---|
| 400 | mkdir -p gcc/include |
---|
| 401 | cp ../gcc-%{gcc_pkgvers}/gcc/gsyslimits.h gcc/include/syslimits.h |
---|
| 402 | %endif |
---|
| 403 | |
---|
| 404 | make %{?_smp_mflags} all |
---|
| 405 | make info |
---|
| 406 | cd .. |
---|
| 407 | |
---|
| 408 | %install |
---|
| 409 | export PATH="%{_bindir}:${PATH}" |
---|
| 410 | rm -rf $RPM_BUILD_ROOT |
---|
| 411 | |
---|
| 412 | cd build |
---|
| 413 | |
---|
| 414 | make DESTDIR=$RPM_BUILD_ROOT install |
---|
| 415 | cd .. |
---|
| 416 | |
---|
| 417 | cd build/i386-rtems4.11/newlib |
---|
| 418 | make DESTDIR=$RPM_BUILD_ROOT install-info |
---|
| 419 | cd ../../.. |
---|
| 420 | |
---|
| 421 | %if "%{gcc_version}" <= "4.1.2" |
---|
| 422 | # Misplaced header file |
---|
| 423 | if test -f $RPM_BUILD_ROOT%{_includedir}/mf-runtime.h; then |
---|
| 424 | mv $RPM_BUILD_ROOT%{_includedir}/mf-runtime.h \ |
---|
| 425 | $RPM_BUILD_ROOT%{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include/ |
---|
| 426 | fi |
---|
| 427 | %endif |
---|
| 428 | |
---|
| 429 | # host library |
---|
| 430 | %if "%{gcc_version}" >= "4.2.0" |
---|
| 431 | # libiberty doesn't honor --libdir, but always installs to a |
---|
| 432 | # magically guessed _libdir |
---|
| 433 | rm -f ${RPM_BUILD_ROOT}%{_libdir}/libiberty.a |
---|
| 434 | %else |
---|
| 435 | # libiberty installs to --libdir=... |
---|
| 436 | rm -f ${RPM_BUILD_ROOT}%{_gcclibdir}/libiberty.a |
---|
| 437 | %endif |
---|
| 438 | |
---|
| 439 | # We use the version from binutils |
---|
| 440 | rm -f $RPM_BUILD_ROOT%{_bindir}/i386-rtems4.11-c++filt%{_exeext} |
---|
| 441 | |
---|
| 442 | |
---|
| 443 | # We don't ship info/dir |
---|
| 444 | rm -f $RPM_BUILD_ROOT%{_infodir}/dir |
---|
| 445 | touch $RPM_BUILD_ROOT%{_infodir}/dir |
---|
| 446 | |
---|
| 447 | # Bug in gcc-3.4.0pre |
---|
| 448 | rm -f $RPM_BUILD_ROOT%{_bindir}/i386-rtems4.11-i386-rtems4.11-gcjh%{_exeext} |
---|
| 449 | |
---|
| 450 | # Bug in gcc-3.3.x/gcc-3.4.x: Despite we don't need fixincludes, it installs |
---|
| 451 | # the fixinclude-install-tools |
---|
| 452 | rm -rf ${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/install-tools |
---|
| 453 | rm -rf ${RPM_BUILD_ROOT}%{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/install-tools |
---|
| 454 | |
---|
| 455 | # Bug in gcc > 4.1.0: Installs an unused, empty directory |
---|
| 456 | if test -d ${RPM_BUILD_ROOT}%{_prefix}/i386-rtems4.11/include/bits; then |
---|
| 457 | rmdir ${RPM_BUILD_ROOT}%{_prefix}/i386-rtems4.11/include/bits |
---|
| 458 | fi |
---|
| 459 | |
---|
[9e84c716] | 460 | # gcc >= 4.5.0: installs weird libstdc++ python bindings. |
---|
| 461 | %if ! %{with pygdb} |
---|
| 462 | if test -d ${RPM_BUILD_ROOT}%{_datadir}/gcc-%{gcc_version}/python; then |
---|
| 463 | rm -rf ${RPM_BUILD_ROOT}%{_datadir}/gcc-%{gcc_version}/python/libstdcxx |
---|
| 464 | fi |
---|
| 465 | %endif |
---|
| 466 | |
---|
[bf862710] | 467 | # Collect multilib subdirectories |
---|
| 468 | multilibs=`build/gcc/xgcc -Bbuild/gcc/ --print-multi-lib | sed -e 's,;.*$,,'` |
---|
| 469 | |
---|
| 470 | echo "%defattr(-,root,root,-)" > build/files.newlib |
---|
| 471 | TGTDIR="%{_exec_prefix}/i386-rtems4.11/lib" |
---|
| 472 | for i in $multilibs; do |
---|
| 473 | case $i in |
---|
| 474 | \.) echo "%dir ${TGTDIR}" >> build/files.newlib |
---|
| 475 | ;; |
---|
| 476 | *) echo "%dir ${TGTDIR}/$i" >> build/files.newlib |
---|
| 477 | ;; |
---|
| 478 | esac |
---|
| 479 | done |
---|
| 480 | |
---|
| 481 | rm -f dirs ; |
---|
| 482 | echo "%defattr(-,root,root,-)" >> dirs |
---|
| 483 | TGTDIR="%{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}" |
---|
| 484 | for i in $multilibs; do |
---|
| 485 | case $i in |
---|
| 486 | \.) ;; # ignore, handled elsewhere |
---|
| 487 | *) echo "%dir ${TGTDIR}/$i" >> dirs |
---|
| 488 | ;; |
---|
| 489 | esac |
---|
| 490 | done |
---|
| 491 | |
---|
| 492 | # Collect files to go into different packages |
---|
| 493 | cp dirs build/files.gcc |
---|
| 494 | cp dirs build/files.gfortran |
---|
| 495 | cp dirs build/files.objc |
---|
| 496 | cp dirs build/files.gcj |
---|
| 497 | cp dirs build/files.g++ |
---|
| 498 | |
---|
| 499 | TGTDIR="%{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}" |
---|
| 500 | f=`find ${RPM_BUILD_ROOT}${TGTDIR} ! -type d -print | sed -e "s,^$RPM_BUILD_ROOT,,g"`; |
---|
| 501 | for i in $f; do |
---|
| 502 | case $i in |
---|
| 503 | *lib*.la) rm ${RPM_BUILD_ROOT}/$i ;; # ignore: gcc produces bogus libtool libs |
---|
| 504 | *f771) ;; |
---|
| 505 | *f951) ;; |
---|
| 506 | *cc1) ;; |
---|
| 507 | *cc1obj) ;; |
---|
| 508 | *cc1plus) ;; # ignore: explicitly put into rpm elsewhere |
---|
| 509 | *collect2) ;; |
---|
| 510 | *libobjc*) echo "$i" >> build/files.objc ;; |
---|
| 511 | *include/objc*) ;; |
---|
| 512 | *include/g++*);; |
---|
| 513 | *include/c++*);; |
---|
| 514 | *include-fixed/*);; |
---|
| 515 | *finclude/*);; |
---|
| 516 | *adainclude*);; |
---|
| 517 | *adalib*);; |
---|
| 518 | *gnat1);; |
---|
| 519 | *jc1) ;; |
---|
| 520 | *jvgenmain) ;; |
---|
| 521 | */libgfortran*.*) echo "$i" >> build/files.gfortran ;; |
---|
[9e84c716] | 522 | %{!?with_pygdb:*/libstdc++*gdb.py*) rm ${RPM_BUILD_ROOT}/$i ;;} # ignore for now |
---|
[bba6a24] | 523 | %{?with_pygdb:*/libstdc++*gdb.py*) >> build/files.g++ ;;} |
---|
[bf862710] | 524 | */libstdc++.*) echo "$i" >> build/files.g++ ;; |
---|
| 525 | */libsupc++.*) echo "$i" >> build/files.g++ ;; |
---|
| 526 | *) echo "$i" >> build/files.gcc ;; |
---|
| 527 | esac |
---|
| 528 | done |
---|
| 529 | |
---|
| 530 | TGTDIR="%{_exec_prefix}/i386-rtems4.11/lib" |
---|
| 531 | f=`find ${RPM_BUILD_ROOT}${TGTDIR} ! -type d -print | sed -e "s,^$RPM_BUILD_ROOT,,g"`; |
---|
| 532 | for i in $f; do |
---|
| 533 | case $i in |
---|
| 534 | *lib*.la) rm ${RPM_BUILD_ROOT}/$i;; # ignore - gcc produces bogus libtool libs |
---|
| 535 | *libiberty.a) rm ${RPM_BUILD_ROOT}/$i ;; # ignore - GPL'ed |
---|
| 536 | # all other files belong to newlib |
---|
| 537 | *) echo "$i" >> build/files.newlib ;; |
---|
| 538 | esac |
---|
| 539 | done |
---|
| 540 | # Extract %%__os_install_post into os_install_post~ |
---|
| 541 | cat << \EOF > os_install_post~ |
---|
| 542 | %__os_install_post |
---|
| 543 | EOF |
---|
| 544 | |
---|
| 545 | # Generate customized brp-*scripts |
---|
| 546 | cat os_install_post~ | while read a x y; do |
---|
| 547 | case $a in |
---|
| 548 | # Prevent brp-strip* from trying to handle foreign binaries |
---|
| 549 | */brp-strip*) |
---|
| 550 | b=$(basename $a) |
---|
| 551 | sed -e 's,find $RPM_BUILD_ROOT,find $RPM_BUILD_ROOT%_bindir $RPM_BUILD_ROOT%_libexecdir,' $a > $b |
---|
| 552 | chmod a+x $b |
---|
| 553 | ;; |
---|
| 554 | # Fix up brp-compress to handle %%_prefix != /usr |
---|
| 555 | */brp-compress*) |
---|
| 556 | b=$(basename $a) |
---|
| 557 | sed -e 's,\./usr/,.%{_prefix}/,g' < $a > $b |
---|
| 558 | chmod a+x $b |
---|
| 559 | ;; |
---|
| 560 | esac |
---|
| 561 | done |
---|
| 562 | |
---|
| 563 | sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \ |
---|
| 564 | -e 's,^[ ]*/usr/lib/rpm.*/brp-compress,./brp-compress,' \ |
---|
| 565 | < os_install_post~ > os_install_post |
---|
| 566 | %define __os_install_post . ./os_install_post |
---|
| 567 | |
---|
| 568 | |
---|
| 569 | cat << EOF > %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides |
---|
| 570 | #!/bin/sh |
---|
| 571 | grep -E -v '^${RPM_BUILD_ROOT}%{_exec_prefix}/i386-rtems4.11/(lib|include|sys-root)' \ |
---|
| 572 | %{?_gcclibdir:| grep -v '^${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/i386-rtems4.11/'} | %__find_provides |
---|
| 573 | EOF |
---|
| 574 | chmod +x %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides |
---|
| 575 | %define __find_provides %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides |
---|
| 576 | |
---|
| 577 | cat << EOF > %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires |
---|
| 578 | #!/bin/sh |
---|
| 579 | grep -E -v '^${RPM_BUILD_ROOT}%{_exec_prefix}/i386-rtems4.11/(lib|include|sys-root)' \ |
---|
| 580 | %{?_gcclibdir:| grep -v '^${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/i386-rtems4.11/'} | %__find_requires |
---|
| 581 | EOF |
---|
| 582 | chmod +x %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires |
---|
| 583 | %define __find_requires %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires |
---|
| 584 | |
---|
| 585 | %ifnarch noarch |
---|
| 586 | # Extract %%__debug_install_post into debug_install_post~ |
---|
| 587 | cat << \EOF > debug_install_post~ |
---|
| 588 | %__debug_install_post |
---|
| 589 | EOF |
---|
| 590 | |
---|
| 591 | # Generate customized debug_install_post script |
---|
| 592 | cat debug_install_post~ | while read a x y; do |
---|
| 593 | case $a in |
---|
| 594 | # Prevent find-debuginfo.sh* from trying to handle foreign binaries |
---|
| 595 | */find-debuginfo.sh) |
---|
| 596 | b=$(basename $a) |
---|
| 597 | sed -e 's,find "$RPM_BUILD_ROOT" !,find "$RPM_BUILD_ROOT"%_bindir "$RPM_BUILD_ROOT"%_libexecdir !,' $a > $b |
---|
| 598 | chmod a+x $b |
---|
| 599 | ;; |
---|
| 600 | esac |
---|
| 601 | done |
---|
| 602 | |
---|
| 603 | sed -e 's,^[ ]*/usr/lib/rpm/find-debuginfo.sh,./find-debuginfo.sh,' \ |
---|
| 604 | < debug_install_post~ > debug_install_post |
---|
| 605 | %define __debug_install_post . ./debug_install_post |
---|
| 606 | |
---|
| 607 | %endif |
---|
| 608 | |
---|
| 609 | %clean |
---|
| 610 | rm -rf $RPM_BUILD_ROOT |
---|
| 611 | |
---|
| 612 | # ============================================================== |
---|
| 613 | # rtems-4.11-i386-rtems4.11-gcc |
---|
| 614 | # ============================================================== |
---|
| 615 | # %package -n rtems-4.11-i386-rtems4.11-gcc |
---|
| 616 | # Summary: GNU cc compiler for i386-rtems4.11 |
---|
| 617 | # Group: Development/Tools |
---|
| 618 | # Version: %{gcc_rpmvers} |
---|
| 619 | # Requires: rtems-4.11-i386-rtems4.11-binutils |
---|
[e2e8537] | 620 | # Requires: rtems-4.11-i386-rtems4.11-newlib = %{newlib_version}-10%{?dist} |
---|
[bf862710] | 621 | # License: GPL |
---|
| 622 | |
---|
| 623 | # %if %build_infos |
---|
| 624 | # Requires: rtems-4.11-gcc-common |
---|
| 625 | # %endif |
---|
| 626 | |
---|
| 627 | %description -n rtems-4.11-i386-rtems4.11-gcc |
---|
| 628 | GNU cc compiler for i386-rtems4.11. |
---|
| 629 | |
---|
| 630 | # ============================================================== |
---|
| 631 | # rtems-4.11-i386-rtems4.11-gcc-libgcc |
---|
| 632 | # ============================================================== |
---|
| 633 | %package -n rtems-4.11-i386-rtems4.11-gcc-libgcc |
---|
| 634 | Summary: libgcc for i386-rtems4.11-gcc |
---|
| 635 | Group: Development/Tools |
---|
| 636 | Version: %{gcc_rpmvers} |
---|
| 637 | %{?_with_noarch_subpackages:BuildArch: noarch} |
---|
[e2e8537] | 638 | Requires: rtems-4.11-i386-rtems4.11-newlib = %{newlib_version}-10%{?dist} |
---|
[bf862710] | 639 | License: GPL |
---|
| 640 | |
---|
| 641 | %description -n rtems-4.11-i386-rtems4.11-gcc-libgcc |
---|
| 642 | libgcc i386-rtems4.11-gcc. |
---|
| 643 | |
---|
| 644 | |
---|
| 645 | %files -n rtems-4.11-i386-rtems4.11-gcc |
---|
| 646 | %defattr(-,root,root) |
---|
| 647 | %dir %{_prefix} |
---|
| 648 | |
---|
| 649 | %dir %{_mandir} |
---|
| 650 | %dir %{_mandir}/man1 |
---|
| 651 | %{_mandir}/man1/i386-rtems4.11-gcc.1* |
---|
| 652 | %{_mandir}/man1/i386-rtems4.11-cpp.1* |
---|
| 653 | %{_mandir}/man1/i386-rtems4.11-gcov.1* |
---|
| 654 | |
---|
| 655 | %dir %{_bindir} |
---|
| 656 | %{_bindir}/i386-rtems4.11-cpp%{_exeext} |
---|
| 657 | %{_bindir}/i386-rtems4.11-gcc%{_exeext} |
---|
| 658 | %{_bindir}/i386-rtems4.11-gcc-%{gcc_version}%{_exeext} |
---|
| 659 | %{_bindir}/i386-rtems4.11-gcov%{_exeext} |
---|
| 660 | %{_bindir}/i386-rtems4.11-gccbug |
---|
| 661 | |
---|
| 662 | %dir %{_libexecdir} |
---|
| 663 | %dir %{_libexecdir}/gcc |
---|
| 664 | %dir %{_libexecdir}/gcc/i386-rtems4.11 |
---|
| 665 | %dir %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version} |
---|
| 666 | %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/cc1%{_exeext} |
---|
| 667 | %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/collect2%{_exeext} |
---|
[9e84c716] | 668 | %if "%{gcc_version}" >= "4.5.0" |
---|
| 669 | %{?with_lto:%{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/lto%{_exeext}} |
---|
| 670 | %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/lto-wrapper%{_exeext} |
---|
| 671 | %endif |
---|
[bf862710] | 672 | |
---|
| 673 | %files -n rtems-4.11-i386-rtems4.11-gcc-libgcc -f build/files.gcc |
---|
| 674 | %defattr(-,root,root) |
---|
| 675 | %dir %{_prefix} |
---|
| 676 | %dir %{_gcclibdir} |
---|
| 677 | %dir %{_gcclibdir}/gcc |
---|
| 678 | %dir %{_gcclibdir}/gcc/i386-rtems4.11 |
---|
| 679 | %dir %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version} |
---|
| 680 | %dir %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include |
---|
| 681 | |
---|
| 682 | %if "%{gcc_version}" > "4.0.3" |
---|
| 683 | %dir %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include/ssp |
---|
| 684 | %endif |
---|
| 685 | |
---|
| 686 | %if "%{gcc_version}" >= "4.3.0" |
---|
| 687 | %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include-fixed |
---|
| 688 | %endif |
---|
| 689 | |
---|
| 690 | # ============================================================== |
---|
| 691 | # rtems-4.11-gcc-common |
---|
| 692 | # ============================================================== |
---|
| 693 | %package -n rtems-4.11-gcc-common |
---|
| 694 | Summary: Base package for rtems gcc and newlib C Library |
---|
| 695 | Group: Development/Tools |
---|
| 696 | Version: %{gcc_rpmvers} |
---|
| 697 | %{?_with_noarch_subpackages:BuildArch: noarch} |
---|
| 698 | License: GPL |
---|
| 699 | |
---|
| 700 | Requires(post): /sbin/install-info |
---|
| 701 | Requires(preun): /sbin/install-info |
---|
| 702 | |
---|
| 703 | %description -n rtems-4.11-gcc-common |
---|
| 704 | GCC files that are shared by all targets. |
---|
| 705 | |
---|
| 706 | %files -n rtems-4.11-gcc-common |
---|
| 707 | %defattr(-,root,root) |
---|
| 708 | %dir %{_prefix} |
---|
| 709 | %dir %{_prefix}/share |
---|
| 710 | |
---|
| 711 | %dir %{_infodir} |
---|
| 712 | %ghost %{_infodir}/dir |
---|
| 713 | %{_infodir}/cpp.info* |
---|
| 714 | %{_infodir}/cppinternals.info* |
---|
| 715 | %{_infodir}/gcc.info* |
---|
| 716 | %{_infodir}/gccint.info* |
---|
| 717 | %{_infodir}/gccinstall.info* |
---|
| 718 | |
---|
| 719 | %dir %{_mandir} |
---|
| 720 | %dir %{_mandir}/man7 |
---|
| 721 | %{_mandir}/man7/fsf-funding.7* |
---|
| 722 | %{_mandir}/man7/gfdl.7* |
---|
| 723 | %{_mandir}/man7/gpl.7* |
---|
| 724 | |
---|
| 725 | %post -n rtems-4.11-gcc-common |
---|
| 726 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/cpp.info.gz || : |
---|
| 727 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/cppinternals.info.gz || : |
---|
| 728 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gcc.info.gz || : |
---|
| 729 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gccint.info.gz || : |
---|
| 730 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gccinstall.info.gz || : |
---|
| 731 | |
---|
| 732 | %preun -n rtems-4.11-gcc-common |
---|
| 733 | if [ $1 -eq 0 ]; then |
---|
| 734 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/cpp.info.gz || : |
---|
| 735 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/cppinternals.info.gz || : |
---|
| 736 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gcc.info.gz || : |
---|
| 737 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gccint.info.gz || : |
---|
| 738 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gccinstall.info.gz || : |
---|
| 739 | fi |
---|
| 740 | |
---|
| 741 | # ============================================================== |
---|
| 742 | # rtems-4.11-i386-rtems4.11-gcc-c++ |
---|
| 743 | # ============================================================== |
---|
| 744 | %package -n rtems-4.11-i386-rtems4.11-gcc-c++ |
---|
| 745 | Summary: GCC c++ compiler for i386-rtems4.11 |
---|
| 746 | Group: Development/Tools |
---|
| 747 | Version: %{gcc_rpmvers} |
---|
| 748 | License: GPL |
---|
| 749 | Requires: rtems-4.11-i386-rtems4.11-gcc-libstdc++ = %{gcc_rpmvers}-%{release} |
---|
| 750 | |
---|
| 751 | %if "%{_build}" != "%{_host}" |
---|
| 752 | BuildRequires: rtems-4.11-i386-rtems4.11-gcc-c++ = %{gcc_rpmvers} |
---|
| 753 | %endif |
---|
| 754 | |
---|
| 755 | Requires: rtems-4.11-gcc-common |
---|
| 756 | Requires: rtems-4.11-i386-rtems4.11-gcc = %{gcc_rpmvers}-%{release} |
---|
| 757 | |
---|
| 758 | %description -n rtems-4.11-i386-rtems4.11-gcc-c++ |
---|
| 759 | GCC c++ compiler for i386-rtems4.11. |
---|
| 760 | |
---|
| 761 | |
---|
| 762 | %package -n rtems-4.11-i386-rtems4.11-gcc-libstdc++ |
---|
| 763 | Summary: libstdc++ for i386-rtems4.11 |
---|
| 764 | Group: Development/Tools |
---|
| 765 | Version: %{gcc_rpmvers} |
---|
| 766 | %{?_with_noarch_subpackages:BuildArch: noarch} |
---|
| 767 | License: GPL |
---|
| 768 | |
---|
| 769 | %description -n rtems-4.11-i386-rtems4.11-gcc-libstdc++ |
---|
| 770 | %{summary} |
---|
| 771 | |
---|
| 772 | |
---|
| 773 | %files -n rtems-4.11-i386-rtems4.11-gcc-c++ |
---|
| 774 | %defattr(-,root,root) |
---|
| 775 | %dir %{_prefix} |
---|
| 776 | |
---|
| 777 | %dir %{_mandir} |
---|
| 778 | %dir %{_mandir}/man1 |
---|
| 779 | %{_mandir}/man1/i386-rtems4.11-g++.1* |
---|
| 780 | |
---|
| 781 | %dir %{_bindir} |
---|
| 782 | %{_bindir}/i386-rtems4.11-c++%{_exeext} |
---|
| 783 | %{_bindir}/i386-rtems4.11-g++%{_exeext} |
---|
| 784 | |
---|
| 785 | %dir %{_libexecdir} |
---|
| 786 | %dir %{_libexecdir}/gcc |
---|
| 787 | %dir %{_libexecdir}/gcc/i386-rtems4.11 |
---|
| 788 | %dir %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version} |
---|
| 789 | %{_libexecdir}/gcc/i386-rtems4.11/%{gcc_version}/cc1plus%{_exeext} |
---|
| 790 | |
---|
| 791 | |
---|
| 792 | %files -n rtems-4.11-i386-rtems4.11-gcc-libstdc++ -f build/files.g++ |
---|
| 793 | %defattr(-,root,root) |
---|
| 794 | %dir %{_prefix} |
---|
| 795 | %dir %{_gcclibdir} |
---|
| 796 | %dir %{_gcclibdir}/gcc |
---|
| 797 | %dir %{_gcclibdir}/gcc/i386-rtems4.11 |
---|
| 798 | %dir %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version} |
---|
| 799 | %dir %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include |
---|
| 800 | %{_gcclibdir}/gcc/i386-rtems4.11/%{gcc_version}/include/c++ |
---|
| 801 | |
---|
| 802 | |
---|
| 803 | |
---|
| 804 | # ============================================================== |
---|
| 805 | # rtems-4.11-i386-rtems4.11-newlib |
---|
| 806 | # ============================================================== |
---|
| 807 | %package -n rtems-4.11-i386-rtems4.11-newlib |
---|
| 808 | Summary: C Library (newlib) for i386-rtems4.11 |
---|
| 809 | Group: Development/Tools |
---|
| 810 | License: Distributable |
---|
| 811 | Version: %{newlib_version} |
---|
[e2e8537] | 812 | Release: 10%{?dist} |
---|
[bf862710] | 813 | %{?_with_noarch_subpackages:BuildArch: noarch} |
---|
| 814 | |
---|
| 815 | Requires: rtems-4.11-newlib-common |
---|
| 816 | |
---|
| 817 | %description -n rtems-4.11-i386-rtems4.11-newlib |
---|
| 818 | Newlib C Library for i386-rtems4.11. |
---|
| 819 | |
---|
| 820 | %files -n rtems-4.11-i386-rtems4.11-newlib -f build/files.newlib |
---|
| 821 | %defattr(-,root,root) |
---|
| 822 | %dir %{_exec_prefix} |
---|
| 823 | %dir %{_exec_prefix}/i386-rtems4.11 |
---|
| 824 | %{_exec_prefix}/i386-rtems4.11/include |
---|
| 825 | |
---|
| 826 | # ============================================================== |
---|
| 827 | # rtems-4.11-newlib-common |
---|
| 828 | # ============================================================== |
---|
| 829 | %package -n rtems-4.11-newlib-common |
---|
| 830 | Summary: Base package for RTEMS newlib C Library |
---|
| 831 | Group: Development/Tools |
---|
| 832 | Version: %{newlib_version} |
---|
[e2e8537] | 833 | Release: 10%{?dist} |
---|
[bf862710] | 834 | %{?_with_noarch_subpackages:BuildArch: noarch} |
---|
| 835 | License: Distributable |
---|
| 836 | |
---|
| 837 | Requires(post): /sbin/install-info |
---|
| 838 | Requires(preun): /sbin/install-info |
---|
| 839 | |
---|
| 840 | %description -n rtems-4.11-newlib-common |
---|
| 841 | newlib files that are shared by all targets. |
---|
| 842 | |
---|
| 843 | %files -n rtems-4.11-newlib-common |
---|
| 844 | %defattr(-,root,root) |
---|
| 845 | %dir %{_prefix} |
---|
| 846 | %dir %{_prefix}/share |
---|
| 847 | |
---|
| 848 | %dir %{_infodir} |
---|
| 849 | %ghost %{_infodir}/dir |
---|
| 850 | %{_infodir}/libc.info* |
---|
| 851 | %{_infodir}/libm.info* |
---|
| 852 | |
---|
| 853 | %post -n rtems-4.11-newlib-common |
---|
| 854 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/libc.info.gz || : |
---|
| 855 | /sbin/install-info --info-dir=%{_infodir} %{_infodir}/libm.info.gz || : |
---|
| 856 | |
---|
| 857 | %preun -n rtems-4.11-newlib-common |
---|
| 858 | if [ $1 -eq 0 ]; then |
---|
| 859 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/libc.info.gz || : |
---|
| 860 | /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/libm.info.gz || : |
---|
| 861 | fi |
---|
| 862 | |
---|