diff options
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r-- | gnu/packages/patches/cpufrequtils-fix-aclocal.patch | 46 | ||||
-rw-r--r-- | gnu/packages/patches/ganeti-sphinx-compat.patch | 24 | ||||
-rw-r--r-- | gnu/packages/patches/libhx-fix-double-free-bug.patch | 80 | ||||
-rw-r--r-- | gnu/packages/patches/qemu-meson-compat.patch | 27 | ||||
-rw-r--r-- | gnu/packages/patches/qemu-sphinx-compat.patch | 18 |
5 files changed, 104 insertions, 91 deletions
diff --git a/gnu/packages/patches/cpufrequtils-fix-aclocal.patch b/gnu/packages/patches/cpufrequtils-fix-aclocal.patch deleted file mode 100644 index be5767f462..0000000000 --- a/gnu/packages/patches/cpufrequtils-fix-aclocal.patch +++ /dev/null @@ -1,46 +0,0 @@ -Add an extra layer of quoting to ltmain.sh sanity check. - ---- a/configure 2005-05-07 14:19:31.000000000 +0200 -+++ b/configure 2015-02-10 11:16:32.456146934 +0100 -@@ -6266,7 +6266,7 @@ - exit 1 - fi - gentoo_lt_version="1.5.16" --gentoo_ltmain_version=`grep '^[:space:]*VERSION=' $ltmain | sed -e 's|^[:space:]*VERSION=||'` -+gentoo_ltmain_version=`grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||'` - if test "$gentoo_lt_version" != "$gentoo_ltmain_version"; then - echo "$as_me:$LINENO: result: no" >&5 - echo "${ECHO_T}no" >&6 ---- a/aclocal.m4 2005-05-07 14:19:25.000000000 +0200 -+++ b/aclocal.m4 2015-02-10 11:16:15.352030318 +0100 -@@ -246,7 +246,7 @@ - exit 1 - fi - gentoo_lt_version="1.5.16" --gentoo_ltmain_version=`grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||'` -+gentoo_ltmain_version=`[grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||']` - if test "$gentoo_lt_version" != "$gentoo_ltmain_version"; then - AC_MSG_RESULT(no) - echo ---- a/libcpufreq/configure 2005-05-07 14:19:31.000000000 +0200 -+++ b/libcpufreq/configure 2015-02-10 11:16:32.456146934 +0100 -@@ -6266,7 +6266,7 @@ - exit 1 - fi - gentoo_lt_version="1.5.16" --gentoo_ltmain_version=`grep '^[:space:]*VERSION=' $ltmain | sed -e 's|^[:space:]*VERSION=||'` -+gentoo_ltmain_version=`grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||'` - if test "$gentoo_lt_version" != "$gentoo_ltmain_version"; then - echo "$as_me:$LINENO: result: no" >&5 - echo "${ECHO_T}no" >&6 ---- a/libcpufreq/aclocal.m4 2005-05-07 14:19:25.000000000 +0200 -+++ b/libcpufreq/aclocal.m4 2015-02-10 11:16:15.352030318 +0100 -@@ -246,7 +246,7 @@ - exit 1 - fi - gentoo_lt_version="1.5.16" --gentoo_ltmain_version=`grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||'` -+gentoo_ltmain_version=`[grep '^[[:space:]]*VERSION=' $ltmain | sed -e 's|^[[:space:]]*VERSION=||']` - if test "$gentoo_lt_version" != "$gentoo_ltmain_version"; then - AC_MSG_RESULT(no) - echo diff --git a/gnu/packages/patches/ganeti-sphinx-compat.patch b/gnu/packages/patches/ganeti-sphinx-compat.patch new file mode 100644 index 0000000000..4e84abbf37 --- /dev/null +++ b/gnu/packages/patches/ganeti-sphinx-compat.patch @@ -0,0 +1,24 @@ +Adjust documentation for Sphinx 4.0. + +Discussed upstream at <https://github.com/ganeti/ganeti/pull/1615>. + +diff --git a/doc/index.rst b/doc/index.rst +--- a/doc/index.rst ++++ b/doc/index.rst +@@ -119,7 +119,6 @@ Draft designs + design-hotplug.rst + design-internal-shutdown.rst + design-kvmd.rst +- design-location.rst + design-linuxha.rst + design-location.rst + design-lu-generated-jobs.rst +diff --git a/lib/build/shell_example_lexer.py b/lib/build/shell_example_lexer.py +--- a/lib/build/shell_example_lexer.py ++++ b/lib/build/shell_example_lexer.py +@@ -79,4 +79,4 @@ class ShellExampleLexer(RegexLexer): + + + def setup(app): +- app.add_lexer("shell-example", ShellExampleLexer()) ++ app.add_lexer("shell-example", ShellExampleLexer) diff --git a/gnu/packages/patches/libhx-fix-double-free-bug.patch b/gnu/packages/patches/libhx-fix-double-free-bug.patch new file mode 100644 index 0000000000..80c2c6ca84 --- /dev/null +++ b/gnu/packages/patches/libhx-fix-double-free-bug.patch @@ -0,0 +1,80 @@ +From a08eabc6e5a3e0a9c7a15ca15ff7d450ecb6db88 Mon Sep 17 00:00:00 2001 +From: Jan Engelhardt <jengelh@inai.de> +Date: Tue, 12 Oct 2021 17:32:43 +0200 +Subject: [PATCH] io: fix a use-after-free in conjunction with HX_realpath + +HX_readlink(&x, ...) forgot to set x to nullptr upon error, which +trips up subsequent calls to HX_readlink with the very same x. + +Fixes: v3.26-1-g97f4be2 +--- + src/io.c | 8 ++++++-- + src/tc-realpath.c | 10 ++++++++++ + 2 files changed, 16 insertions(+), 2 deletions(-) + +diff --git a/src/io.c b/src/io.c +index 95d6fd6..14078fc 100644 +--- a/src/io.c ++++ b/src/io.c +@@ -316,8 +316,10 @@ EXPORT_SYMBOL int HX_readlink(hxmc_t **target, const char *path) + ssize_t ret = readlink(path, *target, linkbuf_size); + if (ret < 0) { + int saved_errno = errno; +- if (allocate) ++ if (allocate) { + HXmc_free(*target); ++ *target = nullptr; ++ } + return -(errno = saved_errno); + } + if (static_cast(size_t, ret) < linkbuf_size) { +@@ -327,8 +329,10 @@ EXPORT_SYMBOL int HX_readlink(hxmc_t **target, const char *path) + linkbuf_size *= 2; + if (HXmc_setlen(target, linkbuf_size) == NULL) { + int saved_errno = errno; +- if (allocate) ++ if (allocate) { + HXmc_free(*target); ++ *target = nullptr; ++ } + return -(errno = saved_errno); + } + } +diff --git a/src/tc-realpath.c b/src/tc-realpath.c +index 5dd9aa2..c2ef15a 100644 +--- a/src/tc-realpath.c ++++ b/src/tc-realpath.c +@@ -11,6 +11,7 @@ + #include <stdlib.h> + #include <libHX/io.h> + #include <libHX/option.h> ++#include <libHX/string.h> + + static unsigned int rp_flags; + static unsigned int rp_absolute; +@@ -42,6 +43,14 @@ static bool rp_get_options(int *argc, const char ***argv) + return true; + } + ++static void t_1(void) ++{ ++ hxmc_t *tmp = HXmc_strinit(""); ++ /* two components, so that HX_readlink gets called twice */ ++ HX_realpath(&tmp, "/dev/tty", HX_REALPATH_DEFAULT); ++ HXmc_free(tmp); ++} ++ + int main(int argc, const char **argv) + { + hxmc_t *res; +@@ -49,6 +58,7 @@ int main(int argc, const char **argv) + + if (!rp_get_options(&argc, &argv)) + return EXIT_FAILURE; ++ t_1(); + + res = NULL; + while (--argc > 0) { +-- +2.33.0 + diff --git a/gnu/packages/patches/qemu-meson-compat.patch b/gnu/packages/patches/qemu-meson-compat.patch deleted file mode 100644 index e6968c57dc..0000000000 --- a/gnu/packages/patches/qemu-meson-compat.patch +++ /dev/null @@ -1,27 +0,0 @@ -Fix a build failure that occurs with newer versions of Meson when -gdbus-codegen is unavailable. - -Taken from upstream: -https://gitlab.com/qemu-project/qemu/-/commit/5ecfb76ccc056eb6127e44268e475827ae73b9e0 - -diff --git a/configure b/configure ---- a/configure -+++ b/configure -@@ -3341,7 +3341,7 @@ if ! test "$gio" = "no"; then - gio_cflags=$($pkg_config --cflags gio-2.0) - gio_libs=$($pkg_config --libs gio-2.0) - gdbus_codegen=$($pkg_config --variable=gdbus_codegen gio-2.0) -- if [ ! -x "$gdbus_codegen" ]; then -+ if ! has "$gdbus_codegen"; then - gdbus_codegen= - fi - # Check that the libraries actually work -- Ubuntu 18.04 ships -@@ -5704,6 +5704,8 @@ if test "$gio" = "yes" ; then - echo "CONFIG_GIO=y" >> $config_host_mak - echo "GIO_CFLAGS=$gio_cflags" >> $config_host_mak - echo "GIO_LIBS=$gio_libs" >> $config_host_mak -+fi -+if test "$gdbus_codegen" != "" ; then - echo "GDBUS_CODEGEN=$gdbus_codegen" >> $config_host_mak - fi - echo "CONFIG_TLS_PRIORITY=\"$tls_priority\"" >> $config_host_mak diff --git a/gnu/packages/patches/qemu-sphinx-compat.patch b/gnu/packages/patches/qemu-sphinx-compat.patch deleted file mode 100644 index 7342ebee4e..0000000000 --- a/gnu/packages/patches/qemu-sphinx-compat.patch +++ /dev/null @@ -1,18 +0,0 @@ -Prevent Sphinx 4 and later from creating subdirectories, which -the build scripts are not equipped to deal with. - -Taken from upstream: -https://gitlab.com/qemu-project/qemu/-/issues/256 -https://gitlab.com/qemu-project/qemu/-/commit/269a7e97865cb863c9ca19e5f2e6a40ac9eddf82 - -diff --git a/docs/conf.py b/docs/conf.py ---- a/docs/conf.py -+++ b/docs/conf.py -@@ -279,6 +279,7 @@ - ['Stefan Hajnoczi <stefanha@redhat.com>', - 'Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>'], 1), - ] -+man_make_section_directory = False - - # -- Options for Texinfo output ------------------------------------------- - |