Accepting request 1246053 from network:idm

OBS-URL: https://build.opensuse.org/request/show/1246053
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/kanidm?expand=0&rev=45
This commit is contained in:
Dominique Leuenberger 2025-02-16 21:41:07 +00:00 committed by Git OBS Bridge
commit 5efcf865ae
2 changed files with 18 additions and 4 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sat Feb 15 03:46:27 UTC 2025 - William Brown <william.brown@suse.com>
- Fix building on CentOS_9
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Feb 11 06:37:21 UTC 2025 - william.brown@suse.com Tue Feb 11 06:37:21 UTC 2025 - william.brown@suse.com

View File

@ -29,12 +29,12 @@ Source: kanidm-%{version}.tar.zst
Source1: vendor.tar.zst Source1: vendor.tar.zst
BuildRequires: cargo BuildRequires: cargo
BuildRequires: cargo-packaging
%if 0%{?is_opensuse} %if 0%{?is_opensuse}
BuildRequires: cargo-packaging
BuildRequires: llvm-clang >= 13 BuildRequires: llvm-clang >= 13
%else %else
# Sle is missing these provides. BuildRequires: clang >= 13
BuildRequires: clang15 BuildRequires: lld >= 13
%endif %endif
BuildRequires: libselinux-devel BuildRequires: libselinux-devel
BuildRequires: libudev-devel BuildRequires: libudev-devel
@ -59,7 +59,11 @@ BuildRequires: libopenssl-3-devel
Requires: %{name}-clients Requires: %{name}-clients
Requires: %{name}-unixd-clients Requires: %{name}-unixd-clients
%if 0%{?is_opensuse}
ExclusiveArch: %{rust_tier1_arches} ExclusiveArch: %{rust_tier1_arches}
%else
ExclusiveArch: x86_64
%endif
%description %description
An identity management platform written in rust that supports RADIUS, SSH Key management An identity management platform written in rust that supports RADIUS, SSH Key management
@ -120,10 +124,15 @@ export KANIDM_BUILD_PROFILE=%{kanidm_profile}
# export RUSTC_LOG='rustc_codegen_ssa::back::link=info' # export RUSTC_LOG='rustc_codegen_ssa::back::link=info'
# Dump the target features of this cpu. # Dump the target features of this cpu.
rustc --print target-cpus rustc --print target-cpus
%if 0%{?is_opensuse}
# Override buildflags, we want to use clang + lld here. It's much better/faster than bfd. # Override buildflags, we want to use clang + lld here. It's much better/faster than bfd.
%define build_rustflags -C linker=clang -C link-arg=-fuse-ld=/usr/lib/rustlib/%{_arch}-unknown-linux-gnu/bin/gcc-ld/ld.lld -C debuginfo=2 -C incremental=false %define build_rustflags -C linker=clang -C link-arg=-fuse-ld=/usr/lib/rustlib/%{_arch}-unknown-linux-gnu/bin/gcc-ld/ld.lld
%{cargo_build} --features=kanidm_unix_int/tpm,kanidm_unix_int/selinux %{cargo_build} --features=kanidm_unix_int/tpm,kanidm_unix_int/selinux
%else
CARGO_INCREMENTAL=0 CARGO_FEATURE_VENDORED=1 RUSTFLAGS="-Clink-arg=-Wl,-z,relro,-z,now -C debuginfo=2 -C strip=none -C linker=clang -C link-arg=-fuse-ld=lld" cargo build --release --features=kanidm_unix_int/selinux
%endif
%install %install
install -D -d -m 0755 %{buildroot}%{_sysconfdir} install -D -d -m 0755 %{buildroot}%{_sysconfdir}