1 Summary: mold: A Modern Linker
6 Group: Development/Libraries
7 Source0: https://github.com/rui314/mold/archive/v%{version}/%{name}-%{version}.tar.gz
8 # Source0-md5: 49a64a18376bb6b216c05a900f4aacae
9 URL: https://github.com/rui314/mold
10 BuildRequires: libstdc++-devel >= 6:10
11 BuildRequires: mimalloc-devel >= 1.7
12 BuildRequires: openssl-devel
13 BuildRequires: pkgconfig
14 BuildRequires: tbb-devel >= 2021.3.0
15 BuildRequires: zlib-devel
16 Requires: mimalloc >= 1.7
17 Requires: tbb >= 2021.3.0
18 ExclusiveArch: %{ix86} %{x8664} aarch64 riscv64
19 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22 mold is a faster drop-in replacement for existing Unix linkers. It is
23 several times faster than LLVM lld linker, the second-fastest
24 open-source linker which I originally created a few years ago. mold is
25 created for increasing developer productivity by reducing build time
26 especially in rapid debug-edit-rebuild cycles.
31 %{__rm} -r third-party/{mimalloc,tbb}
37 CFLAGS="%{rpmcppflags} %{rpmcflags}" \
38 CXXFLAGS="%{rpmcppflags} %{rpmcxxflags}" \
39 LDFLAGS="%{rpmldflags}" \
48 rm -rf $RPM_BUILD_ROOT
61 rm -rf $RPM_BUILD_ROOT
64 %defattr(644,root,root,755)
65 %doc CONTRIBUTING.md README.md docs/*.md
66 %attr(755,root,root) %{_bindir}/ld.mold
67 %attr(755,root,root) %{_bindir}/ld64.mold
68 %attr(755,root,root) %{_bindir}/mold
70 %attr(755,root,root) %{_libdir}/mold/mold-wrapper.so
71 %dir %{_libexecdir}/mold
72 %attr(755,root,root) %{_libexecdir}/mold/ld
73 %{_mandir}/man1/mold.1*