summaryrefslogtreecommitdiff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-03-23 21:45:21 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-03-23 21:45:21 -0400
commit839bb4616f13171a23ad7937bf57d0a01d61d42a (patch)
tree01de78a5ce973b9fb7ac0f9216d64f736f8e163d /gnu/packages/patches
parent0357bbbcd850f9220078a62da3c30358b8983765 (diff)
parentef71e3290916583973724316e815cee840c1b6d8 (diff)
Merge remote-tracking branch 'origin/master' into staging.
With resolved conflicts in: gnu/packages/ibus.scm gnu/packages/image.scm gnu/packages/lisp.scm gnu/packages/virtualization.scm
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/bees-beesd-honor-destdir-on-installation.patch40
-rw-r--r--gnu/packages/patches/boolector-find-googletest.patch204
-rw-r--r--gnu/packages/patches/cabal-install-base16-bytestring1.0.patch29
-rw-r--r--gnu/packages/patches/cabal-install-ghc8.10.patch393
-rw-r--r--gnu/packages/patches/ccextractor-add-missing-header.patch33
-rw-r--r--gnu/packages/patches/ccextractor-autoconf-tesseract.patch37
-rw-r--r--gnu/packages/patches/ccextractor-fix-ocr.patch29
-rw-r--r--gnu/packages/patches/dbacl-icheck-multiple-definitions.patch33
-rw-r--r--gnu/packages/patches/ddclient-skip-test.patch43
-rw-r--r--gnu/packages/patches/efibootmgr-remove-extra-decl.patch27
-rw-r--r--gnu/packages/patches/elm-ghc9.2.patch187
-rw-r--r--gnu/packages/patches/emacs-helpful-fix-docstring-test.patch18
-rw-r--r--gnu/packages/patches/emacs-pasp-mode-quote-file-names.patch20
-rw-r--r--gnu/packages/patches/esmini-no-clutter-log.patch30
-rw-r--r--gnu/packages/patches/esmini-use-pkgconfig.patch541
-rw-r--r--gnu/packages/patches/evdi-fix-build-with-linux-6.2.patch72
-rw-r--r--gnu/packages/patches/flatpak-unset-gdk-pixbuf-for-sandbox.patch8
-rw-r--r--gnu/packages/patches/fluxbox-1.3.7-no-dynamic-cursor.patch163
-rw-r--r--gnu/packages/patches/ghc-9.2-glibc-2.33-link-order.patch35
-rw-r--r--gnu/packages/patches/ghc-bloomfilter-ghc9.2.patch303
-rw-r--r--gnu/packages/patches/ghc-bytestring-handle-ghc9.patch67
-rw-r--r--gnu/packages/patches/icecat-makeicecat.patch10
-rw-r--r--gnu/packages/patches/ipxe-reproducible-geniso.patch77
-rw-r--r--gnu/packages/patches/m17n-lib-1.8.0-use-pkg-config-for-freetype.patch125
-rw-r--r--gnu/packages/patches/ngless-unliftio.patch66
-rw-r--r--gnu/packages/patches/onionshare-cli-async-mode.patch25
-rw-r--r--gnu/packages/patches/openbios-aarch64-riscv64-support.patch17
-rw-r--r--gnu/packages/patches/openbios-gcc-warnings.patch95
-rw-r--r--gnu/packages/patches/opencascade-oce-glibc-2.26.patch62
-rw-r--r--gnu/packages/patches/opentaxsolver-file-browser-fix.patch58
-rw-r--r--gnu/packages/patches/php-bug-74093-test.patch48
-rw-r--r--gnu/packages/patches/php-curl-compat.patch17
-rw-r--r--gnu/packages/patches/php-fix-streams-copy-length.patch52
-rw-r--r--gnu/packages/patches/python-hiredis-fix-header.patch49
-rw-r--r--gnu/packages/patches/python-hiredis-use-system-hiredis.patch82
-rw-r--r--gnu/packages/patches/python-pillow-CVE-2022-45199.patch36
-rw-r--r--gnu/packages/patches/qpdfview-qt515-compat.patch17
-rw-r--r--gnu/packages/patches/qtwebkit-fix-building-with-bison-3.7.patch54
-rw-r--r--gnu/packages/patches/qtwebkit-fix-building-with-glib-2.68.patch21
-rw-r--r--gnu/packages/patches/qtwebkit-fix-building-with-icu-68.patch152
-rw-r--r--gnu/packages/patches/qtwebkit-fix-building-with-python-3.9.patch35
-rw-r--r--gnu/packages/patches/qtwebkit-pbutils-include.patch15
-rw-r--r--gnu/packages/patches/racket-backport-8.7-pkg-strip.patch90
-rw-r--r--gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch36
-rw-r--r--gnu/packages/patches/rng-tools-revert-build-randstat.patch49
-rw-r--r--gnu/packages/patches/rnp-add-version.cmake.patch169
-rw-r--r--gnu/packages/patches/rnp-disable-ruby-rnp-tests.patch26
-rw-r--r--gnu/packages/patches/rnp-unbundle-googletest.patch43
-rw-r--r--gnu/packages/patches/sbcl-eazy-gnuplot-skip-path-check.patch14
-rw-r--r--gnu/packages/patches/scsh-nonstring-search-path.patch15
-rw-r--r--gnu/packages/patches/spice-vdagent-glib-2.68.patch112
-rw-r--r--gnu/packages/patches/virglrenderer-CVE-2017-6386.patch54
-rw-r--r--gnu/packages/patches/virtuoso-ose-remove-pre-built-jar-files.patch42
-rw-r--r--gnu/packages/patches/widelands-add-missing-map-include.patch28
-rw-r--r--gnu/packages/patches/widelands-system-wide_minizip.patch141
-rw-r--r--gnu/packages/patches/wpa-supplicant-dbus-group-policy.patch23
-rw-r--r--gnu/packages/patches/xf86-video-tga-remove-mibstore.patch34
-rw-r--r--gnu/packages/patches/xmonad-dynamic-linking.patch24
-rw-r--r--gnu/packages/patches/xmonad-next-dynamic-linking.patch16
59 files changed, 2384 insertions, 1957 deletions
diff --git a/gnu/packages/patches/bees-beesd-honor-destdir-on-installation.patch b/gnu/packages/patches/bees-beesd-honor-destdir-on-installation.patch
deleted file mode 100644
index 93817f42cf..0000000000
--- a/gnu/packages/patches/bees-beesd-honor-destdir-on-installation.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 66b00f8a972ebb4da68f7aa0d0656f43ce2a2c3a Mon Sep 17 00:00:00 2001
-From: Hilton Chain <hako@ultrarare.space>
-Date: Fri, 23 Dec 2022 11:04:46 +0800
-Subject: [PATCH] beesd: Honor DESTDIR on installation.
-
-Co-authored-by: Adam Faiz <adam.faiz@disroot.org>
-Signed-off-by: Hilton Chain <hako@ultrarare.space>
----
- Defines.mk | 1 +
- scripts/beesd.in | 2 +-
- 2 files changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/Defines.mk b/Defines.mk
-index 9e8df40..e5394ba 100644
---- a/Defines.mk
-+++ b/Defines.mk
-@@ -2,6 +2,7 @@ MAKE += PREFIX=$(PREFIX) LIBEXEC_PREFIX=$(LIBEXEC_PREFIX) ETC_PREFIX=$(ETC_PREFI
-
- define TEMPLATE_COMPILER =
- sed $< >$@ \
-+ -e's#@DESTDIR@#$(DESTDIR)#' \
- -e's#@PREFIX@#$(PREFIX)#' \
- -e's#@ETC_PREFIX@#$(ETC_PREFIX)#' \
- -e's#@LIBEXEC_PREFIX@#$(LIBEXEC_PREFIX)#'
-diff --git a/scripts/beesd.in b/scripts/beesd.in
-index 174bb6c..35d04aa 100755
---- a/scripts/beesd.in
-+++ b/scripts/beesd.in
-@@ -15,7 +15,7 @@ readonly AL128K="$((128*1024))"
- readonly AL16M="$((16*1024*1024))"
- readonly CONFIG_DIR=@ETC_PREFIX@/bees/
-
--readonly bees_bin=$(realpath @LIBEXEC_PREFIX@/bees)
-+readonly bees_bin=$(realpath @DESTDIR@/@LIBEXEC_PREFIX@/bees)
-
- command -v "$bees_bin" &> /dev/null || ERRO "Missing 'bees' agent"
-
---
-2.38.1
-
diff --git a/gnu/packages/patches/boolector-find-googletest.patch b/gnu/packages/patches/boolector-find-googletest.patch
new file mode 100644
index 0000000000..baa7c6cd96
--- /dev/null
+++ b/gnu/packages/patches/boolector-find-googletest.patch
@@ -0,0 +1,204 @@
+From 91533caf29a2c5b10b4912fd352e7af82c787598 Mon Sep 17 00:00:00 2001
+From: Aina Niemetz <aina.niemetz@gmail.com>
+Date: Wed, 16 Jun 2021 16:17:27 -0700
+Subject: [PATCH] Configure google test as external project.
+
+---
+ CMakeLists.txt | 7 ----
+ cmake/FindGoogleTest.cmake | 60 +++++++++++++++++++++++++++++++++
+ cmake/googletest-download.cmake | 28 ---------------
+ cmake/googletest.cmake | 41 ----------------------
+ test/CMakeLists.txt | 5 ++-
+ 5 files changed, 64 insertions(+), 77 deletions(-)
+ create mode 100644 cmake/FindGoogleTest.cmake
+ delete mode 100644 cmake/googletest-download.cmake
+ delete mode 100644 cmake/googletest.cmake
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 38056ede6..d30475bcd 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -440,13 +440,6 @@ configure_file(
+ #-----------------------------------------------------------------------------#
+ # Regression tests
+
+-# Get and configure google test
+-include(cmake/googletest.cmake)
+-fetch_googletest(
+- ${PROJECT_SOURCE_DIR}/cmake
+- ${PROJECT_BINARY_DIR}/googletest
+- )
+-
+ enable_testing()
+
+ #-----------------------------------------------------------------------------#
+diff --git a/cmake/FindGoogleTest.cmake b/cmake/FindGoogleTest.cmake
+new file mode 100644
+index 000000000..c6eecd179
+--- /dev/null
++++ b/cmake/FindGoogleTest.cmake
+@@ -0,0 +1,60 @@
++# Boolector: Satisfiablity Modulo Theories (SMT) solver.
++#
++# Copyright (C) 2007-2021 by the authors listed in the AUTHORS file.
++#
++# This file is part of Boolector.
++# See COPYING for more information on using this software.
++#
++
++# Find GTest
++#
++# GTest_FOUND - Found GTest
++# GTest::GTest - GTest library
++
++find_package(GTest 1.10.0)
++
++if(NOT GTest_FOUND)
++ include(ExternalProject)
++
++ set(GTest_VERSION "1.10.0")
++
++ ExternalProject_Add(
++ GTest-EP
++ PREFIX "${CMAKE_BINARY_DIR}/deps"
++ URL https://github.com/google/googletest/archive/refs/tags/release-${GTest_VERSION}.tar.gz
++ URL_HASH SHA1=9c89be7df9c5e8cb0bc20b3c4b39bf7e82686770
++ DOWNLOAD_NAME gtest.tar.gz
++ CMAKE_ARGS
++ -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
++ BUILD_COMMAND ${CMAKE_COMMAND} --build .
++ BUILD_BYPRODUCTS
++ <INSTALL_DIR>/lib/libgtest.a
++ <INSTALL_DIR>/lib/libgtest_main.a
++ LOG_DOWNLOAD ON
++ LOG_UPDATE ON
++ LOG_CONFIGURE ON
++ LOG_BUILD ON
++ LOG_INSTALL ON
++ LOG_OUTPUT_ON_FAILURE TRUE
++ )
++
++ set(GTest_INCLUDE_DIR "${CMAKE_BINARY_DIR}/deps/include/")
++ set(GTest_MAIN_LIBRARY "${CMAKE_BINARY_DIR}/deps/lib/libgtest_main.a")
++ set(GTest_LIBRARY "${CMAKE_BINARY_DIR}/deps/lib/libgtest.a")
++ file(MAKE_DIRECTORY "${GTest_INCLUDE_DIR}")
++
++ add_library(GTest::gtest_main STATIC IMPORTED GLOBAL)
++ set_target_properties(GTest::gtest_main
++ PROPERTIES
++ IMPORTED_LOCATION "${GTest_MAIN_LIBRARY}"
++ INTERFACE_INCLUDE_DIRECTORIES "${GTest_INCLUDE_DIR}"
++ INTERFACE_LINK_LIBRARIES "${GTest_LIBRARY}"
++ )
++ set(GTest_FOUND TRUE)
++ add_dependencies(GTest::gtest_main GTest-EP)
++ message(STATUS "Building GTest ${GTest_VERSION}: ${GTest_MAIN_LIBRARY}")
++
++ mark_as_advanced(GTest_FOUND)
++ mark_as_advanced(GTest_INCLUDE_DIR)
++ mark_as_advanced(GTest_LIBRARIES)
++endif()
+diff --git a/cmake/googletest-download.cmake b/cmake/googletest-download.cmake
+deleted file mode 100644
+index 8dca59539..000000000
+--- a/cmake/googletest-download.cmake
++++ /dev/null
+@@ -1,28 +0,0 @@
+-# Boolector: Satisfiablity Modulo Theories (SMT) solver.
+-#
+-# Copyright (C) 2007-2021 by the authors listed in the AUTHORS file.
+-#
+-# This file is part of Boolector.
+-# See COPYING for more information on using this software.
+-#
+-
+-# code copied from https://crascit.com/2015/07/25/cmake-gtest/
+-cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
+-
+-project(googletest-download NONE)
+-
+-include(ExternalProject)
+-
+-ExternalProject_Add(
+- googletest
+- SOURCE_DIR "@GOOGLETEST_DOWNLOAD_ROOT@/googletest-src"
+- BINARY_DIR "@GOOGLETEST_DOWNLOAD_ROOT@/googletest-build"
+- GIT_REPOSITORY
+- https://github.com/google/googletest.git
+- GIT_TAG
+- release-1.10.0
+- CONFIGURE_COMMAND ""
+- BUILD_COMMAND ""
+- INSTALL_COMMAND ""
+- TEST_COMMAND ""
+- )
+diff --git a/cmake/googletest.cmake b/cmake/googletest.cmake
+deleted file mode 100644
+index af5a5bc36..000000000
+--- a/cmake/googletest.cmake
++++ /dev/null
+@@ -1,41 +0,0 @@
+-# Boolector: Satisfiablity Modulo Theories (SMT) solver.
+-#
+-# Copyright (C) 2007-2021 by the authors listed in the AUTHORS file.
+-#
+-# This file is part of Boolector.
+-# See COPYING for more information on using this software.
+-#
+-
+-# the following code to fetch googletest
+-# is inspired by and adapted after https://crascit.com/2015/07/25/cmake-gtest/
+-# download and unpack googletest at configure time
+-
+-macro(fetch_googletest _download_module_path _download_root)
+- set(GOOGLETEST_DOWNLOAD_ROOT ${_download_root})
+- configure_file(
+- ${_download_module_path}/googletest-download.cmake
+- ${_download_root}/CMakeLists.txt
+- @ONLY
+- )
+- unset(GOOGLETEST_DOWNLOAD_ROOT)
+-
+- execute_process(
+- COMMAND
+- "${CMAKE_COMMAND}" -G "${CMAKE_GENERATOR}" .
+- WORKING_DIRECTORY
+- ${_download_root}
+- )
+- execute_process(
+- COMMAND
+- "${CMAKE_COMMAND}" --build .
+- WORKING_DIRECTORY
+- ${_download_root}
+- )
+-
+- # adds the targers: gtest, gtest_main, gmock, gmock_main
+- add_subdirectory(
+- ${_download_root}/googletest-src
+- ${_download_root}/googletest-build
+- EXCLUDE_FROM_ALL
+- )
+-endmacro()
+diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
+index 13f87d5e0..f2e14fd81 100644
+--- a/test/CMakeLists.txt
++++ b/test/CMakeLists.txt
+@@ -5,6 +5,9 @@
+ # This file is part of Boolector.
+ # See COPYING for more information on using this software.
+ #
++
++find_package(GoogleTest REQUIRED)
++
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin/tests)
+
+ set(test_names
+@@ -47,7 +50,7 @@ foreach(test ${test_names})
+ add_executable (test${test} test_${test}.cpp)
+ target_include_directories(test${test} PRIVATE ${PROJECT_SOURCE_DIR}/test/new_test)
+ target_link_libraries(test${test} boolector m)
+- target_link_libraries(test${test} gtest_main)
++ target_link_libraries(test${test} GTest::gtest_main)
+ set_target_properties(test${test} PROPERTIES OUTPUT_NAME test${test})
+ add_test(${test} ${CMAKE_BINARY_DIR}/bin/tests/test${test})
+ endforeach()
diff --git a/gnu/packages/patches/cabal-install-base16-bytestring1.0.patch b/gnu/packages/patches/cabal-install-base16-bytestring1.0.patch
deleted file mode 100644
index 998bf08718..0000000000
--- a/gnu/packages/patches/cabal-install-base16-bytestring1.0.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Restore compatibility with newer version of base16-bytestring.
-
-Taken from https://raw.githubusercontent.com/archlinux/svntogit-community/packages/trunk/cabal-install-base16-bytestring1.0.patch
-
-diff --git a/Distribution/Client/HashValue.hs b/Distribution/Client/HashValue.hs
-index 54b8aee9e..11e647c1c 100644
---- a/Distribution/Client/HashValue.hs
-+++ b/Distribution/Client/HashValue.hs
-@@ -1,3 +1,4 @@
-+{-# LANGUAGE CPP #-}
- {-# LANGUAGE DeriveDataTypeable #-}
- {-# LANGUAGE DeriveGeneric #-}
- module Distribution.Client.HashValue (
-@@ -72,10 +73,14 @@ hashFromTUF (Sec.Hash hashstr) =
- --TODO: [code cleanup] either we should get TUF to use raw bytestrings or
- -- perhaps we should also just use a base16 string as the internal rep.
- case Base16.decode (BS.pack hashstr) of
-+#if MIN_VERSION_base16_bytestring(1,0,0)
-+ Right hash -> HashValue hash
-+ Left _ -> error "hashFromTUF: cannot decode base16"
-+#else
- (hash, trailing) | not (BS.null hash) && BS.null trailing
- -> HashValue hash
- _ -> error "hashFromTUF: cannot decode base16 hash"
--
-+#endif
-
- -- | Truncate a 32 byte SHA256 hash to
- --
diff --git a/gnu/packages/patches/cabal-install-ghc8.10.patch b/gnu/packages/patches/cabal-install-ghc8.10.patch
deleted file mode 100644
index 67c0953058..0000000000
--- a/gnu/packages/patches/cabal-install-ghc8.10.patch
+++ /dev/null
@@ -1,393 +0,0 @@
-From ac9b41eef3c781ce188ded2551f98fe75152e30c Mon Sep 17 00:00:00 2001
-From: Oleg Grenrus <oleg.grenrus@iki.fi>
-Date: Tue, 14 Apr 2020 11:31:34 +0300
-Subject: [PATCH] GHC-8.10 support for 3.2
-
-Includes cherry-picked commits:
-
-- Test cabal-install with GHC-8.10 #6709
-- Add GHC-8.10.1 job. Only tests Cabal-the-lib part atm. #6617
-
-Also add topHandler' signature.
----
- .docker/validate-8.10.1.dockerfile | 60 ++++++
- .github/workflows/artifacts.yml | 6 +-
- .github/workflows/bootstrap.yml | 4 +-
- .github/workflows/linux.yml | 179 ++++++++++++------
- .github/workflows/macos.yml | 40 ++--
- .github/workflows/quick-jobs.yml | 4 +-
- .github/workflows/windows.yml | 117 +++++++++++-
- .../Distribution/PackageDescription/Quirks.hs | 19 +-
- Makefile | 4 +
- boot/ci-artifacts.template.yml | 6 +-
- boot/ci-bootstrap.template.yml | 4 +-
- boot/ci-linux.template.yml | 8 +-
- boot/ci-macos.template.yml | 7 +-
- boot/ci-quick-jobs.template.yml | 4 +-
- boot/ci-windows.template.yml | 8 +-
- cabal-dev-scripts/src/GenValidate.hs | 33 ++--
- Distribution/Client/CmdSdist.hs | 3 +
- .../Distribution/Client/FetchUtils.hs | 4 +-
- .../Distribution/Client/IndexUtils.hs | 2 +-
- Distribution/Client/Sandbox.hs | 5 +-
- .../Distribution/Client/TargetSelector.hs | 2 +-
- Distribution/Client/Update.hs | 4 +-
- .../Distribution/Client/Utils/Json.hs | 13 +-
- .../Distribution/Solver/Modular/Assignment.hs | 11 +-
- .../Distribution/Solver/Modular/Builder.hs | 10 +-
- .../Distribution/Solver/Modular/Index.hs | 6 +-
- .../Solver/Modular/IndexConversion.hs | 8 +-
- .../Distribution/Solver/Modular/Solver.hs | 12 +-
- .../Distribution/Solver/Modular/Validate.hs | 5 +-
- bootstrap.sh | 6 +-
- cabal-install.cabal | 4 +-
- cabal-install.cabal.pp | 4 +-
- .../targets/complex/q/q.cabal | 3 +-
- cabal-testsuite/cabal-testsuite.cabal | 4 +-
- validate.sh | 21 +-
- 35 files changed, 461 insertions(+), 169 deletions(-)
- create mode 100644 .docker/validate-8.10.1.dockerfile
-diff --git a/Distribution/Client/CmdSdist.hs b/Distribution/Client/CmdSdist.hs
-index 9ce0c80100e..a22317004c4 100644
---- a/Distribution/Client/CmdSdist.hs
-+++ b/Distribution/Client/CmdSdist.hs
-@@ -237,7 +237,10 @@ packageToSdist verbosity projectRootDir format outputFile pkg = do
- (norm NoExec -> nonexec, norm Exec -> exec) <-
- listPackageSources verbosity (flattenPackageDescription $ packageDescription pkg) knownSuffixHandlers
-
-+ print $ map snd exec
-+ print $ map snd nonexec
- let files = nub . sortOn snd $ nonexec ++ exec
-+ print files
-
- case format of
- SourceList nulSep -> do
-diff --git a/Distribution/Client/FetchUtils.hs b/Distribution/Client/FetchUtils.hs
-index e9a31a91f84..4e5e581f9ec 100644
---- a/Distribution/Client/FetchUtils.hs
-+++ b/Distribution/Client/FetchUtils.hs
-@@ -176,8 +176,8 @@ fetchRepoTarball verbosity' repoCtxt repo pkgid = do
- verbosity = verboseUnmarkOutput verbosity'
-
- downloadRepoPackage = case repo of
-- RepoLocal{..} -> return (packageFile repo pkgid)
-- RepoLocalNoIndex{..} -> return (packageFile repo pkgid)
-+ RepoLocal{} -> return (packageFile repo pkgid)
-+ RepoLocalNoIndex{} -> return (packageFile repo pkgid)
-
- RepoRemote{..} -> do
- transport <- repoContextGetTransport repoCtxt
-diff --git a/Distribution/Client/IndexUtils.hs b/Distribution/Client/IndexUtils.hs
-index a76becc05ba..bf0ff7cf5ba 100644
---- a/Distribution/Client/IndexUtils.hs
-+++ b/Distribution/Client/IndexUtils.hs
-@@ -634,7 +634,7 @@ withIndexEntries
- -> ([IndexCacheEntry] -> IO a)
- -> ([NoIndexCacheEntry] -> IO a)
- -> IO a
--withIndexEntries _ (RepoIndex repoCtxt repo@RepoSecure{..}) callback _ =
-+withIndexEntries _ (RepoIndex repoCtxt repo@RepoSecure{}) callback _ =
- repoContextWithSecureRepo repoCtxt repo $ \repoSecure ->
- Sec.withIndex repoSecure $ \Sec.IndexCallbacks{..} -> do
- -- Incrementally (lazily) read all the entries in the tar file in order,
-diff --git a/Distribution/Client/Sandbox.hs b/Distribution/Client/Sandbox.hs
-index 66b415d7239..14bad3f2135 100644
---- a/Distribution/Client/Sandbox.hs
-+++ b/Distribution/Client/Sandbox.hs
-@@ -666,7 +666,7 @@ reinstallAddSourceDeps :: Verbosity
- -> FilePath
- -> IO WereDepsReinstalled
- reinstallAddSourceDeps verbosity configFlags' configExFlags
-- installFlags globalFlags sandboxDir = topHandler' $ do
-+ installFlags globalFlags sandboxDir = topHandlerWith errorMsg $ do
- let sandboxDistPref = sandboxBuildDir sandboxDir
- configFlags = configFlags'
- { configDistPref = Flag sandboxDistPref }
-@@ -710,7 +710,8 @@ reinstallAddSourceDeps verbosity configFlags' configExFlags
- ++ "offending packages or recreating the sandbox."
- logMsg message rest = debugNoWrap verbosity message >> rest
-
-- topHandler' = topHandlerWith $ \_ -> do
-+ errorMsg :: a -> IO WereDepsReinstalled
-+ errorMsg _ = do
- warn verbosity "Couldn't reinstall some add-source dependencies."
- -- Here we can't know whether any deps have been reinstalled, so we have
- -- to be conservative.
-diff --git a/Distribution/Client/TargetSelector.hs b/Distribution/Client/TargetSelector.hs
-index 23d92f580fd..f8f683d9875 100644
---- a/Distribution/Client/TargetSelector.hs
-+++ b/Distribution/Client/TargetSelector.hs
-@@ -222,7 +222,7 @@ readTargetSelectorsWith :: (Applicative m, Monad m) => DirActions m
- -> Maybe ComponentKindFilter
- -> [String]
- -> m (Either [TargetSelectorProblem] [TargetSelector])
--readTargetSelectorsWith dirActions@DirActions{..} pkgs mfilter targetStrs =
-+readTargetSelectorsWith dirActions@DirActions{} pkgs mfilter targetStrs =
- case parseTargetStrings targetStrs of
- ([], usertargets) -> do
- usertargets' <- mapM (getTargetStringFileStatus dirActions) usertargets
-diff --git a/Distribution/Client/Update.hs b/Distribution/Client/Update.hs
-index 52bb1f76c96..8ded78b9d2e 100644
---- a/Distribution/Client/Update.hs
-+++ b/Distribution/Client/Update.hs
-@@ -73,8 +73,8 @@ updateRepo :: Verbosity -> UpdateFlags -> RepoContext -> Repo -> IO ()
- updateRepo verbosity updateFlags repoCtxt repo = do
- transport <- repoContextGetTransport repoCtxt
- case repo of
-- RepoLocal{..} -> return ()
-- RepoLocalNoIndex{..} -> return ()
-+ RepoLocal{} -> return ()
-+ RepoLocalNoIndex{} -> return ()
- RepoRemote{..} -> do
- downloadResult <- downloadIndex transport verbosity repoRemote repoLocalDir
- case downloadResult of
-diff --git a/Distribution/Client/Utils/Json.hs b/Distribution/Client/Utils/Json.hs
-index 89a13af87a4..01d5753136b 100644
---- a/Distribution/Client/Utils/Json.hs
-+++ b/Distribution/Client/Utils/Json.hs
-@@ -15,12 +15,9 @@ module Distribution.Client.Utils.Json
- )
- where
-
--import Data.Char
--import Data.Int
--import Data.String
--import Data.Word
--import Data.List
--import Data.Monoid
-+import Distribution.Client.Compat.Prelude
-+
-+import Data.Char (intToDigit)
-
- import Data.ByteString.Builder (Builder)
- import qualified Data.ByteString.Builder as BB
-@@ -135,13 +132,13 @@ encodeArrayBB :: [Value] -> Builder
- encodeArrayBB [] = "[]"
- encodeArrayBB jvs = BB.char8 '[' <> go jvs <> BB.char8 ']'
- where
-- go = Data.Monoid.mconcat . intersperse (BB.char8 ',') . map encodeValueBB
-+ go = mconcat . intersperse (BB.char8 ',') . map encodeValueBB
-
- encodeObjectBB :: Object -> Builder
- encodeObjectBB [] = "{}"
- encodeObjectBB jvs = BB.char8 '{' <> go jvs <> BB.char8 '}'
- where
-- go = Data.Monoid.mconcat . intersperse (BB.char8 ',') . map encPair
-+ go = mconcat . intersperse (BB.char8 ',') . map encPair
- encPair (l,x) = encodeStringBB l <> BB.char8 ':' <> encodeValueBB x
-
- encodeStringBB :: String -> Builder
-diff --git a/Distribution/Solver/Modular/Assignment.hs b/Distribution/Solver/Modular/Assignment.hs
-index be5e63bfbc1..b05a099ec5a 100644
---- a/Distribution/Solver/Modular/Assignment.hs
-+++ b/Distribution/Solver/Modular/Assignment.hs
-@@ -9,10 +9,11 @@ module Distribution.Solver.Modular.Assignment
- import Prelude ()
- import Distribution.Solver.Compat.Prelude hiding (pi)
-
--import Data.Array as A
--import Data.List as L
--import Data.Map as M
--import Data.Maybe
-+import qualified Data.Array as A
-+import qualified Data.List as L
-+import qualified Data.Map as M
-+
-+import Data.Maybe (fromJust)
-
- import Distribution.PackageDescription (FlagAssignment, mkFlagAssignment) -- from Cabal
-
-@@ -79,7 +80,7 @@ toCPs (A pa fa sa) rdm =
- -- Dependencies per package.
- depp :: QPN -> [(Component, PI QPN)]
- depp qpn = let v :: Vertex
-- v = fromJust (cvm qpn)
-+ v = fromJust (cvm qpn) -- TODO: why this is safe?
- dvs :: [(Component, Vertex)]
- dvs = tg A.! v
- in L.map (\ (comp, dv) -> case vm dv of (_, x, _) -> (comp, PI x (pa M.! x))) dvs
-diff --git a/Distribution/Solver/Modular/Builder.hs b/Distribution/Solver/Modular/Builder.hs
-index eb11a36aa16..5d196f4fd9f 100644
---- a/Distribution/Solver/Modular/Builder.hs
-+++ b/Distribution/Solver/Modular/Builder.hs
-@@ -19,10 +19,10 @@ module Distribution.Solver.Modular.Builder (
- -- flag-guarded dependencies, we cannot introduce them immediately. Instead, we
- -- store the entire dependency.
-
--import Data.List as L
--import Data.Map as M
--import Data.Set as S
--import Prelude hiding (sequence, mapM)
-+import qualified Data.List as L
-+import qualified Data.Map as M
-+import qualified Data.Set as S
-+import Prelude
-
- import qualified Distribution.Solver.Modular.ConflictSet as CS
- import Distribution.Solver.Modular.Dependency
-@@ -55,7 +55,7 @@ data BuildState = BS {
- }
-
- -- | Map of available linking targets.
--type LinkingState = Map (PN, I) [PackagePath]
-+type LinkingState = M.Map (PN, I) [PackagePath]
-
- -- | Extend the set of open goals with the new goals listed.
- --
-diff --git a/Distribution/Solver/Modular/Index.hs b/Distribution/Solver/Modular/Index.hs
-index fdddfc8237a..ac60fec7d65 100644
---- a/Distribution/Solver/Modular/Index.hs
-+++ b/Distribution/Solver/Modular/Index.hs
-@@ -6,10 +6,12 @@ module Distribution.Solver.Modular.Index
- , mkIndex
- ) where
-
--import Data.List as L
--import Data.Map as M
- import Prelude hiding (pi)
-
-+import Data.Map (Map)
-+import qualified Data.List as L
-+import qualified Data.Map as M
-+
- import Distribution.Solver.Modular.Dependency
- import Distribution.Solver.Modular.Flag
- import Distribution.Solver.Modular.Package
-diff --git a/Distribution/Solver/Modular/IndexConversion.hs b/Distribution/Solver/Modular/IndexConversion.hs
-index c9565c80dba..8e9ef614184 100644
---- a/Distribution/Solver/Modular/IndexConversion.hs
-+++ b/Distribution/Solver/Modular/IndexConversion.hs
-@@ -2,12 +2,12 @@ module Distribution.Solver.Modular.IndexConversion
- ( convPIs
- ) where
-
--import Data.List as L
-+import qualified Data.List as L
- import Data.Map.Strict (Map)
- import qualified Data.Map.Strict as M
--import Data.Maybe
-+import Data.Maybe (mapMaybe, fromMaybe, maybeToList)
- import Data.Monoid as Mon
--import Data.Set as S
-+import qualified Data.Set as S
-
- import Distribution.Compiler
- import Distribution.InstalledPackageInfo as IPI
-@@ -330,7 +330,7 @@ flagInfo (StrongFlags strfl) =
-
- -- | Internal package names, which should not be interpreted as true
- -- dependencies.
--type IPNs = Set PN
-+type IPNs = S.Set PN
-
- -- | Convenience function to delete a 'Dependency' if it's
- -- for a 'PN' that isn't actually real.
-diff --git a/Distribution/Solver/Modular/Solver.hs b/Distribution/Solver/Modular/Solver.hs
-index 32452550556..e6aa1fb4374 100644
---- a/Distribution/Solver/Modular/Solver.hs
-+++ b/Distribution/Solver/Modular/Solver.hs
-@@ -9,9 +9,9 @@ module Distribution.Solver.Modular.Solver
- , PruneAfterFirstSuccess(..)
- ) where
-
--import Data.Map as M
--import Data.List as L
--import Data.Set as S
-+import qualified Data.Map as M
-+import qualified Data.List as L
-+import qualified Data.Set as S
- import Distribution.Verbosity
-
- import Distribution.Compiler (CompilerInfo)
-@@ -91,8 +91,8 @@ solve :: SolverConfig -- ^ solver parameters
- -> Index -- ^ all available packages as an index
- -> PkgConfigDb -- ^ available pkg-config pkgs
- -> (PN -> PackagePreferences) -- ^ preferences
-- -> Map PN [LabeledPackageConstraint] -- ^ global constraints
-- -> Set PN -- ^ global goals
-+ -> M.Map PN [LabeledPackageConstraint] -- ^ global constraints
-+ -> S.Set PN -- ^ global goals
- -> RetryLog Message SolverFailure (Assignment, RevDepMap)
- solve sc cinfo idx pkgConfigDB userPrefs userConstraints userGoals =
- explorePhase $
-@@ -232,7 +232,7 @@ instance GSimpleTree (Tree d c) where
-
- -- Show conflict set
- goCS :: ConflictSet -> String
-- goCS cs = "{" ++ (intercalate "," . L.map showVar . CS.toList $ cs) ++ "}"
-+ goCS cs = "{" ++ (L.intercalate "," . L.map showVar . CS.toList $ cs) ++ "}"
- #endif
-
- -- | Replace all goal reasons with a dummy goal reason in the tree
-diff --git a/Distribution/Solver/Modular/Validate.hs b/Distribution/Solver/Modular/Validate.hs
-index 6195d101b02..a3dec6e1f67 100644
---- a/Distribution/Solver/Modular/Validate.hs
-+++ b/Distribution/Solver/Modular/Validate.hs
-@@ -15,11 +15,12 @@ module Distribution.Solver.Modular.Validate (validateTree) where
- import Control.Applicative
- import Control.Monad.Reader hiding (sequence)
- import Data.Function (on)
--import Data.List as L
--import Data.Set as S
- import Data.Traversable
- import Prelude hiding (sequence)
-
-+import qualified Data.List as L
-+import qualified Data.Set as S
-+
- import Language.Haskell.Extension (Extension, Language)
-
- import Data.Map.Strict as M
-diff --git a/bootstrap.sh b/bootstrap.sh
-index 077d7f4efd2..d5141660474 100755
---- a/bootstrap.sh
-+++ b/bootstrap.sh
-@@ -260,9 +260,9 @@ EDIT_DISTANCE_VER="0.2.2.1"; EDIT_DISTANCE_VER_REGEXP="0\.2\.2\.?"
- # 0.2.2.*
- ED25519_VER="0.0.5.0"; ED25519_VER_REGEXP="0\.0\.?"
- # 0.0.*
--HACKAGE_SECURITY_VER="0.6.0.0"; HACKAGE_SECURITY_VER_REGEXP="0\.6\."
-- # >= 0.7.0.0 && < 0.7
--TAR_VER="0.5.1.0"; TAR_VER_REGEXP="0\.5\.([1-9]|1[0-9]|0\.[3-9]|0\.1[0-9])\.?"
-+HACKAGE_SECURITY_VER="0.6.0.1"; HACKAGE_SECURITY_VER_REGEXP="0\.6\."
-+ # >= 0.6.0.0 && < 0.7
-+TAR_VER="0.5.1.1"; TAR_VER_REGEXP="0\.5\.([1-9]|1[0-9]|0\.[3-9]|0\.1[0-9])\.?"
- # >= 0.5.0.3 && < 0.6
- DIGEST_VER="0.0.1.2"; DIGEST_REGEXP="0\.0\.(1\.[2-9]|[2-9]\.?)"
- # >= 0.0.1.2 && < 0.1
-diff --git a/cabal-install.cabal b/cabal-install.cabal
-index 985ea9a5a69..c9d713c29fe 100644
---- a/cabal-install.cabal
-+++ b/cabal-install.cabal
-@@ -316,7 +316,7 @@ executable cabal
- build-depends:
- async >= 2.0 && < 2.3,
- array >= 0.4 && < 0.6,
-- base >= 4.8 && < 4.14,
-+ base >= 4.8 && < 4.15,
- base16-bytestring >= 0.1.1 && < 0.2,
- binary >= 0.7.3 && < 0.9,
- bytestring >= 0.10.6.0 && < 0.11,
-@@ -341,7 +341,7 @@ executable cabal
- time >= 1.5.0.1 && < 1.10,
- transformers >= 0.4.2.0 && < 0.6,
- zlib >= 0.5.3 && < 0.7,
-- hackage-security >= 0.6.0.0 && < 0.7,
-+ hackage-security >= 0.6.0.1 && < 0.7,
- text >= 1.2.3 && < 1.3,
- parsec >= 3.1.13.0 && < 3.2
-
-diff --git a/tests/IntegrationTests2/targets/complex/q/q.cabal b/tests/IntegrationTests2/targets/complex/q/q.cabal
-index 556fa4a4202..7ee22fcb28d 100644
---- a/tests/IntegrationTests2/targets/complex/q/q.cabal
-+++ b/tests/IntegrationTests2/targets/complex/q/q.cabal
-@@ -5,7 +5,8 @@ cabal-version: >= 1.2
-
- library
- exposed-modules: Q
-- build-depends: base, filepath
-+ -- we rely that filepath has filepath-tests component
-+ build-depends: base, filepath >=1.4.0.0
-
- executable buildable-false
- main-is: Main.hs
diff --git a/gnu/packages/patches/ccextractor-add-missing-header.patch b/gnu/packages/patches/ccextractor-add-missing-header.patch
new file mode 100644
index 0000000000..6c6c02be51
--- /dev/null
+++ b/gnu/packages/patches/ccextractor-add-missing-header.patch
@@ -0,0 +1,33 @@
+Upstream status: https://github.com/CCExtractor/ccextractor/pull/1505
+
+From 272e0e1410135c3a5de105cecce400c7b2a9ed5b Mon Sep 17 00:00:00 2001
+From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
+Date: Fri, 17 Mar 2023 09:49:29 -0400
+Subject: [PATCH] linux/Makefile.am: Add missing generated header.
+
+This header is generated by the pre-build.sh script. The compilation
+fails if it is missing.
+
+* linux/Makefile.am (ccextractor_SOURCES): Add
+../src/lib_ccx/compile_info_real.h.
+---
+ linux/Makefile.am | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/linux/Makefile.am b/linux/Makefile.am
+index fddc26a5..f83f1eff 100644
+--- a/linux/Makefile.am
++++ b/linux/Makefile.am
+@@ -118,6 +118,7 @@ ccextractor_SOURCES = \
+ ../src/lib_ccx/bitstream.h \
+ ../src/lib_ccx/ccx_common_option.c \
+ ../src/lib_ccx/ccx_common_common.c \
++ ../src/lib_ccx/compile_info_real.h \
+ ../src/lib_ccx/utility.c \
+ ../src/lib_ccx/activity.c \
+ ../src/lib_ccx/asf_functions.c \
+
+base-commit: cb496a711923c984251483776e652ca9c027513c
+--
+2.39.1
+
diff --git a/gnu/packages/patches/ccextractor-autoconf-tesseract.patch b/gnu/packages/patches/ccextractor-autoconf-tesseract.patch
new file mode 100644
index 0000000000..3ce2925acf
--- /dev/null
+++ b/gnu/packages/patches/ccextractor-autoconf-tesseract.patch
@@ -0,0 +1,37 @@
+Upstream status: https://github.com/CCExtractor/ccextractor/pull/1504
+
+From f587050c2b5805ff5feb667736381dcc9991a5d3 Mon Sep 17 00:00:00 2001
+From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
+Date: Fri, 17 Mar 2023 00:57:13 -0400
+Subject: [PATCH] linux/configure.ac: Fix tesseract conditional problem.
+
+For tesseract-ocr's stock pkg-config, it would produce an error due to
+unquoted whitespace:
+
+ $ test ! -z `pkg-config --libs-only-l --silence-errors tesseract`
+ bash: test: syntax error: `-larchive' unexpected
+
+* linux/configure.ac: Use a positive test, and double-quote the $() command
+substitution.
+---
+ linux/configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/linux/configure.ac b/linux/configure.ac
+index 45fc11f3..118ee7fa 100644
+--- a/linux/configure.ac
++++ b/linux/configure.ac
+@@ -149,7 +149,7 @@ AS_IF([ (test x$ocr = xtrue || test x$hardsubx = xtrue) && test ! $HAS_LEPT -gt
+ AM_CONDITIONAL(HARDSUBX_IS_ENABLED, [ test x$hardsubx = xtrue ])
+ AM_CONDITIONAL(OCR_IS_ENABLED, [ test x$ocr = xtrue || test x$hardsubx = xtrue ])
+ AM_CONDITIONAL(FFMPEG_IS_ENABLED, [ test x$ffmpeg = xtrue ])
+-AM_CONDITIONAL(TESSERACT_PRESENT, [ test ! -z `pkg-config --libs-only-l --silence-errors tesseract` ])
++AM_CONDITIONAL(TESSERACT_PRESENT, [ test -n "$(pkg-config --libs-only-l --silence-errors tesseract)" ])
+ AM_CONDITIONAL(TESSERACT_PRESENT_RPI, [ test -d "/usr/include/tesseract" && test `ls -A /usr/include/tesseract | wc -l` -gt 0 ])
+ AM_CONDITIONAL(SYS_IS_LINUX, [ test `uname -s` = "Linux"])
+ AM_CONDITIONAL(SYS_IS_MAC, [ test `uname -s` = "Darwin"])
+
+base-commit: cb496a711923c984251483776e652ca9c027513c
+--
+2.39.1
+
diff --git a/gnu/packages/patches/ccextractor-fix-ocr.patch b/gnu/packages/patches/ccextractor-fix-ocr.patch
new file mode 100644
index 0000000000..9a06026724
--- /dev/null
+++ b/gnu/packages/patches/ccextractor-fix-ocr.patch
@@ -0,0 +1,29 @@
+Extracted from upstream commit 0264e7da2be67182deb031228eb07e6ed4943c81.
+
+diff --git a/src/lib_ccx/ocr.c b/src/lib_ccx/ocr.c
+index 31cc1c5c..73bd4818 100644
+--- a/src/lib_ccx/ocr.c
++++ b/src/lib_ccx/ocr.c
+@@ -331,6 +331,11 @@ char *ocr_bitmap(void *arg, png_color *palette, png_byte *alpha, unsigned char *
+ }
+
+ BOX *crop_points = ignore_alpha_at_edge(copy->alpha, copy->data, w, h, color_pix, &color_pix_out);
++
++ l_int32 x, y, _w, _h;
++
++ boxGetGeometry(crop_points, &x, &y, &_w, &_h);
++
+ // Converting image to grayscale for OCR to avoid issues with transparency
+ cpix_gs = pixConvertRGBToGray(cpix, 0.0, 0.0, 0.0);
+
+@@ -426,8 +431,8 @@ char *ocr_bitmap(void *arg, png_color *palette, png_byte *alpha, unsigned char *
+ {
+ for (int j = x1; j <= x2; j++)
+ {
+- if (copy->data[(crop_points->y + i) * w + (crop_points->x + j)] != firstpixel)
+- histogram[copy->data[(crop_points->y + i) * w + (crop_points->x + j)]]++;
++ if (copy->data[(y + i) * w + (x + j)] != firstpixel)
++ histogram[copy->data[(y + i) * w + (x + j)]]++;
+ }
+ }
+ /* sorted in increasing order of intensity */
diff --git a/gnu/packages/patches/dbacl-icheck-multiple-definitions.patch b/gnu/packages/patches/dbacl-icheck-multiple-definitions.patch
new file mode 100644
index 0000000000..e82d0819bb
--- /dev/null
+++ b/gnu/packages/patches/dbacl-icheck-multiple-definitions.patch
@@ -0,0 +1,33 @@
+From f5df6813e305372e25b8a2124c491293a176e115 Mon Sep 17 00:00:00 2001
+From: Danny O'Brien <danny@spesh.com>
+Date: Fri, 3 Feb 2023 16:48:59 -0800
+Subject: [PATCH] Fix failing build of icheck.
+
+Building icheck fails with a duplicate symbol definition
+error. This allows the icheck executable to compile.
+
+Submitted upstream[1] but not yet moderated/accepted.
+
+[1] https://sourceforge.net/p/dbacl/discussion/239876/thread/87636b0114/
+
+---
+ src/icheck.c | 3 ---
+ 1 file changed, 3 deletions(-)
+
+diff --git a/src/icheck.c b/src/icheck.c
+index efbb6a5..12a3b7a 100644
+--- a/src/icheck.c
++++ b/src/icheck.c
+@@ -39,9 +39,6 @@ extern regex_count_t regex_count;
+ extern empirical_t empirical;
+
+ extern int cmd;
+-char *progname = "icheck";
+-char *inputfile = "";
+-long inputline = 0;
+
+ extern long system_pagesize;
+ extern void *in_iobuf;
+--
+2.39.1
+
diff --git a/gnu/packages/patches/ddclient-skip-test.patch b/gnu/packages/patches/ddclient-skip-test.patch
new file mode 100644
index 0000000000..28d748997b
--- /dev/null
+++ b/gnu/packages/patches/ddclient-skip-test.patch
@@ -0,0 +1,43 @@
+From e5657802025f238b39581534f3b4d408565c8943 Mon Sep 17 00:00:00 2001
+From: Bruno Victal <mirai@makinata.eu>
+Date: Sun, 5 Feb 2023 21:05:00 +0000
+Subject: [PATCH] Disable sandbox incompatible tests.
+
+See: https://github.com/ddclient/ddclient/issues/465
+---
+ t/get_ip_from_if.pl | 21 ---------------------
+ 1 file changed, 21 deletions(-)
+
+diff --git a/t/get_ip_from_if.pl b/t/get_ip_from_if.pl
+index 6f08e5d..d78c3d0 100644
+--- a/t/get_ip_from_if.pl
++++ b/t/get_ip_from_if.pl
+@@ -39,25 +39,4 @@ subtest "get_ip_from_interface tests" => sub {
+ }
+ };
+
+-subtest "Get default interface and IP for test system" => sub {
+- my $interface = ddclient::get_default_interface(4);
+- if ($interface) {
+- isnt($interface, "lo", "Check for loopback 'lo'");
+- isnt($interface, "lo0", "Check for loopback 'lo0'");
+- my $ip1 = ddclient::get_ip_from_interface("default", 4);
+- my $ip2 = ddclient::get_ip_from_interface($interface, 4);
+- is($ip1, $ip2, "Check IPv4 from default interface");
+- ok(ddclient::is_ipv4($ip1), "Valid IPv4 from get_ip_from_interface($interface)");
+- }
+- $interface = ddclient::get_default_interface(6);
+- if ($interface) {
+- isnt($interface, "lo", "Check for loopback 'lo'");
+- isnt($interface, "lo0", "Check for loopback 'lo0'");
+- my $ip1 = ddclient::get_ip_from_interface("default", 6);
+- my $ip2 = ddclient::get_ip_from_interface($interface, 6);
+- is($ip1, $ip2, "Check IPv6 from default interface");
+- ok(ddclient::is_ipv6($ip1), "Valid IPv6 from get_ip_from_interface($interface)");
+- }
+-};
+-
+ done_testing();
+--
+2.38.1
+
diff --git a/gnu/packages/patches/efibootmgr-remove-extra-decl.patch b/gnu/packages/patches/efibootmgr-remove-extra-decl.patch
deleted file mode 100644
index eb68108f88..0000000000
--- a/gnu/packages/patches/efibootmgr-remove-extra-decl.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 99b578501643377e0b1994b2a068b790d189d5ad Mon Sep 17 00:00:00 2001
-From: Peter Jones <pjones@redhat.com>
-Date: Wed, 13 Jun 2018 09:41:01 -0400
-Subject: [PATCH] remove extra decl
-
-Signed-off-by: Peter Jones <pjones@redhat.com>
----
- src/efibootmgr.c | 3 ---
- 1 file changed, 3 deletions(-)
-
-diff --git a/src/efibootmgr.c b/src/efibootmgr.c
-index de38f01..4e1a680 100644
---- a/src/efibootmgr.c
-+++ b/src/efibootmgr.c
-@@ -1536,9 +1536,6 @@ parse_opts(int argc, char **argv)
- "invalid numeric value %s\n",
- optarg);
- }
-- /* XXX efivar-36 accidentally doesn't have a public
-- * header for this */
-- extern int efi_set_verbose(int verbosity, FILE *errlog);
- efi_set_verbose(opts.verbose - 2, stderr);
- break;
- case 'V':
---
-2.24.0
-
diff --git a/gnu/packages/patches/elm-ghc9.2.patch b/gnu/packages/patches/elm-ghc9.2.patch
new file mode 100644
index 0000000000..7b1e653e80
--- /dev/null
+++ b/gnu/packages/patches/elm-ghc9.2.patch
@@ -0,0 +1,187 @@
+From f88043586337ba33cf3e852908003a71dfe493ec Mon Sep 17 00:00:00 2001
+From: vlkrs <codeberg@schlecht.dev>
+Date: Sat, 7 May 2022 17:51:15 +0200
+Subject: [PATCH] Quick hack to build on ghc-9.2.2
+
+Taken from
+https://codeberg.org/vlkrs/elm-compiler/commit/f88043586337ba33cf3e852908003a71dfe493ec.patch
+
+diff --git a/compiler/src/Data/Name.hs b/compiler/src/Data/Name.hs
+index beecf114..39b64029 100644
+--- a/compiler/src/Data/Name.hs
++++ b/compiler/src/Data/Name.hs
+@@ -47,6 +47,7 @@ import qualified Data.Utf8 as Utf8
+ import GHC.Exts
+ ( Int(I#), Ptr
+ , MutableByteArray#
++ , int8ToInt#
+ , isTrue#
+ , newByteArray#
+ , sizeofByteArray#
+@@ -241,7 +242,7 @@ fromTypeVariable name@(Utf8.Utf8 ba#) index =
+ else
+ let
+ len# = sizeofByteArray# ba#
+- end# = indexWord8Array# ba# (len# -# 1#)
++ end# = word8ToWord# (indexWord8Array# ba# (len# -# 1#))
+ in
+ if isTrue# (leWord# 0x30## end#) && isTrue# (leWord# end# 0x39##) then
+ runST
+@@ -316,11 +317,11 @@ fromManyNames names =
+ ST $ \s ->
+ case newByteArray# (len# +# 3#) s of
+ (# s, mba# #) ->
+- case writeWord8Array# mba# 0# 0x5F## {-_-} s of
++ case writeWord8Array# mba# 0# (wordToWord8# 0x5F##) {-_-} s of
+ s ->
+- case writeWord8Array# mba# 1# 0x4D## {-M-} s of
++ case writeWord8Array# mba# 1# (wordToWord8# 0x4D##) {-M-} s of
+ s ->
+- case writeWord8Array# mba# 2# 0x24## {-$-} s of
++ case writeWord8Array# mba# 2# (wordToWord8# 0x24##) {-$-} s of
+ s ->
+ case copyByteArray# ba# 0# mba# 3# len# s of
+ s ->
+diff --git a/compiler/src/Data/Utf8.hs b/compiler/src/Data/Utf8.hs
+index e985aa64..472777df 100644
+--- a/compiler/src/Data/Utf8.hs
++++ b/compiler/src/Data/Utf8.hs
+@@ -109,10 +109,10 @@ contains (W8# word#) (Utf8 ba#) =
+ containsHelp word# ba# 0# (sizeofByteArray# ba#)
+
+
+-containsHelp :: Word# -> ByteArray# -> Int# -> Int# -> Bool
++containsHelp :: Word8# -> ByteArray# -> Int# -> Int# -> Bool
+ containsHelp word# ba# !offset# len# =
+ if isTrue# (offset# <# len#) then
+- if isTrue# (eqWord# word# (indexWord8Array# ba# offset#))
++ if isTrue# (eqWord8# word# (indexWord8Array# ba# offset#))
+ then True
+ else containsHelp word# ba# (offset# +# 1#) len#
+ else
+@@ -147,10 +147,10 @@ startsWithChar isGood bytes@(Utf8 ba#) =
+ let
+ !w# = indexWord8Array# ba# 0#
+ !char
+- | isTrue# (ltWord# w# 0xC0##) = C# (chr# (word2Int# w#))
+- | isTrue# (ltWord# w# 0xE0##) = chr2 ba# 0# w#
+- | isTrue# (ltWord# w# 0xF0##) = chr3 ba# 0# w#
+- | True = chr4 ba# 0# w#
++ | isTrue# (ltWord8# w# (wordToWord8# 0xC0##)) = C# (chr# (int8ToInt# (word8ToInt8# w#)))
++ | isTrue# (ltWord8# w# (wordToWord8# 0xE0##)) = chr2 ba# 0# (word8ToWord# w#)
++ | isTrue# (ltWord8# w# (wordToWord8# 0xF0##)) = chr3 ba# 0# (word8ToWord# w#)
++ | True = chr4 ba# 0# (word8ToWord# w#)
+ in
+ isGood char
+
+@@ -164,7 +164,7 @@ endsWithWord8 (W8# w#) (Utf8 ba#) =
+ let len# = sizeofByteArray# ba# in
+ isTrue# (len# ># 0#)
+ &&
+- isTrue# (eqWord# w# (indexWord8Array# ba# (len# -# 1#)))
++ isTrue# (eqWord8# w# (indexWord8Array# ba# (len# -# 1#)))
+
+
+
+@@ -186,11 +186,11 @@ splitHelp str start offsets =
+ unsafeSlice str start offset : splitHelp str (offset + 1) offsets
+
+
+-findDividers :: Word# -> ByteArray# -> Int# -> Int# -> [Int] -> [Int]
++findDividers :: Word8# -> ByteArray# -> Int# -> Int# -> [Int] -> [Int]
+ findDividers divider# ba# !offset# len# revOffsets =
+ if isTrue# (offset# <# len#) then
+ findDividers divider# ba# (offset# +# 1#) len# $
+- if isTrue# (eqWord# divider# (indexWord8Array# ba# offset#))
++ if isTrue# (eqWord8# divider# (indexWord8Array# ba# offset#))
+ then I# offset# : revOffsets
+ else revOffsets
+ else
+@@ -353,10 +353,10 @@ toCharsHelp ba# offset# len# =
+ let
+ !w# = indexWord8Array# ba# offset#
+ !(# char, width# #)
+- | isTrue# (ltWord# w# 0xC0##) = (# C# (chr# (word2Int# w#)), 1# #)
+- | isTrue# (ltWord# w# 0xE0##) = (# chr2 ba# offset# w#, 2# #)
+- | isTrue# (ltWord# w# 0xF0##) = (# chr3 ba# offset# w#, 3# #)
+- | True = (# chr4 ba# offset# w#, 4# #)
++ | isTrue# (ltWord8# w# (wordToWord8# 0xC0##)) = (# C# (chr# (int8ToInt# (word8ToInt8# w#))), 1# #)
++ | isTrue# (ltWord8# w# (wordToWord8# 0xE0##)) = (# chr2 ba# offset# (word8ToWord# w#), 2# #)
++ | isTrue# (ltWord8# w# (wordToWord8# 0xF0##)) = (# chr3 ba# offset# (word8ToWord# w#), 3# #)
++ | True = (# chr4 ba# offset# (word8ToWord# w#), 4# #)
+
+ !newOffset# = offset# +# width#
+ in
+@@ -368,7 +368,7 @@ chr2 :: ByteArray# -> Int# -> Word# -> Char
+ chr2 ba# offset# firstWord# =
+ let
+ !i1# = word2Int# firstWord#
+- !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
++ !i2# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 1#)))
+ !c1# = uncheckedIShiftL# (i1# -# 0xC0#) 6#
+ !c2# = i2# -# 0x80#
+ in
+@@ -380,8 +380,8 @@ chr3 :: ByteArray# -> Int# -> Word# -> Char
+ chr3 ba# offset# firstWord# =
+ let
+ !i1# = word2Int# firstWord#
+- !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
+- !i3# = word2Int# (indexWord8Array# ba# (offset# +# 2#))
++ !i2# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 1#)))
++ !i3# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 2#)))
+ !c1# = uncheckedIShiftL# (i1# -# 0xE0#) 12#
+ !c2# = uncheckedIShiftL# (i2# -# 0x80#) 6#
+ !c3# = i3# -# 0x80#
+@@ -394,9 +394,9 @@ chr4 :: ByteArray# -> Int# -> Word# -> Char
+ chr4 ba# offset# firstWord# =
+ let
+ !i1# = word2Int# firstWord#
+- !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
+- !i3# = word2Int# (indexWord8Array# ba# (offset# +# 2#))
+- !i4# = word2Int# (indexWord8Array# ba# (offset# +# 3#))
++ !i2# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 1#)))
++ !i3# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 2#)))
++ !i4# = int8ToInt# (word8ToInt8# (indexWord8Array# ba# (offset# +# 3#)))
+ !c1# = uncheckedIShiftL# (i1# -# 0xF0#) 18#
+ !c2# = uncheckedIShiftL# (i2# -# 0x80#) 12#
+ !c3# = uncheckedIShiftL# (i3# -# 0x80#) 6#
+@@ -471,7 +471,7 @@ toEscapedBuilderHelp before after !name@(Utf8 ba#) k =
+ escape :: Word8 -> Word8 -> Ptr a -> Utf8 t -> Int -> Int -> Int -> IO ()
+ escape before@(W8# before#) after ptr name@(Utf8 ba#) offset@(I# offset#) len@(I# len#) i@(I# i#) =
+ if isTrue# (i# <# len#) then
+- if isTrue# (eqWord# before# (indexWord8Array# ba# (offset# +# i#)))
++ if isTrue# (eqWord8# before# (indexWord8Array# ba# (offset# +# i#)))
+ then
+ do writeWordToPtr ptr i after
+ escape before after ptr name offset len (i + 1)
+diff --git a/compiler/src/Parse/Primitives.hs b/compiler/src/Parse/Primitives.hs
+index bb973193..3747cfac 100644
+--- a/compiler/src/Parse/Primitives.hs
++++ b/compiler/src/Parse/Primitives.hs
+@@ -82,7 +82,7 @@ instance Functor (Parser x) where
+
+ instance Applicative.Applicative (Parser x) where
+ {-# INLINE pure #-}
+- pure = return
++ pure = pure
+
+ {-# INLINE (<*>) #-}
+ (<*>) (Parser parserFunc) (Parser parserArg) =
+diff --git a/compiler/src/Parse/Variable.hs b/compiler/src/Parse/Variable.hs
+index f3d86145..5e0ea802 100644
+--- a/compiler/src/Parse/Variable.hs
++++ b/compiler/src/Parse/Variable.hs
+@@ -22,6 +22,7 @@ import qualified Data.Set as Set
+ import Data.Word (Word8)
+ import Foreign.Ptr (Ptr, plusPtr)
+ import GHC.Exts (Char(C#), Int#, (+#), (-#), chr#, uncheckedIShiftL#, word2Int#)
++import GHC.Prim
+ import GHC.Word (Word8(W8#))
+
+ import qualified AST.Source as Src
+@@ -384,4 +385,4 @@ chr4 pos firstWord =
+
+ unpack :: Word8 -> Int#
+ unpack (W8# word#) =
+- word2Int# word#
++ int8ToInt# (word8ToInt8# word#)
diff --git a/gnu/packages/patches/emacs-helpful-fix-docstring-test.patch b/gnu/packages/patches/emacs-helpful-fix-docstring-test.patch
deleted file mode 100644
index de40010fa2..0000000000
--- a/gnu/packages/patches/emacs-helpful-fix-docstring-test.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This patch fixing a build failure has been cherry-picked from upstream.
-Originally submitted as pull request by Erik Šabič.
-See also <https://github.com/Wilfred/helpful/pull/296>.
-diff --git a/test/helpful-unit-test.el b/test/helpful-unit-test.el
-index a07aa8e..8a95129 100644
---- a/test/helpful-unit-test.el
-+++ b/test/helpful-unit-test.el
-@@ -119,7 +119,9 @@ bar")))
- (should
- (equal
- (helpful--docstring #'test-foo-advised t)
-- "Docstring here too.")))
-+ (if (version< emacs-version "28")
-+ "Docstring here too."
-+ "Docstring here too.\n\nThis function has :around advice: `ad-Advice-test-foo-advised'."))))
-
- (defun test-foo-no-docstring ()
- nil)
diff --git a/gnu/packages/patches/emacs-pasp-mode-quote-file-names.patch b/gnu/packages/patches/emacs-pasp-mode-quote-file-names.patch
new file mode 100644
index 0000000000..39dc5d0253
--- /dev/null
+++ b/gnu/packages/patches/emacs-pasp-mode-quote-file-names.patch
@@ -0,0 +1,20 @@
+diff --git a/pasp-mode.el b/pasp-mode.el
+index 7f83645..5daf08e 100644
+--- a/pasp-mode.el
++++ b/pasp-mode.el
+@@ -199,9 +199,12 @@
+ Argument ENCODING The current buffer which holds the problem encoding.
+ Optional argument INSTANCE The problem instance which is solved by the encoding.
+ If no instance it is assumed to be also in the encoding file."
+- (if 'instance
+- (concat pasp-clingo-path " " pasp-clingo-options " " encoding " " instance)
+- (concat pasp-clingo-path " " pasp-clingo-options " " encoding)))
++ (if instance
++ (concat pasp-clingo-path " " pasp-clingo-options " "
++ (shell-quote-argument encoding) " "
++ (shell-quote-argument instance))
++ (concat pasp-clingo-path " " pasp-clingo-options " "
++ (shell-quote-argument encoding))))
+
+ (defun pasp-run-clingo (encoding &optional instance)
+ "Run Clingo with some ASP input files.
diff --git a/gnu/packages/patches/esmini-no-clutter-log.patch b/gnu/packages/patches/esmini-no-clutter-log.patch
new file mode 100644
index 0000000000..0920244f78
--- /dev/null
+++ b/gnu/packages/patches/esmini-no-clutter-log.patch
@@ -0,0 +1,30 @@
+Don't clutter /tmp with logs.
+
+---
+ EnvironmentSimulator/Modules/CommonMini/CommonMini.cpp | 10 ++--------
+ 1 file changed, 2 insertions(+), 8 deletions(-)
+
+diff --git a/EnvironmentSimulator/Modules/CommonMini/CommonMini.cpp b/EnvironmentSimulator/Modules/CommonMini/CommonMini.cpp
+index 56c655dc..2750f5a6 100644
+--- a/EnvironmentSimulator/Modules/CommonMini/CommonMini.cpp
++++ b/EnvironmentSimulator/Modules/CommonMini/CommonMini.cpp
+@@ -1013,14 +1013,8 @@ void Logger::OpenLogfile(std::string filename)
+ file_.open(filename.c_str());
+ if (file_.fail())
+ {
+- const char* filename_tmp = std::tmpnam(NULL);
+- printf("Cannot open log file: %s in working directory. Trying system tmp-file: %s\n",
+- SE_Env::Inst().GetLogFilePath().c_str(), filename_tmp);
+- file_.open(filename_tmp);
+- if (file_.fail())
+- {
+- printf("Also failed to open log file: %s. Continue without logfile, still logging to console.\n", filename_tmp);
+- }
++ printf("Cannot open log file: %s in working directory. Continuing without logfile, still logging to console.\n",
++ filename.c_str());
+ }
+ }
+ #endif
+--
+2.38.1
+
diff --git a/gnu/packages/patches/esmini-use-pkgconfig.patch b/gnu/packages/patches/esmini-use-pkgconfig.patch
new file mode 100644
index 0000000000..73e1b50015
--- /dev/null
+++ b/gnu/packages/patches/esmini-use-pkgconfig.patch
@@ -0,0 +1,541 @@
+Find dependencies via pkg-config.
+
+---
+ CMakeLists.txt | 16 +-
+ .../Applications/esmini-dyn/CMakeLists.txt | 5 +-
+ .../Applications/esmini/CMakeLists.txt | 1 +
+ EnvironmentSimulator/CMakeLists.txt | 296 +-----------------
+ .../Modules/Controllers/ControllerSumo.cpp | 1 -
+ .../Modules/RoadManager/CMakeLists.txt | 8 +-
+ .../Modules/ScenarioEngine/CMakeLists.txt | 15 +-
+ 7 files changed, 23 insertions(+), 319 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 156d9448..10ec48f9 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -8,6 +8,7 @@ else()
+ cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR)
+ endif()
+
++include(FindPkgConfig)
+
+ project (EnvironmentSimulator)
+
+@@ -33,15 +34,10 @@ else ()
+ set (LINUX false)
+ endif ()
+
+-if (LINUX OR APPLE OR MINGW OR MSVC)
+- set(INSTALL_DIRECTORY "${CMAKE_HOME_DIRECTORY}/bin")
+-else ()
+- message(FATAL_ERROR "Unrecognized platform therefore there isn't an installation directory. Stopping the cmake process.")
+-endif ()
+-
+ set(INSTALL_DIRECTORY_CODE_EXAMPLES "${CMAKE_HOME_DIRECTORY}/code-examples-bin")
+
+-set(PUGIXML_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/externals/pugixml")
++find_package(pugixml)
++
+ set(EXPR_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/externals/expr")
+ if(MSVC)
+ set(DIRENT_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/externals/dirent/win")
+@@ -61,10 +57,14 @@ set(ENABLE_SANITIZERS False CACHE BOOL "Enable sanitizers (Only valid for Linux
+
+
+ if (USE_OSG)
++ pkg_check_modules(OSG REQUIRED openscenegraph osgdb_jpeg osgdb_osg
++ osgdb_serializers_osg
++ osgdb_serializers_osgsim)
+ add_definitions(-D_USE_OSG)
+ endif (USE_OSG)
+
+ if (USE_OSI)
++ find_package(open_simulation_interface REQUIRED)
+ add_definitions(-D_USE_OSI)
+ endif (USE_OSI)
+
+@@ -73,6 +73,7 @@ if (USE_SUMO)
+ endif (USE_SUMO)
+
+ if (USE_GTEST)
++ find_package(GTest REQUIRED)
+ add_definitions(-D_USE_GTEST)
+ endif (USE_GTEST)
+
+@@ -90,5 +91,4 @@ if( NOT EXISTS "test/OSC-ALKS-scenarios/.git" )
+ endif()
+
+ # Add variables to global scope, e.g. when esmini is used as submodule
+-set(PUGIXML_INCLUDE_DIR ${PUGIXML_INCLUDE_DIR} CACHE INTERNAL "")
+ set(EXPR_INCLUDE_DIR ${EXPR_INCLUDE_DIR} CACHE INTERNAL "")
+diff --git a/EnvironmentSimulator/Applications/esmini-dyn/CMakeLists.txt b/EnvironmentSimulator/Applications/esmini-dyn/CMakeLists.txt
+index 83d89420..e15062d3 100644
+--- a/EnvironmentSimulator/Applications/esmini-dyn/CMakeLists.txt
++++ b/EnvironmentSimulator/Applications/esmini-dyn/CMakeLists.txt
+@@ -1,7 +1,7 @@
+
+ include_directories (
+ ${SCENARIOENGINE_DLL_INCLUDE_DIR}
+- ${COMMON_MINI_INCLUDE_DIR}
++ ${COMMON_MINI_INCLUDE_DIR}
+ ${OSI_INCLUDE_DIR}
+ )
+
+@@ -19,11 +19,12 @@ link_directories( ${OSI_DIR}/lib )
+ add_executable ( ${TARGET} ${SOURCES} ${INCLUDES} )
+
+
+-target_link_libraries (
++target_link_libraries (
+ ${TARGET}
+ esminiLib
+ CommonMini
+ ${TIME_LIB}
++ pugixml::pugixml
+ project_options
+ )
+
+diff --git a/EnvironmentSimulator/Applications/esmini/CMakeLists.txt b/EnvironmentSimulator/Applications/esmini/CMakeLists.txt
+index 6890c26a..a088ebdc 100644
+--- a/EnvironmentSimulator/Applications/esmini/CMakeLists.txt
++++ b/EnvironmentSimulator/Applications/esmini/CMakeLists.txt
+@@ -44,6 +44,7 @@ target_link_libraries (
+ ${sumo_libs}
+ ${TIME_LIB}
+ ${SOCK_LIB}
++ pugixml::pugixml
+ project_options
+ )
+
+diff --git a/EnvironmentSimulator/CMakeLists.txt b/EnvironmentSimulator/CMakeLists.txt
+index 157e8fe0..e771231a 100644
+--- a/EnvironmentSimulator/CMakeLists.txt
++++ b/EnvironmentSimulator/CMakeLists.txt
+@@ -1,7 +1,3 @@
+-
+-set ( FILE_STORAGE "esmini" ) # "dropbox", "google", "esmini" (limited GB/Day)
+-set ( MODEL_STORAGE "esmini" ) # "dropbox", "google", "esmini" (limited GB/Day)
+-
+ set ( VIEWER_BASE_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Modules/ViewerBase" )
+ set ( PLAYER_BASE_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Modules/PlayerBase" )
+ set ( ROADMANAGER_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Modules/RoadManager" )
+@@ -17,88 +13,12 @@ set ( CONTROLLERS_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Modules/Controllers")
+
+ # OpenSceneGraph package adapted for this project
+ set ( OSG_VERSION "osg161" )
+-set ( OSG_BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../externals/OpenSceneGraph" )
+-set ( OSI_BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../externals/OSI" )
+-set ( SUMO_BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../externals/SUMO" )
+
+ # GoogleTest package
+ set ( GTEST_VERSION "1.10.1" )
+-set ( GTEST_BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../externals/googletest" )
+
+ set( CMAKE_VERBOSE_MAKEFILE true )
+
+-if ( ${FILE_STORAGE} STREQUAL "dropbox" )
+- if (APPLE)
+- set ( OSG_PACKAGE_URL https://www.dropbox.com/s/d0czj6b89p9jyvv/OpenSceneGraph_mac.7z?dl=1 )
+- set ( OSI_PACKAGE_URL https://www.dropbox.com/s/m62v19gp0m73dte/osi_mac.7z?dl=1 )
+- set ( SUMO_PACKAGE_URL https://www.dropbox.com/s/0x8kwztk7nmacs1/sumo_mac.7z?dl=1 )
+- elseif (LINUX)
+- set ( OSG_PACKAGE_URL https://www.dropbox.com/s/4ug0gmkgdavzyb4/osg_linux_glibc_2_31_gcc_7_5_0.7z?dl=1 )
+- set ( OSI_PACKAGE_URL https://dl.dropboxusercontent.com/s/kwtdg0c1c8pawa1/osi_linux.7z?dl=1 )
+- set ( SUMO_PACKAGE_URL https://dl.dropboxusercontent.com/s/gfwtqd3gf76f86a/sumo_linux.7z?dl=1 )
+- set ( GTEST_PACKAGE_URL https://dl.dropboxusercontent.com/s/si7jsjjsy5bpoym/googletest_linux.7z?dl=1 )
+- elseif (MSVC)
+- set ( OSG_PACKAGE_URL https://dl.dropboxusercontent.com/s/e95hnoo782p40uc/OpenSceneGraph_v10.7z?dl=1 )
+- set ( OSI_PACKAGE_URL https://dl.dropboxusercontent.com/s/an58ckp2qfx5069/osi_v10.7z?dl=1 )
+- set ( SUMO_PACKAGE_URL https://dl.dropboxusercontent.com/s/5jtpnnd61wonxuh/sumo_v10.7z?dl=1 )
+- set ( GTEST_PACKAGE_URL https://dl.dropboxusercontent.com/s/aaiehwzc6woqbc6/googletest_v10.7z?dl=1 )
+- elseif (MINGW)
+- message("MinGW, enforcing slimmed esmini")
+- else ()
+- message ("Unsupported configuration")
+- endif ()
+-elseif ( ${FILE_STORAGE} STREQUAL "google" )
+- if (APPLE)
+- set ( OSG_PACKAGE_URL https://drive.google.com/u/1/uc?id=1mfn_vrcXBoFBekR_t8RXTWB4sD59JD7p&export=download )
+- set ( OSI_PACKAGE_URL https://drive.google.com/u/1/uc?id=1UVzO8cPQaDU9KVn9v2v8Suj0uUw1dzYI&export=download )
+- set ( SUMO_PACKAGE_URL https://drive.google.com/u/1/uc?id=1FAve0-MlJPv6lUZy0HvriZI7xstLAzvX&export=download )
+- elseif (LINUX)
+- set ( OSG_PACKAGE_URL https://drive.google.com/u/1/uc?id=1Ya1bLp_0-qqlhs67WAwbGW7l37wqP3o2&export=download )
+- set ( OSI_PACKAGE_URL https://drive.google.com/u/1/uc?id=1Q8O9YciIC0BPEszIKtQ2UW9KcVRZS4iB&export=download )
+- set ( SUMO_PACKAGE_URL https://drive.google.com/u/1/uc?id=1m4znxNIXapP0D-l21oIm2l7L5ti-JbZH&export=download )
+- set ( GTEST_PACKAGE_URL https://drive.google.com/u/1/uc?id=1Hyr9eJX2GmgpYwZhx14xOoXlZ2j-FY_p&export=download )
+- elseif (MSVC)
+- set ( OSG_PACKAGE_URL https://drive.google.com/u/1/uc?id=1RTag0aUn_pJPK697j0-E72ABW10wZvOm&export=download )
+- set ( OSI_PACKAGE_URL https://drive.google.com/u/1/uc?id=1pcQcVHUESOk2Wmi-zUA7uzdxxE6iwRJx&export=download )
+- set ( SUMO_PACKAGE_URL https://drive.google.com/u/1/uc?id=18PhbSLyvs0IGWTAY3YBoYzpVnMFPbOuR&export=download )
+- set ( GTEST_PACKAGE_URL https://drive.google.com/u/1/uc?id=1So-3gtrmEdW9RhEvVQisj1QFksHM_otU&export=download )
+- elseif (MINGW)
+- message("MinGW, enforcing slimmed esmini")
+- else ()
+- message ("Unsupported configuration")
+- endif ()
+-elseif ( ${FILE_STORAGE} STREQUAL "esmini" )
+- if (APPLE)
+- set ( OSG_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/OpenSceneGraph_mac.7z )
+- set ( OSI_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/osi_mac.7z )
+- set ( SUMO_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/sumo_mac.7z )
+- elseif (LINUX)
+- set ( OSG_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/osg_linux_glibc_2_31_gcc_7_5_0.7z )
+- set ( OSI_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/osi_linux.7z )
+- set ( SUMO_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/sumo_linux.7z )
+- set ( GTEST_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/googletest_linux.7z )
+- elseif (MSVC)
+- set ( OSG_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/OpenSceneGraph_v10.7z )
+- set ( OSI_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/osi_v10.7z )
+- set ( SUMO_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/sumo_v10.7z )
+- set ( GTEST_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD766065121/libs/googletest_v10.7z )
+- elseif (MINGW)
+- message("MinGW, enforcing slimmed esmini")
+- else ()
+- message ("Unsupported configuration")
+- endif ()
+-else ()
+- Message("Unknown storage type: " ${FILE_STORAGE})
+-endif()
+-
+-if ( ${MODEL_STORAGE} STREQUAL "dropbox" )
+- set ( MODELS_PACKAGE_URL https://dl.dropboxusercontent.com/s/5gk8bvgzqiaaoco/models.7z?dl=0 )
+-elseif ( ${MODEL_STORAGE} STREQUAL "google" )
+- set ( MODELS_PACKAGE_URL https://drive.google.com/u/1/uc?id=1c3cqRzwY41gWXbg0rmugQkL5I_5L6DH_&export=download )
+-elseif ( ${MODEL_STORAGE} STREQUAL "esmini" )
+- set ( MODELS_PACKAGE_URL https://esmini.asuscomm.com/AICLOUD779364751/models/models.7z )
+-endif()
+-
+ if (APPLE)
+ set ( EXT_DIR_NAME "mac" )
+ set ( TIME_LIB "" )
+@@ -127,21 +47,8 @@ set ( OSI_DIR "${OSI_BASE_DIR}/${EXT_DIR_NAME}" )
+ set ( SUMO_DIR "${SUMO_BASE_DIR}/${EXT_DIR_NAME}" )
+ set ( GTEST_DIR "${GTEST_BASE_DIR}/${EXT_DIR_NAME}" )
+
+-set ( OSG_INCLUDE_DIR
+- "${OSG_DIR}/build/include"
+- "${OSG_DIR}/include"
+-)
+-set ( OSG_LIBRARIES_PATH
+- "${OSG_DIR}/lib"
+- "${OSG_DIR}/lib/osgPlugins-3.6.5"
+-)
+-
+ set ( OSI_INCLUDE_DIR "${OSI_DIR}/include" )
+-if (DYN_PROTOBUF)
+- set ( OSI_LIBRARIES_PATH "${OSI_DIR}/lib-dyn" )
+-else ()
+- set ( OSI_LIBRARIES_PATH "${OSI_DIR}/lib" )
+-endif (DYN_PROTOBUF)
++set ( OSI_LIBRARIES_PATH "${OSI_DIR}/lib" )
+
+ set ( SUMO_INCLUDE_DIR "${SUMO_DIR}/include" )
+ set ( SUMO_LIBRARIES_PATH "${SUMO_DIR}/lib" )
+@@ -153,74 +60,6 @@ link_directories(${OSG_LIBRARIES_PATH} ${OSI_LIBRARIES_PATH} ${SUMO_LIBRARIES_PA
+
+ if(APPLE)
+ SET(CMAKE_CXX_FLAGS "${CXX_STD_FLAG} -std=c++14 -pthread -fPIC -flto -DGL_SILENCE_DEPRECATION -Wl,-dead_strip")
+-
+- set ( OSG_LIBRARIES
+- osg
+- osgViewer
+- osgDB
+- osgdb_serializers_osgsim
+- osgdb_serializers_osg
+- osgGA
+- osgText
+- osgSim
+- osgdb_osg
+- osgdb_jpeg
+- osgUtil
+- osgAnimation
+- osg
+- OpenThreads
+- jpeg
+- "-framework OpenGL"
+- "-framework Cocoa"
+- dl
+- z
+- )
+-
+- if (DYN_PROTOBUF)
+- set ( OSI_LIBRARIES
+- open_simulation_interface
+- protobuf
+- )
+- else ()
+- set ( OSI_LIBRARIES
+- open_simulation_interface_pic
+- protobuf
+- )
+- endif (DYN_PROTOBUF)
+-
+-
+- set ( SUMO_LIBRARIES
+- optimized libsumostatic debug libsumostaticd
+- optimized netload debug netloadd
+- optimized traciserver debug traciserverd
+- optimized libsumostatic debug libsumostaticd
+- optimized utils_vehicle debug utils_vehicled
+- optimized utils_distribution debug utils_distributiond
+- optimized utils_shapes debug utils_shapesd
+- optimized utils_options debug utils_optionsd
+- optimized utils_xml debug utils_xmld
+- optimized utils_geom debug utils_geomd
+- optimized utils_common debug utils_commond
+- optimized utils_iodevices debug utils_iodevicesd
+- optimized utils_traction_wire debug utils_traction_wired
+- optimized utils_emissions debug utils_emissionsd
+- optimized microsim_engine debug microsim_engined
+- optimized microsim_lcmodels debug microsim_lcmodelsd
+- optimized microsim_devices debug microsim_devicesd
+- optimized microsim_trigger debug microsim_triggerd
+- optimized microsim_output debug microsim_outputd
+- optimized microsim_transportables debug microsim_transportablesd
+- optimized microsim_actions debug microsim_actionsd
+- optimized microsim_traffic_lights debug microsim_traffic_lightsd
+- optimized microsim debug microsimd
+- optimized mesosim debug mesosimd
+- optimized foreign_phemlight debug foreign_phemlightd
+- optimized foreign_tcpip debug foreign_tcpipd
+- optimized microsim_cfmodels debug microsim_cfmodelsd
+- optimized zlibstatic debug zlibstaticd
+- optimized xerces-c_3 debug xerces-c_3D
+- "-framework CoreServices"
+- )
+
+ elseif(LINUX)
+
+@@ -251,82 +90,8 @@ elseif(LINUX)
+ SET(CMAKE_CXX_FLAGS "${CXX_STD_FLAG} -pthread -fPIC -Wl,-strip-all")
+ endif()
+
+- set ( OSG_LIBRARIES
+- optimized osg debug osgd
+- optimized osgViewer debug osgViewerd
+- optimized osgDB debug osgDBd
+- optimized osgdb_serializers_osgsim debug osgdb_serializers_osgsimd
+- optimized osgdb_serializers_osg debug osgdb_serializers_osgd
+- optimized osgGA debug osgGAd
+- optimized osgText debug osgTextd
+- optimized osgSim debug osgSimd
+- optimized osgdb_osg debug osgdb_osgd
+- optimized osgdb_jpeg debug osgdb_jpegd
+- optimized osgUtil debug osgUtild
+- optimized osgAnimation debug osgAnimationd
+- optimized osg debug osgd
+- optimized OpenThreads debug OpenThreadsd
+- optimized jpeg debug jpegd
+-
+- GL
+- X11
+- Xrandr
+- dl
+- z
+- Xinerama
+- fontconfig
+- )
+-
+- if (DYN_PROTOBUF)
+- set ( OSI_LIBRARIES
+- optimized open_simulation_interface debug open_simulation_interfaced
+- optimized protobuf debug protobufd
+- )
+- else ()
+- set ( OSI_LIBRARIES
+- optimized open_simulation_interface_pic debug open_simulation_interface_picd
+- optimized protobuf debug protobufd
+- )
+- endif (DYN_PROTOBUF)
+-
+- set ( SUMO_LIBRARIES
+- optimized libsumostatic debug libsumostaticd
+- optimized netload debug netloadd
+- optimized traciserver debug traciserverd
+- optimized libsumostatic debug libsumostaticd
+- optimized utils_vehicle debug utils_vehicled
+- optimized utils_distribution debug utils_distributiond
+- optimized utils_shapes debug utils_shapesd
+- optimized utils_options debug utils_optionsd
+- optimized utils_xml debug utils_xmld
+- optimized utils_geom debug utils_geomd
+- optimized utils_common debug utils_commond
+- optimized utils_iodevices debug utils_iodevicesd
+- optimized utils_traction_wire debug utils_traction_wired
+- optimized utils_emissions debug utils_emissionsd
+- optimized microsim_engine debug microsim_engined
+- optimized microsim_lcmodels debug microsim_lcmodelsd
+- optimized microsim_devices debug microsim_devicesd
+- optimized microsim_trigger debug microsim_triggerd
+- optimized microsim_output debug microsim_outputd
+- optimized microsim_transportables debug microsim_transportablesd
+- optimized microsim_actions debug microsim_actionsd
+- optimized microsim_traffic_lights debug microsim_traffic_lightsd
+- optimized microsim debug microsimd
+- optimized mesosim debug mesosimd
+- optimized foreign_phemlight debug foreign_phemlightd
+- optimized foreign_tcpip debug foreign_tcpipd
+- optimized microsim_cfmodels debug microsim_cfmodelsd
+- optimized zlibstatic debug zlibstaticd
+- optimized xerces-c_3 debug xerces-c_3D
+- )
+-
+- set (GTEST_LIBRARIES
+- optimized gmock debug gmockd
+- optimized gmock_main debug gmock_maind
+- optimized gtest debug gtestd
+- optimized gtest_main debug gtest_maind
+- )
++ set ( OSI_LIBRARIES open_simulation_interface::open_simulation_interface )
++ set ( SUMO_LIBRARIES sumocpp tracicpp )
+
+ elseif(MSVC)
+
+@@ -510,61 +275,6 @@ FOREACH(subdir ${SUBDIRS})
+ endif ()
+ ENDFOREACH()
+
+-
+-#
+-# Download library and content binary packets
+-#
+-
+-function (download_and_extract url target_folder target_filename)
+- message (STATUS "downloading ${target_filename} ...")
+- file (DOWNLOAD ${url} ${target_folder}/${target_filename} STATUS DOWNLOAD_STATUS)
+-
+- if(DOWNLOAD_STATUS AND NOT DOWNLOAD_STATUS EQUAL 0)
+- message(FATAL_ERROR "FAILED to download ${target_filename} (Status: ${DOWNLOAD_STATUS})")
+- endif()
+-
+- execute_process (COMMAND sleep 1) # allow for file to be completely flushed
+-
+- message (STATUS "extracting ${target_filename} ... ")
+- execute_process (COMMAND ${CMAKE_COMMAND} -E tar xfz ${target_filename} WORKING_DIRECTORY ${target_folder} RESULT_VARIABLE STATUS)
+-
+- if(STATUS AND NOT STATUS EQUAL 0)
+- message(FATAL_ERROR "FAILED to unpack ${target_filename}")
+- endif()
+-
+- file (REMOVE ${target_folder}/${target_filename})
+-endfunction (download_and_extract)
+-
+-# download OpenSceneGraph
+-set ( OSG_PACKAGE_FILENAME "osg.7z" )
+-if (DEFINED OSG_DIR AND (FORCE_DOWNLOAD_BINARIES OR NOT EXISTS ${OSG_DIR} ))
+- download_and_extract( ${OSG_PACKAGE_URL} ${OSG_BASE_DIR} ${OSG_PACKAGE_FILENAME} )
+-endif()
+-
+-# download OSI
+-set ( OSI_PACKAGE_FILENAME "osi.7z" )
+-if (DEFINED OSI_DIR AND (FORCE_DOWNLOAD_BINARIES OR NOT EXISTS ${OSI_DIR} ))
+- download_and_extract( ${OSI_PACKAGE_URL} ${OSI_BASE_DIR} ${OSI_PACKAGE_FILENAME} )
+-endif()
+-
+-# download SUMO
+-set ( SUMO_PACKAGE_FILENAME "sumo.7z" )
+-if (DEFINED SUMO_DIR AND (FORCE_DOWNLOAD_BINARIES OR NOT EXISTS ${SUMO_DIR} ))
+- download_and_extract( ${SUMO_PACKAGE_URL} ${SUMO_BASE_DIR} ${SUMO_PACKAGE_FILENAME} )
+-endif()
+-
+-# download googletest
+-if(NOT (APPLE OR MINGW)) # not available for Mac yet
+- set ( GTEST_PACKAGE_FILENAME "googletest.7z" )
+- if (DEFINED GTEST_DIR AND (FORCE_DOWNLOAD_BINARIES OR NOT EXISTS ${GTEST_DIR} ))
+- download_and_extract( ${GTEST_PACKAGE_URL} ${GTEST_BASE_DIR} ${GTEST_PACKAGE_FILENAME} )
+- endif()
+-endif()
+-
+-if (DEFINED MODELS_DIR AND (FORCE_DOWNLOAD_BINARIES OR NOT EXISTS ${MODELS_DIR} ))
+- download_and_extract(${MODELS_PACKAGE_URL} ${MODELS_BASE_DIR} ${MODELS_PACKAGE_FILENAME})
+-endif()
+-
+ add_subdirectory(Applications/odrplot)
+ add_subdirectory(Applications/replayer)
+
+diff --git a/EnvironmentSimulator/Modules/Controllers/ControllerSumo.cpp b/EnvironmentSimulator/Modules/Controllers/ControllerSumo.cpp
+index 4c701d94..cb5de5bb 100644
+--- a/EnvironmentSimulator/Modules/Controllers/ControllerSumo.cpp
++++ b/EnvironmentSimulator/Modules/Controllers/ControllerSumo.cpp
+@@ -16,7 +16,6 @@
+ #include "ScenarioGateway.hpp"
+ #include "pugixml.hpp"
+
+-#include <utils/geom/PositionVector.h>
+ #include <libsumo/Simulation.h>
+ #include <libsumo/Vehicle.h>
+ #include <libsumo/TraCIDefs.h>
+diff --git a/EnvironmentSimulator/Modules/RoadManager/CMakeLists.txt b/EnvironmentSimulator/Modules/RoadManager/CMakeLists.txt
+index e4fad5f1..32d7a79c 100644
+--- a/EnvironmentSimulator/Modules/RoadManager/CMakeLists.txt
++++ b/EnvironmentSimulator/Modules/RoadManager/CMakeLists.txt
+@@ -2,7 +2,7 @@
+ include_directories (
+ ${PUGIXML_INCLUDE_DIR}
+ ${COMMON_MINI_INCLUDE_DIR}
+- ${ROADMANAGER_INCLUDE_DIR}
++ ${ROADMANAGER_INCLUDE_DIR}
+ )
+
+ set ( SOURCES
+@@ -11,8 +11,6 @@ set ( SOURCES
+ LaneIndependentRouter.cpp
+ )
+
+-set ( SRC_ADDITIONAL ../../../externals/pugixml/pugixml.cpp)
+-
+ SOURCE_GROUP("External Libraries" FILES ${SRC_ADDITIONAL})
+
+ set ( INCLUDES
+@@ -25,6 +23,6 @@ if(MSVC)
+ add_definitions("/wd4482")
+ endif()
+
+-add_library ( RoadManager STATIC ${SOURCES} ${SRC_ADDITIONAL} ${INCLUDES} )
++add_library ( RoadManager STATIC ${SOURCES} ${INCLUDES} )
+
+-target_link_libraries ( RoadManager CommonMini project_options)
+\ No newline at end of file
++target_link_libraries ( RoadManager CommonMini pugixml::pugixml project_options)
+diff --git a/EnvironmentSimulator/Modules/ScenarioEngine/CMakeLists.txt b/EnvironmentSimulator/Modules/ScenarioEngine/CMakeLists.txt
+index aec86ad6..86da77c1 100644
+--- a/EnvironmentSimulator/Modules/ScenarioEngine/CMakeLists.txt
++++ b/EnvironmentSimulator/Modules/ScenarioEngine/CMakeLists.txt
+@@ -5,7 +5,7 @@ include_directories (
+ ${ROADMANAGER_INCLUDE_DIR}
+ ${COMMON_MINI_INCLUDE_DIR}
+ ${CONTROLLERS_INCLUDE_DIR}
+- ${REPLAY_INCLUDE_DIR}
++ ${REPLAY_INCLUDE_DIR}
+ ${RDB_INCLUDE_DIR}
+ ${OSI_INCLUDE_DIR}
+ ${SUMO_INCLUDE_DIR}
+@@ -20,20 +20,15 @@ if (NOT USE_OSI)
+ list(REMOVE_ITEM SRC_SOURCEFILES "${CMAKE_CURRENT_LIST_DIR}/SourceFiles/OSIReporter.cpp")
+ endif (NOT USE_OSI)
+
+-set ( SRC_ADDITIONAL ../../../externals/pugixml/pugixml.cpp )
+-
+ SOURCE_GROUP(OSCTypeDefs FILES ${SRC_OSCTYPEDEFS})
+ SOURCE_GROUP("Source Files" FILES ${SRC_SOURCEFILES})
+ SOURCE_GROUP("External Libraries" FILES ${SRC_ADDITIONAL})
+
+-add_library ( ScenarioEngine STATIC
+- ${SRC_OSCTYPEDEFS}
+- ${SRC_SOURCEFILES}
+- ${SRC_ADDITIONAL}
++add_library ( ScenarioEngine STATIC
++ ${SRC_OSCTYPEDEFS}
++ ${SRC_SOURCEFILES}
+ )
+
+ add_definitions(-D_CRT_SECURE_NO_WARNINGS)
+
+-target_link_libraries(ScenarioEngine PRIVATE project_options)
+-
+-
++target_link_libraries(ScenarioEngine PRIVATE pugixml::pugixml project_options)
+--
+2.38.1
+
diff --git a/gnu/packages/patches/evdi-fix-build-with-linux-6.2.patch b/gnu/packages/patches/evdi-fix-build-with-linux-6.2.patch
new file mode 100644
index 0000000000..0c53cd2ef7
--- /dev/null
+++ b/gnu/packages/patches/evdi-fix-build-with-linux-6.2.patch
@@ -0,0 +1,72 @@
+Fix the build with Linux 6.2:
+
+https://github.com/DisplayLink/evdi/issues/402
+
+Patch copied from upstream pull request:
+
+https://github.com/DisplayLink/evdi/pull/401
+
+From a90ecd5f0f09e976e4b8784fa16b92804138b1bd Mon Sep 17 00:00:00 2001
+From: listout <listout@protonmail.com>
+Date: Wed, 22 Feb 2023 13:09:40 +0530
+Subject: [PATCH] Original patch was suggested by Crashdummyy.
+
+Since commit 9877d8f6bc374912b08dfe862cddbb78b395a5ef
+feild fbdev has been renamed to info in struct drm_fb_helper.
+
+Fixes: https://github.com/DisplayLink/evdi/issues/402
+Fixes: https://github.com/DisplayLink/evdi/issues/394
+Fixes: https://github.com/DisplayLink/evdi/issues/384
+Signed-off-by: listout <listout@protonmail.com>
+---
+ module/evdi_fb.c | 16 ++++++++++++++++
+ 1 file changed, 16 insertions(+)
+
+diff --git a/module/evdi_fb.c b/module/evdi_fb.c
+index 6b367fe8..f5de81f1 100644
+--- a/module/evdi_fb.c
++++ b/module/evdi_fb.c
+@@ -405,7 +405,11 @@ static int evdifb_create(struct drm_fb_helper *helper,
+ fb = &efbdev->efb.base;
+
+ efbdev->helper.fb = fb;
++#if KERNEL_VERSION(6, 2, 0) <= LINUX_VERSION_CODE
++ efbdev->helper.info = info;
++#else
+ efbdev->helper.fbdev = info;
++#endif
+
+ strcpy(info->fix.id, "evdidrmfb");
+
+@@ -459,8 +463,13 @@ static void evdi_fbdev_destroy(__always_unused struct drm_device *dev,
+ {
+ struct fb_info *info;
+
++#if KERNEL_VERSION(6, 2, 0) <= LINUX_VERSION_CODE
++ if (efbdev->helper.info) {
++ info = efbdev->helper.info;
++#else
+ if (efbdev->helper.fbdev) {
+ info = efbdev->helper.fbdev;
++#endif
+ unregister_framebuffer(info);
+ if (info->cmap.len)
+ fb_dealloc_cmap(&info->cmap);
+@@ -537,10 +546,17 @@ void evdi_fbdev_unplug(struct drm_device *dev)
+ return;
+
+ efbdev = evdi->fbdev;
++#if KERNEL_VERSION(6, 2, 0) <= LINUX_VERSION_CODE
++ if (efbdev->helper.info) {
++ struct fb_info *info;
++
++ info = efbdev->helper.info;
++#else
+ if (efbdev->helper.fbdev) {
+ struct fb_info *info;
+
+ info = efbdev->helper.fbdev;
++#endif
+ #if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE || defined(EL8)
+ unregister_framebuffer(info);
+ #else
diff --git a/gnu/packages/patches/flatpak-unset-gdk-pixbuf-for-sandbox.patch b/gnu/packages/patches/flatpak-unset-gdk-pixbuf-for-sandbox.patch
index 79fec8e526..bf9c487ba8 100644
--- a/gnu/packages/patches/flatpak-unset-gdk-pixbuf-for-sandbox.patch
+++ b/gnu/packages/patches/flatpak-unset-gdk-pixbuf-for-sandbox.patch
@@ -9,10 +9,10 @@ of host system.
--- a/common/flatpak-run.c
+++ b/common/flatpak-run.c
-@@ -1853,6 +1853,7 @@ static const ExportData default_exports[] = {
- {"GST_PTP_HELPER", NULL},
- {"GST_PTP_HELPER_1_0", NULL},
- {"GST_INSTALL_PLUGINS_HELPER", NULL},
+@@ -1900,6 +1900,7 @@ static const ExportData default_exports[] = {
+ {"XKB_CONFIG_ROOT", NULL},
+ {"GIO_EXTRA_MODULES", NULL},
+ {"GDK_BACKEND", NULL},
+ {"GDK_PIXBUF_MODULE_FILE", NULL},
};
diff --git a/gnu/packages/patches/fluxbox-1.3.7-no-dynamic-cursor.patch b/gnu/packages/patches/fluxbox-1.3.7-no-dynamic-cursor.patch
new file mode 100644
index 0000000000..8ac455833c
--- /dev/null
+++ b/gnu/packages/patches/fluxbox-1.3.7-no-dynamic-cursor.patch
@@ -0,0 +1,163 @@
+From: Danny Milosavljevic <dannym@scratchpost.org>
+Date: Sun, 19 Feb 2023 15:48:23 +0100
+Subject: Make fluxbox use libxcursor directly
+
+This patch makes fluxbox use libxcursor directly. This way, big cursors work.
+Without it, libx11 would try to dlopen("libXcursor.so.1") and fail.
+
+--- orig/fluxbox-1.3.7/configure.ac 2015-02-08 11:44:45.333187008 +0100
++++ fluxbox-1.3.7/configure.ac 2023-02-19 15:42:50.595886984 +0100
+@@ -214,6 +214,18 @@
+ CXXFLAGS="$X11_CFLAGS $CXXFLAGS"
+ LIBS="$X11_LIBS $LIBS"
+
++dnl Check for Xcursor
++PKG_CHECK_MODULES([XCURSOR], [ xcursor ],
++ [AC_DEFINE([HAVE_XCURSOR], [1], [Define if xcursor is available]) have_cursor=yes],
++ [have_xcursor=no])
++AM_CONDITIONAL([XCURSOR], [test "$have_xcursor" = "yes"], AC_MSG_ERROR([Could not find XOpenDisplay in -lXcursor.]))
++AS_IF([test x$have_xcursor = "xno"], [
++ AC_MSG_ERROR([Fluxbox requires the Xcursor libraries and headers.])
++])
++
++CXXFLAGS="$XCURSOR_CFLAGS $CXXFLAGS"
++LIBS="$XCURSOR_LIBS $LIBS"
++
+ dnl Check for xpg4
+ AC_CHECK_LIB([xpg4], [setlocale], [LIBS="-lxpg4 $LIBS"])
+ AC_CHECK_PROGS([gencat_cmd], [gencat])
+diff -ru orig/fluxbox-1.3.7/src/FbWinFrameTheme.cc fluxbox-1.3.7/src/FbWinFrameTheme.cc
+--- orig/fluxbox-1.3.7/src/FbWinFrameTheme.cc 2015-02-08 11:44:45.365187009 +0100
++++ fluxbox-1.3.7/src/FbWinFrameTheme.cc 2023-02-19 15:28:56.183284901 +0100
+@@ -20,6 +20,7 @@
+ // DEALINGS IN THE SOFTWARE.
+
+ #include "FbWinFrameTheme.hh"
++#include "Xutil.hh"
+ #include "IconbarTheme.hh"
+
+ #include "FbTk/App.hh"
+@@ -53,15 +54,15 @@
+
+ // create cursors
+ Display *disp = FbTk::App::instance()->display();
+- m_cursor_move = XCreateFontCursor(disp, XC_fleur);
+- m_cursor_lower_left_angle = XCreateFontCursor(disp, XC_bottom_left_corner);
+- m_cursor_lower_right_angle = XCreateFontCursor(disp, XC_bottom_right_corner);
+- m_cursor_upper_right_angle = XCreateFontCursor(disp, XC_top_right_corner);
+- m_cursor_upper_left_angle = XCreateFontCursor(disp, XC_top_left_corner);
+- m_cursor_left_side = XCreateFontCursor(disp, XC_left_side);
+- m_cursor_top_side = XCreateFontCursor(disp, XC_top_side);
+- m_cursor_right_side = XCreateFontCursor(disp, XC_right_side);
+- m_cursor_bottom_side = XCreateFontCursor(disp, XC_bottom_side);
++ m_cursor_move = Xutil::hidpiCreateFontCursor(disp, XC_fleur);
++ m_cursor_lower_left_angle = Xutil::hidpiCreateFontCursor(disp, XC_bottom_left_corner);
++ m_cursor_lower_right_angle = Xutil::hidpiCreateFontCursor(disp, XC_bottom_right_corner);
++ m_cursor_upper_right_angle = Xutil::hidpiCreateFontCursor(disp, XC_top_right_corner);
++ m_cursor_upper_left_angle = Xutil::hidpiCreateFontCursor(disp, XC_top_left_corner);
++ m_cursor_left_side = Xutil::hidpiCreateFontCursor(disp, XC_left_side);
++ m_cursor_top_side = Xutil::hidpiCreateFontCursor(disp, XC_top_side);
++ m_cursor_right_side = Xutil::hidpiCreateFontCursor(disp, XC_right_side);
++ m_cursor_bottom_side = Xutil::hidpiCreateFontCursor(disp, XC_bottom_side);
+
+ FbTk::ThemeManager::instance().loadTheme(*this);
+ reconfigTheme();
+diff -ru orig/fluxbox-1.3.7/src/Screen.cc fluxbox-1.3.7/src/Screen.cc
+--- orig/fluxbox-1.3.7/src/Screen.cc 2015-02-08 11:44:45.369187009 +0100
++++ fluxbox-1.3.7/src/Screen.cc 2023-02-19 15:28:23.783092203 +0100
+@@ -53,6 +53,7 @@
+ #include "SystemTray.hh"
+ #endif
+ #include "Debug.hh"
++#include "Xutil.hh"
+
+ #include "FbTk/I18n.hh"
+ #include "FbTk/FbWindow.hh"
+@@ -306,7 +307,7 @@
+ if (keys)
+ keys->registerWindow(rootWindow().window(), *this,
+ Keys::GLOBAL|Keys::ON_DESKTOP);
+- rootWindow().setCursor(XCreateFontCursor(disp, XC_left_ptr));
++ rootWindow().setCursor(Xutil::hidpiCreateFontCursor(disp, XC_left_ptr));
+
+ // load this screens resources
+ fluxbox->load_rc(*this);
+diff -ru orig/fluxbox-1.3.7/src/Xutil.cc fluxbox-1.3.7/src/Xutil.cc
+--- orig/fluxbox-1.3.7/src/Xutil.cc 2015-02-08 11:44:45.377187009 +0100
++++ fluxbox-1.3.7/src/Xutil.cc 2023-02-19 15:47:29.009541689 +0100
+@@ -28,6 +28,10 @@
+
+ #include <X11/Xutil.h>
+ #include <X11/Xatom.h>
++#include <X11/Xlibint.h>
++#undef min
++#undef max
++#include <X11/Xcursor/Xcursor.h>
+ #include <iostream>
+
+ #ifdef HAVE_CSTRING
+@@ -133,5 +137,19 @@
+ return class_name;
+ }
+
++static XColor _Xconst foreground = { 0, 0, 0, 0 }; /* black */
++static XColor _Xconst background = { 0, 65535, 65535, 65535 }; /* white */
++Cursor hidpiCreateFontCursor(Display* dpy, unsigned int shape) {
++ if (dpy->cursor_font == None) {
++ dpy->cursor_font = XLoadFont(dpy, "cursor");
++ if (dpy->cursor_font == None) return None;
++ }
++
++ Cursor result = XcursorTryShapeCursor(dpy, dpy->cursor_font, dpy->cursor_font, (int) shape, (int) shape + 1, &foreground, &background);
++ if (!result)
++ result = XCreateFontCursor(dpy, (int) shape);
++ return result;
++}
++
+ } // end namespace Xutil
+
+diff -ru orig/fluxbox-1.3.7/src/Xutil.hh fluxbox-1.3.7/src/Xutil.hh
+--- orig/fluxbox-1.3.7/src/Xutil.hh 2015-02-08 11:44:45.377187009 +0100
++++ fluxbox-1.3.7/src/Xutil.hh 2023-02-19 15:26:37.495619659 +0100
+@@ -32,7 +32,7 @@
+
+ FbTk::FbString getWMClassName(Window win);
+ FbTk::FbString getWMClassClass(Window win);
+-
++Cursor hidpiCreateFontCursor(Display* dpy, unsigned int shape);
+
+ } // end namespace Xutil
+
+diff -ru orig/fluxbox-1.3.7/util/fbrun/FbRun.cc fluxbox-1.3.7/util/fbrun/FbRun.cc
+--- orig/fluxbox-1.3.7/util/fbrun/FbRun.cc 2015-02-08 11:44:45.377187009 +0100
++++ fluxbox-1.3.7/util/fbrun/FbRun.cc 2023-02-19 15:28:18.532468099 +0100
+@@ -26,6 +26,7 @@
+ #include "FbTk/Color.hh"
+ #include "FbTk/KeyUtil.hh"
+ #include "FbTk/FileUtil.hh"
++#include "Xutil.hh"
+
+ #ifdef HAVE_XPM
+ #include <X11/xpm.h>
+@@ -67,7 +68,7 @@
+ m_current_history_item(0),
+ m_last_completion_prefix(""),
+ m_current_apps_item(0),
+- m_cursor(XCreateFontCursor(FbTk::App::instance()->display(), XC_xterm)) {
++ m_cursor(Xutil::hidpiCreateFontCursor(FbTk::App::instance()->display(), XC_xterm)) {
+
+ setGC(m_gc.gc());
+ setCursor(m_cursor);
+diff -ru orig/fluxbox-1.3.7/util/fbrun/Makemodule.am fluxbox-1.3.7/util/fbrun/Makemodule.am
+--- orig/fluxbox-1.3.7/util/fbrun/Makemodule.am 2015-02-08 11:44:45.377187009 +0100
++++ fluxbox-1.3.7/util/fbrun/Makemodule.am 2023-02-19 15:50:33.029069099 +0100
+@@ -8,7 +8,8 @@
+ util/fbrun/FbRun.hh \
+ util/fbrun/FbRun.cc \
+ util/fbrun/main.cc \
+- util/fbrun/fbrun.xpm
++ util/fbrun/fbrun.xpm \
++ src/Xutil.cc
+
+ fbrun_LDADD = libFbTk.a \
+ $(FRIBIDI_LIBS) \
diff --git a/gnu/packages/patches/ghc-9.2-glibc-2.33-link-order.patch b/gnu/packages/patches/ghc-9.2-glibc-2.33-link-order.patch
new file mode 100644
index 0000000000..5d4afa28c1
--- /dev/null
+++ b/gnu/packages/patches/ghc-9.2-glibc-2.33-link-order.patch
@@ -0,0 +1,35 @@
+Slightly modified version of
+https://gitlab.haskell.org/ghc/ghc/-/issues/19029#note_447989, required
+for older, buggy glibc versions < 2.34.
+
+diff -Naur ghc-9.2.5/compiler/GHC/Linker/Unit.hs ghc-9.2.5.patched/compiler/GHC/Linker/Unit.hs
+--- ghc-9.2.5/compiler/GHC/Linker/Unit.hs 2022-11-06 20:40:29.000000000 +0100
++++ ghc-9.2.5.patched/compiler/GHC/Linker/Unit.hs 2023-01-15 14:52:57.511275338 +0100
+@@ -31,11 +31,26 @@
+ ps <- mayThrowUnitErr $ preloadUnitsInfo' unit_env pkgs
+ return (collectLinkOpts dflags ps)
+
++fixOrderLinkOpts :: [String] -> [String]
++fixOrderLinkOpts opts
++ | have_bad_glibc_version -- glibc version strictly less than 2.34
++ , let (before, rest) = break (== libc) opts
++ , not (pthread `elem` before)
++ , pthread `elem` rest -- optional if we know pthread is definitely present
++ = before ++ pthread_and_deps ++ rest
++ | otherwise
++ = opts
++ where
++ pthread = "-lpthread"
++ libc = "-lc"
++ pthread_and_deps = [ "-lrt", pthread ] -- should depend on the environment
++ have_bad_glibc_version = True
++
+ collectLinkOpts :: DynFlags -> [UnitInfo] -> ([String], [String], [String])
+ collectLinkOpts dflags ps =
+ (
+ concatMap (map ("-l" ++) . unitHsLibs (ghcNameVersion dflags) (ways dflags)) ps,
+- concatMap (map ("-l" ++) . map ST.unpack . unitExtDepLibsSys) ps,
++ fixOrderLinkOpts $ concatMap (map ("-l" ++) . map ST.unpack . unitExtDepLibsSys) ps,
+ concatMap (map ST.unpack . unitLinkerOptions) ps
+ )
+
diff --git a/gnu/packages/patches/ghc-bloomfilter-ghc9.2.patch b/gnu/packages/patches/ghc-bloomfilter-ghc9.2.patch
new file mode 100644
index 0000000000..97caf2cc9b
--- /dev/null
+++ b/gnu/packages/patches/ghc-bloomfilter-ghc9.2.patch
@@ -0,0 +1,303 @@
+Taken from https://github.com/bos/bloomfilter/pull/20
+
+From fb79b39c44404fd791a3bed973e9d844fb084f1e Mon Sep 17 00:00:00 2001
+From: Simon Jakobi <simon.jakobi@gmail.com>
+Date: Fri, 12 Nov 2021 01:37:36 +0100
+Subject: [PATCH] Fix build with GHC 9.2
+
+The `FastShift.shift{L,R}` methods are replaced with `unsafeShift{L,R}`
+introduced in base-4.5.
+
+Fixes #19.
+---
+ Data/BloomFilter.hs | 16 +++++------
+ Data/BloomFilter/Hash.hs | 15 +++++-----
+ Data/BloomFilter/Mutable.hs | 20 +++++++-------
+ Data/BloomFilter/Util.hs | 55 ++++++-------------------------------
+ bloomfilter.cabal | 2 +-
+ 5 files changed, 34 insertions(+), 74 deletions(-)
+
+diff --git a/Data/BloomFilter.hs b/Data/BloomFilter.hs
+index 2210cef..6b47c21 100644
+--- a/Data/BloomFilter.hs
++++ b/Data/BloomFilter.hs
+@@ -78,8 +78,8 @@ import Control.DeepSeq (NFData(..))
+ import Data.Array.Base (unsafeAt)
+ import qualified Data.Array.Base as ST
+ import Data.Array.Unboxed (UArray)
+-import Data.Bits ((.&.))
+-import Data.BloomFilter.Util (FastShift(..), (:*)(..))
++import Data.Bits ((.&.), unsafeShiftL, unsafeShiftR)
++import Data.BloomFilter.Util ((:*)(..))
+ import qualified Data.BloomFilter.Mutable as MB
+ import qualified Data.BloomFilter.Mutable.Internal as MB
+ import Data.BloomFilter.Mutable.Internal (Hash, MBloom)
+@@ -98,7 +98,7 @@ data Bloom a = B {
+ }
+
+ instance Show (Bloom a) where
+- show ub = "Bloom { " ++ show ((1::Int) `shiftL` shift ub) ++ " bits } "
++ show ub = "Bloom { " ++ show ((1::Int) `unsafeShiftL` shift ub) ++ " bits } "
+
+ instance NFData (Bloom a) where
+ rnf !_ = ()
+@@ -172,7 +172,7 @@ singleton hash numBits elt = create hash numBits (\mb -> MB.insert mb elt)
+ -- | Given a filter's mask and a hash value, compute an offset into
+ -- a word array and a bit offset within that word.
+ hashIdx :: Int -> Word32 -> (Int :* Int)
+-hashIdx mask x = (y `shiftR` logBitsInHash) :* (y .&. hashMask)
++hashIdx mask x = (y `unsafeShiftR` logBitsInHash) :* (y .&. hashMask)
+ where hashMask = 31 -- bitsInHash - 1
+ y = fromIntegral x .&. mask
+
+@@ -191,7 +191,7 @@ hashesU ub elt = hashIdx (mask ub) `map` hashes ub elt
+ -- /still/ some possibility that @True@ will be returned.
+ elem :: a -> Bloom a -> Bool
+ elem elt ub = all test (hashesU ub elt)
+- where test (off :* bit) = (bitArray ub `unsafeAt` off) .&. (1 `shiftL` bit) /= 0
++ where test (off :* bit) = (bitArray ub `unsafeAt` off) .&. (1 `unsafeShiftL` bit) /= 0
+
+ modify :: (forall s. (MBloom s a -> ST s z)) -- ^ mutation function (result is discarded)
+ -> Bloom a
+@@ -255,11 +255,11 @@ insertList elts = modify $ \mb -> mapM_ (MB.insert mb) elts
+ -- is /still/ some possibility that @True@ will be returned.
+ notElem :: a -> Bloom a -> Bool
+ notElem elt ub = any test (hashesU ub elt)
+- where test (off :* bit) = (bitArray ub `unsafeAt` off) .&. (1 `shiftL` bit) == 0
++ where test (off :* bit) = (bitArray ub `unsafeAt` off) .&. (1 `unsafeShiftL` bit) == 0
+
+ -- | Return the size of an immutable Bloom filter, in bits.
+ length :: Bloom a -> Int
+-length = shiftL 1 . shift
++length = unsafeShiftL 1 . shift
+
+ -- | Build an immutable Bloom filter from a seed value. The seeding
+ -- function populates the filter as follows.
+@@ -318,7 +318,7 @@ fromList hashes numBits = unfold hashes numBits convert
+ logPower2 :: Int -> Int
+ logPower2 k = go 0 k
+ where go j 1 = j
+- go j n = go (j+1) (n `shiftR` 1)
++ go j n = go (j+1) (n `unsafeShiftR` 1)
+
+ -- $overview
+ --
+diff --git a/Data/BloomFilter/Hash.hs b/Data/BloomFilter/Hash.hs
+index 132a3a4..d071fd4 100644
+--- a/Data/BloomFilter/Hash.hs
++++ b/Data/BloomFilter/Hash.hs
+@@ -38,8 +38,7 @@ module Data.BloomFilter.Hash
+ ) where
+
+ import Control.Monad (foldM)
+-import Data.Bits ((.&.), (.|.), xor)
+-import Data.BloomFilter.Util (FastShift(..))
++import Data.Bits ((.&.), (.|.), unsafeShiftL, unsafeShiftR, xor)
+ import Data.List (unfoldr)
+ import Data.Int (Int8, Int16, Int32, Int64)
+ import Data.Word (Word8, Word16, Word32, Word64)
+@@ -91,11 +90,11 @@ class Hashable a where
+ -> Word64 -- ^ salt
+ -> IO Word64
+ hashIO64 v salt = do
+- let s1 = fromIntegral (salt `shiftR` 32) .&. maxBound
++ let s1 = fromIntegral (salt `unsafeShiftR` 32) .&. maxBound
+ s2 = fromIntegral salt
+ h1 <- hashIO32 v s1
+ h2 <- hashIO32 v s2
+- return $ (fromIntegral h1 `shiftL` 32) .|. fromIntegral h2
++ return $ (fromIntegral h1 `unsafeShiftL` 32) .|. fromIntegral h2
+
+ -- | Compute a 32-bit hash.
+ hash32 :: Hashable a => a -> Word32
+@@ -149,8 +148,8 @@ cheapHashes :: Hashable a => Int -- ^ number of hashes to compute
+ cheapHashes k v = go 0
+ where go i | i == j = []
+ | otherwise = hash : go (i + 1)
+- where !hash = h1 + (h2 `shiftR` i)
+- h1 = fromIntegral (h `shiftR` 32)
++ where !hash = h1 + (h2 `unsafeShiftR` i)
++ h1 = fromIntegral (h `unsafeShiftR` 32)
+ h2 = fromIntegral h
+ h = hashSalt64 0x9150a946c4a8966e v
+ j = fromIntegral k
+@@ -163,7 +162,7 @@ instance Hashable Integer where
+ (salt `xor` 0x3ece731e)
+ | otherwise = hashIO32 (unfoldr go k) salt
+ where go 0 = Nothing
+- go i = Just (fromIntegral i :: Word32, i `shiftR` 32)
++ go i = Just (fromIntegral i :: Word32, i `unsafeShiftR` 32)
+
+ instance Hashable Bool where
+ hashIO32 = hashOne32
+@@ -224,7 +223,7 @@ instance Hashable Word64 where
+ -- | A fast unchecked shift. Nasty, but otherwise GHC 6.8.2 does a
+ -- test and branch on every shift.
+ div4 :: CSize -> CSize
+-div4 k = fromIntegral ((fromIntegral k :: HTYPE_SIZE_T) `shiftR` 2)
++div4 k = fromIntegral ((fromIntegral k :: HTYPE_SIZE_T) `unsafeShiftR` 2)
+
+ alignedHash :: Ptr a -> CSize -> Word32 -> IO Word32
+ alignedHash ptr bytes salt
+diff --git a/Data/BloomFilter/Mutable.hs b/Data/BloomFilter/Mutable.hs
+index edff1fc..0bb5cc9 100644
+--- a/Data/BloomFilter/Mutable.hs
++++ b/Data/BloomFilter/Mutable.hs
+@@ -65,9 +65,9 @@ module Data.BloomFilter.Mutable
+ import Control.Monad (liftM, forM_)
+ import Control.Monad.ST (ST)
+ import Data.Array.Base (unsafeRead, unsafeWrite)
+-import Data.Bits ((.&.), (.|.))
++import Data.Bits ((.&.), (.|.), unsafeShiftL, unsafeShiftR)
+ import Data.BloomFilter.Array (newArray)
+-import Data.BloomFilter.Util (FastShift(..), (:*)(..), nextPowerOfTwo)
++import Data.BloomFilter.Util ((:*)(..), nextPowerOfTwo)
+ import Data.Word (Word32)
+ import Data.BloomFilter.Mutable.Internal
+
+@@ -86,9 +86,9 @@ new hash numBits = MB hash shft msk `liftM` newArray numElems numBytes
+ | numBits > maxHash = maxHash
+ | isPowerOfTwo numBits = numBits
+ | otherwise = nextPowerOfTwo numBits
+- numElems = max 2 (twoBits `shiftR` logBitsInHash)
+- numBytes = numElems `shiftL` logBytesInHash
+- trueBits = numElems `shiftL` logBitsInHash
++ numElems = max 2 (twoBits `unsafeShiftR` logBitsInHash)
++ numBytes = numElems `unsafeShiftL` logBytesInHash
++ trueBits = numElems `unsafeShiftL` logBitsInHash
+ shft = logPower2 trueBits
+ msk = trueBits - 1
+ isPowerOfTwo n = n .&. (n - 1) == 0
+@@ -109,7 +109,7 @@ logBytesInHash = 2 -- logPower2 (sizeOf (undefined :: Hash))
+ -- | Given a filter's mask and a hash value, compute an offset into
+ -- a word array and a bit offset within that word.
+ hashIdx :: Int -> Word32 -> (Int :* Int)
+-hashIdx msk x = (y `shiftR` logBitsInHash) :* (y .&. hashMask)
++hashIdx msk x = (y `unsafeShiftR` logBitsInHash) :* (y .&. hashMask)
+ where hashMask = 31 -- bitsInHash - 1
+ y = fromIntegral x .&. msk
+
+@@ -125,7 +125,7 @@ insert mb elt = do
+ let mu = bitArray mb
+ forM_ (hashesM mb elt) $ \(word :* bit) -> do
+ old <- unsafeRead mu word
+- unsafeWrite mu word (old .|. (1 `shiftL` bit))
++ unsafeWrite mu word (old .|. (1 `unsafeShiftL` bit))
+
+ -- | Query a mutable Bloom filter for membership. If the value is
+ -- present, return @True@. If the value is not present, there is
+@@ -135,7 +135,7 @@ elem elt mb = loop (hashesM mb elt)
+ where mu = bitArray mb
+ loop ((word :* bit):wbs) = do
+ i <- unsafeRead mu word
+- if i .&. (1 `shiftL` bit) == 0
++ if i .&. (1 `unsafeShiftL` bit) == 0
+ then return False
+ else loop wbs
+ loop _ = return True
+@@ -145,7 +145,7 @@ elem elt mb = loop (hashesM mb elt)
+
+ -- | Return the size of a mutable Bloom filter, in bits.
+ length :: MBloom s a -> Int
+-length = shiftL 1 . shift
++length = unsafeShiftL 1 . shift
+
+
+ -- | Slow, crummy way of computing the integer log of an integer known
+@@ -153,7 +153,7 @@ length = shiftL 1 . shift
+ logPower2 :: Int -> Int
+ logPower2 k = go 0 k
+ where go j 1 = j
+- go j n = go (j+1) (n `shiftR` 1)
++ go j n = go (j+1) (n `unsafeShiftR` 1)
+
+ -- $overview
+ --
+diff --git a/Data/BloomFilter/Util.hs b/Data/BloomFilter/Util.hs
+index 7f695dc..6ade6e5 100644
+--- a/Data/BloomFilter/Util.hs
++++ b/Data/BloomFilter/Util.hs
+@@ -2,15 +2,11 @@
+
+ module Data.BloomFilter.Util
+ (
+- FastShift(..)
+- , nextPowerOfTwo
++ nextPowerOfTwo
+ , (:*)(..)
+ ) where
+
+-import Data.Bits ((.|.))
+-import qualified Data.Bits as Bits
+-import GHC.Base
+-import GHC.Word
++import Data.Bits ((.|.), unsafeShiftR)
+
+ -- | A strict pair type.
+ data a :* b = !a :* !b
+@@ -22,46 +18,11 @@ nextPowerOfTwo :: Int -> Int
+ {-# INLINE nextPowerOfTwo #-}
+ nextPowerOfTwo n =
+ let a = n - 1
+- b = a .|. (a `shiftR` 1)
+- c = b .|. (b `shiftR` 2)
+- d = c .|. (c `shiftR` 4)
+- e = d .|. (d `shiftR` 8)
+- f = e .|. (e `shiftR` 16)
+- g = f .|. (f `shiftR` 32) -- in case we're on a 64-bit host
++ b = a .|. (a `unsafeShiftR` 1)
++ c = b .|. (b `unsafeShiftR` 2)
++ d = c .|. (c `unsafeShiftR` 4)
++ e = d .|. (d `unsafeShiftR` 8)
++ f = e .|. (e `unsafeShiftR` 16)
++ g = f .|. (f `unsafeShiftR` 32) -- in case we're on a 64-bit host
+ !h = g + 1
+ in h
+-
+--- | This is a workaround for poor optimisation in GHC 6.8.2. It
+--- fails to notice constant-width shifts, and adds a test and branch
+--- to every shift. This imposes about a 10% performance hit.
+-class FastShift a where
+- shiftL :: a -> Int -> a
+- shiftR :: a -> Int -> a
+-
+-instance FastShift Word32 where
+- {-# INLINE shiftL #-}
+- shiftL (W32# x#) (I# i#) = W32# (x# `uncheckedShiftL#` i#)
+-
+- {-# INLINE shiftR #-}
+- shiftR (W32# x#) (I# i#) = W32# (x# `uncheckedShiftRL#` i#)
+-
+-instance FastShift Word64 where
+- {-# INLINE shiftL #-}
+- shiftL (W64# x#) (I# i#) = W64# (x# `uncheckedShiftL64#` i#)
+-
+- {-# INLINE shiftR #-}
+- shiftR (W64# x#) (I# i#) = W64# (x# `uncheckedShiftRL64#` i#)
+-
+-instance FastShift Int where
+- {-# INLINE shiftL #-}
+- shiftL (I# x#) (I# i#) = I# (x# `iShiftL#` i#)
+-
+- {-# INLINE shiftR #-}
+- shiftR (I# x#) (I# i#) = I# (x# `iShiftRA#` i#)
+-
+-instance FastShift Integer where
+- {-# INLINE shiftL #-}
+- shiftL = Bits.shiftL
+-
+- {-# INLINE shiftR #-}
+- shiftR = Bits.shiftR
+diff --git a/bloomfilter.cabal b/bloomfilter.cabal
+index 821a5d7..c621f7f 100644
+--- a/bloomfilter.cabal
++++ b/bloomfilter.cabal
+@@ -18,7 +18,7 @@ extra-source-files: README.markdown cbits/lookup3.c cbits/lookup3.h
+ library
+ build-depends:
+ array,
+- base >= 4.4 && < 5,
++ base >= 4.5 && < 5,
+ bytestring >= 0.9,
+ deepseq
+ exposed-modules: Data.BloomFilter
diff --git a/gnu/packages/patches/ghc-bytestring-handle-ghc9.patch b/gnu/packages/patches/ghc-bytestring-handle-ghc9.patch
new file mode 100644
index 0000000000..43dd472bf6
--- /dev/null
+++ b/gnu/packages/patches/ghc-bytestring-handle-ghc9.patch
@@ -0,0 +1,67 @@
+Taken from https://raw.githubusercontent.com/archlinux/svntogit-community/packages/haskell-bytestring-handle/trunk/ghc9.patch
+
+--- bytestring-handle-0.1.0.6/src/Data/ByteString/Handle/Write.hs.orig 2021-06-21 14:54:12.217134401 +0800
++++ bytestring-handle-0.1.0.6/src/Data/ByteString/Handle/Write.hs 2021-06-21 15:24:01.794796505 +0800
+@@ -17,7 +17,7 @@
+
+ import GHC.IO.Buffer ( BufferState(..), emptyBuffer, Buffer(..) )
+ import GHC.IO.BufferedIO ( BufferedIO(..) )
+-import GHC.IO.Device ( IODevice(..), IODeviceType(..), SeekMode(..) )
++import GHC.IO.Device ( IODevice(..), IODeviceType(..), SeekMode(..), RawIO(..) )
+ #if MIN_VERSION_base(4,5,0)
+ import GHC.IO.Encoding ( getLocaleEncoding )
+ #else
+@@ -138,6 +138,7 @@
+ seek_base = error "seek_base needs to be updated"
+ })
+ modifyIORef (write_size ws) (`max` newSeekPos)
++ pure newSeekPos
+
+ tell ws = do
+ ss <- readIORef (write_seek_state ws)
+@@ -152,6 +153,12 @@
+
+ devType _ = return RegularFile -- TODO: is this correct?
+
++instance RawIO WriteState where
++ read _ _ _ _ = return 0
++ readNonBlocking _ _ _ _ = return Nothing
++ write _ _ _ _ = return ()
++ writeNonBlocking _ _ _ _ = return 0
++
+ ioe_seekOutOfRange :: IO a
+ ioe_seekOutOfRange =
+ ioException $ IOError Nothing InvalidArgument ""
+--- bytestring-handle-0.1.0.6/src/Data/ByteString/Handle/Read.hs.orig 2021-06-21 14:53:55.433129276 +0800
++++ bytestring-handle-0.1.0.6/src/Data/ByteString/Handle/Read.hs 2021-06-21 15:24:25.998784996 +0800
+@@ -24,7 +24,7 @@
+ , emptyBuffer, isEmptyBuffer, newBuffer, newByteBuffer
+ , bufferElems, withBuffer, withRawBuffer )
+ import GHC.IO.BufferedIO ( BufferedIO(..) )
+-import GHC.IO.Device ( IODevice(..), IODeviceType(..), SeekMode(..) )
++import GHC.IO.Device ( IODevice(..), IODeviceType(..), SeekMode(..), RawIO(..) )
+ #if MIN_VERSION_base(4,5,0)
+ import GHC.IO.Encoding ( getLocaleEncoding )
+ #else
+@@ -155,7 +155,7 @@
+ (seek_before_length curSeekState)
+ (fromIntegral (seek_pos curSeekState) + seekPos)
+ SeekFromEnd -> normalisedSeekState (read_chunks_backwards rs) [] (read_length rs) seekPos
+- maybe ioe_seekOutOfRange (writeIORef (read_seek_state rs)) newSeekState
++ maybe ioe_seekOutOfRange (\nss -> writeIORef (read_seek_state rs) nss >> pure (fromIntegral(seek_pos nss))) newSeekState
+
+ tell rs = do
+ ss <- readIORef (read_seek_state rs)
+@@ -166,6 +166,12 @@
+
+ devType _ = return RegularFile -- TODO: is this correct?
+
++instance RawIO ReadState where
++ read _ _ _ _ = return 0
++ readNonBlocking _ _ _ _ = return Nothing
++ write _ _ _ _ = return ()
++ writeNonBlocking _ _ _ _ = return 0
++
+ ioe_seekOutOfRange :: IO a
+ ioe_seekOutOfRange =
+ ioException $ IOError Nothing InvalidArgument ""
diff --git a/gnu/packages/patches/icecat-makeicecat.patch b/gnu/packages/patches/icecat-makeicecat.patch
index c46cb27ff6..940ca36b6c 100644
--- a/gnu/packages/patches/icecat-makeicecat.patch
+++ b/gnu/packages/patches/icecat-makeicecat.patch
@@ -6,7 +6,7 @@ diff --git a/makeicecat b/makeicecat
index bf2b7a6..bc3b19b 100755
--- a/makeicecat
+++ b/makeicecat
-@@ -58,7 +58,7 @@ readonly SOURCEDIR=icecat-${FFVERSION}
+@@ -56,7 +56,7 @@ readonly SOURCEDIR=icecat-${FFVERSION}
# debug/shell options
readonly DEVEL=0
set -euo pipefail
@@ -15,8 +15,8 @@ index bf2b7a6..bc3b19b 100755
###############################################################################
-@@ -459,7 +459,7 @@ configure_search()
- sed 's|ddg@|ddg-html@|' -i browser/components/search/extensions/ddg-html/manifest.json
+@@ -455,7 +455,7 @@ configure_search()
+
# Process various JSON pre-configuration dumps.
- python3 ../../tools/process-json-files.py . browser/components/extensions/schemas/
@@ -24,7 +24,7 @@ index bf2b7a6..bc3b19b 100755
}
configure_mobile()
-@@ -855,12 +855,12 @@ finalize_sourceball()
+@@ -837,12 +837,12 @@ finalize_sourceball()
# entry point
###############################################################################
@@ -43,7 +43,7 @@ index bf2b7a6..bc3b19b 100755
apply_patches
configure
configure_search
-@@ -872,4 +872,4 @@ prepare_macos_packaging
+@@ -854,4 +854,4 @@ prepare_macos_packaging
configure_extensions
configure_onboarding
apply_bugfixes
diff --git a/gnu/packages/patches/ipxe-reproducible-geniso.patch b/gnu/packages/patches/ipxe-reproducible-geniso.patch
deleted file mode 100644
index ff6aa1da94..0000000000
--- a/gnu/packages/patches/ipxe-reproducible-geniso.patch
+++ /dev/null
@@ -1,77 +0,0 @@
-From 052d24d8217c51c572c2f6cbb4a687be2e8ba52d Mon Sep 17 00:00:00 2001
-From: Brice Waegeneire <brice@waegenei.re>
-Date: Fri, 5 Jun 2020 14:38:43 +0200
-Subject: [PATCH] [geniso] Make it reproducible
-
-Some timestamps get embedded in the generated ISO, making it
-unreproducible so we overwrite those timestamps to be at the UNIX epoch.
----
- src/util/geniso | 24 +++++++++++++++++++++---
- 1 file changed, 21 insertions(+), 3 deletions(-)
-
-diff --git a/src/util/geniso b/src/util/geniso
-index ff090d4a..e032ffb0 100755
---- a/src/util/geniso
-+++ b/src/util/geniso
-@@ -11,6 +11,13 @@ function help() {
- echo " -o FILE save iso image to file"
- }
-
-+function reset_timestamp() {
-+ for f in "$1"/*; do
-+ touch -t 197001010100 "$f"
-+ done
-+ touch -t 197001010100 "$1"
-+}
-+
- LEGACY=0
- FIRST=""
-
-@@ -37,8 +44,9 @@ if [ -z "${OUT}" ]; then
- exit 1
- fi
-
--# There should either be mkisofs or the compatible genisoimage program
--for command in genisoimage mkisofs; do
-+# There should either be mkisofs, xorriso or the compatible genisoimage
-+# program
-+for command in xorriso genisoimage mkisofs; do
- if ${command} --version >/dev/null 2>/dev/null; then
- mkisofs=(${command})
- break
-@@ -46,8 +54,10 @@ for command in genisoimage mkisofs; do
- done
-
- if [ -z "${mkisofs}" ]; then
-- echo "${0}: mkisofs or genisoimage not found, please install or set PATH" >&2
-+ echo "${0}: mkisofs, xorriso or genisoimage not found, please install or set PATH" >&2
- exit 1
-+elif [ "$mkisofs" = "xorriso" ]; then
-+ mkisofs+=(-as mkisofs)
- fi
-
- dir=$(mktemp -d bin/iso.dir.XXXXXX)
-@@ -115,6 +125,8 @@ case "${LEGACY}" in
- exit 1
- fi
-
-+ reset_timestamp "$dir"
-+
- # generate the iso image
- "${mkisofs[@]}" -b boot.img -output ${OUT} ${dir}
- ;;
-@@ -127,6 +139,12 @@ case "${LEGACY}" in
- cp ${LDLINUX_C32} ${dir}
- fi
-
-+ reset_timestamp "$dir"
-+
-+ if [ "${mkisofs[0]}" = "xorriso" ]; then
-+ mkisofs+=(-isohybrid-mbr "$SYSLINUX_MBR_DISK_PATH")
-+ fi
-+
- # generate the iso image
- "${mkisofs[@]}" -b isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table -output ${OUT} ${dir}
-
---
-2.26.2
diff --git a/gnu/packages/patches/m17n-lib-1.8.0-use-pkg-config-for-freetype.patch b/gnu/packages/patches/m17n-lib-1.8.0-use-pkg-config-for-freetype.patch
new file mode 100644
index 0000000000..38c311bee5
--- /dev/null
+++ b/gnu/packages/patches/m17n-lib-1.8.0-use-pkg-config-for-freetype.patch
@@ -0,0 +1,125 @@
+backport from upstream.
+
+From b468fc95150b7ca0e766e7c385a60879e65322d4 Mon Sep 17 00:00:00 2001
+From: "K. Handa" <handa@gnu.org>
+Date: Tue, 23 Oct 2018 00:05:46 +0900
+Subject: Use pkg-config for freetype, use %p to print a pointer
+
+---
+ ChangeLog | 5 +++++
+ configure.ac | 48 +++++++++++++++++++-----------------------------
+ src/ChangeLog | 5 +++++
+ src/chartab.c | 4 ++--
+ 4 files changed, 31 insertions(+), 31 deletions(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index b069d89..9dfc0b0 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2018-10-22 K. Handa <handa@gnu.org>
++
++ * configure.ac: Do not use the program freetype-config, use
++ PKG_CHECK_MODULES for checking freetype2.
++
+ 2018-02-08 K. Handa <handa@gnu.org>
+
+ Version 1.8.0 released.
+diff --git a/configure.ac b/configure.ac
+index 7f8b08e..3516bad 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -204,36 +204,26 @@ fi
+ AC_SUBST(OTF_LD_FLAGS)
+
+ dnl Check for Freetype2 usability.
+-AC_CHECK_PROG(HAVE_FREETYPE_CONFIG, freetype-config, yes)
+-if test "x$HAVE_FREETYPE_CONFIG" = "xyes"; then
+- FREETYPE_INC=`freetype-config --cflags`
+- save_CPPFLAGS="$CPPFLAGS"
+- CPPFLAGS="$CPPFLAGS $FREETYPE_INC"
+- AC_CHECK_HEADER(ft2build.h, HAVE_FREETYPE=yes,
+- HAVE_FREETYPE=no CPPFLAGS="$save_CPPFLAGS")
+- if test "x$HAVE_FREETYPE" = "xyes" ; then
+- save_LIBS="$LIBS"
+- LIBS="$LIBS `freetype-config --libs`"
+- AC_CHECK_LIB(freetype, FT_Init_FreeType, HAVE_FREETYPE=yes,
+- HAVE_FREETYPE=no)
+- LIBS="$save_LIBS"
+- if test "x$HAVE_FREETYPE" = "xyes"; then
+- FREETYPE_LD_FLAGS=`freetype-config --libs`
+- AC_DEFINE(HAVE_FREETYPE, 1,
+- [Define to 1 if you have FreeType library and header file.])
+- M17N_EXT_LIBS="$M17N_EXT_LIBS freetype"
+- AC_CHECK_HEADER(freetype/ftbdf.h, HAVE_FTBDF_H=yes, HAVE_FTBDF_H=no,
+- [#include <ft2build.h>
++PKG_CHECK_MODULES([FREETYPE], [freetype2], [HAVE_FREETYPE=yes],
++ [HAVE_FREETYPE=no])
++AS_IF([test "x$HAVE_FREETYPE" = "xyes"],
++ [CPPFLAGS="$CPPFLAGS $FREETYPE_CFLAGS";
++ FREETYPE_LD_FLAGS=FREETYPE_LIBS;
++ AC_DEFINE([HAVE_FREETYPE], [1],
++ [Define to 1 if you have FreeType library and header file.])
++ M17N_EXT_LIBS="$M17N_EXT_LIBS freetype";
++ AC_CHECK_HEADER([freetype/ftbdf.h], [HAVE_FTBDF_H=yes], [HAVE_FTBDF_H=no],
++ [#include <ft2build.h>
+ #include FT_FREETYPE_H])
+- if test "x$HAVE_FTBDF_H" = "xyes"; then
+- AC_DEFINE(HAVE_FTBDF_H, 1,
+- [Define to 1 if you have freetype/ftbdf.h.])
+- fi
+- CONFIG_FLAGS="$CONFIG_FLAGS -DHAVE_FREETYPE"
+- fi
+- fi
+-fi
+-AC_SUBST(FREETYPE_LD_FLAGS)
++ AS_IF([test "x$HAVE_FTBDF_H" = "xyes"],
++ [AC_DEFINE([HAVE_FTBDF_H], [1],
++ [Define to 1 if you have freetype/ftbdf.h.])],
++ [])
++ CONFIG_FLAGS="$CONFIG_FLAGS -DHAVE_FREETYPE"
++ ],
++ []
++ )
++AC_SUBST([FREETYPE_LD_FLAGS])
+
+ dnl Check for Xft2 usability.
+ save_CPPFLAGS="$CPPFLAGS"
+diff --git a/src/ChangeLog b/src/ChangeLog
+index ee28ea6..8cb91c1 100644
+--- a/src/ChangeLog
++++ b/src/ChangeLog
+@@ -1,3 +1,8 @@
++2018-10-22 K. Handa <handa@gnu.org>
++
++ * chartab.c (dump_sub_chartab): Use %p directive to print a
++ pointer value.
++
+ 2018-02-08 K. Handa <handa@gnu.org>
+
+ Version 1.8.0 released.
+diff --git a/src/chartab.c b/src/chartab.c
+index d58aa65..8aeb6d7 100644
+--- a/src/chartab.c
++++ b/src/chartab.c
+@@ -558,7 +558,7 @@ dump_sub_chartab (MSubCharTable *table, void *default_value,
+ fprintf (mdebug__output, "(default nil)");
+ }
+ else
+- fprintf (mdebug__output, "(default #x%X)", (unsigned) table->default_value);
++ fprintf (mdebug__output, "(default #x%p)", table->default_value);
+
+ default_value = table->default_value;
+ if (table->contents.tables)
+@@ -589,7 +589,7 @@ dump_sub_chartab (MSubCharTable *table, void *default_value,
+ fprintf (mdebug__output, "nil)");
+ }
+ else
+- fprintf (mdebug__output, " #xx%X)", (unsigned) default_value);
++ fprintf (mdebug__output, " #x%p)", default_value);
+ }
+ }
+ fprintf (mdebug__output, ")");
+--
+cgit v1.1
+
diff --git a/gnu/packages/patches/ngless-unliftio.patch b/gnu/packages/patches/ngless-unliftio.patch
deleted file mode 100644
index 87f5e79fcf..0000000000
--- a/gnu/packages/patches/ngless-unliftio.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-From 919565adc1216b9d3108b3043e8d307292b37393 Mon Sep 17 00:00:00 2001
-From: Luis Pedro Coelho <luis@luispedro.org>
-Date: Fri, 7 May 2021 11:42:56 +0800
-Subject: [PATCH] BLD Update to LTS-17.10
-
-- Updates the GHC version
-- Requires `extra-deps` for `diagrams` package
-- Simplifies code for NGLessIO monad as UnliftIO can now be auto-derived
----
- NGLess/NGLess/NGError.hs | 8 ++------
- stack.yaml | 11 ++++++++---
- 2 files changed, 10 insertions(+), 9 deletions(-)
-
-diff --git a/NGLess/NGLess/NGError.hs b/NGLess/NGLess/NGError.hs
-index a22e557f..c7eddf5b 100644
---- a/NGLess/NGLess/NGError.hs
-+++ b/NGLess/NGLess/NGError.hs
-@@ -50,7 +50,8 @@ type NGLess = Either NGError
-
- newtype NGLessIO a = NGLessIO { unwrapNGLessIO :: ResourceT IO a }
- deriving (Functor, Applicative, Monad, MonadIO,
-- MonadResource, MonadThrow, MonadCatch, MonadMask)
-+ MonadResource, MonadThrow, MonadCatch, MonadMask,
-+ MonadUnliftIO)
-
-
- instance MonadError NGError NGLessIO where
-@@ -62,11 +63,6 @@ instance PrimMonad NGLessIO where
- primitive act = NGLessIO (primitive act)
- {-# INLINE primitive #-}
-
--instance MonadUnliftIO NGLessIO where
-- askUnliftIO = NGLessIO $ do
-- u <- askUnliftIO
-- return $ UnliftIO (\(NGLessIO act) -> unliftIO u act)
--
- instance MonadFail NGLessIO where
- fail err = throwShouldNotOccur err
-
-diff --git a/stack.yaml b/stack.yaml
-index 051d973d..11b65887 100644
---- a/stack.yaml
-+++ b/stack.yaml
-@@ -1,14 +1,19 @@
- # For more information, see: https://github.com/commercialhaskell/stack/blob/release/doc/yaml_configuration.md
-
--resolver: lts-14.20
-+resolver: lts-17.10
- compiler-check: newer-minor
-
- # Packages to be pulled from upstream that are not in the resolver (e.g., acme-missiles-0.3)
- extra-deps:
- - git: "https://github.com/ngless-toolkit/interval-to-int"
- commit: "78289f6b48d41f7cc48169520ec9b77b050a0029"
--
--
-+ - diagrams-core-1.4.2@sha256:47de45658e8a805b7cb7f535e7b093daf7e861604fa3c70e25bd4ef481bf1571,2997
-+ - diagrams-lib-1.4.3@sha256:04f77778d4b550d3c8e54440800685f88467bef91075e82e009a8a6f45c51033,8232
-+ - diagrams-svg-1.4.3@sha256:36708b0b4cf35507ccf689f1a25f6f81b8f41c2c4c2900793de820f66d4e241c,3181
-+ - active-0.2.0.14@sha256:e618aba4a7881eb85dc1585e0a01230af6b4fbab6693931e4a5d0d3a5b184406,1823
-+ - dual-tree-0.2.2.1@sha256:9ff31e461d873ae74ba51d93b454c0c4094726d7cb78a0c454394c965e83539d,2830
-+ - monoid-extras-0.5.1@sha256:438dbfd7b4dce47d8f0ca577f56caf94bd1e21391afa545cad09fe7cf2e5793d,2333
-+ - svg-builder-0.1.1@sha256:22de54d326a6b6912e461e1302edb9108b02aac0b6a6368fcdc3c4a224d487fd,1440
- allow-newer: true
-
- # Override default flag values for local packages and extra-deps
diff --git a/gnu/packages/patches/onionshare-cli-async-mode.patch b/gnu/packages/patches/onionshare-cli-async-mode.patch
new file mode 100644
index 0000000000..b71b56046d
--- /dev/null
+++ b/gnu/packages/patches/onionshare-cli-async-mode.patch
@@ -0,0 +1,25 @@
+Specifying the `async_mode` parameter seems to have been a workaround for
+packaging on Windows and macOS. If not given, flask_socketio.SocketIO will
+probe for an available asynchronous model, e.g. `eventlet`, and otherwise gets
+stuck if `gevent-socketio` is not available.
+
+c.f. https://github.com/onionshare/onionshare/commit/ec7fa4ef16c9e1ba6028ee927c23f76c399a17a6
+and https://github.com/onionshare/onionshare/issues/1510
+
+diff --git a/cli/onionshare_cli/web/web.py b/cli/onionshare_cli/web/web.py
+index 64844b5..7e1b095 100644
+--- a/cli/onionshare_cli/web/web.py
++++ b/cli/onionshare_cli/web/web.py
+@@ -164,10 +164,10 @@ class Web:
+ elif self.mode == "chat":
+ if self.common.verbose:
+ self.socketio = SocketIO(
+- async_mode="gevent", logger=True, engineio_logger=True
++ logger=True, engineio_logger=True
+ )
+ else:
+- self.socketio = SocketIO(async_mode="gevent")
++ self.socketio = SocketIO()
+ self.socketio.init_app(self.app)
+ self.chat_mode = ChatModeWeb(self.common, self)
+
diff --git a/gnu/packages/patches/openbios-aarch64-riscv64-support.patch b/gnu/packages/patches/openbios-aarch64-riscv64-support.patch
new file mode 100644
index 0000000000..25cf2499b8
--- /dev/null
+++ b/gnu/packages/patches/openbios-aarch64-riscv64-support.patch
@@ -0,0 +1,17 @@
+This was submitted upstream
+https://github.com/openbios/openbios/pull/12
+
+diff --git a/config/scripts/switch-arch b/config/scripts/switch-arch
+index b5acc6c..a96ef4b 100755
+--- a/config/scripts/switch-arch
++++ b/config/scripts/switch-arch
+@@ -38,7 +38,8 @@ longbits()
+ if test "$cpu" = "sparc64" -o "$cpu" = "ia64" \
+ -o "$cpu" = "amd64" -o "$cpu" = "x86_64" \
+ -o "$cpu" = "powerpc64" -o "$cpu" = "ppc64" \
+- -o "$cpu" = "ppc64le" -o "$cpu" = "alpha" ; then
++ -o "$cpu" = "ppc64le" -o "$cpu" = "alpha" \
++ -o "$cpu" = "aarch64" -o "$cpu" = "riscv64" ; then
+ echo 64
+ else
+ echo 32
diff --git a/gnu/packages/patches/openbios-gcc-warnings.patch b/gnu/packages/patches/openbios-gcc-warnings.patch
deleted file mode 100644
index b96cecc31e..0000000000
--- a/gnu/packages/patches/openbios-gcc-warnings.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-Fix warnings with recent versions of GCC.
-
-This is a combination of these commits:
-
- https://github.com/openbios/openbios/commit/14be7d187a327a89c068c4e2551d5012a3c25703
- https://github.com/openbios/openbios/commit/0e6b8b3cb4a25a4680f238bae76de5e370e706c8
- https://github.com/openbios/openbios/commit/51067854a7606cceb8b1e0a3d2108da69ff46973
-
-...with minor adaptations to apply on 1.1.
-
-
-diff --git a/arch/sparc32/context.c b/arch/sparc32/context.c
---- a/arch/sparc32/context.c
-+++ b/arch/sparc32/context.c
-@@ -86,7 +86,7 @@ struct context *switch_to(struct context *ctx)
- __context = ctx;
- asm __volatile__ ("\n\tcall __switch_context"
- "\n\tnop" ::: "g1", "g2", "g3", "g4", "g5", "g6", "g7",
-- "o0", "o1", "o2", "o3", "o4", "o5", "sp", "o7",
-+ "o0", "o1", "o2", "o3", "o4", "o5", "o7",
- "l0", "l1", "l2", "l3", "l4", "l5", "l6", "l7",
- "i0", "i1", "i2", "i3", "i4", "i5", "i7",
- "f0", "f1", "f2", "f3", "f4", "f5", "f6", "f7", "f8", "f9",
-diff --git a/drivers/cuda.c b/drivers/cuda.c
---- a/drivers/cuda.c
-+++ b/drivers/cuda.c
-@@ -355,7 +355,7 @@ static void
- rtc_init(char *path)
- {
- phandle_t ph, aliases;
-- char buf[64];
-+ char buf[128];
-
- snprintf(buf, sizeof(buf), "%s/rtc", path);
- REGISTER_NAMED_NODE(rtc, buf);
-diff --git a/drivers/ide.c b/drivers/ide.c
---- a/drivers/ide.c
-+++ b/drivers/ide.c
-@@ -987,7 +987,7 @@ ob_ide_identify_drive(struct ide_drive *drive)
- drive->sect = id.sectors;
- }
-
-- strncpy(drive->model, (char*)id.model, sizeof(id.model));
-+ strncpy(drive->model, (char*)id.model, sizeof(drive->model));
- drive->model[40] = '\0';
- return 0;
- }
-diff --git a/fs/hfs/hfs_fs.c b/fs/hfs/hfs_fs.c
---- a/fs/hfs/hfs_fs.c
-+++ b/fs/hfs/hfs_fs.c
-@@ -86,7 +86,7 @@ _search( hfsvol *vol, const char *path, const char *sname, hfsfile **ret_fd )
-
- strncpy( buf, path, sizeof(buf) );
- if( buf[strlen(buf)-1] != ':' )
-- strncat( buf, ":", sizeof(buf) );
-+ strncat( buf, ":", sizeof(buf) - 1 );
- buf[sizeof(buf)-1] = 0;
- p = buf + strlen( buf );
-
-@@ -101,7 +101,7 @@ _search( hfsvol *vol, const char *path, const char *sname, hfsfile **ret_fd )
- *p = 0;
- topdir = 0;
-
-- strncat( buf, ent.name, sizeof(buf) );
-+ strncat( buf, ent.name, sizeof(buf) - 1);
- if( (status=_search(vol, buf, sname, ret_fd)) != 2 )
- continue;
- topdir = 1;
-diff --git a/libc/string.c b/libc/string.c
---- a/libc/string.c
-+++ b/libc/string.c
-@@ -349,10 +349,7 @@ int memcmp(const void * cs,const void * ct,size_t count)
- char *
- strdup( const char *str )
- {
-- char *p;
-- if( !str )
-- return NULL;
-- p = malloc( strlen(str) + 1 );
-+ char *p = malloc( strlen(str) + 1 );
- strcpy( p, str );
- return p;
- }
-diff --git a/packages/nvram.c b/packages/nvram.c
---- a/packages/nvram.c
-+++ b/packages/nvram.c
-@@ -105,7 +105,7 @@ create_free_part( char *ptr, int size )
- nvpart_t *nvp = (nvpart_t*)ptr;
- memset( nvp, 0, size );
-
-- strncpy( nvp->name, "777777777777", sizeof(nvp->name) );
-+ strncpy( nvp->name, "77777777777", sizeof(nvp->name) );
- nvp->signature = NV_SIG_FREE;
- nvp->len_hi = (size /16) >> 8;
- nvp->len_lo = size /16;
diff --git a/gnu/packages/patches/opencascade-oce-glibc-2.26.patch b/gnu/packages/patches/opencascade-oce-glibc-2.26.patch
deleted file mode 100644
index ee5ed572c8..0000000000
--- a/gnu/packages/patches/opencascade-oce-glibc-2.26.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-Fix build with glibc 2.26:
-
-https://github.com/tpaviot/oce/issues/675
-
-Patch copied from upstream source repository:
-
-https://github.com/tpaviot/oce/commit/aa1321e68cc004e3debe38d79ae74581a617c767
-
-From aa1321e68cc004e3debe38d79ae74581a617c767 Mon Sep 17 00:00:00 2001
-From: Janus Weil <janus@gcc.gnu.org>
-Date: Mon, 18 Dec 2017 11:27:55 +0100
-Subject: [PATCH] fix build errors with glibc 2.26+ due to missing xlocale.h
- (issue #675)
-
-* check for the presence of xlocale.h via cmake
-* remove related logic from Standard_CLocaleSentry.hxx
----
- CMakeLists.txt | 1 +
- src/Standard/Standard_CLocaleSentry.hxx | 15 ---------------
- 2 files changed, 1 insertion(+), 15 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index b782b4101..50e9500b2 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -616,6 +616,7 @@ if (NOT WIN32)
- # compilation anywhere in OCE
- include(CheckIncludeFile)
- check_include_file(strings.h HAVE_STRINGS_H)
-+ check_include_file(xlocale.h HAVE_XLOCALE_H)
- include(CheckIncludeFileCXX)
- check_include_file_cxx(mm_malloc.h HAVE_MM_MALLOC_H)
- check_include_file_cxx(atomic.h OCE_HAVE_ATOMIC_H)
-diff --git a/src/Standard/Standard_CLocaleSentry.hxx b/src/Standard/Standard_CLocaleSentry.hxx
-index 2b226e7f3..1a4c1dadc 100644
---- a/src/Standard/Standard_CLocaleSentry.hxx
-+++ b/src/Standard/Standard_CLocaleSentry.hxx
-@@ -20,21 +20,6 @@
-
- #include <locale.h>
-
--#ifndef HAVE_XLOCALE_H
-- //! "xlocale.h" available in Mac OS X and glibc (Linux) for a long time as an extension
-- //! and become part of POSIX since '2008.
-- //! Notice that this is impossible to test (_POSIX_C_SOURCE >= 200809L)
-- //! since POSIX didn't declared such identifier.
-- #if defined(__APPLE__)
-- #define HAVE_XLOCALE_H
-- #endif
--
-- //! We check _GNU_SOURCE for glibc extensions here and it is always defined by g++ compiler.
-- #if defined(_GNU_SOURCE) && !defined(__ANDROID__)
-- #define HAVE_XLOCALE_H
-- #endif
--#endif // ifndef HAVE_LOCALE_H
--
- #ifdef HAVE_XLOCALE_H
- #include <xlocale.h>
- #endif
---
-2.15.1
-
diff --git a/gnu/packages/patches/opentaxsolver-file-browser-fix.patch b/gnu/packages/patches/opentaxsolver-file-browser-fix.patch
new file mode 100644
index 0000000000..0e6be74f85
--- /dev/null
+++ b/gnu/packages/patches/opentaxsolver-file-browser-fix.patch
@@ -0,0 +1,58 @@
+From 96fda11a53a89c6647031f2c05ef12f1a9df6a08 Mon Sep 17 00:00:00 2001
+From: Skylar Hill <stellarskylark@posteo.net>
+Date: Tue, 31 Jan 2023 21:02:18 -0600
+Subject: [PATCH] Change default directory in file browser
+
+---
+ src/Gui_gtk/ots_gui2.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/src/Gui_gtk/ots_gui2.c b/src/Gui_gtk/ots_gui2.c
+index ff3366b..1247933 100644
+--- a/src/Gui_gtk/ots_gui2.c
++++ b/src/Gui_gtk/ots_gui2.c
+@@ -82,6 +82,7 @@ char ots_release_package[]="20.00";
+ #include <string.h>
+ #include <stdlib.h>
+ #include <ctype.h>
++#include <unistd.h>
+ #include <sys/stat.h>
+ // #include "backcompat.c"
+ #include "gtk_utils.c" /* Include the graphics library. */
+@@ -109,6 +110,7 @@ char toolpath[MaxFname]="", *start_cmd;
+ int pending_compute=0, supported_pdf_form=1;
+ int filingstatus_mfj=1;
+ int round_to_whole_nums=0;
++char *working_dir[MaxFname+512];
+
+ void pick_file( GtkWidget *wdg, void *data ); /* Prototype */
+ void consume_leading_trailing_whitespace( char *line );
+@@ -2364,7 +2366,7 @@ void save_taxfile( GtkWidget *wdg, void *data )
+ if (cpt != 0)
+ strcpy( cpt, "_xxxx.txt" );
+ // printf("OTS_save_taxfile: dir='%s', wc='%s', fname='%s'\n", directory_dat, wildcards_fb, filename_fb );
+- Browse_Files( "File to Save As:", 2048, directory_dat, wildcards_fb, filename_fb, Save_Tax_File );
++ Browse_Files( "File to Save As:", 2048, working_dir, wildcards_fb, filename_fb, Save_Tax_File );
+ }
+
+
+@@ -3878,7 +3880,7 @@ void pick_file( GtkWidget *wdg, void *data )
+ strcpy( wildcards_fb, ".txt" );
+ strcpy( filename_fb, "" );
+ // printf("OTS_pick_file: dir='%s', wc='%s', fname='%s'\n", directory_dat, wildcards_fb, filename_fb );
+- Browse_Files( "Select File", 2048, directory_dat, wildcards_fb, filename_fb, receive_filename );
++ Browse_Files( "Select File", 2048, working_dir, wildcards_fb, filename_fb, receive_filename );
+ }
+
+
+@@ -4019,6 +4021,7 @@ int main(int argc, char *argv[] )
+ invocation_path[k] = '\0';
+ // printf("Invocation path = '%s'\n", invocation_path);
+ set_ots_path();
++ getcwd(working_dir, MaxFname+512);
+
+ /* Decode any command-line arguments. */
+ argn = 1; k=1;
+--
+2.38.1
+
diff --git a/gnu/packages/patches/php-bug-74093-test.patch b/gnu/packages/patches/php-bug-74093-test.patch
deleted file mode 100644
index 07b1949cef..0000000000
--- a/gnu/packages/patches/php-bug-74093-test.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From c641825c64e42627a2c9cac969b371ed532e0b57 Mon Sep 17 00:00:00 2001
-From: Ryan Sundberg <ryan@arctype.co>
-Date: Mon, 4 Oct 2021 20:12:25 -0700
-Subject: [PATCH] Zend/tests/bug74093.phpt: Fix failing test case
-
-This test case fails (on non-Windows hosts, where it is enabled) due
-to mismatching output in the error log language. This fixes the
-expectation, and also rewrites the test procedure in a more stable
-fashion.
-
-The objective of the test case is to run a program that exceeds
-the max_execution_time and verify that the process was aborted. The
-previous implementation tested this using a loop on array_intersect with
-large enough inputs to "probably" take enough time to trigger
-max_execution_time to abort it. With faster CPUs, over time this test
-can become flaky. Instead we simply spin a loop until enough
-wall clock time has passed to check our assertion.
----
- Zend/tests/bug74093.phpt | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/Zend/tests/bug74093.phpt b/Zend/tests/bug74093.phpt
-index 7f20285805..32eb445ddc 100644
---- a/Zend/tests/bug74093.phpt
-+++ b/Zend/tests/bug74093.phpt
-@@ -1,5 +1,5 @@
- --TEST--
--Bug #74093 (Maximum execution time of n+2 seconds exceed not written in error_log)
-+Bug #74093 (Maximum execution time exceeded not written in error_log)
- --SKIPIF--
- <?php
- if (getenv("SKIP_SLOW_TESTS")) die("skip slow test");
-@@ -12,9 +12,9 @@ max_execution_time=1
- hard_timeout=1
- --FILE--
- <?php
--$a1 = range(1, 1000000);
--$a2 = range(100000, 1999999);
--array_intersect($a1, $a2);
-+$start = time();
-+while (time() - $start < 5);
-+die("Failed to interrupt execution");
- ?>
- --EXPECTF--
--Fatal error: Maximum execution time of 1+1 seconds exceeded %s
-+Fatal error: Maximum execution time of 1 second exceeded in %s
---
-2.31.1
diff --git a/gnu/packages/patches/php-curl-compat.patch b/gnu/packages/patches/php-curl-compat.patch
deleted file mode 100644
index 0617251194..0000000000
--- a/gnu/packages/patches/php-curl-compat.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Fix test result with cURL 7.83 and later.
-
-Taken from upstream:
-
- https://github.com/php/php-src/commit/a4179e4c92b6365d39e09cb9cd63c476848013af
-
-diff --git a/ext/curl/tests/curl_basic_007.phpt b/ext/curl/tests/curl_basic_007.phpt
-index 3b53658d6a7e..3834e4674f82 100644
---- a/ext/curl/tests/curl_basic_007.phpt
-+++ b/ext/curl/tests/curl_basic_007.phpt
-@@ -20,5 +20,5 @@ curl_close($ch);
-
- ?>
- --EXPECTF--
--string(%d) "No URL set!%w"
-+string(%d) "No URL set%A"
- int(3)
diff --git a/gnu/packages/patches/php-fix-streams-copy-length.patch b/gnu/packages/patches/php-fix-streams-copy-length.patch
new file mode 100644
index 0000000000..d68f658071
--- /dev/null
+++ b/gnu/packages/patches/php-fix-streams-copy-length.patch
@@ -0,0 +1,52 @@
+From cddcc10becb013ae498ea9c2836792f407b61678 Mon Sep 17 00:00:00 2001
+From: Julien Lepiller <julien@lepiller.eu>
+Date: Tue, 7 Feb 2023 22:55:59 +0100
+Subject: [PATCH] Fix file corruption when using copy_file_range.
+
+This patch is adapted from https://github.com/php/php-src/pull/10440.
+---
+ main/streams/streams.c | 21 +++++++++++++++++----
+ 1 file changed, 17 insertions(+), 4 deletions(-)
+
+diff --git a/main/streams/streams.c b/main/streams/streams.c
+index 20029fc7..68dc76c5 100644
+--- a/main/streams/streams.c
++++ b/main/streams/streams.c
+@@ -1634,8 +1634,21 @@ PHPAPI zend_result _php_stream_copy_to_stream_ex(php_stream *src, php_stream *de
+ char *p;
+
+ do {
+- size_t chunk_size = (maxlen == 0 || maxlen > PHP_STREAM_MMAP_MAX) ? PHP_STREAM_MMAP_MAX : maxlen;
+- size_t mapped;
++ /* We must not modify maxlen here, because otherwise the file copy fallback below can fail */
++ size_t chunk_size, must_read, mapped;
++ if (maxlen == 0) {
++ /* Unlimited read */
++ must_read = chunk_size = PHP_STREAM_MMAP_MAX;
++ } else {
++ must_read = maxlen - haveread;
++ if (must_read >= PHP_STREAM_MMAP_MAX) {
++ chunk_size = PHP_STREAM_MMAP_MAX;
++ } else {
++ /* In case the length we still have to read from the file could be smaller than the file size,
++ * chunk_size must not get bigger the size we're trying to read. */
++ chunk_size = must_read;
++ }
++ }
+
+ p = php_stream_mmap_range(src, php_stream_tell(src), chunk_size, PHP_STREAM_MAP_MODE_SHARED_READONLY, &mapped);
+
+@@ -1667,8 +1680,8 @@ PHPAPI zend_result _php_stream_copy_to_stream_ex(php_stream *src, php_stream *de
+ return SUCCESS;
+ }
+ if (maxlen != 0) {
+- maxlen -= mapped;
+- if (maxlen == 0) {
++ must_read -= mapped;
++ if (must_read == 0) {
+ return SUCCESS;
+ }
+ }
+--
+2.38.1
+
diff --git a/gnu/packages/patches/python-hiredis-fix-header.patch b/gnu/packages/patches/python-hiredis-fix-header.patch
new file mode 100644
index 0000000000..168b76920d
--- /dev/null
+++ b/gnu/packages/patches/python-hiredis-fix-header.patch
@@ -0,0 +1,49 @@
+Upstream status: https://github.com/redis/hiredis-py/pull/159
+
+From c2a20695aae53de7b5160e29675344df0b805fa6 Mon Sep 17 00:00:00 2001
+From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
+Date: Sat, 18 Mar 2023 15:18:08 -0400
+Subject: [PATCH] pack: Replace sdsalloc.h with alloc.h
+
+Fixes #158.
+
+* src/pack.c: Replace sdsalloc.h with alloc.h.
+(pack_command): Replace s_malloc with hi_malloc.
+---
+ src/pack.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/src/pack.c b/src/pack.c
+index 443e9d3..23e4004 100644
+--- a/src/pack.c
++++ b/src/pack.c
+@@ -16,7 +16,7 @@ extern sds sdscpylen(sds s, const char *t, size_t len);
+ extern sds sdsnewlen(const void *init, size_t initlen);
+ #endif
+
+-#include <hiredis/sdsalloc.h>
++#include <hiredis/alloc.h>
+
+ PyObject *
+ pack_command(PyObject *cmd)
+@@ -32,7 +32,7 @@ pack_command(PyObject *cmd)
+ }
+
+ Py_ssize_t tokens_number = PyTuple_Size(cmd);
+- sds *tokens = s_malloc(sizeof(sds) * tokens_number);
++ sds *tokens = hi_malloc(sizeof(sds) * tokens_number);
+ if (tokens == NULL)
+ {
+ return PyErr_NoMemory();
+@@ -118,4 +118,4 @@ cleanup:
+ sdsfreesplitres(tokens, tokens_number);
+ hi_free(lengths);
+ return result;
+-}
+\ No newline at end of file
++}
+
+base-commit: 8adb1b3cb38b82cdc73fa2d72879712da1f74e70
+--
+2.39.1
+
diff --git a/gnu/packages/patches/python-hiredis-use-system-hiredis.patch b/gnu/packages/patches/python-hiredis-use-system-hiredis.patch
new file mode 100644
index 0000000000..622f049da7
--- /dev/null
+++ b/gnu/packages/patches/python-hiredis-use-system-hiredis.patch
@@ -0,0 +1,82 @@
+Upstream status: https://github.com/redis/hiredis-py/pull/161
+
+From 7b3c8a364f6167f4b1828dd9c48ada3d8b0786f6 Mon Sep 17 00:00:00 2001
+From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
+Date: Sat, 18 Mar 2023 21:32:21 -0400
+Subject: [PATCH] setup.py: Fallback to use the system hiredis library.
+
+Fixes #158 fully, including using a system-prodived hiredis.
+
+When the hiredis git submodule hasn't been initialized, print a
+message about it, and attempt to link against the a system-provided
+hiredis library instead.
+
+* setup.py (is_hiredis_bundled): New procedure.
+(get_hiredis_bundled_sources): Likewise. Print a message when
+bundled_hiredis_sources is empty.
+(get_sources): Adjust to use the above procedure.
+(get_linker_args): Add -lhiredis when the bundled hiredis is not used.
+---
+ setup.py | 30 +++++++++++++++++++++++++++---
+ 1 file changed, 27 insertions(+), 3 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index 905df59..a77aca3 100644
+--- a/setup.py
++++ b/setup.py
+@@ -7,6 +7,7 @@ except ImportError:
+ import importlib
+ import glob
+ import io
++import os
+ import sys
+
+
+@@ -17,16 +18,39 @@ def version():
+ return module.__version__
+
+
++def is_hiredis_bundled():
++ hiredis_submodule = 'vendor/hiredis'
++ if (os.path.exists(hiredis_submodule)
++ and not os.path.isfile(hiredis_submodule)):
++ return not os.listdir()
++ return False
++
++
++def get_hiredis_bundled_sources():
++ hiredis_sources = ("alloc", "async", "hiredis", "net", "read",
++ "sds", "sockcompat")
++ if is_hiredis_bundled():
++ return ["vendor/hiredis/%s.c" % src for src in hiredis_sources]
++ return []
++
++
++if not is_hiredis_bundled():
++ print('the bundled hiredis sources were not found;'
++ ' system hiredis will be used\n'
++ 'to use the bundled hiredis sources instead,'
++ ' run "git submodule update --init"')
++
++
+ def get_sources():
+- hiredis_sources = ("alloc", "async", "hiredis", "net", "read", "sds", "sockcompat")
+- return sorted(glob.glob("src/*.c") + ["vendor/hiredis/%s.c" % src for src in hiredis_sources])
++ return sorted(glob.glob("src/*.c") + get_hiredis_bundled_sources())
+
+
+ def get_linker_args():
+ if 'win32' in sys.platform or 'darwin' in sys.platform:
+ return []
+ else:
+- return ["-Wl,-Bsymbolic", ]
++ return ["-Wl,-Bsymbolic", ] + \
++ ['-lhiredis'] if not is_hiredis_bundled() else []
+
+
+ def get_compiler_args():
+
+base-commit: 8adb1b3cb38b82cdc73fa2d72879712da1f74e70
+--
+2.39.1
+
diff --git a/gnu/packages/patches/python-pillow-CVE-2022-45199.patch b/gnu/packages/patches/python-pillow-CVE-2022-45199.patch
new file mode 100644
index 0000000000..3b01d3a8f4
--- /dev/null
+++ b/gnu/packages/patches/python-pillow-CVE-2022-45199.patch
@@ -0,0 +1,36 @@
+From 13f2c5ae14901c89c38f898496102afd9daeaf6d Mon Sep 17 00:00:00 2001
+From: Eric Soroos <eric-github@soroos.net>
+Date: Fri, 28 Oct 2022 14:11:25 +0200
+Subject: [PATCH 1/5] Prevent DOS with large SAMPLESPERPIXEL in Tiff IFD
+
+A large value in the SAMPLESPERPIXEL tag could lead to a memory and
+runtime DOS in TiffImagePlugin.py when setting up the context for
+image decoding.
+
+diff --git a/src/PIL/TiffImagePlugin.py b/src/PIL/TiffImagePlugin.py
+index 04a63bd2b44..46166fc6335 100644
+--- a/src/PIL/TiffImagePlugin.py
++++ b/src/PIL/TiffImagePlugin.py
+@@ -257,6 +257,8 @@
+ (MM, 8, (1,), 1, (8, 8, 8), ()): ("LAB", "LAB"),
+ }
+
++MAX_SAMPLESPERPIXEL = max(len(key_tp[4]) for key_tp in OPEN_INFO.keys())
++
+ PREFIXES = [
+ b"MM\x00\x2A", # Valid TIFF header with big-endian byte order
+ b"II\x2A\x00", # Valid TIFF header with little-endian byte order
+@@ -1396,6 +1398,12 @@ def _setup(self):
+ SAMPLESPERPIXEL,
+ 3 if self._compression == "tiff_jpeg" and photo in (2, 6) else 1,
+ )
++
++ if samples_per_pixel > MAX_SAMPLESPERPIXEL:
++ # DOS check, samples_per_pixel can be a Long, and we extend the tuple below
++ logger.error("More samples per pixel than can be decoded: %s", samples_per_pixel)
++ raise SyntaxError("Invalid value for samples per pixel")
++
+ if samples_per_pixel < bps_actual_count:
+ # If a file has more values in bps_tuple than expected,
+ # remove the excess.
+
diff --git a/gnu/packages/patches/qpdfview-qt515-compat.patch b/gnu/packages/patches/qpdfview-qt515-compat.patch
deleted file mode 100644
index 1fbf5ec3f1..0000000000
--- a/gnu/packages/patches/qpdfview-qt515-compat.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Fix compatibility with Qt 5.15.
-
-Patch copied from upstream source repository:
-
-https://bazaar.launchpad.net/~adamreichold/qpdfview/trunk/revision/2104
-
---- a/sources/model.h 2017-04-19 21:01:25 +0000
-+++ b/sources/model.h 2020-06-09 06:24:11 +0000
-@@ -24,6 +24,7 @@
- #define DOCUMENTMODEL_H
-
- #include <QList>
-+#include <QPainterPath>
- #include <QtPlugin>
- #include <QWidget>
- #include <QVector>
-
diff --git a/gnu/packages/patches/qtwebkit-fix-building-with-bison-3.7.patch b/gnu/packages/patches/qtwebkit-fix-building-with-bison-3.7.patch
deleted file mode 100644
index ddaf8e2849..0000000000
--- a/gnu/packages/patches/qtwebkit-fix-building-with-bison-3.7.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-Fix build with Bison 3.7
-
-https://bugs.gentoo.org/736499
-
-Patch copied from upstream source repository:
-
-https://github.com/qtwebkit/qtwebkit/commit/d92b11fea65364fefa700249bd3340e0cd4c5b31
-
-From d92b11fea65364fefa700249bd3340e0cd4c5b31 Mon Sep 17 00:00:00 2001
-From: Dmitry Shachnev <mitya57@gmail.com>
-Date: Tue, 4 Aug 2020 21:04:06 +0300
-Subject: [PATCH] Let Bison generate the header directly, to fix build with
- Bison 3.7
-
-Starting with Bison 3.7, the generated C++ file #include's the header
-by default, instead of duplicating it. So we should not delete it.
-
-Remove the code to add #ifdef guards to the header, since Bison adds
-them itself since version 2.6.3.
----
- Source/WebCore/css/makegrammar.pl | 21 +--------------------
- 1 file changed, 1 insertion(+), 20 deletions(-)
-
-diff --git a/Source/WebCore/css/makegrammar.pl b/Source/WebCore/css/makegrammar.pl
-index 5d63b08102eb5..9435701c70612 100644
---- a/Source/WebCore/css/makegrammar.pl
-+++ b/Source/WebCore/css/makegrammar.pl
-@@ -73,25 +73,6 @@
- }
-
- my $fileBase = File::Spec->join($outputDir, $filename);
--my @bisonCommand = ($bison, "-d", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp");
-+my @bisonCommand = ($bison, "--defines=$fileBase.h", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp");
- push @bisonCommand, "--no-lines" if $^O eq "MSWin32"; # Work around bug in bison >= 3.0 on Windows where it puts backslashes into #line directives.
- system(@bisonCommand) == 0 or die;
--
--open HEADER, ">$fileBase.h" or die;
--print HEADER << "EOF";
--#ifndef CSSGRAMMAR_H
--#define CSSGRAMMAR_H
--EOF
--
--open HPP, "<$fileBase.cpp.h" or open HPP, "<$fileBase.hpp" or die;
--while (<HPP>) {
-- print HEADER;
--}
--close HPP;
--
--print HEADER "#endif\n";
--close HEADER;
--
--unlink("$fileBase.cpp.h");
--unlink("$fileBase.hpp");
--
diff --git a/gnu/packages/patches/qtwebkit-fix-building-with-glib-2.68.patch b/gnu/packages/patches/qtwebkit-fix-building-with-glib-2.68.patch
deleted file mode 100644
index 63840f4bbc..0000000000
--- a/gnu/packages/patches/qtwebkit-fix-building-with-glib-2.68.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Fix building with glib 2.68:
-
-https://github.com/qtwebkit/qtwebkit/issues/1057
-
-Patch copied from upstream pull request:
-
-https://github.com/qtwebkit/qtwebkit/pull/1058/commits/5b698ba3faffd4e198a45be9fe74f53307395e4b
-
-diff -aurN qtwebkit-5.212.0-alpha4/Source/WTF/wtf/glib/GRefPtr.h qtwebkit-5.212.0-alpha4-mod/Source/WTF/wtf/glib/GRefPtr.h
---- qtwebkit-5.212.0-alpha4/Source/WTF/wtf/glib/GRefPtr.h 2020-03-04 18:16:37.000000000 +0100
-+++ qtwebkit-5.212.0-alpha4-mod/Source/WTF/wtf/glib/GRefPtr.h 2021-04-05 06:58:44.763328636 +0200
-@@ -29,9 +29,6 @@
- #include <wtf/RefPtr.h>
- #include <algorithm>
-
--extern "C" void g_object_unref(gpointer);
--extern "C" gpointer g_object_ref_sink(gpointer);
--
- namespace WTF {
-
- enum GRefPtrAdoptType { GRefPtrAdopt };
diff --git a/gnu/packages/patches/qtwebkit-fix-building-with-icu-68.patch b/gnu/packages/patches/qtwebkit-fix-building-with-icu-68.patch
deleted file mode 100644
index acbfc4c4c8..0000000000
--- a/gnu/packages/patches/qtwebkit-fix-building-with-icu-68.patch
+++ /dev/null
@@ -1,152 +0,0 @@
-Fix building with ICU > 68.
-
-https://bugs.gentoo.org/753260
-
-Patch adapted from Gentoo:
-
-https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=335f29d266c5b169ff1e781f9851a3a203f3198c
-
-From 335f29d266c5b169ff1e781f9851a3a203f3198c Mon Sep 17 00:00:00 2001
-From: Andreas Sturmlechner <asturm@gentoo.org>
-Date: Fri, 6 Nov 2020 09:22:15 +0100
-Subject: dev-qt/qtwebkit: Fix build with ICU-68
-
-Thanks-to: Lars Wendler <polynomial-c@gentoo.org>
-Closes: https://bugs.gentoo.org/753260
-Package-Manager: Portage-3.0.9, Repoman-3.0.2
-Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
----
- .../qtwebkit-5.212.0_pre20200309-icu-68.patch | 120 +++++++++++++++++++++
- 1 file changed, 120 insertions(+)
- create mode 100644 dev-qt/qtwebkit/files/qtwebkit-5.212.0_pre20200309-icu-68.patch
-
-(limited to 'dev-qt/qtwebkit/files/qtwebkit-5.212.0_pre20200309-icu-68.patch')
-
-diff --git a/Source/WebCore/platform/text/TextCodecICU.cpp b/Source/WebCore/platform/text/TextCodecICU.cpp
-index dd6ff06..e0f4bd7 100644
---- a/Source/WebCore/platform/text/TextCodecICU.cpp
-+++ b/Source/WebCore/platform/text/TextCodecICU.cpp
-@@ -308,7 +308,7 @@ void TextCodecICU::createICUConverter() const
- m_converterICU = ucnv_open(m_canonicalConverterName, &err);
- ASSERT(U_SUCCESS(err));
- if (m_converterICU)
-- ucnv_setFallback(m_converterICU, TRUE);
-+ ucnv_setFallback(m_converterICU, true);
- }
-
- int TextCodecICU::decodeToBuffer(UChar* target, UChar* targetLimit, const char*& source, const char* sourceLimit, int32_t* offsets, bool flush, UErrorCode& err)
-diff --git a/Source/WebCore/platform/text/icu/UTextProvider.h b/Source/WebCore/platform/text/icu/UTextProvider.h
-index c254fc4..6d1e1cb 100644
---- a/Source/WebCore/platform/text/icu/UTextProvider.h
-+++ b/Source/WebCore/platform/text/icu/UTextProvider.h
-@@ -80,12 +80,12 @@ inline bool uTextAccessInChunkOrOutOfRange(UText* text, int64_t nativeIndex, int
- // Ensure chunk offset is well formed if computed offset exceeds int32_t range.
- ASSERT(offset < std::numeric_limits<int32_t>::max());
- text->chunkOffset = offset < std::numeric_limits<int32_t>::max() ? static_cast<int32_t>(offset) : 0;
-- isAccessible = TRUE;
-+ isAccessible = true;
- return true;
- }
- if (nativeIndex >= nativeLength && text->chunkNativeLimit == nativeLength) {
- text->chunkOffset = text->chunkLength;
-- isAccessible = FALSE;
-+ isAccessible = false;
- return true;
- }
- } else {
-@@ -94,12 +94,12 @@ inline bool uTextAccessInChunkOrOutOfRange(UText* text, int64_t nativeIndex, int
- // Ensure chunk offset is well formed if computed offset exceeds int32_t range.
- ASSERT(offset < std::numeric_limits<int32_t>::max());
- text->chunkOffset = offset < std::numeric_limits<int32_t>::max() ? static_cast<int32_t>(offset) : 0;
-- isAccessible = TRUE;
-+ isAccessible = true;
- return true;
- }
- if (nativeIndex <= 0 && !text->chunkNativeStart) {
- text->chunkOffset = 0;
-- isAccessible = FALSE;
-+ isAccessible = false;
- return true;
- }
- }
-diff --git a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
-index cd6852c..6a864b1 100644
---- a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
-+++ b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
-@@ -100,23 +100,23 @@ static UBool uTextLatin1Access(UText* uText, int64_t index, UBool forward)
- if (index < uText->chunkNativeLimit && index >= uText->chunkNativeStart) {
- // Already inside the buffer. Set the new offset.
- uText->chunkOffset = static_cast<int32_t>(index - uText->chunkNativeStart);
-- return TRUE;
-+ return true;
- }
- if (index >= length && uText->chunkNativeLimit == length) {
- // Off the end of the buffer, but we can't get it.
- uText->chunkOffset = static_cast<int32_t>(index - uText->chunkNativeStart);
-- return FALSE;
-+ return false;
- }
- } else {
- if (index <= uText->chunkNativeLimit && index > uText->chunkNativeStart) {
- // Already inside the buffer. Set the new offset.
- uText->chunkOffset = static_cast<int32_t>(index - uText->chunkNativeStart);
-- return TRUE;
-+ return true;
- }
- if (!index && !uText->chunkNativeStart) {
- // Already at the beginning; can't go any farther.
- uText->chunkOffset = 0;
-- return FALSE;
-+ return false;
- }
- }
-
-@@ -144,7 +144,7 @@ static UBool uTextLatin1Access(UText* uText, int64_t index, UBool forward)
-
- uText->nativeIndexingLimit = uText->chunkLength;
-
-- return TRUE;
-+ return true;
- }
-
- static int32_t uTextLatin1Extract(UText* uText, int64_t start, int64_t limit, UChar* dest, int32_t destCapacity, UErrorCode* status)
-@@ -336,7 +336,7 @@ static int64_t uTextLatin1ContextAwareNativeLength(UText* text)
- static UBool uTextLatin1ContextAwareAccess(UText* text, int64_t nativeIndex, UBool forward)
- {
- if (!text->context)
-- return FALSE;
-+ return false;
- int64_t nativeLength = uTextLatin1ContextAwareNativeLength(text);
- UBool isAccessible;
- if (uTextAccessInChunkOrOutOfRange(text, nativeIndex, nativeLength, forward, isAccessible))
-@@ -356,7 +356,7 @@ static UBool uTextLatin1ContextAwareAccess(UText* text, int64_t nativeIndex, UBo
- ASSERT(newContext == UTextProviderContext::PriorContext);
- textLatin1ContextAwareSwitchToPriorContext(text, nativeIndex, nativeLength, forward);
- }
-- return TRUE;
-+ return true;
- }
-
- static int32_t uTextLatin1ContextAwareExtract(UText*, int64_t, int64_t, UChar*, int32_t, UErrorCode* errorCode)
-diff --git a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
-index 7aaac48..9ae0d36 100644
---- a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
-+++ b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
-@@ -125,7 +125,7 @@ static inline int64_t uTextUTF16ContextAwareNativeLength(UText* text)
- static UBool uTextUTF16ContextAwareAccess(UText* text, int64_t nativeIndex, UBool forward)
- {
- if (!text->context)
-- return FALSE;
-+ return false;
- int64_t nativeLength = uTextUTF16ContextAwareNativeLength(text);
- UBool isAccessible;
- if (uTextAccessInChunkOrOutOfRange(text, nativeIndex, nativeLength, forward, isAccessible))
-@@ -145,7 +145,7 @@ static UBool uTextUTF16ContextAwareAccess(UText* text, int64_t nativeIndex, UBoo
- ASSERT(newContext == UTextProviderContext::PriorContext);
- textUTF16ContextAwareSwitchToPriorContext(text, nativeIndex, nativeLength, forward);
- }
-- return TRUE;
-+ return true;
- }
-
- static int32_t uTextUTF16ContextAwareExtract(UText*, int64_t, int64_t, UChar*, int32_t, UErrorCode* errorCode)
diff --git a/gnu/packages/patches/qtwebkit-fix-building-with-python-3.9.patch b/gnu/packages/patches/qtwebkit-fix-building-with-python-3.9.patch
deleted file mode 100644
index 9f9674de33..0000000000
--- a/gnu/packages/patches/qtwebkit-fix-building-with-python-3.9.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Fix building with Python 3.9:
-
-https://github.com/qtwebkit/qtwebkit/issues/993
-
-Patch copied from upstream source repository:
-
-https://github.com/qtwebkit/qtwebkit/commit/78360c01c796b6260bf828bc9c8a0ef73c5132fd
-
-From 78360c01c796b6260bf828bc9c8a0ef73c5132fd Mon Sep 17 00:00:00 2001
-From: Konstantin Tokarev <annulen@yandex.ru>
-Date: Wed, 3 Jun 2020 15:01:42 +0300
-Subject: [PATCH] Fix compilation with Python 3.9: avoid passing encoding to
- json.load()
-
-In Python 2.7 UTF-8 is assumed by default, while in Python 3 this argument
-is not supported.
-
-Change-Id: Ic459d60a6b20bc1838d8771bc36ac41614fe61a9
----
- Source/JavaScriptCore/generate-bytecode-files | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/Source/JavaScriptCore/generate-bytecode-files b/Source/JavaScriptCore/generate-bytecode-files
-index c5dab429c7b0f..af3431275ecf9 100644
---- a/Source/JavaScriptCore/generate-bytecode-files
-+++ b/Source/JavaScriptCore/generate-bytecode-files
-@@ -163,7 +163,7 @@ if __name__ == "__main__":
- initBytecodesFile = openOrExit(initASMFileName, "w")
-
- try:
-- bytecodeSections = json.load(bytecodeFile, encoding = "utf-8")
-+ bytecodeSections = json.load(bytecodeFile)
- except:
- print("Unexpected error parsing {0}: {1}".format(bytecodeJSONFile, sys.exc_info()))
-
diff --git a/gnu/packages/patches/qtwebkit-pbutils-include.patch b/gnu/packages/patches/qtwebkit-pbutils-include.patch
deleted file mode 100644
index 57961e7a51..0000000000
--- a/gnu/packages/patches/qtwebkit-pbutils-include.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Patch taken from Nix:
- https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/qt-5/5.11/qtwebkit.patch
-
-diff --git a/Source/WebKit2/PlatformQt.cmake b/Source/WebKit2/PlatformQt.cmake
---- a/Source/WebKit2/PlatformQt.cmake
-+++ b/Source/WebKit2/PlatformQt.cmake
-@@ -261,6 +261,7 @@
- list(APPEND WebKit2_SYSTEM_INCLUDE_DIRECTORIES
- ${GLIB_INCLUDE_DIRS}
- ${GSTREAMER_INCLUDE_DIRS}
-+ ${GSTREAMER_PBUTILS_INCLUDE_DIRS}
- ${Qt5Quick_INCLUDE_DIRS}
- ${Qt5Quick_PRIVATE_INCLUDE_DIRS}
- ${SQLITE_INCLUDE_DIR}
-
diff --git a/gnu/packages/patches/racket-backport-8.7-pkg-strip.patch b/gnu/packages/patches/racket-backport-8.7-pkg-strip.patch
deleted file mode 100644
index 703b6e8e82..0000000000
--- a/gnu/packages/patches/racket-backport-8.7-pkg-strip.patch
+++ /dev/null
@@ -1,90 +0,0 @@
-From 1b7e15c23baf1fda44b1d0752902ddea11419fc5 Mon Sep 17 00:00:00 2001
-From: Philip McGrath <philip@philipmcgrath.com>
-Date: Fri, 7 Oct 2022 02:15:13 -0400
-Subject: [PATCH] pkg/strip: handle read-only input
-
-A package directory supplied to the functions from `pkg/strip` might
-have had all of its write permission bits unset. Since `copy-file`
-preserves the permissions of the source file, we may end up with a
-read-only file that we want to overwrite (e.g. an `info.rkt` file).
-Explicitly setting `user-write-bit` before writing avoids this problem.
-Conservatively, we only set the permissions when actually needed,
-and we restore the original permissions when we are done.
-
-(cherry picked from commit 8c647c8cc9b66112198fcf9bea27fc0e3737162f)
----
- racket/collects/pkg/strip.rkt | 35 +++++++++++++++++++++++++++++------
- 1 file changed, 29 insertions(+), 6 deletions(-)
-
-diff --git a/racket/collects/pkg/strip.rkt b/racket/collects/pkg/strip.rkt
-index 0ff58cea02..5899dbc6e6 100644
---- a/racket/collects/pkg/strip.rkt
-+++ b/racket/collects/pkg/strip.rkt
-@@ -306,9 +306,8 @@
- #t
- new-mod*-subs))))
- (unless (eq? mod new-mod)
-- (call-with-output-file*
-+ (call-with-output-file/writable
- new-p
-- #:exists 'truncate/replace
- (lambda (out) (write new-mod out)))))
-
- (define (fixup-local-redirect-reference p js-path #:user [user-js-path js-path])
-@@ -340,9 +339,8 @@
- (string->bytes/utf-8 user-js-path)
- (subbytes s (+ delta end2)))]
- [else s]))))
-- (call-with-output-file*
-+ (call-with-output-file/writable
- p
-- #:exists 'truncate/replace
- (lambda (out) (write-bytes new-bstr out)))))
-
- ;; Used in binary[-lib] mode:
-@@ -383,9 +381,8 @@
- (convert-mod info-lib defns)]))
- (unless (equal? new-content content)
- ;; write updated:
-- (call-with-output-file*
-+ (call-with-output-file/writable
- new-p
-- #:exists 'truncate
- (lambda (out)
- (write new-content out)
- (newline out)))
-@@ -503,3 +500,29 @@
- which
- dir)
- (current-continuation-marks)))))
-+
-+(define (call-with-output-file/writable pth proc)
-+ ;; In case `pth` was copied from a file without the user-write-bit set,
-+ ;; explicitly make it writable while we overwrite it.
-+ (define (run)
-+ (call-with-output-file* pth
-+ #:exists 'truncate/replace
-+ proc))
-+ (cond
-+ [(file-exists? pth)
-+ (define old-mode
-+ (file-or-directory-permissions pth 'bits))
-+ (define new-mode
-+ (if (eq? (system-type) 'windows)
-+ (bitwise-ior old-mode user-write-bit group-write-bit other-write-bit)
-+ (bitwise-ior old-mode user-write-bit)))
-+ (if (= old-mode new-mode)
-+ (run)
-+ (dynamic-wind
-+ (λ ()
-+ (file-or-directory-permissions pth new-mode))
-+ run
-+ (λ ()
-+ (file-or-directory-permissions pth old-mode))))]
-+ [else
-+ (run)]))
-
-base-commit: 7e4f6e2362d4a08affbbae3c7ee4b98e325274c6
---
-2.38.0
-
diff --git a/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch b/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch
deleted file mode 100644
index ffa75918b8..0000000000
--- a/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 4c02c080475c9d08dbed98dd64ecca337aa359ae Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= <iyzsong@member.fsf.org>
-Date: Sat, 20 Feb 2021 20:37:39 +0800
-Subject: [PATCH] Allow set libretro_directory via environment variable
-
----
- retroarch.c | 13 ++++++++++++-
- 1 file changed, 12 insertions(+), 1 deletion(-)
-
-diff --git a/retroarch.c b/retroarch.c
-index 8a0461c816..cbf11d8b6a 100644
---- a/retroarch.c
-+++ b/retroarch.c
-@@ -17603,7 +17603,18 @@ static bool retroarch_parse_input_and_config(
- p_rarch->configuration_settings->bools.log_to_file,
- p_rarch->configuration_settings->bools.log_to_file_timestamp,
- p_rarch->configuration_settings->paths.log_dir);
--
-+
-+ /* Override settings via environment variables */
-+ {
-+ settings_t *settings = p_rarch->configuration_settings;
-+ char *value = getenv("LIBRETRO_DIRECTORY");
-+ if (value != NULL)
-+ {
-+ retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO_DIRECTORY, NULL);
-+ configuration_set_string(settings, settings->paths.directory_libretro, value);
-+ }
-+ }
-+
- /* Second pass: All other arguments override the config file */
- optind = 1;
-
---
-2.33.0
-
diff --git a/gnu/packages/patches/rng-tools-revert-build-randstat.patch b/gnu/packages/patches/rng-tools-revert-build-randstat.patch
new file mode 100644
index 0000000000..6402884af0
--- /dev/null
+++ b/gnu/packages/patches/rng-tools-revert-build-randstat.patch
@@ -0,0 +1,49 @@
+Source: https://src.fedoraproject.org/rpms/rng-tools/blob/aaca5d6d9c9a50e0d0eed74c67b09863ac37149a/f/2-rt-revert-build-randstat.patch
+
+From de2ee0d8b7e8ad2915165ef941a6ec37442a2fdc Mon Sep 17 00:00:00 2001
+From: Vladis Dronov <vdronov@redhat.com>
+Date: Tue, 6 Jul 2021 14:36:46 +0200
+Subject: [PATCH] Revert "Build randstat binary"
+
+We do not want new and mostly useless randstat binary.
+This reverts commit 2ce93190cb0111fcab2f622a539689d70960643a.
+
+Signed-off-by: Vladis Dronov <vdronov@redhat.com>
+---
+ .gitignore | 3 +--
+ contrib/Makefile.am | 5 +++--
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git .gitignore .gitignore
+index 943fa2b..5dc334d 100644
+--- .gitignore
++++ .gitignore
+@@ -1,6 +1,6 @@
+ *.a
+ *.o
+-.deps/
++/.deps/
+ /aclocal.m4
+ /ar-lib
+ /autom4te.cache/
+@@ -10,7 +10,6 @@
+ /config.status
+ /config.sub
+ /configure
+-/contrib/randstat
+ /depcomp
+ /install-sh
+ /missing
+diff --git contrib/Makefile.am contrib/Makefile.am
+index a81fb0e..18c4fbc 100644
+--- contrib/Makefile.am
++++ contrib/Makefile.am
+@@ -1,2 +1,3 @@
+-bin_PROGRAMS = randstat
+-randstat_SOURCES = randstat.c
++
++EXTRA_DIST = randstat.c
++
+--
+2.26.3
+
diff --git a/gnu/packages/patches/rnp-add-version.cmake.patch b/gnu/packages/patches/rnp-add-version.cmake.patch
deleted file mode 100644
index 67e3b75457..0000000000
--- a/gnu/packages/patches/rnp-add-version.cmake.patch
+++ /dev/null
@@ -1,169 +0,0 @@
-From b4326f4649ceb146d5cc74f8579b68d8dc8f51e6 Mon Sep 17 00:00:00 2001
-From: Justus Winter <teythoon@avior.uberspace.de>
-Date: Mon, 27 Jul 2020 14:00:25 +0200
-Subject: [PATCH 3/3] Add external version.cmake.
-
-This file is maintained in an external repository. It is only
-included in released versions. For building snapshots of RNP, a fixed
-snapshot of version.cmake is downloaded on demand. To avoid this,
-this patch explicitly provides the file.
----
- cmake/version.cmake | 146 ++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 146 insertions(+)
- create mode 100644 cmake/version.cmake
-
-diff --git a/cmake/version.cmake b/cmake/version.cmake
-new file mode 100644
-index 00000000..514027aa
---- /dev/null
-+++ b/cmake/version.cmake
-@@ -0,0 +1,146 @@
-+# Copyright (c) 2018 Ribose Inc.
-+# All rights reserved.
-+#
-+# Redistribution and use in source and binary forms, with or without
-+# modification, are permitted provided that the following conditions
-+# are met:
-+# 1. Redistributions of source code must retain the above copyright
-+# notice, this list of conditions and the following disclaimer.
-+# 2. Redistributions in binary form must reproduce the above copyright
-+# notice, this list of conditions and the following disclaimer in the
-+# documentation and/or other materials provided with the distribution.
-+#
-+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-+# ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
-+# TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-+# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS
-+# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-+# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-+# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-+# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-+# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-+# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-+# POSSIBILITY OF SUCH DAMAGE.
-+
-+# desired length of commit hash
-+set(GIT_REV_LEN 7)
-+
-+# call git, store output in var (can fail)
-+macro(_git var)
-+ execute_process(
-+ COMMAND "${GIT_EXECUTABLE}" ${ARGN}
-+ WORKING_DIRECTORY "${source_dir}"
-+ RESULT_VARIABLE _git_ec
-+ OUTPUT_VARIABLE ${var}
-+ OUTPUT_STRIP_TRAILING_WHITESPACE
-+ ERROR_QUIET
-+ )
-+endmacro()
-+
-+# call git, store output in var (can not fail)
-+macro(git var)
-+ _git(${var} ${ARGN})
-+ if (NOT _git_ec EQUAL 0)
-+ string(REPLACE ";" " " args "${ARGN}")
-+ message(FATAL_ERROR "Failed to execute: git ${args}")
-+ endif()
-+endmacro()
-+
-+function(extract_version_info version var_prefix)
-+ # extract the main components
-+ # v1.9.0-3-g5b92266+1546836556
-+ # v1.9.0-3-g5b92266-dirty+1546836556
-+ string(REGEX MATCH "^v?([0-9]+\\.[0-9]+\\.[0-9]+)(-([0-9]+)-g([0-9a-f]+)(-dirty)?)?(\\+([0-9]+))?$" matches "${version}")
-+ if (NOT matches)
-+ message(FATAL_ERROR "Failed to extract version components.")
-+ endif()
-+ set(${var_prefix}_VERSION "${CMAKE_MATCH_1}" PARENT_SCOPE) # 1.9.0
-+ if (NOT CMAKE_MATCH_3)
-+ set(CMAKE_MATCH_3 "0")
-+ endif()
-+ set(${var_prefix}_VERSION_NCOMMITS "${CMAKE_MATCH_3}" PARENT_SCOPE) # 3
-+ if (NOT CMAKE_MATCH_4)
-+ set(CMAKE_MATCH_4 "0")
-+ endif()
-+ set(${var_prefix}_VERSION_GIT_REV "${CMAKE_MATCH_4}" PARENT_SCOPE) # 5b92266
-+ if (CMAKE_MATCH_5 STREQUAL "-dirty")
-+ set(${var_prefix}_VERSION_IS_DIRTY TRUE PARENT_SCOPE)
-+ else()
-+ set(${var_prefix}_VERSION_IS_DIRTY FALSE PARENT_SCOPE)
-+ endif()
-+ # timestamp is optional, default to 0
-+ if (NOT CMAKE_MATCH_7)
-+ set(CMAKE_MATCH_7 "0")
-+ endif()
-+ set(${var_prefix}_VERSION_COMMIT_TIMESTAMP "${CMAKE_MATCH_7}" PARENT_SCOPE) # 1546836556
-+endfunction()
-+
-+function(determine_version source_dir var_prefix)
-+ if (EXISTS "${source_dir}/.git")
-+ # for GIT_EXECUTABLE
-+ find_package(Git REQUIRED)
-+ # get a description of the version, something like:
-+ # v1.9.1-0-g38ffe82 (a tagged release)
-+ # v1.9.1-0-g38ffe82-dirty (a tagged release with local modifications)
-+ # v1.9.0-3-g5b92266 (post-release snapshot)
-+ # v1.9.0-3-g5b92266-dirty (post-release snapshot with local modifications)
-+ _git(version describe --abbrev=${GIT_REV_LEN} --match "v[0-9]*" --long --dirty)
-+ if (NOT _git_ec EQUAL 0)
-+ # no annotated tags, fake one
-+ git(revision rev-parse --short=${GIT_REV_LEN} --verify HEAD)
-+ set(version "v0.0.0-0-g${revision}")
-+ # check if dirty (this won't detect untracked files, but should be ok)
-+ _git(changes diff-index --quiet HEAD --)
-+ if (NOT _git_ec EQUAL 0)
-+ string(APPEND version "-dirty")
-+ endif()
-+ # append the commit timestamp of the most recent commit (only
-+ # in non-release branches -- typically master)
-+ git(commit_timestamp show -s --format=%ct)
-+ string(APPEND version "+${commit_timestamp}")
-+ endif()
-+ else()
-+ # same as above, but used for snapshots
-+ file(STRINGS "${source_dir}/version.txt" version)
-+ endif()
-+ set(local_prefix "_determine_ver")
-+ extract_version_info("${version}" "${local_prefix}")
-+ foreach(suffix VERSION VERSION_NCOMMITS VERSION_GIT_REV VERSION_IS_DIRTY VERSION_COMMIT_TIMESTAMP)
-+ if (NOT DEFINED ${local_prefix}_${suffix})
-+ message(FATAL_ERROR "Unable to determine version.")
-+ endif()
-+ set(${var_prefix}_${suffix} "${${local_prefix}_${suffix}}" PARENT_SCOPE)
-+ message(STATUS "${var_prefix}_${suffix}: ${${local_prefix}_${suffix}}")
-+ endforeach()
-+ # Set VERSION_SUFFIX and VERSION_FULL. When making changes, be aware that
-+ # this is used in packaging as well and will affect ordering.
-+ # | state | version_full |
-+ # |------------------------------------------------|
-+ # | exact tag | 0.9.0 |
-+ # | exact tag, dirty | 0.9.0+git20180604 |
-+ # | after tag | 0.9.0+git20180604.1.085039f |
-+ # | no tag | 0.0.0+git20180604.2ee02af |
-+ string(TIMESTAMP date "%Y%m%d" UTC)
-+ set(version_suffix "")
-+ if ((NOT ${local_prefix}_VERSION_NCOMMITS EQUAL 0) OR (${local_prefix}_VERSION STREQUAL "0.0.0"))
-+ # 0.9.0+git20150604.4.289818b
-+ string(APPEND version_suffix "+git${date}")
-+ if (NOT ${local_prefix}_VERSION_NCOMMITS EQUAL 0)
-+ string(APPEND version_suffix ".${${local_prefix}_VERSION_NCOMMITS}")
-+ endif()
-+ string(APPEND version_suffix ".${${local_prefix}_VERSION_GIT_REV}")
-+ else()
-+ if (${local_prefix}_VERSION_IS_DIRTY)
-+ # 0.9.0+git20150604
-+ string(APPEND version_suffix "+git${date}")
-+ endif()
-+ endif()
-+ set(version_full "${${local_prefix}_VERSION}${version_suffix}")
-+ # set the results
-+ set(${var_prefix}_VERSION_SUFFIX "${version_suffix}" PARENT_SCOPE)
-+ set(${var_prefix}_VERSION_FULL "${version_full}" PARENT_SCOPE)
-+ # for informational purposes
-+ message(STATUS "${var_prefix}_VERSION_SUFFIX: ${version_suffix}")
-+ message(STATUS "${var_prefix}_VERSION_FULL: ${version_full}")
-+endfunction()
-+
---
-2.20.1
-
diff --git a/gnu/packages/patches/rnp-disable-ruby-rnp-tests.patch b/gnu/packages/patches/rnp-disable-ruby-rnp-tests.patch
deleted file mode 100644
index 5a75b6f40f..0000000000
--- a/gnu/packages/patches/rnp-disable-ruby-rnp-tests.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 40e53d639d86337cf58be3a2b9750b6c97a3c740 Mon Sep 17 00:00:00 2001
-From: Justus Winter <teythoon@avior.uberspace.de>
-Date: Tue, 21 Jul 2020 16:10:21 +0200
-Subject: [PATCH 2/2] Disable ruby-rnp tests.
-
-Prevents cmake from cloning the ruby-rnp repository in order to run its tests.
----
- src/tests/CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt
-index d3c4fbe6..e7e1965e 100644
---- a/src/tests/CMakeLists.txt
-+++ b/src/tests/CMakeLists.txt
-@@ -125,7 +125,7 @@ gtest_discover_tests(rnp_tests
-
- # ruby-rnp
- # cruby does not currently play nice with ASaN et al.
--if (NOT ENABLE_SANITIZERS AND BUILD_SHARED_LIBS AND NOT WIN32)
-+if (NOT ENABLE_SANITIZERS AND BUILD_SHARED_LIBS AND NOT WIN32 AND IGNORE)
- include(ExternalProject)
- set(_sourcedir "${CMAKE_BINARY_DIR}/ruby-rnp")
- if (DEFINED ENV{RUBY_RNP_INSTALL})
---
-2.20.1
-
diff --git a/gnu/packages/patches/rnp-unbundle-googletest.patch b/gnu/packages/patches/rnp-unbundle-googletest.patch
deleted file mode 100644
index b85bfd1f0e..0000000000
--- a/gnu/packages/patches/rnp-unbundle-googletest.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 4b4697c8dd66bd2b1e4d6b831bbde46e27d62c46 Mon Sep 17 00:00:00 2001
-From: Justus Winter <teythoon@avior.uberspace.de>
-Date: Tue, 21 Jul 2020 16:10:12 +0200
-Subject: [PATCH 1/2] Unbundle googletest.
-
----
- src/tests/CMakeLists.txt | 2 +-
- src/tests/gtest-CMakeLists.txt.in | 6 +++---
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt
-index 0a841666..d3c4fbe6 100644
---- a/src/tests/CMakeLists.txt
-+++ b/src/tests/CMakeLists.txt
-@@ -53,7 +53,7 @@ endif()
- # maintain compiler/linker settings on Windows
- set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
- # add to our build (provides gtest_main target)
--add_subdirectory(${CMAKE_CURRENT_BINARY_DIR}/googletest-src
-+add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/googletest-src
- ${CMAKE_CURRENT_BINARY_DIR}/googletest-build
- EXCLUDE_FROM_ALL)
-
-diff --git a/src/tests/gtest-CMakeLists.txt.in b/src/tests/gtest-CMakeLists.txt.in
-index a43e8e5d..3cc0ddd5 100644
---- a/src/tests/gtest-CMakeLists.txt.in
-+++ b/src/tests/gtest-CMakeLists.txt.in
-@@ -4,9 +4,9 @@ project(googletest-download NONE)
-
- include(ExternalProject)
- ExternalProject_Add(googletest
-- GIT_REPOSITORY https://github.com/google/googletest.git
-- GIT_TAG c43f710
-- SOURCE_DIR "${CMAKE_CURRENT_BINARY_DIR}/googletest-src"
-+# GIT_REPOSITORY https://github.com/google/googletest.git
-+# GIT_TAG c43f710
-+ SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/googletest-src"
- BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/googletest-build"
- CONFIGURE_COMMAND ""
- BUILD_COMMAND ""
---
-2.20.1
-
diff --git a/gnu/packages/patches/sbcl-eazy-gnuplot-skip-path-check.patch b/gnu/packages/patches/sbcl-eazy-gnuplot-skip-path-check.patch
new file mode 100644
index 0000000000..ccc9c09fb9
--- /dev/null
+++ b/gnu/packages/patches/sbcl-eazy-gnuplot-skip-path-check.patch
@@ -0,0 +1,14 @@
+Don't check whether gnuplot is present in $PATH, because we know it is.
+
+diff --git a/eazy-gnuplot.asd b/eazy-gnuplot.asd
+index 7b1c09b..4657cd6 100644
+--- a/eazy-gnuplot.asd
++++ b/eazy-gnuplot.asd
+@@ -37,7 +37,4 @@
+ :fill-pointer t)))
+ (setf (fill-pointer seq) (read-sequence seq stream))
+ seq)))
+- :perform (load-op :before (op c)
+- (unless (zerop (nth-value 2 (uiop:run-program "which gnuplot" :ignore-error-status t)))
+- (warn "Could not find GNUPLOT in $PATH")))
+ :in-order-to ((test-op (test-op eazy-gnuplot.test))))
diff --git a/gnu/packages/patches/scsh-nonstring-search-path.patch b/gnu/packages/patches/scsh-nonstring-search-path.patch
new file mode 100644
index 0000000000..3934d49fa3
--- /dev/null
+++ b/gnu/packages/patches/scsh-nonstring-search-path.patch
@@ -0,0 +1,15 @@
+This patch was submitted upstream:
+https://github.com/scheme/scsh/pull/46
+
+diff --git a/scheme/lib-dirs.scm b/scheme/lib-dirs.scm
+index a1fc009..c630fb4 100644
+--- a/scheme/lib-dirs.scm
++++ b/scheme/lib-dirs.scm
+@@ -75,6 +75,7 @@
+ (let ((val (read)))
+ (cond ((eof-object? val) '())
+ ((string? val) (cons val (recur)))
++ ((symbol? val) (cons (symbol->string val) (recur)))
+ ((not val) (append default-lib-dirs (recur)))
+ (else
+ (error
diff --git a/gnu/packages/patches/spice-vdagent-glib-2.68.patch b/gnu/packages/patches/spice-vdagent-glib-2.68.patch
deleted file mode 100644
index cd5f13a909..0000000000
--- a/gnu/packages/patches/spice-vdagent-glib-2.68.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-From 8348ef3c6121247e2b8be0641bbf3df3d55d9bff Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= <marcandre.lureau@redhat.com>
-Date: Tue, 4 May 2021 13:20:47 +0400
-Subject: [PATCH] Fix g_memdup deprecation warning with glib >= 2.68
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Related to:
-https://bugzilla.redhat.com/show_bug.cgi?id=1943059
-
-Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
----
- configure.ac | 4 ++++
- src/vdagent/vdagent.c | 4 ++--
- src/vdagent/x11-randr.c | 2 +-
- src/vdagentd/vdagentd.c | 8 ++++----
- 4 files changed, 11 insertions(+), 7 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 7b2a99c..3de9b9b 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -124,6 +124,10 @@ PKG_CHECK_MODULES(ALSA, [alsa >= 1.0.22])
- PKG_CHECK_MODULES([DBUS], [dbus-1])
- PKG_CHECK_MODULES([DRM], [libdrm])
-
-+PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.68], [], [
-+ AC_DEFINE(g_memdup2, g_memdup, [GLib2 < 2.68 compatibility])
-+])
-+
- if test "$with_session_info" = "auto" || test "$with_session_info" = "systemd"; then
- PKG_CHECK_MODULES([LIBSYSTEMD_LOGIN],
- [libsystemd >= 209],
-diff --git a/src/vdagent/vdagent.c b/src/vdagent/vdagent.c
-index 0c69907..fd08522 100644
---- a/src/vdagent/vdagent.c
-+++ b/src/vdagent/vdagent.c
-@@ -228,7 +228,7 @@ static void daemon_read_complete(UdscsConnection *conn,
- break;
- case VDAGENTD_AUDIO_VOLUME_SYNC: {
- VDAgentAudioVolumeSync *avs = (VDAgentAudioVolumeSync *)data;
-- uint16_t *volume = g_memdup(avs->volume, sizeof(uint16_t) * avs->nchannels);
-+ uint16_t *volume = g_memdup2(avs->volume, sizeof(uint16_t) * avs->nchannels);
-
- if (avs->is_playback) {
- vdagent_audio_playback_sync(avs->mute, avs->nchannels, volume);
-@@ -414,7 +414,7 @@ int main(int argc, char *argv[])
- GOptionContext *context;
- GError *error = NULL;
- VDAgent *agent;
-- char **orig_argv = g_memdup(argv, sizeof(char*) * (argc+1));
-+ char **orig_argv = g_memdup2(argv, sizeof(char*) * (argc+1));
- orig_argv[argc] = NULL; /* To avoid clang analyzer false-positive */
-
- context = g_option_context_new(NULL);
-diff --git a/src/vdagent/x11-randr.c b/src/vdagent/x11-randr.c
-index 27404a1..037aded 100644
---- a/src/vdagent/x11-randr.c
-+++ b/src/vdagent/x11-randr.c
-@@ -982,7 +982,7 @@ void vdagent_x11_set_monitor_config(struct vdagent_x11 *x11,
- fullscreen it will keep sending the failing config. */
- g_free(x11->randr.failed_conf);
- x11->randr.failed_conf =
-- g_memdup(mon_config, config_size(mon_config->num_of_monitors));
-+ g_memdup2(mon_config, config_size(mon_config->num_of_monitors));
- return;
- }
- }
-diff --git a/src/vdagentd/vdagentd.c b/src/vdagentd/vdagentd.c
-index 78378aa..3e59331 100644
---- a/src/vdagentd/vdagentd.c
-+++ b/src/vdagentd/vdagentd.c
-@@ -216,7 +216,7 @@ static void do_client_monitors(VirtioPort *vport, int port_nr,
- vdagentd_write_xorg_conf(new_monitors);
-
- g_free(mon_config);
-- mon_config = g_memdup(new_monitors, size);
-+ mon_config = g_memdup2(new_monitors, size);
-
- /* Send monitor config to currently active agent */
- if (active_session_conn)
-@@ -249,7 +249,7 @@ static void do_client_capabilities(VirtioPort *vport,
- {
- capabilities_size = VD_AGENT_CAPS_SIZE_FROM_MSG_SIZE(message_header->size);
- g_free(capabilities);
-- capabilities = g_memdup(caps->caps, capabilities_size * sizeof(uint32_t));
-+ capabilities = g_memdup2(caps->caps, capabilities_size * sizeof(uint32_t));
-
- if (caps->request) {
- /* Report the previous client has disconnected. */
-@@ -647,7 +647,7 @@ static void virtio_port_read_complete(
- case VD_AGENT_GRAPHICS_DEVICE_INFO: {
- // store device info for re-sending when a session agent reconnects
- g_free(device_info);
-- device_info = g_memdup(data, message_header->size);
-+ device_info = g_memdup2(data, message_header->size);
- device_info_size = message_header->size;
- forward_data_to_session_agent(VDAGENTD_GRAPHICS_DEVICE_INFO, data, message_header->size);
- break;
-@@ -1090,7 +1090,7 @@ static void do_agent_xorg_resolution(UdscsConnection *conn,
- }
-
- g_free(agent_data->screen_info);
-- agent_data->screen_info = g_memdup(data, header->size);
-+ agent_data->screen_info = g_memdup2(data, header->size);
- agent_data->width = header->arg1;
- agent_data->height = header->arg2;
- agent_data->screen_count = n;
---
-GitLab
-
diff --git a/gnu/packages/patches/virglrenderer-CVE-2017-6386.patch b/gnu/packages/patches/virglrenderer-CVE-2017-6386.patch
deleted file mode 100644
index bd3bf106bf..0000000000
--- a/gnu/packages/patches/virglrenderer-CVE-2017-6386.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-Fix CVE-2017-6386 (memory leak introduced by fix for CVE-2017-5994).
-
-https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-5994
-
-Patch copied from upstream source repository:
-
-https://cgit.freedesktop.org/virglrenderer/commit/?id=737c3350850ca4dbc5633b3bdb4118176ce59920
-
-From 737c3350850ca4dbc5633b3bdb4118176ce59920 Mon Sep 17 00:00:00 2001
-From: Dave Airlie <airlied@redhat.com>
-Date: Tue, 28 Feb 2017 14:52:09 +1000
-Subject: renderer: fix memory leak in vertex elements state create
-
-Reported-by: Li Qiang
-Free the vertex array in error path.
-This was introduced by this commit:
-renderer: fix heap overflow in vertex elements state create.
-
-I rewrote the code to not require the allocation in the first
-place if we have an error, seems nicer.
-
-Signed-off-by: Dave Airlie <airlied@redhat.com>
-
-diff --git a/src/vrend_renderer.c b/src/vrend_renderer.c
-index 1bca7ad..e5d9f5c 100644
---- a/src/vrend_renderer.c
-+++ b/src/vrend_renderer.c
-@@ -1648,18 +1648,19 @@ int vrend_create_vertex_elements_state(struct vrend_context *ctx,
- unsigned num_elements,
- const struct pipe_vertex_element *elements)
- {
-- struct vrend_vertex_element_array *v = CALLOC_STRUCT(vrend_vertex_element_array);
-+ struct vrend_vertex_element_array *v;
- const struct util_format_description *desc;
- GLenum type;
- int i;
- uint32_t ret_handle;
-
-- if (!v)
-- return ENOMEM;
--
- if (num_elements > PIPE_MAX_ATTRIBS)
- return EINVAL;
-
-+ v = CALLOC_STRUCT(vrend_vertex_element_array);
-+ if (!v)
-+ return ENOMEM;
-+
- v->count = num_elements;
- for (i = 0; i < num_elements; i++) {
- memcpy(&v->elements[i].base, &elements[i], sizeof(struct pipe_vertex_element));
---
-cgit v0.10.2
-
diff --git a/gnu/packages/patches/virtuoso-ose-remove-pre-built-jar-files.patch b/gnu/packages/patches/virtuoso-ose-remove-pre-built-jar-files.patch
index 17413c71ae..548c3c2a1d 100644
--- a/gnu/packages/patches/virtuoso-ose-remove-pre-built-jar-files.patch
+++ b/gnu/packages/patches/virtuoso-ose-remove-pre-built-jar-files.patch
@@ -2,14 +2,14 @@ This patch disables build targets that contain pre-built Java archives that
would be copied to the build's output.
Patch by Roel Janssen <roel@gnu.org>
-*** a-virtuoso-opensource-7.2.7/binsrc/Makefile.am 1970-01-01 01:00:01.000000000 +0100
---- b-virtuoso-opensource-7.2.7/binsrc/Makefile.am 2022-05-27 12:20:52.909135774 +0200
+*** a-virtuoso-opensource-7.2.9/binsrc/Makefile.am 1970-01-01 01:00:01.000000000 +0100
+--- b-virtuoso-opensource-7.2.9/binsrc/Makefile.am 2023-03-05 13:05:37.946449855 +0100
***************
*** 19,25 ****
#
#
-! SUBDIRS = dav mono virtuoso tests rdf_mappers driver maildrop sqldoc hosting bpel fct tutorial conductor samples vsp ws sync vspx vad cached_resources virtodbc virtoledb virtuoso_sink xddl VirtuosoClient.Net oat isparql jena jena2 jena3 jena4 sesame sesame2 sesame3 sesame4 redland hibernate dbpedia rdb2rdf rdf4j
+! SUBDIRS = dav mono virtuoso tests rdf_mappers driver maildrop sqldoc hosting graphql bpel fct tutorial conductor samples vsp ws sync vspx vad cached_resources virtodbc virtoledb virtuoso_sink xddl VirtuosoClient.Net oat isparql jena jena2 jena3 jena4 sesame sesame2 sesame3 sesame4 redland hibernate dbpedia rdb2rdf rdf4j rdf4j_4 websocket
# ----------------------------------------------------------------------
@@ -17,42 +17,41 @@ Patch by Roel Janssen <roel@gnu.org>
#
#
-! SUBDIRS = dav mono virtuoso tests rdf_mappers driver maildrop sqldoc hosting bpel fct tutorial conductor samples vsp ws sync vspx vad cached_resources virtodbc virtoledb virtuoso_sink xddl VirtuosoClient.Net oat isparql redland dbpedia rdb2rdf
+! SUBDIRS = dav mono virtuoso tests rdf_mappers driver maildrop sqldoc hosting graphql bpel fct tutorial conductor samples vsp ws sync vspx vad cached_resources virtodbc virtoledb virtuoso_sink xddl VirtuosoClient.Net oat isparql redland dbpedia rdb2rdf websocket
# ----------------------------------------------------------------------
-*** a-virtuoso-opensource-7.2.7/configure.ac 1970-01-01 01:00:01.000000000 +0100
---- b-virtuoso-opensource-7.2.7/configure.ac 2022-05-27 12:27:51.879208018 +0200
+*** a-virtuoso-opensource-7.2.9/configure.ac 1970-01-01 01:00:01.000000000 +0100
+--- b-virtuoso-opensource-7.2.9/configure.ac 2023-03-05 13:03:01.302629421 +0100
***************
-*** 57,64 ****
+*** 57,63 ****
dnl AM_INIT_AUTOMAKE([1.8])
dnl AM_INIT_AUTOMAKE([1.9 tar-ustar])
dnl
! AM_INIT_AUTOMAKE([1.9 tar-ustar])
-!
- AM_MAINTAINER_MODE
+ AM_MAINTAINER_MODE
--- 57,63 ----
dnl AM_INIT_AUTOMAKE([1.8])
dnl AM_INIT_AUTOMAKE([1.9 tar-ustar])
dnl
! AM_INIT_AUTOMAKE([1.9 tar-ustar subdir-objects])
- AM_MAINTAINER_MODE
+ AM_MAINTAINER_MODE
***************
-*** 3157,3163 ****
- binsrc/dbpedia/Makefile
+*** 3210,3216 ****
binsrc/driver/Makefile
binsrc/fct/Makefile
+ binsrc/graphql/Makefile
- binsrc/hibernate/Makefile
binsrc/hosting/Makefile
binsrc/hosting/mono/Makefile
binsrc/hosting/mono/tests/Makefile
---- 3156,3161 ----
+--- 3210,3215 ----
***************
-*** 3169,3184 ****
+*** 3222,3238 ****
binsrc/hosting/ruby/Makefile
binsrc/hosting/shapefileio/Makefile
binsrc/isparql/Makefile
@@ -66,12 +65,13 @@ Patch by Roel Janssen <roel@gnu.org>
binsrc/rdf_mappers/Makefile
binsrc/rdb2rdf/Makefile
- binsrc/rdf4j/Makefile
+- binsrc/rdf4j_4/Makefile
binsrc/redland/Makefile
binsrc/samples/demo/Makefile
binsrc/samples/hslookup/Makefile
---- 3167,3177 ----
+--- 3221,3231 ----
***************
-*** 3191,3200 ****
+*** 3245,3254 ****
binsrc/samples/webapp/Makefile
binsrc/samples/xpath/Makefile
binsrc/samples/xquery/Makefile
@@ -82,9 +82,9 @@ Patch by Roel Janssen <roel@gnu.org>
binsrc/sqldoc/Makefile
binsrc/sync/Makefile
binsrc/tests/biftest/Makefile
---- 3184,3189 ----
+--- 3238,3243 ----
***************
-*** 3236,3245 ****
+*** 3291,3300 ****
docsrc/stylesheets/Makefile
docsrc/xmlsource/Makefile
libsrc/Dk/Makefile
@@ -95,9 +95,9 @@ Patch by Roel Janssen <roel@gnu.org>
libsrc/langfunc/Makefile
libsrc/odbcsdk/Makefile
libsrc/plugin/Makefile
---- 3225,3230 ----
-*** a-virtuoso-opensource-7.2.7/libsrc/Makefile.am 1970-01-01 01:00:01.000000000 +0100
---- b-virtuoso-opensource-7.2.7/libsrc/Makefile.am 2022-05-27 12:30:12.658593011 +0200
+--- 3280,3285 ----
+*** a-virtuoso-opensource-7.2.9/libsrc/Makefile.am 1970-01-01 01:00:01.000000000 +0100
+--- b-virtuoso-opensource-7.2.9/libsrc/Makefile.am 2023-03-05 13:03:17.616027294 +0100
***************
*** 19,25 ****
#
diff --git a/gnu/packages/patches/widelands-add-missing-map-include.patch b/gnu/packages/patches/widelands-add-missing-map-include.patch
deleted file mode 100644
index 633731bea2..0000000000
--- a/gnu/packages/patches/widelands-add-missing-map-include.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 316eaea209754368a57f445ea4dd016ecf8eded6 Mon Sep 17 00:00:00 2001
-From: matthiakl <t-m.42@mailpost.spdns.org>
-Date: Sat, 14 Aug 2021 19:24:08 +0200
-Subject: [PATCH] Added missing direct incude (#5025)
-
----
-This patch is from
-https://github.com/widelands/widelands/pull/5025
-which has been merged after the release of Widelands 1.0.
-
- src/network/bufferedconnection.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/network/bufferedconnection.h b/src/network/bufferedconnection.h
-index fe974b9e..7e1ecf87 100644
---- a/src/network/bufferedconnection.h
-+++ b/src/network/bufferedconnection.h
-@@ -20,6 +20,7 @@
- #ifndef WL_NETWORK_BUFFEREDCONNECTION_H
- #define WL_NETWORK_BUFFEREDCONNECTION_H
-
-+#include <map>
- #include <memory>
- #include <mutex>
- #include <thread>
---
-2.30.2
-
diff --git a/gnu/packages/patches/widelands-system-wide_minizip.patch b/gnu/packages/patches/widelands-system-wide_minizip.patch
deleted file mode 100644
index b59fed7531..0000000000
--- a/gnu/packages/patches/widelands-system-wide_minizip.patch
+++ /dev/null
@@ -1,141 +0,0 @@
-Description: use the system-wide minizip instead of the embeeded one if found.
-Forwarded-Upstream: It was provided by upstream: http://bazaar.launchpad.net/~widelands-dev/widelands/b19-debian/revision/8147
- .
- Thanks to Fòram na Gàidhlig for the patch.
-
-=== modified file 'CMakeLists.txt'
----
- CMakeLists.txt | 1 +
- cmake/Modules/FindMinizip.cmake | 37 +++++++++++++++++++++++++++++++++++++
- cmake/WlFunctions.cmake | 8 ++++++++
- src/io/filesystem/CMakeLists.txt | 2 +-
- src/io/filesystem/zip_filesystem.h | 6 ++++++
- src/third_party/CMakeLists.txt | 20 +++++++++++---------
- 6 files changed, 64 insertions(+), 10 deletions(-)
-
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -142,6 +142,7 @@
- find_package(SDL2_mixer REQUIRED)
- find_package(SDL2_ttf REQUIRED)
- find_package(ZLIB REQUIRED)
-+find_package(Minizip)
- if(${CMAKE_VERSION} VERSION_LESS 3.9.0)
- find_package(ICU_old REQUIRED)
- else()
---- /dev/null
-+++ b/cmake/Modules/FindMinizip.cmake
-@@ -0,0 +1,37 @@
-+# - Try to find Minizip
-+# Once done this will define
-+#
-+# MINIZIP_FOUND - system has MINIZIP
-+# MINIZIP_INCLUDE_DIR - the MINIZIP include directory
-+# MINIZIP_LIBRARY_DIR - where the libraries are
-+# MINIZIP_LIBRARY - Link these to use MINIZIP
-+#
-+
-+IF (MINIZIP_INCLUDE_DIR)
-+ # Already in cache, be silent
-+ SET(MINIZIP_FIND_QUIETLY TRUE)
-+ENDIF (MINIZIP_INCLUDE_DIR)
-+
-+FIND_PATH( MINIZIP_INCLUDE_DIR
-+ NAMES zip.h unzip.h ioapi.h
-+ PATHS /usr/local/include /usr/include
-+ PATH_SUFFIXES minizip/ )
-+SET( MINIZIP_NAMES minizip MINIZIP )
-+FIND_LIBRARY( MINIZIP_LIBRARY
-+ NAMES ${MINIZIP_NAMES}
-+ PATHS /usr/lib /usr/local/lib )
-+
-+GET_FILENAME_COMPONENT( MINIZIP_LIBRARY_DIR ${MINIZIP_LIBRARY} PATH )
-+
-+IF (MINIZIP_INCLUDE_DIR AND MINIZIP_LIBRARY)
-+ SET(MINIZIP_FOUND TRUE)
-+ SET(MINIZIP_LIBRARY_DIR ${MINIZIP_LIBRARY} )
-+ IF (NOT MINIZIP_FIND_QUIETLY)
-+ MESSAGE (STATUS "Found Minizip: ${MINIZIP_LIBRARY} ${MINIZIP_INCLUDE_DIR}")
-+ ENDIF (NOT MINIZIP_FIND_QUIETLY)
-+ELSE (MINIZIP_INCLUDE_DIR AND MINIZIP_LIBRARY)
-+ SET( MINIZIP_FOUND FALSE )
-+ SET( MINIZIP_LIBRARY_DIR )
-+ SET( MINIZIP_EXTRA_DEFINITIONS )
-+ENDIF (MINIZIP_INCLUDE_DIR AND MINIZIP_LIBRARY)
-+
---- a/cmake/WlFunctions.cmake
-+++ b/cmake/WlFunctions.cmake
-@@ -84,6 +84,14 @@
-
- if(ARG_USES_ZLIB)
- target_link_libraries(${NAME} ZLIB::ZLIB)
-+ if (MINIZIP_FOUND)
-+ wl_include_system_directories(${NAME} ${MINIZIP_INCLUDE_DIR})
-+ target_link_libraries(${NAME} ${MINIZIP_LIBRARY})
-+ target_compile_definitions(${NAME} PUBLIC -DHAVE_SYSTEM_MINIZIP)
-+ else(MINIZIP_FOUND)
-+ target_link_libraries(${NAME} third_party_minizip)
-+ message(FATAL_ERROR "You are using widelands-bundled minizip sources. Please install your distribution's minizip dev library or urge your distribution maintainer to include the minizip library in your package repository. Thank you.")
-+ endif(MINIZIP_FOUND)
- endif()
-
- # OpenGL and GLEW are one thing for us. If you use the one, you also use the
---- a/src/third_party/CMakeLists.txt
-+++ b/src/third_party/CMakeLists.txt
-@@ -1,12 +1,14 @@
--wl_library(third_party_minizip
-- THIRD_PARTY
-- SRCS
-- minizip/ioapi.h
-- minizip/unzip.cc
-- minizip/unzip.h
-- minizip/zip.h
-- USES_ZLIB
--)
-+if(NOT MINIZIP_FOUND)
-+ wl_library(third_party_minizip
-+ THIRD_PARTY
-+ SRCS
-+ ioapi.h
-+ unzip.cc
-+ unzip.h
-+ zip.h
-+ USES_ZLIB
-+ )
-+endif(NOT MINIZIP_FOUND)
-
- wl_library(third_party_eris
- THIRD_PARTY
---- a/src/io/filesystem/CMakeLists.txt
-+++ b/src/io/filesystem/CMakeLists.txt
-@@ -12,6 +12,7 @@
- zip_exceptions.h
- zip_filesystem.cc
- zip_filesystem.h
-+ USES_ZLIB
- DEPENDS
- base_exceptions
- base_i18n
-@@ -19,5 +20,4 @@
- base_macros
- graphic_text_layout
- io_stream
-- third_party_minizip
- )
---- a/src/io/filesystem/zip_filesystem.h
-+++ b/src/io/filesystem/zip_filesystem.h
-@@ -25,8 +25,14 @@
- #include "io/filesystem/filesystem.h"
- #include "io/streamread.h"
- #include "io/streamwrite.h"
-+
-+#ifndef HAVE_SYSTEM_MINIZIP
- #include "third_party/minizip/unzip.h"
- #include "third_party/minizip/zip.h"
-+#else
-+#include <minizip/unzip.h>
-+#include <minizip/zip.h>
-+#endif
-
- class ZipFilesystem : public FileSystem {
- public:
diff --git a/gnu/packages/patches/wpa-supplicant-dbus-group-policy.patch b/gnu/packages/patches/wpa-supplicant-dbus-group-policy.patch
new file mode 100644
index 0000000000..95c18dac18
--- /dev/null
+++ b/gnu/packages/patches/wpa-supplicant-dbus-group-policy.patch
@@ -0,0 +1,23 @@
+Borrowed from debian, allows users in netdev group to control wpa-supplicant
+via D-Bus.
+
+Description: Debian does not use pam_console but uses group membership
+ to control access to D-Bus. Activating both options in the conf file
+ makes it work on Debian and Ubuntu.
+Author: Michael Biebl <biebl@debian.org>
+Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?msg=15;bug=412179
+---
+--- a/wpa_supplicant/dbus/dbus-wpa_supplicant.conf
++++ b/wpa_supplicant/dbus/dbus-wpa_supplicant.conf
+@@ -14,6 +14,11 @@
+ <allow send_interface="fi.w1.wpa_supplicant1"/>
+ <allow receive_sender="fi.w1.wpa_supplicant1" receive_type="signal"/>
+ </policy>
++ <policy group="netdev">
++ <allow send_destination="fi.w1.wpa_supplicant1"/>
++ <allow send_interface="fi.w1.wpa_supplicant1"/>
++ <allow receive_sender="fi.w1.wpa_supplicant1" receive_type="signal"/>
++ </policy>
+ <policy context="default">
+ <deny own="fi.epitest.hostap.WPASupplicant"/>
+ <deny send_destination="fi.epitest.hostap.WPASupplicant"/>
diff --git a/gnu/packages/patches/xf86-video-tga-remove-mibstore.patch b/gnu/packages/patches/xf86-video-tga-remove-mibstore.patch
deleted file mode 100644
index b1a96c3f10..0000000000
--- a/gnu/packages/patches/xf86-video-tga-remove-mibstore.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-Removes references to mibstore.h and miInitializeBackingStore, which
-have been removed from xorg-server. Zack Rusin <zackr@vmware.com>
-wrote: "It was a noop for at least 5 years and it has been removed."
-See: http://patches.openembedded.org/patch/46133/
-
---- xf86-video-tga-1.2.2/src/tga_accel.c.~1~ 2012-07-15 23:54:04.000000000 -0400
-+++ xf86-video-tga-1.2.2/src/tga_accel.c 2014-12-19 01:40:27.535913013 -0500
-@@ -37,7 +37,6 @@
- #include "xf86cmap.h"
- #include "mipointer.h"
-
--#include "mibstore.h"
- #include "miline.h"
-
- #include "tga_regs.h"
---- xf86-video-tga-1.2.2/src/tga_driver.c.~1~ 2012-07-15 23:54:28.000000000 -0400
-+++ xf86-video-tga-1.2.2/src/tga_driver.c 2014-12-19 01:40:48.756018238 -0500
-@@ -46,8 +46,6 @@
-
- /* software cursor */
- #include "mipointer.h"
--/* backing store */
--#include "mibstore.h"
-
- /* #include "mibank.h" */
- /* colormap manipulation */
-@@ -1451,7 +1449,6 @@
-
- fbPictureInit (pScreen, 0, 0);
-
-- miInitializeBackingStore(pScreen);
- xf86SetBackingStore(pScreen);
- xf86SetSilkenMouse(pScreen);
-
diff --git a/gnu/packages/patches/xmonad-dynamic-linking.patch b/gnu/packages/patches/xmonad-dynamic-linking.patch
index 4f3386e53a..a1d71825b6 100644
--- a/gnu/packages/patches/xmonad-dynamic-linking.patch
+++ b/gnu/packages/patches/xmonad-dynamic-linking.patch
@@ -2,15 +2,15 @@ This patch is required for xmonad to make use of shared libraries.
Without it, xmonad will not work since we do not (by default) use
statically linked Haskell libraries.
-diff -ruN xmonad-0.15-a/src/XMonad/Core.hs xmonad-0.15-b/src/XMonad/Core.hs
---- xmonad-0.15-a/src/XMonad/Core.hs 1969-12-31 19:00:00.000000000 -0500
-+++ xmonad-0.15-b/src/XMonad/Core.hs 1969-12-31 19:00:00.000000000 -0500
-@@ -681,6 +681,8 @@
- compileGHC bin dir errHandle =
- runProcess "ghc" ["--make"
- , "xmonad.hs"
-+ , "-dynamic"
-+ , "-fPIC"
- , "-i"
- , "-ilib"
- , "-fforce-recomp"
+index 46a0939..5ad4f8f 100644
+--- a/src/XMonad/Core.hs
++++ b/src/XMonad/Core.hs
+@@ -664,6 +664,8 @@ compile dirs method =
+ where
+ ghcArgs = [ "--make"
+ , "xmonad.hs"
++ , "-dynamic"
++ , "-fPIC"
+ , "-i" -- only look in @lib@
+ , "-ilib"
+ , "-fforce-recomp"
diff --git a/gnu/packages/patches/xmonad-next-dynamic-linking.patch b/gnu/packages/patches/xmonad-next-dynamic-linking.patch
deleted file mode 100644
index a1d71825b6..0000000000
--- a/gnu/packages/patches/xmonad-next-dynamic-linking.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-This patch is required for xmonad to make use of shared libraries.
-Without it, xmonad will not work since we do not (by default) use
-statically linked Haskell libraries.
-
-index 46a0939..5ad4f8f 100644
---- a/src/XMonad/Core.hs
-+++ b/src/XMonad/Core.hs
-@@ -664,6 +664,8 @@ compile dirs method =
- where
- ghcArgs = [ "--make"
- , "xmonad.hs"
-+ , "-dynamic"
-+ , "-fPIC"
- , "-i" -- only look in @lib@
- , "-ilib"
- , "-fforce-recomp"