RPM 4.19.0 Release Notes
September 19, 2023
Download
- Source: rpm-4.19.0.tar.bz2
- SHA256SUM: b30916dc148cbeab077797e9fc365702931e3a9a7eacf70add84153b549b3f77
Changes since 4.18.1
Overview
- New spec snippet support for dynamic spec generation
- New
sysusers.d(5)integration for automated user and group handling - Proper shell-like globbing and escaping in
%filesand CLI - Memory and address-space aware build resource allocation
- Platform detection fixes and improvements for x86 CPUs
- Chroot handling fixes
- New CMake build system
- Export of RPM libraries for CMake’s
find_package() - Adoption of Linux containers in the test-suite, replacing
fakechroot(1) - New Python binding usage examples
- Translations split off
- Removal of various deprecated and/or unused APIs
- Various internal code cleanups
General bugfixes and enhancements
Command line
- Allow piping from rpm2archive(8) (#2208)
- Add rpmsort(8) utility for sorting RPM versions
- Add
--nopreuntransand--nopostuntransscriptlet disablers (#2119) - Add
--nosysusersto disable automatic user/group creation at install time (#1032) - Conditionally display VCS tag in
--infoquery - Show the tag number for unknown tags in
--xmloutput - Check inside
--rootwhen querying for files (#2576) - Add aliases for weak dependency queries to rpmspec(8)
Database
- Remove obscure check for package build time from
--rebuilddb(#2527) - Don’t muck with per-process global sqlite configuration from the db backend
Package building
Spec
- Add support for
.specpartfiles for dynamic spec generation - Add
--generate-subpackagestofind_lang.sh(utilizes.specpart) - Add
sysusers.d(5)integration for automated user and group handling (#1032) - Bundle custom
sysusers.shscript implementingsystemd-sysusers(8)interface - Generate user/group requires from
%files(#1032) - Improve shell-like globbing and escaping in
%files(#1749) - Expand
%docand%licenseglobs only once (#1294) - Add support for
%preuntransand%postuntransscriptlets (#2119) - Turn
%patchlines without arguments and options into an error - Fix misleading error message on some invalid filetrigger conditions (#2584)
Macros
- Add
%specpartsdirtomacros.in(#2532) - Add optional
total/proc/threadarguments to%{getncpus}macro (#804) - Add shorthand
macros
for some convenient Lua string operations:
%{gsub:...},%{len:...},%{lower:...},%{rep:...},%{reverse:...},%{sub:...}and%{upper:...} - Add
%{rpmversion}builtin macro for getting the running rpm version (#2523) - Calculate number of threads to use during build, not spec parse
Buildroot policies
- Fix a race condition in
brp-strip(RhBug:1959049) - Hardening fixes in
check-buildroot
Generators
- Generate user/group provides from packaged
/etc/passwd,/etc/groupandsysusers.d(5)files (#1032)
Package format
- Populate user and group data in cpio payload again (ancient regression)
Architecture handling
- Add x86-64 architecture levels (v2-v4) as architectures
- Fix how x86 models are derived in
rpmrc(#2535) - Use
__builtin_cpu_supportsin x86-64 CPU feature level detection (#2463) - Allow setting platform macro settings externally (#2578)
- Behave more consistently when target arch
%optflagsare not defined (RhBug:2231727)
Signatures and keys
Plugins
- Fix per-file plugin hook regression introduced in 4.18 (#2543)
- Suppress inhibition lock warning message when DBus service is not available
Python bindings
- Add some Python binding examples (#2075)
Lua interface
- Export
rpmGlobPath()asrpm.glob() - Fix error handling of
rpm.execute()andrpm.redirect2null()(#2528)
API changes
Added APIs
rpmGlobPath(), likerpmGlob()but also takes flagsrpmEscape()andrpmUnescape()for prepending and removing backslashes to and from special chars in a string, respectively- Add
pgpVerifySignature2()andpgpPrtParams2(), like their original variants but also return descriptive error messages (on failure) or lints (on success)
Changed APIs
rpmGlob()now only accepts one pattern in the input string, not a space separated list
Removed APIs
- Directory index related empty stubs
rpmfiSetDX(),rpmfiNextD()andrpmfiInitD() - File iterator related deprecated function
rpmteFI()and Python’ste.FI() - Epoch promote empty stubs
rpmdsNoPromote(),rpmdsSetNoPromote(), global variable_rpmds_nopromoteand Python’sds.SetNoPromote() - Keyring related deprecated functions
rpmKeyringLookup()andrpmPubkeyDig() - PGP related deprecated struct
pgpDigand functionspgpPrtPkts(),pgpNewDig(),pgpCleanDig(),pgpFreeDig(),pgpDigGetParams(),pgpVerifySig(),pgpHexStr()and Python’sts.pgpPrtPkts() - Header related deprecated functions
headerUnload(),headerLoad()andheaderCopyLoad() - File classifier related deprecated function
rpmfcNew() - Signal related type
rpmsqAction_t, definesRPMSQ_DFL,RPMSQ_IGN,RPMSQ_ERRand functionsrpmsqIsCaught(),rpmsqActivate(),rpmsqSetAction(),rpmsqPoll(),rpmsqSetInterruptSafety()and Python’ssignalCaught(),checkSignals(),setInterruptSafety() - File util function
rpmIsGlob()
Internal improvements and cleanups
- Make build parallelism memory and address-space aware (#804)
- Make user/group info reliable operation across chroot (#882, #1789)
- Make rpmscript machinery chroot-aware
- Fix ignoring exit code of child scripts in case of
EINTR - Axe our internal and buggy
glob()andfnmatch()copies - Drop now redundant bundled copies of
stpcpy()andstpncpy() - Rely on POSIX.1-2008
realpath()semantics - Simplify and clean up
rpmiothread enablement code - Header internals type cleanup
rpmdsrelated cleanups and sanity fixes- Eliminate signedness mismatch from
RPMTAG_NOT_FOUND - Fix a segfault on a non-stringable argument to macro call from Lua
- Remove some unused logging defines
- Rewrite
--lastto just usesed(1)for formatting
Build process
- New CMake build system, replaces Autotools
- Replace
fakechroot(1)with proper container technology in test-suite (#1580) - Default to Sequoia crypto as per roadmap
- Fix missing includes on macOS
- Drop support for buggy and problematic alternative Python build method (#130, #2230)
- Drop support for openssl < 1.1
- Drop some other redundant and ancient configure-time checks
- Split off translations to a separate project
- Default to C.UTF-8 locale, allow fallback to C (#2587)
- Export our libraries as a cmake
find_package()config (#2471)
Documentation
- Add devel documentation on documentation building
- Various other additions and fixes
Compatibility notes
- Any non-root ownership in the
%filessection (through%attr()or%defattr()) now generates an automatic dependency on the named user and/or group. This dependency can be satisfied by another package shipping asysusers.d(5)file or the/etc/passwdand/etc/groupfiles themselves. Existing packages shipping any of these files will have to be rebuilt with RPM 4.19 in order for them to carry the respective user and/or group provides. This may require distro-level coordination to ensure proper installation of all the affected packages. For more information, please consult the manual. %patchwithout arguments (previously an alias to%patch 0) is now a build error (use%patch Ninstead)