Skip to content

Commit

Permalink
Remove vendored tpm2-tss libs from Requires and Provides lists of EL …
Browse files Browse the repository at this point in the history
…packages. (#552)

Otherwise the a-i-s package conflicts with the distro's tpm2-tss package.

Cherry-pick from main of 1b88277
  • Loading branch information
arsing authored Sep 12, 2023
1 parent ed69cc4 commit d644195
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ci/install-build-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ case "$OS:$ARCH" in
pkgconfig
;;

'platform:el9:amd64')
'platform:el9:amd64')
export VENDOR_LIBTSS=1

dnf install -y \
Expand Down
16 changes: 16 additions & 0 deletions contrib/enterprise-linux/aziot-identity-service.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,22 @@ BuildRequires: pkgconfig
# Required for _unitdir to be defined, as described in https://fedoraproject.org/wiki/Packaging:Systemd
BuildRequires: systemd


# Since we vendor tpm2-tss (VENDOR_LIBTSS=1 for all CentOS and EL packages), we need to tell rpm that
# we do not want it showing up in the package's Requires or Provides lists.
# If it shows up in the Provides list it will force the distro tpm2-tss package to be uninstalled,
# and if it's removed from the Provides list but not the Requires list it will force
# the distro tpm2-tss package to be installed.
#
# Ideally we would want this to apply to $libdir/$name/*.so.* , but the regex is run on
# the sonames rather than the full path, so we need list the library names explicitly.
#
# Ref: https://docs.fedoraproject.org/en-US/packaging-guidelines/AutoProvidesAndRequiresFiltering/#_private_libraries
%global _privatelibs libtss2.*[.]so.*
%global __provides_exclude ^(%{_privatelibs})$
%global __requires_exclude ^(%{_privatelibs})$


%description
This package contains the Azure IoT device runtime, comprised of the following services:

Expand Down

0 comments on commit d644195

Please sign in to comment.