Skip to content

Commit

Permalink
Merge pull request #5187 from cgwalters/spec-cond-bootc
Browse files Browse the repository at this point in the history
packaging: Add a bcond without ostree_ext
  • Loading branch information
cgwalters authored Dec 10, 2024
2 parents 3ca929b + 31d7164 commit e601c83
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions packaging/rpm-ostree.spec
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ BuildRequires: rust
%bcond_with sanitizers
# Embedded unit tests
%bcond_with bin_unit_tests
# Don't add the ostree-container binaries
%bcond_without ostree_ext

# This is copied from the libdnf spec
%if 0%{?rhel} && ! 0%{?centos}
Expand Down Expand Up @@ -147,6 +149,10 @@ Requires: fuse3
# For container functionality
# https://github.com/coreos/rpm-ostree/issues/3286
Requires: skopeo
Requires: bootc
%if %{without ostree_ext}
Requires: ostree-cli(ostree-container)
%endif

Requires: %{name}-libs%{?_isa} = %{version}-%{release}

Expand Down Expand Up @@ -197,6 +203,9 @@ export RUSTFLAGS="%{build_rustflags}"

%install
%make_install INSTALL="install -p -c"
%if %{without ostree_ext}
rm -vrf $RPM_BUILD_ROOT/usr/libexec/libostree/ext
%endif
find $RPM_BUILD_ROOT -name '*.la' -delete

# I try to do continuous delivery via rpmdistro-gitoverlay while
Expand Down Expand Up @@ -233,7 +242,9 @@ $PYTHON autofiles.py > files \
'%{_sysconfdir}/rpm-ostreed.conf' \
'%{_prefix}/lib/systemd/system/*' \
'%{_libexecdir}/rpm-ostree*' \
%if %{with ostree_ext}
'%{_libexecdir}/libostree/ext/*' \
%endif
'%{_datadir}/polkit-1/actions/*.policy' \
'%{_datadir}/dbus-1/system-services/*' \
'%{_datadir}/bash-completion/completions/*'
Expand Down

0 comments on commit e601c83

Please sign in to comment.