diff options
author | Robbie Harwood <rharwood@redhat.com> | 2022-10-27 15:11:36 -0400 |
---|---|---|
committer | Florian Festi <ffesti@redhat.com> | 2022-11-25 10:38:42 +0100 |
commit | 4c6052c42aee71695a0c1bde0b674e2ad6f8c96b (patch) | |
tree | ab2a0beb629b060278adfcb51e421ecf8577d252 /CMakeLists.txt | |
parent | 96f9b82e263bc83a4aacc1d8ccd729170b1a2676 (diff) | |
download | rpm-4c6052c42aee71695a0c1bde0b674e2ad6f8c96b.tar.gz |
Add rpmsort utility for sorting RPM versions
rpmsort(8) is intended for use in shell scripts. sort(1) is not RPM
versioning-aware, and attempting to work around that is fraught.
Instead, provide a wrapper around rpmvercmp() using qsort().
Fedora's grub2 has carried a version of this since 2015, and a more
complex version was also part of the grubby project (provided at
/usr/libexec/grubby/rpm-sort) since 2018. This version has been
simplified and adapted to the RPM project.
Also-authored-by: Peter Jones <pjones@redhat.com>
Signed-off-by: Peter Jones <pjones@redhat.com>
Signed-off-by: Robbie Harwood <rharwood@redhat.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 8f8678640..e3b82faa8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -321,7 +321,7 @@ endforeach() set(rpmdeps_libs librpmbuild) set(rpmlua_libs ${READLINE_LIBRARIES}) -set(rpmtools rpmdeps rpmgraph rpmlua rpmuncompress) +set(rpmtools rpmdeps rpmgraph rpmlua rpmsort rpmuncompress) if (${LIBELF_FOUND}) set(elfdeps_libs ${LIBELF_LIBRARIES}) list(APPEND rpmtools elfdeps) |