From 227a21dc8901464bec070c7780d920972268a75d Mon Sep 17 00:00:00 2001 From: factory-maintainer <> Date: Apr 23 2022 18:30:57 +0000 Subject: Update rpm to version 4.17.0 / rev 296 via SR 971138 https://build.opensuse.org/request/show/971138 by user factory-maintainer + dimstar_suse Automatic submission by obs-autosubmit --- diff --git a/.files b/.files index 02cfbfa..dc31ad0 100644 Binary files a/.files and b/.files differ diff --git a/.rev b/.rev index 24b37a8..d759b2d 100644 --- a/.rev +++ b/.rev @@ -2326,4 +2326,12 @@ See bugzilla 1167537 for the gory details. -> 961665 + + 6ba620b6ab4ef6f007868e4fbc4c1efe + 4.17.0 + + dimstar_suse + Automatic submission by obs-autosubmit + 971138 + diff --git a/rpm.changes b/rpm.changes index f929954..ade5038 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,4 +1,9 @@ ------------------------------------------------------------------- +Wed Mar 30 08:54:50 UTC 2022 - Martin Liška + +- Update zstdpool.diff in order to fix boo#1197643. + +------------------------------------------------------------------- Mon Mar 14 10:50:39 UTC 2022 - Dirk Müller - drop rpm-deptracking.patch, this is already upstream and diff --git a/rpm.spec b/rpm.spec index e34a1f2..e270626 100644 --- a/rpm.spec +++ b/rpm.spec @@ -183,8 +183,8 @@ Requires: findutils Requires: gawk Requires: gcc #Requires: gcc-PIE -Requires: gettext-tools Requires: /usr/bin/gzip +Requires: gettext-tools Requires: glibc-devel Requires: glibc-locale-base Requires: grep diff --git a/zstdpool.diff b/zstdpool.diff index b4d7ff5..3640438 100644 --- a/zstdpool.diff +++ b/zstdpool.diff @@ -1,5 +1,5 @@ ---- ./rpmio/rpmio.c.orig 2021-10-14 12:34:22.865316722 +0000 -+++ ./rpmio/rpmio.c 2021-10-14 13:37:56.835119919 +0000 +--- ./rpmio/rpmio.c.orig 2021-06-21 12:00:44.648612706 +0000 ++++ ./rpmio/rpmio.c 2022-04-13 13:48:55.224954032 +0000 @@ -8,6 +8,7 @@ #include #include @@ -16,7 +16,7 @@ #include typedef struct rpmzstd_s { -@@ -1048,6 +1050,27 @@ typedef struct rpmzstd_s { +@@ -1048,6 +1050,29 @@ typedef struct rpmzstd_s { ZSTD_outBuffer zob; /*!< ZSTD_outBuffer */ } * rpmzstd; @@ -24,6 +24,7 @@ + +static pthread_once_t zstdThreadPoolCreated = PTHREAD_ONCE_INIT; +static ZSTD_threadPool *zstdThreadPool; ++static int zstdThreadPoolThreads; + +static void zstdCreateThreadPool(void) +{ @@ -31,6 +32,7 @@ + if (numthreads >= 0) + numthreads = get_compression_threads(numthreads > 0 ? numthreads : -1); + if (numthreads > 0) { ++ zstdThreadPoolThreads = numthreads; + zstdThreadPool = ZSTD_createThreadPool(numthreads); + if (!zstdThreadPool) + rpmlog(RPMLOG_WARNING, "Could not create zstd thread pool for %d threads\n", numthreads); @@ -44,7 +46,7 @@ static rpmzstd rpmzstdNew(int fdno, const char *fmode) { int flags = 0; -@@ -1133,8 +1156,15 @@ static rpmzstd rpmzstdNew(int fdno, cons +@@ -1133,8 +1158,18 @@ static rpmzstd rpmzstdNew(int fdno, cons threads = get_compression_threads(threads); if (threads > 0) { @@ -54,8 +56,11 @@ + } else { +#if ZSTD_VERSION_NUMBER >= 10407 + pthread_once(&zstdThreadPoolCreated, zstdCreateThreadPool); -+ if (zstdThreadPool) ++ if (zstdThreadPool) { ++ if (threads > zstdThreadPoolThreads) ++ ZSTD_CCtx_setParameter(_stream, ZSTD_c_nbWorkers, zstdThreadPoolThreads); + ZSTD_CCtx_refThreadPool(_stream, zstdThreadPool); ++ } +#endif + } }