Skip to content

Commit

Permalink
MDEV-27386: cpack rpm libsepol installed detects verison incorrectly
Browse files Browse the repository at this point in the history
... when two packages are installed.

(fc35 with i686 and x86_64 packages of libsepol installed).
$ rpm -q --qf "%{VERSION}" libsepol
3.33.3

Restricting the version to the current achitecture generates
a much more obtainable version dependency.

$ rpm -q --qf "%{VERSION}" libsepol.x86_64
3.3

This make dependency resolution easier preventing:
$ sudo dnf localinstall  MariaDB-server-10.8.0-1.fc35.x86_64.rpm ...
Last metadata expiration check: 2:06:49 ago on Thu 30 Dec 2021 14:02:32.
Error:
 Problem 1: conflicting requests
  - nothing provides libsepol >= 3.33.3 needed by MariaDB-server-10.8.0-1.fc35.x86_64

The CMAKE_SYSTEM_PROCESSOR is used in the generation of architecture
filenames so its preduent to just use the same version.
  • Loading branch information
grooverdan committed Dec 30, 2021
1 parent 5465200 commit 5d57e04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion support-files/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ IF(UNIX)
INSTALL(FILES ${out} DESTINATION ${inst_location}/policy/selinux COMPONENT SupportFiles)
ENDFOREACH()
IF(RPM)
EXECUTE_PROCESS(COMMAND rpm -q --qf "%{VERSION}" libsepol
EXECUTE_PROCESS(COMMAND rpm -q --qf "%{VERSION}" libsepol."${CMAKE_SYSTEM_PROCESSOR}"
OUTPUT_VARIABLE LIBSEPOL_VERSION RESULT_VARIABLE err)
IF (NOT err)
SET(CPACK_RPM_server_PACKAGE_REQUIRES
Expand Down

0 comments on commit 5d57e04

Please sign in to comment.