/[packages]/updates/9/rust/current/SPECS/rust.spec
ViewVC logotype

Contents of /updates/9/rust/current/SPECS/rust.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2073578 - (show annotations) (download)
Fri Jun 14 14:42:19 2024 UTC (4 weeks, 6 days ago) by akien
File size: 37467 byte(s)
Another attempt to fix BRs (SILENT)
1 # (akien) This package is synced with Fedora / Josh Stone's spec.
2 # The aim is to work with them on a rust packaging policy we could share,
3 # so that we can ensure a good packaging and share the workload.
4
5 Name: rust
6 Version: 1.76.0
7 Release: %mkrel 1.1
8 Summary: The Rust Programming Language
9 %if 0%{?mageia}
10 Group: Development/Other
11 %endif
12 License: (Apache-2.0 OR MIT) AND (Artistic-2.0 AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0 AND Unicode-DFS-2016)
13 # ^ written as: (rust itself) and (bundled libraries)
14 URL: https://www.rust-lang.org
15
16 # Only x86_64, i686, and aarch64 are Tier 1 platforms at this time.
17 # https://doc.rust-lang.org/nightly/rustc/platform-support.html
18 %global rust_arches x86_64 i686 armv7hl aarch64 ppc64le s390x riscv64
19
20 #ExclusiveArch: %%{rust_arches} i586
21 # Temporary workaround for testing llvm17-suite, which for now is x86 only.
22 ExclusiveArch: x86_64 %ix86
23
24 %if 0%{?mageia}
25 # (akien) Added by tv in mga8/rust 1.37.0.
26 %global _python_bytecompile_extra 0
27 %endif
28
29 # To bootstrap from scratch, set the channel and date from src/stage0.json
30 # e.g. 1.59.0 wants rustc: 1.58.0-2022-01-13
31 # or nightly wants some beta-YYYY-MM-DD
32 %global bootstrap_version 1.75.0
33 %global bootstrap_channel 1.75.0
34 %global bootstrap_date 2023-12-28
35
36 # Only the specified arches will use bootstrap binaries.
37 # NOTE: Those binaries used to be uploaded with every new release, but that was
38 # a waste of lookaside cache space when they're most often unused.
39 # Run "spectool -g rust.spec" after changing this and then "fedpkg upload" to
40 # add them to sources. Remember to remove them again after the bootstrap build!
41 #global bootstrap_arches %%{rust_arches}
42
43 # Define a space-separated list of targets to ship rust-std-static-$triple for
44 # cross-compilation. The packages are noarch, but they're not fully
45 # reproducible between hosts, so only x86_64 actually builds it.
46 %ifarch x86_64
47 %if 0%{?fedora} || 0%{?mageia}
48 %global mingw_targets i686-pc-windows-gnu x86_64-pc-windows-gnu
49 %endif
50 %global wasm_targets wasm32-unknown-unknown wasm32-wasi
51 %if 0%{?fedora} || 0%{?rhel} >= 10 || 0%{?mageia}
52 %global extra_targets x86_64-unknown-none x86_64-unknown-uefi
53 %endif
54 %endif
55 %global all_targets %{?mingw_targets} %{?wasm_targets} %{?extra_targets}
56 %define target_enabled() %{lua:
57 print(string.find(rpm.expand(" %{all_targets} "), rpm.expand(" %1 "), 1, true) or 0)
58 }
59
60 # We need CRT files for *-wasi targets, at least as new as the commit in
61 # src/ci/docker/host-x86_64/dist-various-2/build-wasi-toolchain.sh
62 # (updated per https://github.com/rust-lang/rust/pull/96907)
63 %global wasi_libc_url https://github.com/WebAssembly/wasi-libc
64 #global wasi_libc_ref wasi-sdk-21
65 %global wasi_libc_ref 03b228e46bb02fcc5927253e1b8ad715072b1ae4
66 %global wasi_libc_name wasi-libc-%{wasi_libc_ref}
67 %global wasi_libc_source %{wasi_libc_url}/archive/%{wasi_libc_ref}/%{wasi_libc_name}.tar.gz
68 %global wasi_libc_dir %{_builddir}/%{wasi_libc_name}
69 %if 0%{?fedora}
70 %bcond_with bundled_wasi_libc
71 %else
72 %bcond_without bundled_wasi_libc
73 %endif
74
75 # Using llvm-static may be helpful as an opt-in, e.g. to aid LLVM rebases.
76 %bcond_without llvm_static
77
78 # We can also choose to just use Rust's bundled LLVM, in case the system LLVM
79 # is insufficient. Rust currently requires LLVM 16.0+.
80 %global min_llvm_version 16.0.0
81 %global bundled_llvm_version 17.0.6
82 %bcond_with bundled_llvm
83 # (akien) Hacks below are needed on mga's buildsystem when we have to rebootstrap llvm.
84 # Bundled LLVM has underlinking issues:
85 #%%global _disable_ld_no_undefined 1
86 #%%ifarch %%{arm} %%ix86
87 # Decrease debuginfo verbosity to reduce memory consumption during final library linking
88 #%%global optflags %%(echo %%{optflags} | sed 's/-g /-g1 /')
89 #%%endif
90
91 # Requires stable libgit2 1.7, and not the next minor soname change.
92 # This needs to be consistent with the bindings in vendor/libgit2-sys.
93 %global min_libgit2_version 1.7.1
94 %global next_libgit2_version 1.8.0~
95 %global bundled_libgit2_version 1.7.1
96 %if 0%{?fedora} >= 39 || 0%{?mageia} >= 99
97 %bcond_with bundled_libgit2
98 %else
99 %bcond_without bundled_libgit2
100 %endif
101
102 %if 0%{?rhel}
103 # Disable cargo->libgit2->libssh2 on RHEL, as it's not approved for FIPS (rhbz1732949)
104 %bcond_without disabled_libssh2
105 %else
106 %bcond_with disabled_libssh2
107 %endif
108
109 # On Mageia, we also need to use the "32-bit" path below.
110 %if 0%{?mageia}
111 %ifarch aarch64
112 %global mga_aarch64 1
113 %endif
114 %endif
115
116 # Reduce rustc's own debuginfo and optimizations to conserve 32-bit memory.
117 # e.g. https://github.com/rust-lang/rust/issues/45854
118 %global reduced_debuginfo 0
119 %if 0%{?__isa_bits} == 32
120 %global reduced_debuginfo 1
121 %endif
122 # Also on current riscv64 hardware, although future hardware will be
123 # able to handle it.
124 # e.g. http://fedora.riscv.rocks/koji/buildinfo?buildID=249870
125 # (akien) Also on aarch64 for Mageia.
126 %ifarch riscv64 aarch64
127 %global reduced_debuginfo 1
128 %endif
129
130 %if 0%{?reduced_debuginfo}
131 %global enable_debuginfo --debuginfo-level=0 --debuginfo-level-std=2
132 %global enable_rust_opts --set rust.codegen-units-std=1
133 %bcond_with rustc_pgo
134 %else
135 # Build rustc with full debuginfo, CGU=1, ThinLTO, and PGO.
136 %global enable_debuginfo --debuginfo-level=2
137 %global enable_rust_opts --set rust.codegen-units=1 --set rust.lto=thin
138 %bcond_without rustc_pgo
139 %endif
140
141 # Detect non-stable channels from the version, like 1.74.0~beta.1
142 %{lua: do
143 local version = rpm.expand("%{version}")
144 local version_channel, subs = string.gsub(version, "^.*~(%w+).*$", "%1", 1)
145 rpm.define("channel " .. (subs ~= 0 and version_channel or "stable"))
146 rpm.define("rustc_package rustc-" .. version_channel .. "-src")
147 end}
148 Source0: https://static.rust-lang.org/dist/%{rustc_package}.tar.xz
149 Source1: %{wasi_libc_source}
150 # Sources for bootstrap_arches are inserted by lua below
151
152 # By default, rust tries to use "rust-lld" as a linker for some targets.
153 Patch1: 0001-Use-lld-provided-by-system.patch
154
155 # Set a substitute-path in rust-gdb for standard library sources.
156 Patch2: rustc-1.70.0-rust-gdb-substitute-path.patch
157
158 # Override default target CPUs to match distro settings
159 # TODO: upstream this ability into the actual build configuration
160 Patch3: 0001-Let-environment-variables-override-some-default-CPUs.patch
161
162 # Override the default self-contained system libraries
163 # TODO: the first can probably be upstreamed, but the second is hard-coded,
164 # and we're only applying that if not with bundled_wasi_libc.
165 Patch4: 0001-bootstrap-allow-disabling-target-self-contained.patch
166 Patch5: 0002-set-an-external-library-path-for-wasm32-wasi.patch
167
168 # We don't want to use the bundled library in libsqlite3-sys
169 Patch6: rustc-1.76.0-unbundle-sqlite.patch
170
171 # (akien) Those tests fail on armv7 - on Fedora too, and jistone ignores them
172 # https://github.com/rust-lang/rust/issues/83453
173 Patch11: rustc-1.50.0-allow_fail-armv7-instruction_set.patch
174
175 ### RHEL-specific patches below ###
176
177 # Simple rpm macros for rust-toolset (as opposed to full rust-packaging)
178 Source100: macros.rust-toolset
179 Source101: macros.rust-srpm
180 Source102: cargo_vendor.attr
181 Source103: cargo_vendor.prov
182
183 # Disable cargo->libgit2->libssh2 on RHEL, as it's not approved for FIPS (rhbz1732949)
184 Patch100: rustc-1.76.0-disable-libssh2.patch
185
186 # Get the Rust triple for any arch.
187 %{lua: function rust_triple(arch)
188 local abi = "gnu"
189 if arch == "armv7hl" then
190 arch = "armv7"
191 abi = "gnueabihf"
192 elseif arch == "ppc64" then
193 arch = "powerpc64"
194 elseif arch == "ppc64le" then
195 arch = "powerpc64le"
196 elseif arch == "riscv64" then
197 arch = "riscv64gc"
198 end
199 return arch.."-unknown-linux-"..abi
200 end}
201
202 %global rust_triple %{lua: print(rust_triple(rpm.expand("%{_target_cpu}")))}
203
204 # Get the environment form of the Rust triple
205 %global rust_triple_env %{lua:
206 print(string.upper(string.gsub(rpm.expand("%{rust_triple}"), "-", "_")))
207 }
208
209 %if %defined bootstrap_arches
210 # For each bootstrap arch, add an additional binary Source.
211 # Also define bootstrap_source just for the current target.
212 %{lua: do
213 local bootstrap_arches = {}
214 for arch in string.gmatch(rpm.expand("%{bootstrap_arches}"), "%S+") do
215 table.insert(bootstrap_arches, arch)
216 end
217 local base = rpm.expand("https://static.rust-lang.org/dist/%{bootstrap_date}")
218 local channel = rpm.expand("%{bootstrap_channel}")
219 local target_arch = rpm.expand("%{_target_cpu}")
220 for i, arch in ipairs(bootstrap_arches) do
221 i = 1000 + i * 3
222 local suffix = channel.."-"..rust_triple(arch)
223 print(string.format("Source%d: %s/cargo-%s.tar.xz\n", i, base, suffix))
224 print(string.format("Source%d: %s/rustc-%s.tar.xz\n", i+1, base, suffix))
225 print(string.format("Source%d: %s/rust-std-%s.tar.xz\n", i+2, base, suffix))
226 if arch == target_arch then
227 rpm.define("bootstrap_source_cargo "..i)
228 rpm.define("bootstrap_source_rustc "..i+1)
229 rpm.define("bootstrap_source_std "..i+2)
230 rpm.define("bootstrap_suffix "..suffix)
231 end
232 end
233 end}
234 %endif
235
236 %ifarch %{bootstrap_arches}
237 %global local_rust_root %{_builddir}/rust-%{bootstrap_suffix}
238 Provides: bundled(%{name}-bootstrap) = %{bootstrap_version}
239 %else
240 BuildRequires: cargo >= %{bootstrap_version}
241 %if 0%{?mageia}
242 BuildRequires: %{name} >= %{bootstrap_version}
243 BuildConflicts: %{name} > %{version}
244 %else
245 BuildRequires: (%{name} >= %{bootstrap_version} with %{name} <= %{version})
246 %endif
247 %global local_rust_root %{_prefix}
248 %endif
249
250 BuildRequires: make
251 BuildRequires: gcc
252 BuildRequires: gcc-c++
253 BuildRequires: ncurses-devel
254 # explicit curl-devel to avoid httpd24-curl (rhbz1540167)
255 BuildRequires: curl-devel
256 BuildRequires: pkgconfig(libcurl)
257 BuildRequires: pkgconfig(liblzma)
258 BuildRequires: pkgconfig(openssl)
259 BuildRequires: pkgconfig(sqlite3)
260 BuildRequires: pkgconfig(zlib)
261
262 %if %{without bundled_libgit2}
263 %if 0%{?mageia}
264 BuildRequires: pkgconfig(libgit2) >= %{min_libgit2_version}
265 BuildRequires: pkgconfig(libgit2) < %{next_libgit2_version}
266 %else
267 BuildRequires: (pkgconfig(libgit2) >= %{min_libgit2_version} with pkgconfig(libgit2) < %{next_libgit2_version})
268 %endif
269 %endif
270
271 %if %{without disabled_libssh2}
272 BuildRequires: pkgconfig(libssh2)
273 %endif
274
275 %if 0%{?rhel} == 8
276 BuildRequires: platform-python
277 %else
278 BuildRequires: python3
279 %endif
280 BuildRequires: python3-rpm-macros
281
282 %if %with bundled_llvm
283 BuildRequires: cmake >= 3.20.0
284 BuildRequires: ninja-build
285 Provides: bundled(llvm) = %{bundled_llvm_version}
286 %else
287 BuildRequires: cmake >= 3.5.1
288 %define llvm llvm17
289 %if %defined llvm
290 %global llvm_root %{_libdir}/%{llvm}
291 %else
292 %global llvm llvm
293 %global llvm_root %{_prefix}
294 %endif
295 %if 0%{?mageia}
296 BuildRequires: %{llvm}-suite-devel >= %{min_llvm_version}
297 %else
298 BuildRequires: %{llvm}-devel >= %{min_llvm_version}
299 %endif
300 %if %with llvm_static
301 %if 0%{?mageia}
302 BuildRequires: %{llvm}-suite-static
303 BuildRequires: %{llvm}-suite-polly-devel
304 BuildRequires: pkgconfig(libxml-2.0)
305 %else
306 BuildRequires: %{llvm}-static
307 %endif
308 BuildRequires: libffi-devel
309 %endif
310 %endif
311
312 # LLVM seems to need libatomic on armv7hl only. May be fixed in future releases?
313 %ifarch %{arm}
314 BuildRequires: libatomic-devel
315 %endif
316
317 # make check needs "ps" for src/test/ui/wait-forked-but-failed-child.rs
318 BuildRequires: procps-ng
319
320 # debuginfo-gdb tests need gdb
321 BuildRequires: gdb
322
323 # For src/test/run-make/static-pie
324 %if 0%{?mageia}
325 BuildRequires: glibc-static-devel
326 %else
327 BuildRequires: glibc-static
328 %endif
329
330 # Virtual provides for folks who attempt "dnf install rustc"
331 Provides: rustc = %{version}-%{release}
332 Provides: rustc%{?_isa} = %{version}-%{release}
333
334 # Always require our exact standard library
335 Requires: %{name}-std-static%{?_isa} = %{version}-%{release}
336
337 # The C compiler is needed at runtime just for linking. Someday rustc might
338 # invoke the linker directly, and then we'll only need binutils.
339 # https://github.com/rust-lang/rust/issues/11937
340 %if 0%{?mageia}
341 Requires: gcc
342 %else
343 Requires: /usr/bin/cc
344 %endif
345
346 %global __ranlib %{_bindir}/ranlib
347
348 # ALL Rust libraries are private, because they don't keep an ABI.
349 %global _privatelibs lib(.*-[[:xdigit:]]{16}*|rustc.*)[.]so.*
350 %global __provides_exclude ^(%{_privatelibs})$
351 %global __requires_exclude ^(%{_privatelibs})$
352 %global __provides_exclude_from ^(%{_docdir}|%{rustlibdir}/src)/.*$
353 %global __requires_exclude_from ^(%{_docdir}|%{rustlibdir}/src)/.*$
354
355 # While we don't want to encourage dynamic linking to Rust shared libraries, as
356 # there's no stable ABI, we still need the unallocated metadata (.rustc) to
357 # support custom-derive plugins like #[proc_macro_derive(Foo)].
358 %global _find_debuginfo_opts --keep-section .rustc
359
360 %if %{without bundled_llvm}
361 %if "%{llvm_root}" == "%{_prefix}" || 0%{?scl:1}
362 %global llvm_has_filecheck 1
363 %endif
364 %endif
365
366 # We're going to override --libdir when configuring to get rustlib into a
367 # common path, but we'll fix the shared libraries during install.
368 %global common_libdir %{_prefix}/lib
369 %global rustlibdir %{common_libdir}/rustlib
370
371 %if %defined mingw_targets
372 BuildRequires: mingw32-filesystem >= 95
373 BuildRequires: mingw64-filesystem >= 95
374 BuildRequires: mingw32-crt
375 BuildRequires: mingw64-crt
376 BuildRequires: mingw32-gcc
377 BuildRequires: mingw64-gcc
378 BuildRequires: mingw32-winpthreads-static
379 BuildRequires: mingw64-winpthreads-static
380 %endif
381
382 %if %defined wasm_targets
383 %if %with bundled_wasi_libc
384 BuildRequires: clang
385 %else
386 BuildRequires: wasi-libc-static
387 %endif
388 BuildRequires: lld
389 # brp-strip-static-archive breaks the archive index for wasm
390 %global __os_install_post \
391 %__os_install_post \
392 find '%{buildroot}%{rustlibdir}'/wasm*/lib -type f -regex '.*\\.\\(a\\|rlib\\)' -print -exec '%{llvm_root}/bin/llvm-ranlib' '{}' ';' \
393 %{nil}
394 %endif
395
396 # For profiler_builtins
397 BuildRequires: compiler-rt
398 %if 0%{?mageia}
399 BuildRequires: rpm_macro(clang_major_version)
400 %endif
401
402 # This component was removed as of Rust 1.69.0.
403 # https://github.com/rust-lang/rust/pull/101841
404 Obsoletes: %{name}-analysis < 1.69.0~
405
406 %description
407 Rust is a systems programming language that runs blazingly fast, prevents
408 segfaults, and guarantees thread safety.
409
410 This package includes the Rust compiler and documentation generator.
411
412
413 %package std-static
414 Summary: Standard library for Rust
415 Provides: %{name}-std-static-%{rust_triple} = %{version}-%{release}
416 Requires: %{name} = %{version}-%{release}
417 Requires: glibc-devel%{?_isa} >= 2.17
418
419 %description std-static
420 This package includes the standard libraries for building applications
421 written in Rust.
422
423 %global target_package() \
424 %package std-static-%1 \
425 Summary: Standard library for Rust %1 \
426 Requires: %{name} = %{version}-%{release}
427
428 %global target_description() \
429 %description std-static-%1 \
430 This package includes the standard libraries for building applications \
431 written in Rust for the %2 target %1.
432
433 %if %target_enabled i686-pc-windows-gnu
434 %target_package i686-pc-windows-gnu
435 Requires: mingw32-crt
436 Requires: mingw32-gcc
437 Requires: mingw32-winpthreads-static
438 Provides: mingw32-rust = %{version}-%{release}
439 Provides: mingw32-rustc = %{version}-%{release}
440 BuildArch: noarch
441 %target_description i686-pc-windows-gnu MinGW
442 %endif
443
444 %if %target_enabled x86_64-pc-windows-gnu
445 %target_package x86_64-pc-windows-gnu
446 Requires: mingw64-crt
447 Requires: mingw64-gcc
448 Requires: mingw64-winpthreads-static
449 Provides: mingw64-rust = %{version}-%{release}
450 Provides: mingw64-rustc = %{version}-%{release}
451 BuildArch: noarch
452 %target_description x86_64-pc-windows-gnu MinGW
453 %endif
454
455 %if %target_enabled wasm32-unknown-unknown
456 %target_package wasm32-unknown-unknown
457 Requires: lld >= 8.0
458 BuildArch: noarch
459 %target_description wasm32-unknown-unknown WebAssembly
460 %endif
461
462 %if %target_enabled wasm32-wasi
463 %target_package wasm32-wasi
464 Requires: lld >= 8.0
465 %if %with bundled_wasi_libc
466 Provides: bundled(wasi-libc)
467 %else
468 Requires: wasi-libc-static
469 %endif
470 BuildArch: noarch
471 %target_description wasm32-wasi WebAssembly
472 %endif
473
474 %if %target_enabled x86_64-unknown-none
475 %target_package x86_64-unknown-none
476 Requires: lld
477 %target_description x86_64-unknown-none embedded
478 %endif
479
480 %if %target_enabled x86_64-unknown-uefi
481 %target_package x86_64-unknown-uefi
482 Requires: lld
483 %target_description x86_64-unknown-uefi embedded
484 %endif
485
486
487 %package debugger-common
488 Summary: Common debugger pretty printers for Rust
489 BuildArch: noarch
490
491 %description debugger-common
492 This package includes the common functionality for %{name}-gdb and %{name}-lldb.
493
494
495 %package gdb
496 Summary: GDB pretty printers for Rust
497 BuildArch: noarch
498 Requires: gdb
499 Requires: %{name}-debugger-common = %{version}-%{release}
500
501 %description gdb
502 This package includes the rust-gdb script, which allows easier debugging of Rust
503 programs.
504
505
506 %package lldb
507 Summary: LLDB pretty printers for Rust
508 BuildArch: noarch
509 Requires: lldb
510 Requires: python3-lldb
511 Requires: %{name}-debugger-common = %{version}-%{release}
512
513 %description lldb
514 This package includes the rust-lldb script, which allows easier debugging of Rust
515 programs.
516
517
518 %package doc
519 Summary: Documentation for Rust
520 # NOT BuildArch: noarch
521 # Note, while docs are mostly noarch, some things do vary by target_arch.
522 # Koji will fail the build in rpmdiff if two architectures build a noarch
523 # subpackage differently, so instead we have to keep its arch.
524
525 # Cargo no longer builds its own documentation
526 # https://github.com/rust-lang/cargo/pull/4904
527 # We used to keep a shim cargo-doc package, but now that's merged too.
528 Obsoletes: cargo-doc < 1.65.0~
529 Provides: cargo-doc = %{version}-%{release}
530
531 %description doc
532 This package includes HTML documentation for the Rust programming language and
533 its standard library.
534
535
536 %package -n cargo
537 Summary: Rust's package manager and build tool
538 %if %with bundled_libgit2
539 Provides: bundled(libgit2) = %{bundled_libgit2_version}
540 %endif
541 # For tests:
542 BuildRequires: git-core
543 # Cargo is not much use without Rust
544 Requires: %{name}
545
546 # "cargo vendor" is a builtin command starting with 1.37. The Obsoletes and
547 # Provides are mostly relevant to RHEL, but harmless to have on Fedora/etc. too
548 Obsoletes: cargo-vendor <= 0.1.23
549 Provides: cargo-vendor = %{version}-%{release}
550
551 %description -n cargo
552 Cargo is a tool that allows Rust projects to declare their various dependencies
553 and ensure that you'll always get a repeatable build.
554
555
556 %package -n rustfmt
557 Summary: Tool to find and fix Rust formatting issues
558 Requires: cargo
559
560 # /usr/bin/rustfmt is dynamically linked against internal rustc libs
561 Requires: %{name}%{?_isa} = %{version}-%{release}
562
563 # The component/package was rustfmt-preview until Rust 1.31.
564 Obsoletes: rustfmt-preview < 1.0.0
565 Provides: rustfmt-preview = %{version}-%{release}
566
567 %description -n rustfmt
568 A tool for formatting Rust code according to style guidelines.
569
570
571 %package analyzer
572 Summary: Rust implementation of the Language Server Protocol
573
574 # The standard library sources are needed for most functionality.
575 Recommends: %{name}-src
576
577 # RLS is no longer available as of Rust 1.65, but we're including the stub
578 # binary that implements LSP just enough to recommend rust-analyzer.
579 Obsoletes: rls < 1.65.0~
580 # The component/package was rls-preview until Rust 1.31.
581 Obsoletes: rls-preview < 1.31.6
582
583 %description analyzer
584 rust-analyzer is an implementation of Language Server Protocol for the Rust
585 programming language. It provides features like completion and goto definition
586 for many code editors, including VS Code, Emacs and Vim.
587
588
589 %package -n clippy
590 Summary: Lints to catch common mistakes and improve your Rust code
591 Requires: cargo
592 # /usr/bin/clippy-driver is dynamically linked against internal rustc libs
593 Requires: %{name}%{?_isa} = %{version}-%{release}
594
595 # The component/package was clippy-preview until Rust 1.31.
596 Obsoletes: clippy-preview <= 0.0.212
597 Provides: clippy-preview = %{version}-%{release}
598
599 %description -n clippy
600 A collection of lints to catch common mistakes and improve your Rust code.
601
602
603 %package src
604 Summary: Sources for the Rust standard library
605 BuildArch: noarch
606 Recommends: %{name}-std-static = %{version}-%{release}
607
608 %description src
609 This package includes source files for the Rust standard library. It may be
610 useful as a reference for code completion tools in various editors.
611
612
613 %if 0%{?rhel}
614
615 %package srpm-macros
616 Summary: RPM macros for building Rust source packages
617 BuildArch: noarch
618
619 %description srpm-macros
620 RPM macros for building source packages for Rust projects.
621
622
623 %package toolset
624 Summary: Rust Toolset
625 BuildArch: noarch
626 Requires: rust = %{version}-%{release}
627 Requires: cargo = %{version}-%{release}
628
629 %description toolset
630 This is the metapackage for Rust Toolset, bringing in the Rust compiler,
631 the Cargo package manager, and a few convenience macros for rpm builds.
632
633 %endif
634
635
636 %prep
637
638 %ifarch %{bootstrap_arches}
639 rm -rf %{local_rust_root}
640 %setup -q -n cargo-%{bootstrap_suffix} -T -b %{bootstrap_source_cargo}
641 ./install.sh --prefix=%{local_rust_root} --disable-ldconfig
642 %setup -q -n rustc-%{bootstrap_suffix} -T -b %{bootstrap_source_rustc}
643 ./install.sh --prefix=%{local_rust_root} --disable-ldconfig
644 %setup -q -n rust-std-%{bootstrap_suffix} -T -b %{bootstrap_source_std}
645 ./install.sh --prefix=%{local_rust_root} --disable-ldconfig
646 test -f '%{local_rust_root}/bin/cargo'
647 test -f '%{local_rust_root}/bin/rustc'
648 %endif
649
650 %if %{defined wasm_targets} && %{with bundled_wasi_libc}
651 %setup -q -n %{wasi_libc_name} -T -b 1
652 rm -rf %{wasi_libc_dir}/dlmalloc/
653 %endif
654
655 %setup -q -n %{rustc_package}
656
657 %patch -P1 -p1
658 %patch -P2 -p1
659 %patch -P3 -p1
660 %patch -P4 -p1
661 %if %without bundled_wasi_libc
662 %patch -P5 -p1
663 %endif
664 %patch -P6 -p1
665
666 %patch -P11 -p1
667
668 %if %with disabled_libssh2
669 %patch -P100 -p1
670 %endif
671
672 # Use our explicit python3 first
673 sed -i.try-python -e '/^try python3 /i try "%{__python3}" "$@"' ./configure
674
675 # Set a substitute-path in rust-gdb for standard library sources.
676 sed -i.rust-src -e "s#@BUILDDIR@#$PWD#" ./src/etc/rust-gdb
677
678 %if %without bundled_llvm
679 rm -rf src/llvm-project/
680 mkdir -p src/llvm-project/libunwind/
681 %endif
682
683 # Remove other unused vendored libraries. This leaves the directory in place,
684 # because some build scripts watch them, e.g. "cargo:rerun-if-changed=curl".
685 %define clear_dir() find ./%1 -mindepth 1 -delete
686 %clear_dir vendor/curl-sys*/curl/
687 %clear_dir vendor/*jemalloc-sys*/jemalloc/
688 %clear_dir vendor/libffi-sys*/libffi/
689 %clear_dir vendor/libmimalloc-sys*/c_src/mimalloc/
690 %clear_dir vendor/libsqlite3-sys*/{sqlite3,sqlcipher}/
691 %clear_dir vendor/libssh2-sys*/libssh2/
692 %clear_dir vendor/libz-sys*/src/zlib{,-ng}/
693 %clear_dir vendor/lzma-sys*/xz-*/
694 %clear_dir vendor/openssl-src*/openssl/
695
696 %if %without bundled_libgit2
697 %clear_dir vendor/libgit2-sys*/libgit2/
698 %endif
699
700 %if %with disabled_libssh2
701 rm -rf vendor/libssh2-sys*/
702 %endif
703
704 # This only affects the transient rust-installer, but let it use our dynamic xz-libs
705 sed -i.lzma -e '/LZMA_API_STATIC/d' src/bootstrap/src/core/build_steps/tool.rs
706
707 %if %{without bundled_llvm} && %{with llvm_static}
708 # Static linking to distro LLVM needs to add -lffi
709 # https://github.com/rust-lang/rust/issues/34486
710 sed -i.ffi -e '$a #[link(name = "ffi")] extern {}' \
711 compiler/rustc_llvm/src/lib.rs
712 %endif
713
714 # The configure macro will modify some autoconf-related files, which upsets
715 # cargo when it tries to verify checksums in those files. If we just truncate
716 # that file list, cargo won't have anything to complain about.
717 find vendor -name .cargo-checksum.json \
718 -exec sed -i.uncheck -e 's/"files":{[^}]*}/"files":{ }/' '{}' '+'
719
720 # Sometimes Rust sources start with #![...] attributes, and "smart" editors think
721 # it's a shebang and make them executable. Then brp-mangle-shebangs gets upset...
722 find -name '*.rs' -type f -perm /111 -exec chmod -v -x '{}' '+'
723
724 # The distro flags are only appropriate for the host, not our cross-targets,
725 # and they're not as fine-grained as the settings we choose for std vs rustc.
726 %if %defined build_rustflags
727 %global build_rustflags %{nil}
728 %endif
729
730 # These are similar to __cflags_arch_* in /usr/lib/rpm/redhat/macros
731 %global rustc_target_cpus %{lua: do
732 local fedora = tonumber(rpm.expand("0%{?fedora}"))
733 local rhel = tonumber(rpm.expand("0%{?rhel}"))
734 local env =
735 " RUSTC_TARGET_CPU_X86_64=x86-64" .. ((rhel >= 10) and "-v3" or (rhel == 9) and "-v2" or "")
736 .. " RUSTC_TARGET_CPU_PPC64LE=" .. ((rhel >= 9) and "pwr9" or "pwr8")
737 .. " RUSTC_TARGET_CPU_S390X=" ..
738 ((rhel >= 9) and "z14" or (rhel == 8 or fedora >= 38) and "z13" or
739 (fedora >= 26) and "zEC12" or (rhel == 7) and "z196" or "z10")
740 print(env)
741 end}
742
743 # Set up shared environment variables for build/install/check.
744 # *_USE_PKG_CONFIG=1 convinces *-sys crates to use the system library.
745 %global rust_env %{shrink:
746 %{?rustflags:RUSTFLAGS="%{rustflags}"}
747 %{rustc_target_cpus}
748 LIBSQLITE3_SYS_USE_PKG_CONFIG=1
749 %{!?with_disabled_libssh2:LIBSSH2_SYS_USE_PKG_CONFIG=1}
750 }
751 %global export_rust_env export %{rust_env}
752
753 %build
754 %{export_rust_env}
755
756 # Some builders have relatively little memory for their CPU count.
757 # At least 2GB per CPU is a good rule of thumb for building rustc.
758 ncpus=$(/usr/bin/getconf _NPROCESSORS_ONLN)
759 max_cpus=$(( ($(free -g | awk '/^Mem:/{print $2}') + 1) / 2 ))
760 if [ "$max_cpus" -ge 1 -a "$max_cpus" -lt "$ncpus" ]; then
761 ncpus="$max_cpus"
762 fi
763 %ifarch aarch64 %{arm}
764 ncpus="2"
765 %endif
766
767 %if %defined mingw_targets
768 %define mingw_target_config %{shrink:
769 --set target.i686-pc-windows-gnu.linker=%{mingw32_cc}
770 --set target.i686-pc-windows-gnu.cc=%{mingw32_cc}
771 --set target.i686-pc-windows-gnu.ar=%{mingw32_ar}
772 --set target.i686-pc-windows-gnu.ranlib=%{mingw32_ranlib}
773 --set target.i686-pc-windows-gnu.self-contained=false
774 --set target.x86_64-pc-windows-gnu.linker=%{mingw64_cc}
775 --set target.x86_64-pc-windows-gnu.cc=%{mingw64_cc}
776 --set target.x86_64-pc-windows-gnu.ar=%{mingw64_ar}
777 --set target.x86_64-pc-windows-gnu.ranlib=%{mingw64_ranlib}
778 --set target.x86_64-pc-windows-gnu.self-contained=false
779 }
780 %endif
781
782 %if %defined wasm_targets
783 %if %with bundled_wasi_libc
784 %make_build --quiet -C %{wasi_libc_dir} MALLOC_IMPL=emmalloc CC=clang AR=llvm-ar NM=llvm-nm
785 %define wasm_target_config --set target.wasm32-wasi.wasi-root=%{wasi_libc_dir}/sysroot
786 %else
787 %define wasm_target_config %{shrink:
788 --set target.wasm32-wasi.wasi-root=%{_prefix}/wasm32-wasi
789 --set target.wasm32-wasi.self-contained=false
790 }
791 %endif
792 %endif
793
794 # Find the compiler-rt library for the Rust profiler_builtins crate.
795 %if 0%{?clang_major_version} >= 17
796 %if 0%{?mageia}
797 %ifarch %{arm32}
798 %define _gnu -gnueabihf
799 %endif
800 %define profiler %{clang_resource_dir}/lib/%{_arch}-%{_real_vendor}-linux%{?_gnu}/libclang_rt.profile.a
801 %else
802 %define profiler %{clang_resource_dir}/lib/%{_arch}-redhat-linux-gnu/libclang_rt.profile.a
803 %endif
804 %else
805 # The exact profiler path is version dependent..
806 %if 0%{?mageia}
807 clang_arch=%{_arch}
808 %ifarch armv7hl
809 clang_arch=armhf
810 %endif
811 %define profiler %{_libdir}/clang/%{clang_major_version}/lib/libclang_rt.profile-$clang_arch.a
812 %else
813 %define profiler %(echo %{_libdir}/clang/??/lib/libclang_rt.profile-*.a)
814 %endif
815 %endif
816 test -r "%{profiler}"
817
818 %configure --disable-option-checking \
819 --libdir=%{common_libdir} \
820 --build=%{rust_triple} --host=%{rust_triple} --target=%{rust_triple} \
821 --set target.%{rust_triple}.linker=%{__cc} \
822 --set target.%{rust_triple}.cc=%{__cc} \
823 --set target.%{rust_triple}.cxx=%{__cxx} \
824 --set target.%{rust_triple}.ar=%{__ar} \
825 --set target.%{rust_triple}.ranlib=%{__ranlib} \
826 --set target.%{rust_triple}.profiler="%{profiler}" \
827 %{?mingw_target_config} \
828 %{?wasm_target_config} \
829 --python=%{__python3} \
830 --local-rust-root=%{local_rust_root} \
831 --set build.rustfmt=/bin/true \
832 %{!?with_bundled_llvm: --llvm-root=%{llvm_root} \
833 %{!?llvm_has_filecheck: --disable-codegen-tests} \
834 %{!?with_llvm_static: --enable-llvm-link-shared } } \
835 --disable-llvm-static-stdcpp \
836 --disable-rpath \
837 %{enable_debuginfo} \
838 %{enable_rust_opts} \
839 --set build.build-stage=2 \
840 --set build.doc-stage=2 \
841 --set build.install-stage=2 \
842 --set build.test-stage=2 \
843 --enable-extended \
844 --tools=cargo,clippy,rls,rust-analyzer,rustfmt,src \
845 --enable-vendor \
846 --enable-verbose-tests \
847 --dist-compression-formats=gz \
848 --release-channel=%{channel} \
849 --release-description="%{?mageia:Mageia }%{?fedora:Fedora }%{?rhel:Red Hat }%{version}-%{release}"
850
851 %global __x %{__python3} ./x.py
852 %global __xk %{__x} --keep-stage=0 --keep-stage=1
853
854 %if %with rustc_pgo
855 # Build the compiler with profile instrumentation
856 PROFRAW="$PWD/build/profiles"
857 PROFDATA="$PWD/build/rustc.profdata"
858 mkdir -p "$PROFRAW"
859 %{__x} build -j "$ncpus" sysroot --rust-profile-generate="$PROFRAW"
860 # Build cargo as a workload to generate compiler profiles
861 env LLVM_PROFILE_FILE="$PROFRAW/default_%%m_%%p.profraw" %{__xk} build cargo
862 llvm-profdata merge -o "$PROFDATA" "$PROFRAW"
863 rm -r "$PROFRAW" build/%{rust_triple}/stage2*/
864 # Rebuild the compiler using the profile data
865 %{__x} build -j "$ncpus" sysroot --rust-profile-use="$PROFDATA"
866 %else
867 # Build the compiler without PGO
868 %{__x} build -j "$ncpus" sysroot
869 %endif
870
871 # Build everything else normally
872 %{__xk} build
873 %{__xk} doc
874
875 for triple in %{?all_targets} ; do
876 %{__xk} build --target=$triple std
877 done
878
879 %install
880 %if 0%{?rhel} && 0%{?rhel} <= 9
881 %{?set_build_flags}
882 %endif
883 %{export_rust_env}
884
885 DESTDIR=%{buildroot} %{__xk} install
886
887 for triple in %{?all_targets} ; do
888 DESTDIR=%{buildroot} %{__xk} install --target=$triple std
889 done
890
891 # The rls stub doesn't have an install target, but we can just copy it.
892 %{__install} -t %{buildroot}%{_bindir} build/%{rust_triple}/stage2-tools-bin/rls
893
894 # These are transient files used by x.py dist and install
895 rm -rf ./build/dist/ ./build/tmp/
896
897 # Some of the components duplicate-install binaries, leaving backups we don't want
898 rm -f %{buildroot}%{_bindir}/*.old
899
900 # Make sure the shared libraries are in the proper libdir
901 %if "%{_libdir}" != "%{common_libdir}"
902 mkdir -p %{buildroot}%{_libdir}
903 find %{buildroot}%{common_libdir} -maxdepth 1 -type f -name '*.so' \
904 -exec mv -v -t %{buildroot}%{_libdir} '{}' '+'
905 %endif
906
907 # The shared libraries should be executable for debuginfo extraction.
908 find %{buildroot}%{_libdir} -maxdepth 1 -type f -name '*.so' \
909 -exec chmod -v +x '{}' '+'
910
911 # The libdir libraries are identical to those under rustlib/. It's easier on
912 # library loading if we keep them in libdir, but we do need them in rustlib/
913 # to support dynamic linking for compiler plugins, so we'll symlink.
914 find %{buildroot}%{rustlibdir}/%{rust_triple}/lib/ -maxdepth 1 -type f -name '*.so' |
915 while read lib; do
916 lib2="%{buildroot}%{_libdir}/${lib##*/}"
917 if [ -f "$lib2" ]; then
918 # make sure they're actually identical!
919 cmp "$lib" "$lib2"
920 ln -v -f -r -s -T "$lib2" "$lib"
921 fi
922 done
923
924 # Remove installer artifacts (manifests, uninstall scripts, etc.)
925 find %{buildroot}%{rustlibdir} -maxdepth 1 -type f -exec rm -v '{}' '+'
926
927 # Remove backup files from %%configure munging
928 find %{buildroot}%{rustlibdir} -type f -name '*.orig' -exec rm -v '{}' '+'
929
930 # https://fedoraproject.org/wiki/Changes/Make_ambiguous_python_shebangs_error
931 # We don't actually need to ship any of those python scripts in rust-src anyway.
932 find %{buildroot}%{rustlibdir}/src -type f -name '*.py' -exec rm -v '{}' '+'
933
934 # FIXME: __os_install_post will strip the rlibs
935 # -- should we find a way to preserve debuginfo?
936
937 # Remove unwanted documentation files (we already package them)
938 rm -f %{buildroot}%{_docdir}/%{name}/README.md
939 rm -f %{buildroot}%{_docdir}/%{name}/COPYRIGHT
940 rm -f %{buildroot}%{_docdir}/%{name}/LICENSE
941 rm -f %{buildroot}%{_docdir}/%{name}/LICENSE-APACHE
942 rm -f %{buildroot}%{_docdir}/%{name}/LICENSE-MIT
943 rm -f %{buildroot}%{_docdir}/%{name}/LICENSE-THIRD-PARTY
944 rm -f %{buildroot}%{_docdir}/%{name}/*.old
945
946 # Sanitize the HTML documentation
947 find %{buildroot}%{_docdir}/%{name}/html -empty -delete
948 find %{buildroot}%{_docdir}/%{name}/html -type f -exec chmod -x '{}' '+'
949
950 # Create the path for crate-devel packages
951 mkdir -p %{buildroot}%{_datadir}/cargo/registry
952
953 # Cargo no longer builds its own documentation
954 # https://github.com/rust-lang/cargo/pull/4904
955 mkdir -p %{buildroot}%{_docdir}/cargo
956 ln -sT ../rust/html/cargo/ %{buildroot}%{_docdir}/cargo/html
957
958 # We don't want Rust copies of LLVM tools (rust-lld, rust-llvm-dwp)
959 rm -f %{buildroot}%{rustlibdir}/%{rust_triple}/bin/rust-ll*
960
961 %if 0%{?rhel}
962 # This allows users to build packages using Rust Toolset.
963 %{__install} -D -m 644 %{S:100} %{buildroot}%{rpmmacrodir}/macros.rust-toolset
964 %{__install} -D -m 644 %{S:101} %{buildroot}%{rpmmacrodir}/macros.rust-srpm
965 %{__install} -D -m 644 %{S:102} %{buildroot}%{_fileattrsdir}/cargo_vendor.attr
966 %{__install} -D -m 755 %{S:103} %{buildroot}%{_rpmconfigdir}/cargo_vendor.prov
967 %endif
968
969
970 %check
971 %if 0%{?rhel} && 0%{?rhel} <= 9
972 %{?set_build_flags}
973 %endif
974 %{export_rust_env}
975
976 # Sanity-check the installed binaries, debuginfo-stripped and all.
977 TMP_HELLO=$(mktemp -d)
978 (
979 cd "$TMP_HELLO"
980 export RUSTC=%{buildroot}%{_bindir}/rustc \
981 LD_LIBRARY_PATH="%{buildroot}%{_libdir}:$LD_LIBRARY_PATH"
982 %{buildroot}%{_bindir}/cargo init --name hello-world
983 %{buildroot}%{_bindir}/cargo run --verbose
984
985 # Sanity-check that code-coverage builds and runs
986 env RUSTFLAGS="-Cinstrument-coverage" %{buildroot}%{_bindir}/cargo run --verbose
987 test -r default_*.profraw
988
989 # Try a build sanity-check for other std-enabled targets
990 for triple in %{?mingw_targets} %{?wasm_targets}; do
991 %{buildroot}%{_bindir}/cargo build --verbose --target=$triple
992 done
993 )
994 rm -rf "$TMP_HELLO"
995
996 # The results are not stable on koji, so mask errors and just log it.
997 # Some of the larger test artifacts are manually cleaned to save space.
998
999 # Bootstrap is excluded because it's not something we ship, and a lot of its
1000 # tests are geared toward the upstream CI environment.
1001 %{__xk} test --no-fail-fast --skip src/bootstrap || :
1002 rm -rf "./build/%{rust_triple}/test/"
1003
1004 %{__xk} test --no-fail-fast cargo || :
1005 rm -rf "./build/%{rust_triple}/stage2-tools/%{rust_triple}/cit/"
1006
1007 %{__xk} test --no-fail-fast clippy || :
1008
1009 %{__xk} test --no-fail-fast rust-analyzer || :
1010
1011 %{__xk} test --no-fail-fast rustfmt || :
1012
1013
1014 %{?ldconfig_scriptlets}
1015
1016
1017 %files
1018 %license COPYRIGHT LICENSE-APACHE LICENSE-MIT
1019 %doc README.md
1020 %{_bindir}/rustc
1021 %{_bindir}/rustdoc
1022 %{_libdir}/*.so
1023 %{_libexecdir}/rust-analyzer-proc-macro-srv
1024 %{_mandir}/man1/rustc.1*
1025 %{_mandir}/man1/rustdoc.1*
1026 %dir %{rustlibdir}
1027 %dir %{rustlibdir}/%{rust_triple}
1028 %dir %{rustlibdir}/%{rust_triple}/lib
1029 %{rustlibdir}/%{rust_triple}/lib/*.so
1030
1031
1032 %files std-static
1033 %dir %{rustlibdir}
1034 %dir %{rustlibdir}/%{rust_triple}
1035 %dir %{rustlibdir}/%{rust_triple}/lib
1036 %{rustlibdir}/%{rust_triple}/lib/*.rlib
1037
1038 %global target_files() \
1039 %files std-static-%1 \
1040 %dir %{rustlibdir} \
1041 %dir %{rustlibdir}/%1 \
1042 %dir %{rustlibdir}/%1/lib \
1043 %{rustlibdir}/%1/lib/*.rlib
1044
1045 %if %target_enabled i686-pc-windows-gnu
1046 %target_files i686-pc-windows-gnu
1047 %{rustlibdir}/i686-pc-windows-gnu/lib/rs*.o
1048 %exclude %{rustlibdir}/i686-pc-windows-gnu/lib/*.dll
1049 %exclude %{rustlibdir}/i686-pc-windows-gnu/lib/*.dll.a
1050 %endif
1051
1052 %if %target_enabled x86_64-pc-windows-gnu
1053 %target_files x86_64-pc-windows-gnu
1054 %{rustlibdir}/x86_64-pc-windows-gnu/lib/rs*.o
1055 %exclude %{rustlibdir}/x86_64-pc-windows-gnu/lib/*.dll
1056 %exclude %{rustlibdir}/x86_64-pc-windows-gnu/lib/*.dll.a
1057 %endif
1058
1059 %if %target_enabled wasm32-unknown-unknown
1060 %target_files wasm32-unknown-unknown
1061 %endif
1062
1063 %if %target_enabled wasm32-wasi
1064 %target_files wasm32-wasi
1065 %if %with bundled_wasi_libc
1066 %dir %{rustlibdir}/wasm32-wasi/lib/self-contained
1067 %{rustlibdir}/wasm32-wasi/lib/self-contained/crt*.o
1068 %{rustlibdir}/wasm32-wasi/lib/self-contained/libc.a
1069 %endif
1070 %endif
1071
1072 %if %target_enabled x86_64-unknown-none
1073 %target_files x86_64-unknown-none
1074 %endif
1075
1076 %if %target_enabled x86_64-unknown-uefi
1077 %target_files x86_64-unknown-uefi
1078 %endif
1079
1080
1081 %files debugger-common
1082 %dir %{rustlibdir}
1083 %dir %{rustlibdir}/etc
1084 %{rustlibdir}/etc/rust_*.py*
1085
1086
1087 %files gdb
1088 %{_bindir}/rust-gdb
1089 %{rustlibdir}/etc/gdb_*
1090 %exclude %{_bindir}/rust-gdbgui
1091
1092
1093 %files lldb
1094 %{_bindir}/rust-lldb
1095 %{rustlibdir}/etc/lldb_*
1096
1097
1098 %files doc
1099 %docdir %{_docdir}/%{name}
1100 %dir %{_docdir}/%{name}
1101 %{_docdir}/%{name}/html
1102 # former cargo-doc
1103 %docdir %{_docdir}/cargo
1104 %dir %{_docdir}/cargo
1105 %{_docdir}/cargo/html
1106
1107
1108 %files -n cargo
1109 %license src/tools/cargo/LICENSE-{APACHE,MIT,THIRD-PARTY}
1110 %doc src/tools/cargo/README.md
1111 %{_bindir}/cargo
1112 %{_mandir}/man1/cargo*.1*
1113 %{_sysconfdir}/bash_completion.d/cargo
1114 %{_datadir}/zsh/site-functions/_cargo
1115 %dir %{_datadir}/cargo
1116 %dir %{_datadir}/cargo/registry
1117
1118
1119 %files -n rustfmt
1120 %{_bindir}/rustfmt
1121 %{_bindir}/cargo-fmt
1122 %doc src/tools/rustfmt/{README,CHANGELOG,Configurations}.md
1123 %license src/tools/rustfmt/LICENSE-{APACHE,MIT}
1124
1125
1126 %files analyzer
1127 %{_bindir}/rls
1128 %{_bindir}/rust-analyzer
1129 %doc src/tools/rust-analyzer/README.md
1130 %license src/tools/rust-analyzer/LICENSE-{APACHE,MIT}
1131
1132
1133 %files -n clippy
1134 %{_bindir}/cargo-clippy
1135 %{_bindir}/clippy-driver
1136 %doc src/tools/clippy/{README.md,CHANGELOG.md}
1137 %license src/tools/clippy/LICENSE-{APACHE,MIT}
1138
1139
1140 %files src
1141 %dir %{rustlibdir}
1142 %{rustlibdir}/src
1143
1144
1145 %if 0%{?rhel}
1146 %files srpm-macros
1147 %{rpmmacrodir}/macros.rust-srpm
1148 %{_fileattrsdir}/cargo_vendor.attr
1149 %{_rpmconfigdir}/cargo_vendor.prov
1150
1151 %files toolset
1152 %{rpmmacrodir}/macros.rust-toolset
1153 %endif

  ViewVC Help
Powered by ViewVC 1.1.30