Accepting request 957341 from home:mathletic:branches:devel:tools:compiler
Fix building for openSuse Leap 15.3 and 15.4. OBS-URL: https://build.opensuse.org/request/show/957341 OBS-URL: https://build.opensuse.org/package/show/devel:tools:compiler/mold?expand=0&rev=9
This commit is contained in:
parent
90538e3939
commit
7e3d1d3200
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Feb 23 23:29:01 UTC 2022 - Christoph G <foss@grueninger.de>
|
||||||
|
|
||||||
|
- Fix building for openSuse Leap 15.3 and 15.4.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Feb 21 07:51:37 UTC 2022 - Martin Liška <mliska@suse.cz>
|
Mon Feb 21 07:51:37 UTC 2022 - Martin Liška <mliska@suse.cz>
|
||||||
|
|
||||||
|
23
mold.spec
23
mold.spec
@ -24,16 +24,24 @@ License: AGPL-3.0-or-later
|
|||||||
URL: https://github.com/rui314/mold
|
URL: https://github.com/rui314/mold
|
||||||
Source: https://github.com/rui314/mold/archive/v%{version}/mold-%{version}.tar.gz
|
Source: https://github.com/rui314/mold/archive/v%{version}/mold-%{version}.tar.gz
|
||||||
BuildRequires: cmake
|
BuildRequires: cmake
|
||||||
|
# for openSuse Leap user newer versions or libraries from mold
|
||||||
|
%if %{suse_version} < 1550
|
||||||
|
BuildRequires: gcc10-c++
|
||||||
|
%else
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
BuildRequires: mimalloc-devel
|
BuildRequires: mimalloc-devel
|
||||||
|
BuildRequires: tbb-devel
|
||||||
|
%endif
|
||||||
BuildRequires: openssl-devel
|
BuildRequires: openssl-devel
|
||||||
BuildRequires: tbb-devel
|
|
||||||
BuildRequires: tbb-devel
|
|
||||||
BuildRequires: xxhash-devel
|
BuildRequires: xxhash-devel
|
||||||
BuildRequires: zlib-devel
|
BuildRequires: zlib-devel
|
||||||
PreReq: update-alternatives
|
PreReq: update-alternatives
|
||||||
|
|
||||||
|
%if %{suse_version} < 1550
|
||||||
|
%define build_args SYSTEM_XXHASH=1
|
||||||
|
%else
|
||||||
%define build_args SYSTEM_TBB=1 SYSTEM_XXHASH=1 SYSTEM_MIMALLOC=1
|
%define build_args SYSTEM_TBB=1 SYSTEM_XXHASH=1 SYSTEM_MIMALLOC=1
|
||||||
|
%endif
|
||||||
|
|
||||||
%description
|
%description
|
||||||
mold is a faster drop-in replacement for existing Unix linkers.
|
mold is a faster drop-in replacement for existing Unix linkers.
|
||||||
@ -46,8 +54,13 @@ build time especially in rapid debug-edit-rebuild cycles.
|
|||||||
%autosetup -p1
|
%autosetup -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
%if %{suse_version} < 1550
|
||||||
|
export CC=gcc-10
|
||||||
|
export CXX=g++-10
|
||||||
|
%else
|
||||||
export CC=gcc
|
export CC=gcc
|
||||||
export CXX=g++
|
export CXX=g++
|
||||||
|
%endif
|
||||||
export CFLAGS="%{optflags} -Wno-sign-compare"
|
export CFLAGS="%{optflags} -Wno-sign-compare"
|
||||||
export CXXFLAGS="${CFLAGS}"
|
export CXXFLAGS="${CFLAGS}"
|
||||||
export MANDIR=%{_mandir}
|
export MANDIR=%{_mandir}
|
||||||
@ -78,8 +91,14 @@ fi
|
|||||||
%{_bindir}/ld.mold
|
%{_bindir}/ld.mold
|
||||||
%{_bindir}/ld64.mold
|
%{_bindir}/ld64.mold
|
||||||
%dir %{_libdir}/mold
|
%dir %{_libdir}/mold
|
||||||
|
%{_prefix}/libexec/mold/ld
|
||||||
|
%if %{suse_version} < 1550
|
||||||
|
%dir %{_prefix}/libexec
|
||||||
|
%dir %{_prefix}/libexec/mold
|
||||||
|
%else
|
||||||
%{_libexecdir}/mold/ld
|
%{_libexecdir}/mold/ld
|
||||||
%dir %{_libexecdir}/mold
|
%dir %{_libexecdir}/mold
|
||||||
|
%endif
|
||||||
%{_libdir}/mold/mold-wrapper.so
|
%{_libdir}/mold/mold-wrapper.so
|
||||||
%{_mandir}/man1/mold.1.gz
|
%{_mandir}/man1/mold.1.gz
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user