diff options
Diffstat (limited to 'gnu')
314 files changed, 16630 insertions, 16982 deletions
diff --git a/gnu/ci.scm b/gnu/ci.scm index 5159205325..7acd88ed29 100644 --- a/gnu/ci.scm +++ b/gnu/ci.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2022 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012-2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2017, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2018, 2019 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2020 Julien Lepiller <julien@lepiller.eu> @@ -46,6 +46,7 @@ #:use-module (gnu image) #:use-module (gnu packages) #:use-module (gnu packages gcc) + #:use-module (gnu packages gdb) #:use-module (gnu packages base) #:use-module (gnu packages gawk) #:use-module (gnu packages guile) @@ -137,7 +138,7 @@ SYSTEM." ;; Note: Don't put the '-final' package variants because (1) that's ;; implicit, and (2) they cannot be cross-built (due to the explicit input ;; chain.) - (list gcc-8 gcc-9 gcc-10 gcc-11 glibc binutils + (list gcc-10 gcc-11 gcc-12 glibc binutils gdb-minimal gmp mpfr mpc coreutils findutils diffutils patch sed grep gawk gnu-gettext hello guile-2.2 guile-3.0 zlib gzip xz guix %bootstrap-binaries-tarball diff --git a/gnu/local.mk b/gnu/local.mk index b631fa6d5a..a2b7defe30 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1,6 +1,6 @@ # GNU Guix --- Functional package management for GNU # Copyright © 2012-2023 Ludovic Courtès <ludo@gnu.org> -# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2022 Andreas Enge <andreas@enge.fr> +# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2022, 2023 Andreas Enge <andreas@enge.fr> # Copyright © 2016 Mathieu Lirzin <mthl@gnu.org> # Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Mark H Weaver <mhw@netris.org> # Copyright © 2016 Chris Marusich <cmmarusich@gmail.com> @@ -10,7 +10,7 @@ # Copyright © 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Ricardo Wurmus <rekado@elephly.net> # Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com> # Copyright © 2016, 2017, 2018, 2019 Alex Vong <alexvong1995@gmail.com> -# Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> +# Copyright © 2016, 2017, 2018, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> # Copyright © 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> # Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> # Copyright © 2017, 2018 Clément Lassieur <clement@lassieur.org> @@ -350,7 +350,6 @@ GNU_SYSTEM_MODULES = \ %D%/packages/java-xml.scm \ %D%/packages/javascript.scm \ %D%/packages/jemalloc.scm \ - %D%/packages/jrnl.scm \ %D%/packages/jose.scm \ %D%/packages/julia.scm \ %D%/packages/julia-jll.scm \ @@ -916,7 +915,6 @@ dist_patch_DATA = \ %D%/packages/patches/audiofile-hurd.patch \ %D%/packages/patches/audiofile-function-signature.patch \ %D%/packages/patches/automake-skip-amhello-tests.patch \ - %D%/packages/patches/autotrace-glib-compat.patch \ %D%/packages/patches/avahi-localstatedir.patch \ %D%/packages/patches/avidemux-install-to-lib.patch \ %D%/packages/patches/awesome-reproducible-png.patch \ @@ -947,12 +945,10 @@ dist_patch_DATA = \ %D%/packages/patches/beancount-disable-googleapis-fonts.patch \ %D%/packages/patches/beignet-correct-file-names.patch \ %D%/packages/patches/bidiv-update-fribidi.patch \ - %D%/packages/patches/binutils-2.37-file-descriptor-leak.patch \ %D%/packages/patches/binutils-boot-2.20.1a.patch \ %D%/packages/patches/binutils-loongson-workaround.patch \ %D%/packages/patches/binutils-mingw-w64-timestamp.patch \ %D%/packages/patches/binutils-mingw-w64-deterministic.patch \ - %D%/packages/patches/binutils-CVE-2021-45078.patch \ %D%/packages/patches/bloomberg-bde-cmake-module-path.patch \ %D%/packages/patches/bloomberg-bde-tools-fix-install-path.patch \ %D%/packages/patches/boolector-find-googletest.patch \ @@ -965,6 +961,7 @@ dist_patch_DATA = \ %D%/packages/patches/calibre-no-updates-dialog.patch \ %D%/packages/patches/calibre-remove-test-sqlite.patch \ %D%/packages/patches/calibre-remove-test-unrar.patch \ + %D%/packages/patches/camlboot-dynamically-allocate-stack-signal.patch \ %D%/packages/patches/catdoc-CVE-2017-11110.patch \ %D%/packages/patches/ccextractor-add-missing-header.patch \ %D%/packages/patches/ccextractor-autoconf-tesseract.patch \ @@ -1004,7 +1001,6 @@ dist_patch_DATA = \ %D%/packages/patches/cling-use-shared-library.patch \ %D%/packages/patches/clog-fix-shared-build.patch \ %D%/packages/patches/clucene-pkgconfig.patch \ - %D%/packages/patches/cmake-curl-certificates.patch \ %D%/packages/patches/cmake-curl-certificates-3.24.patch \ %D%/packages/patches/coda-use-system-libs.patch \ %D%/packages/patches/collectd-5.11.0-noinstallvar.patch \ @@ -1019,7 +1015,6 @@ dist_patch_DATA = \ %D%/packages/patches/cool-retro-term-wctype.patch \ %D%/packages/patches/coreutils-gnulib-tests.patch \ %D%/packages/patches/coq-fix-envvars.patch \ - %D%/packages/patches/coreutils-ls.patch \ %D%/packages/patches/cpuinfo-system-libraries.patch \ %D%/packages/patches/cpulimit-with-glib-2.32.patch \ %D%/packages/patches/crawl-upgrade-saves.patch \ @@ -1027,12 +1022,9 @@ dist_patch_DATA = \ %D%/packages/patches/crda-optional-gcrypt.patch \ %D%/packages/patches/clucene-contribs-lib.patch \ %D%/packages/patches/cube-nocheck.patch \ - %D%/packages/patches/curl-easy-lock.patch \ %D%/packages/patches/curl-use-ssl-cert-env.patch \ %D%/packages/patches/cursynth-wave-rand.patch \ %D%/packages/patches/cvs-CVE-2017-12836.patch \ - %D%/packages/patches/cyrus-sasl-ac-try-run-fix.patch \ - %D%/packages/patches/cyrus-sasl-CVE-2019-19906.patch \ %D%/packages/patches/c++-gsl-find-system-gtest.patch \ %D%/packages/patches/c++-gsl-move-array-bounds-tests.patch \ %D%/packages/patches/date-output-pkg-config-files.patch \ @@ -1088,6 +1080,7 @@ dist_patch_DATA = \ %D%/packages/patches/emacs-yasnippet-fix-tests.patch \ %D%/packages/patches/emacs-kv-fix-tests.patch \ %D%/packages/patches/emacs-pgtk-super-key-fix.patch \ + %D%/packages/patches/emacs-xelb-ignore-length-element.patch \ %D%/packages/patches/enjarify-setup-py.patch \ %D%/packages/patches/enlightenment-fix-setuid-path.patch \ %D%/packages/patches/erlang-man-path.patch \ @@ -1141,6 +1134,7 @@ dist_patch_DATA = \ %D%/packages/patches/fpc-reproducibility.patch \ %D%/packages/patches/fpm-newer-clamp-fix.patch \ %D%/packages/patches/freedink-engine-fix-sdl-hints.patch \ + %D%/packages/patches/freeimage-libtiff-compat.patch \ %D%/packages/patches/freeimage-unbundle.patch \ %D%/packages/patches/fuse-glibc-2.34.patch \ %D%/packages/patches/fuse-overlapping-headers.patch \ @@ -1151,7 +1145,6 @@ dist_patch_DATA = \ %D%/packages/patches/ganeti-pyyaml-compat.patch \ %D%/packages/patches/ganeti-shepherd-master-failover.patch \ %D%/packages/patches/ganeti-shepherd-support.patch \ - %D%/packages/patches/gash-utils-ls-test.patch \ %D%/packages/patches/gawk-shell.patch \ %D%/packages/patches/gcc-arm-bug-71399.patch \ %D%/packages/patches/gcc-arm-link-spec-fix.patch \ @@ -1194,12 +1187,14 @@ dist_patch_DATA = \ %D%/packages/patches/gcc-9-strmov-store-file-names.patch \ %D%/packages/patches/gcc-12-strmov-store-file-names.patch \ %D%/packages/patches/gcc-10-cross-environment-variables.patch \ + %D%/packages/patches/gcc-11-libstdc++-hurd-libpthread.patch \ %D%/packages/patches/gcc-12-cross-environment-variables.patch \ + %D%/packages/patches/gcc-10-tree-sra-union-handling.patch \ + %D%/packages/patches/gcc-11-libstdc++-powerpc.patch \ %D%/packages/patches/gcolor3-update-libportal-usage.patch \ %D%/packages/patches/gd-fix-tests-on-i686.patch \ %D%/packages/patches/gd-brect-bounds.patch \ %D%/packages/patches/gd-Revert-fix-303-gdlib.pc.patch \ - %D%/packages/patches/gdb-fix-gnu-nat-build.patch \ %D%/packages/patches/gdm-default-session.patch \ %D%/packages/patches/gdm-elogind-support.patch \ %D%/packages/patches/gdm-remove-hardcoded-xwayland-path.patch \ @@ -1209,9 +1204,12 @@ dist_patch_DATA = \ %D%/packages/patches/gemmi-fix-sajson-types.patch \ %D%/packages/patches/genimage-mke2fs-test.patch \ %D%/packages/patches/geoclue-config.patch \ + %D%/packages/patches/gettext-libunicode-update.patch \ %D%/packages/patches/ghc-8.0-fall-back-to-madv_dontneed.patch \ %D%/packages/patches/ghc-9.2-glibc-2.33-link-order.patch \ + %D%/packages/patches/ghc-9.2-grep-warnings.patch \ %D%/packages/patches/ghc-testsuite-dlopen-pie.patch \ + %D%/packages/patches/ghc-testsuite-grep-compat.patch \ %D%/packages/patches/ghc-bloomfilter-ghc9.2.patch \ %D%/packages/patches/ghc-bytestring-handle-ghc9.patch \ %D%/packages/patches/ghc-language-haskell-extract-ghc-8.10.patch \ @@ -1220,7 +1218,6 @@ dist_patch_DATA = \ %D%/packages/patches/ghostscript-no-header-creationdate.patch \ %D%/packages/patches/glib-appinfo-watch.patch \ %D%/packages/patches/glib-networking-gnutls-binding.patch \ - %D%/packages/patches/glib-networking-32-bit-time.patch \ %D%/packages/patches/glib-skip-failing-test.patch \ %D%/packages/patches/glibc-CVE-2019-7309.patch \ %D%/packages/patches/glibc-CVE-2019-9169.patch \ @@ -1250,7 +1247,6 @@ dist_patch_DATA = \ %D%/packages/patches/glibc-versioned-locpath.patch \ %D%/packages/patches/glibc-2.29-git-updates.patch \ %D%/packages/patches/glibc-2.29-supported-locales.patch \ - %D%/packages/patches/glibc-static-nss.patch \ %D%/packages/patches/glibc-supported-locales.patch \ %D%/packages/patches/glslang-install-static-libs.patch \ %D%/packages/patches/gmp-arm-asm-nothumb.patch \ @@ -1261,12 +1257,11 @@ dist_patch_DATA = \ %D%/packages/patches/gnome-settings-daemon-gc.patch \ %D%/packages/patches/gnome-session-support-elogind.patch \ %D%/packages/patches/gnome-tweaks-search-paths.patch \ - %D%/packages/patches/gnupg-CVE-2022-34903.patch \ + %D%/packages/patches/gnumach-add-missing-const_mach_port_name_array_t-type.patch \ %D%/packages/patches/gnupg-default-pinentry.patch \ %D%/packages/patches/gnupg-1-build-with-gcc10.patch \ %D%/packages/patches/gnutls-skip-trust-store-test.patch \ %D%/packages/patches/gnutls-cross.patch \ - %D%/packages/patches/gnutls-guile-eintr-eagain.patch \ %D%/packages/patches/gobject-introspection-absolute-shlib-path.patch \ %D%/packages/patches/gobject-introspection-absolute-shlib-path-1.72.patch \ %D%/packages/patches/gobject-introspection-cc.patch \ @@ -1305,6 +1300,7 @@ dist_patch_DATA = \ %D%/packages/patches/guile-fix-invalid-unicode-handling.patch \ %D%/packages/patches/guile-gdbm-ffi-support-gdbm-1.14.patch \ %D%/packages/patches/guile-git-adjust-for-libgit2-1.2.0.patch \ + %D%/packages/patches/guile-hurd-posix-spawn.patch \ %D%/packages/patches/guile-present-coding.patch \ %D%/packages/patches/guile-rsvg-pkgconfig.patch \ %D%/packages/patches/guile-emacs-fix-configure.patch \ @@ -1338,15 +1334,17 @@ dist_patch_DATA = \ %D%/packages/patches/htslib-for-stringtie.patch \ %D%/packages/patches/hubbub-sort-entities.patch \ %D%/packages/patches/hueplusplus-mbedtls.patch \ - %D%/packages/patches/hurd-cross.patch \ - %D%/packages/patches/hurd-xattr.patch \ + %D%/packages/patches/hurd-add-without-rump-configure-option.patch \ + %D%/packages/patches/hurd-fix-types-of-read-write-and-readables-methods-2.patch \ + %D%/packages/patches/hurd-fix-types-of-read-write-and-readables-methods.patch \ %D%/packages/patches/hwloc-1-test-btrfs.patch \ %D%/packages/patches/i7z-gcc-10.patch \ %D%/packages/patches/icecat-makeicecat.patch \ %D%/packages/patches/icecat-avoid-bundled-libraries.patch \ %D%/packages/patches/icecat-use-system-graphite2+harfbuzz.patch \ %D%/packages/patches/icecat-use-system-media-libs.patch \ - %D%/packages/patches/icedtea-7-hotspot-aarch64-use-c++98.patch\ + %D%/packages/patches/icedtea-7-hotspot-aarch64-use-c++98.patch \ + %D%/packages/patches/icedtea-7-hotspot-pointer-comparison.patch \ %D%/packages/patches/id3lib-CVE-2007-4460.patch \ %D%/packages/patches/id3lib-UTF16-writing-bug.patch \ %D%/packages/patches/idris-test-ffi008.patch \ @@ -1355,6 +1353,7 @@ dist_patch_DATA = \ %D%/packages/patches/imagemagick-ReadDCMImage-fix.patch \ %D%/packages/patches/imagemagick-ReadDCMPixels-fix.patch \ %D%/packages/patches/imagemagick-WriteTHUMBNAILImage-fix.patch \ + %D%/packages/patches/inkscape-poppler-compat.patch \ %D%/packages/patches/instead-use-games-path.patch \ %D%/packages/patches/intel-xed-fix-nondeterminism.patch \ %D%/packages/patches/intltool-perl-compatibility.patch \ @@ -1386,12 +1385,10 @@ dist_patch_DATA = \ %D%/packages/patches/jfsutils-add-sysmacros.patch \ %D%/packages/patches/jfsutils-gcc-compat.patch \ %D%/packages/patches/jfsutils-include-systypes.patch \ - %D%/packages/patches/json-c-0.13-CVE-2020-12762.patch \ - %D%/packages/patches/json-c-0.12-CVE-2020-12762.patch \ - %D%/packages/patches/jsoncpp-pkg-config-version.patch \ + %D%/packages/patches/json-c-0.13-CVE-2020-12762.patch \ + %D%/packages/patches/json-c-0.12-CVE-2020-12762.patch \ %D%/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch \ - %D%/packages/patches/libffi-3.3-powerpc-fixes.patch \ - %D%/packages/patches/libffi-float128-powerpc64le.patch \ + %D%/packages/patches/julia-Use-MPFR-4.2.patch \ %D%/packages/patches/libgeotiff-fix-tests-with-proj-9.1.1.patch \ %D%/packages/patches/libobjc2-unbundle-robin-map.patch \ %D%/packages/patches/librime-fix-build-with-gcc10.patch \ @@ -1429,6 +1426,7 @@ dist_patch_DATA = \ %D%/packages/patches/liba52-link-with-libm.patch \ %D%/packages/patches/liba52-set-soname.patch \ %D%/packages/patches/liba52-use-mtune-not-mcpu.patch \ + %D%/packages/patches/libaio-32bit-test.patch \ %D%/packages/patches/libbase-fix-includes.patch \ %D%/packages/patches/libbase-use-own-logging.patch \ %D%/packages/patches/libbonobo-activation-test-race.patch \ @@ -1469,14 +1467,15 @@ dist_patch_DATA = \ %D%/packages/patches/libqalculate-3.8.0-libcurl-ssl-fix.patch \ %D%/packages/patches/libquicktime-ffmpeg.patch \ %D%/packages/patches/librecad-support-for-boost-1.76.patch \ - %D%/packages/patches/libssh2-CVE-2019-17498.patch \ %D%/packages/patches/libtar-CVE-2013-4420.patch \ %D%/packages/patches/libtgvoip-disable-sse2.patch \ %D%/packages/patches/libtgvoip-disable-webrtc.patch \ %D%/packages/patches/libtheora-config-guess.patch \ + %D%/packages/patches/libtiff-CVE-2022-34526.patch \ %D%/packages/patches/libtirpc-CVE-2021-46828.patch \ %D%/packages/patches/libtirpc-hurd.patch \ %D%/packages/patches/libtommath-fix-linkage.patch \ + %D%/packages/patches/libtool-grep-compat.patch \ %D%/packages/patches/libtool-skip-tests2.patch \ %D%/packages/patches/libusb-0.1-disable-tests.patch \ %D%/packages/patches/libusb-for-axoloti.patch \ @@ -1484,10 +1483,8 @@ dist_patch_DATA = \ %D%/packages/patches/libutils-remove-damaging-includes.patch \ %D%/packages/patches/libvdpau-va-gl-unbundle.patch \ %D%/packages/patches/libvpx-CVE-2016-2818.patch \ - %D%/packages/patches/libxml2-parent-pointers.patch \ - %D%/packages/patches/libxml2-terminating-newline.patch \ - %D%/packages/patches/libxml2-xpath-recursion-limit.patch \ %D%/packages/patches/libxml2-xpath0-Add-option-xpath0.patch \ + %D%/packages/patches/libwpd-gcc-compat.patch \ %D%/packages/patches/libxslt-generated-ids.patch \ %D%/packages/patches/libxt-guix-search-paths.patch \ %D%/packages/patches/lierolibre-check-unaligned-access.patch \ @@ -1501,6 +1498,7 @@ dist_patch_DATA = \ %D%/packages/patches/linux-libre-infodocs-target.patch \ %D%/packages/patches/linux-libre-support-for-Pinebook-Pro.patch \ %D%/packages/patches/linux-pam-no-setfsuid.patch \ + %D%/packages/patches/linux-pam-unix_chkpwd.patch \ %D%/packages/patches/linuxdcpp-openssl-1.1.patch \ %D%/packages/patches/lirc-localstatedir.patch \ %D%/packages/patches/lirc-reproducible-build.patch \ @@ -1509,6 +1507,7 @@ dist_patch_DATA = \ %D%/packages/patches/llvm-3.6-fix-build-with-gcc-10.patch \ %D%/packages/patches/llvm-3.x.1-fix-build-with-gcc.patch \ %D%/packages/patches/llvm-8-fix-build-with-gcc-10.patch \ + %D%/packages/patches/llvm-8-missing-include.patch \ %D%/packages/patches/llvm-9-fix-bitcast-miscompilation.patch \ %D%/packages/patches/llvm-9-fix-lpad-miscompilation.patch \ %D%/packages/patches/llvm-9-fix-scev-miscompilation.patch \ @@ -1526,6 +1525,7 @@ dist_patch_DATA = \ %D%/packages/patches/lua-5.4-liblua-so.patch \ %D%/packages/patches/luit-posix.patch \ %D%/packages/patches/lvm2-static-link.patch \ + %D%/packages/patches/lxqt-session-procps-4.patch \ %D%/packages/patches/mailutils-variable-lookup.patch \ %D%/packages/patches/make-impure-dirs.patch \ %D%/packages/patches/mars-install.patch \ @@ -1549,13 +1549,13 @@ dist_patch_DATA = \ %D%/packages/patches/mercurial-hg-extension-path.patch \ %D%/packages/patches/mercurial-openssl-compat.patch \ %D%/packages/patches/mesa-opencl-all-targets.patch \ - %D%/packages/patches/mesa-skip-tests.patch \ - %D%/packages/patches/meson-allow-dirs-outside-of-prefix.patch \ + %D%/packages/patches/mesa-fix-sporadic-test-failures.patch \ %D%/packages/patches/mhash-keygen-test-segfault.patch \ %D%/packages/patches/mia-fix-boost-headers.patch \ %D%/packages/patches/mia-vtk9.patch \ %D%/packages/patches/mia-vtk92.patch \ %D%/packages/patches/mia-vtk-version.patch \ + %D%/packages/patches/mig-cpu.h-generation.patch \ %D%/packages/patches/mingw-w64-6.0.0-gcc.patch \ %D%/packages/patches/mingw-w64-dlltool-temp-prefix.patch \ %D%/packages/patches/mingw-w64-reproducible-gendef.patch \ @@ -1564,6 +1564,7 @@ dist_patch_DATA = \ %D%/packages/patches/mit-krb5-hurd.patch \ %D%/packages/patches/mixxx-link-qtscriptbytearray-qtscript.patch \ %D%/packages/patches/mixxx-system-googletest-benchmark.patch \ + %D%/packages/patches/mm-common-reproducible-tarball.patch \ %D%/packages/patches/mpc123-initialize-ao.patch \ %D%/packages/patches/mpg321-CVE-2019-14247.patch \ %D%/packages/patches/mpg321-gcc-10.patch \ @@ -1576,7 +1577,6 @@ dist_patch_DATA = \ %D%/packages/patches/mupen64plus-video-z64-glew-correct-path.patch \ %D%/packages/patches/musl-cross-locale.patch \ %D%/packages/patches/mutt-store-references.patch \ - %D%/packages/patches/m4-gnulib-libio.patch \ %D%/packages/patches/m17n-lib-1.8.0-use-pkg-config-for-freetype.patch \ %D%/packages/patches/nautilus-extension-search-path.patch \ %D%/packages/patches/ncompress-fix-softlinks.patch \ @@ -1611,6 +1611,8 @@ dist_patch_DATA = \ %D%/packages/patches/ocaml-dose3-dont-make-printconf.patch \ %D%/packages/patches/ocaml-dose3-Install-mli-cmx-etc.patch \ %D%/packages/patches/ocaml-multiple-definitions.patch \ + %D%/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch \ + %D%/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch \ %D%/packages/patches/ocaml-4.09-multiple-definitions.patch \ %D%/packages/patches/omake-fix-non-determinism.patch \ %D%/packages/patches/oneko-remove-nonfree-characters.patch \ @@ -1624,7 +1626,11 @@ dist_patch_DATA = \ %D%/packages/patches/openboardview-use-system-mpc.patch \ %D%/packages/patches/openbox-python3.patch \ %D%/packages/patches/openfoam-4.1-cleanup.patch \ + %D%/packages/patches/openjdk-9-pointer-comparison.patch \ + %D%/packages/patches/openjdk-9-setsignalhandler.patch \ %D%/packages/patches/openjdk-10-idlj-reproducibility.patch \ + %D%/packages/patches/openjdk-10-pointer-comparison.patch \ + %D%/packages/patches/openjdk-10-setsignalhandler.patch \ %D%/packages/patches/openjdk-15-xcursor-no-dynamic.patch \ %D%/packages/patches/openmpi-mtl-priorities.patch \ %D%/packages/patches/openssh-hurd.patch \ @@ -1643,25 +1649,33 @@ dist_patch_DATA = \ %D%/packages/patches/owncloud-disable-updatecheck.patch \ %D%/packages/patches/p7zip-CVE-2016-9296.patch \ %D%/packages/patches/p7zip-CVE-2017-17969.patch \ + %D%/packages/patches/p7zip-fix-build-with-gcc-11.patch \ %D%/packages/patches/p7zip-remove-unused-code.patch \ %D%/packages/patches/pam-krb5-CVE-2020-10595.patch \ %D%/packages/patches/pango-skip-libthai-test.patch \ %D%/packages/patches/password-store-tree-compat.patch \ - %D%/packages/patches/pciutils-hurd-configure.patch \ - %D%/packages/patches/pciutils-hurd-fix.patch \ %D%/packages/patches/petri-foo-0.1.87-fix-recent-file-not-exist.patch \ %D%/packages/patches/php-fix-streams-copy-length.patch \ %D%/packages/patches/plasma-framework-fix-KF5PlasmaMacros.cmake.patch \ %D%/packages/patches/pocketfft-cpp-prefer-preprocessor-if.patch \ %D%/packages/patches/pokerth-boost.patch \ %D%/packages/patches/ppsspp-disable-upgrade-and-gold.patch \ + %D%/packages/patches/procps-strtod-test.patch \ + %D%/packages/patches/prusa-slicer-boost-fixes.patch \ + %D%/packages/patches/prusa-slicer-fix-tests.patch \ + %D%/packages/patches/prusa-slicer-with-cereal-1.3.1.patch \ %D%/packages/patches/pthreadpool-system-libraries.patch \ %D%/packages/patches/python-chai-drop-python2.patch \ + %D%/packages/patches/python-feedparser-missing-import.patch \ %D%/packages/patches/python-louvain-fix-test.patch \ %D%/packages/patches/python-random2-getrandbits-test.patch \ %D%/packages/patches/python-poppler-qt5-fix-build.patch \ %D%/packages/patches/python-pypdf-annotate-tests-appropriately.patch \ + %D%/packages/patches/python-sip-include-dirs.patch \ + %D%/packages/patches/python-sgmllib3k-assertions.patch \ + %D%/packages/patches/python-shiboken-2-compat.patch \ %D%/packages/patches/python-telingo-fix-comparison.patch \ + %D%/packages/patches/python-typeguard-python3.10.patch \ %D%/packages/patches/python-w3lib-fix-test-failure.patch \ %D%/packages/patches/sdcc-disable-non-free-code.patch \ %D%/packages/patches/sdl-pango-api_additions.patch \ @@ -1724,8 +1738,10 @@ dist_patch_DATA = \ %D%/packages/patches/pybugz-stty.patch \ %D%/packages/patches/pygpgme-disable-problematic-tests.patch \ %D%/packages/patches/pyqt-configure.patch \ + %D%/packages/patches/pytest-fix-unstrable-exception-test.patch \ %D%/packages/patches/python-2-deterministic-build-info.patch \ %D%/packages/patches/python-2.7-adjust-tests.patch \ + %D%/packages/patches/python-2.7-expat-compat.patch \ %D%/packages/patches/python-2.7-search-paths.patch \ %D%/packages/patches/python-2.7-site-prefixes.patch \ %D%/packages/patches/python-2.7-source-date-epoch.patch \ @@ -1736,7 +1752,6 @@ dist_patch_DATA = \ %D%/packages/patches/python-3-search-paths.patch \ %D%/packages/patches/python-3-fix-tests.patch \ %D%/packages/patches/python-3-hurd-configure.patch \ - %D%/packages/patches/python-3-no-static-lib.patch \ %D%/packages/patches/python-aionotify-0.2.0-py3.8.patch \ %D%/packages/patches/python-argcomplete-1.11.1-fish31.patch \ %D%/packages/patches/python-cross-compile.patch \ @@ -1744,7 +1759,6 @@ dist_patch_DATA = \ %D%/packages/patches/python-dateutil-pytest-compat.patch \ %D%/packages/patches/python-debugpy-unbundle-pydevd.patch \ %D%/packages/patches/python-docopt-pytest6-compat.patch \ - %D%/packages/patches/python-execnet-read-only-fix.patch \ %D%/packages/patches/python-fixtures-remove-monkeypatch-test.patch \ %D%/packages/patches/python-hiredis-fix-header.patch \ %D%/packages/patches/python-hiredis-use-system-hiredis.patch \ @@ -1763,7 +1777,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-magic-python-bytecode.patch \ %D%/packages/patches/python-memcached-syntax-warnings.patch \ %D%/packages/patches/python-mox3-python3.6-compat.patch \ - %D%/packages/patches/python-typing-inspect-fix.patch \ + %D%/packages/patches/python-parso-unit-tests-in-3.10.patch \ %D%/packages/patches/python-packaging-test-arch.patch \ %D%/packages/patches/python-paste-remove-timing-test.patch \ %D%/packages/patches/python-pycrypto-CVE-2013-7459.patch \ @@ -1777,6 +1791,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-robotframework-atest.patch \ %D%/packages/patches/python-robotframework-source-date-epoch.patch \ %D%/packages/patches/python-robotframework-sshlibrary-rf5-compat.patch \ + %D%/packages/patches/python-typing-inspect-fix.patch \ %D%/packages/patches/python-unittest2-python3-compat.patch \ %D%/packages/patches/python-unittest2-remove-argparse.patch \ %D%/packages/patches/python-versioneer-guix-support.patch \ @@ -1876,6 +1891,8 @@ dist_patch_DATA = \ %D%/packages/patches/syslinux-strip-gnu-property.patch \ %D%/packages/patches/snappy-add-O2-flag-in-CmakeLists.txt.patch \ %D%/packages/patches/snappy-add-inline-for-GCC.patch \ + %D%/packages/patches/source-highlight-gcc-compat.patch \ + %D%/packages/patches/softhsm-fix-openssl3-tests.patch \ %D%/packages/patches/spectre-meltdown-checker-externalize-fwdb.patch \ %D%/packages/patches/spectre-meltdown-checker-find-kernel.patch \ %D%/packages/patches/sphinxbase-fix-doxygen.patch \ @@ -1885,6 +1902,7 @@ dist_patch_DATA = \ %D%/packages/patches/superlu-dist-awpm-grid.patch \ %D%/packages/patches/superlu-dist-scotchmetis.patch \ %D%/packages/patches/supertux-unbundle-squirrel.patch \ + %D%/packages/patches/swig-support-gcc-12.patch \ %D%/packages/patches/swish-e-search.patch \ %D%/packages/patches/swish-e-format-security.patch \ %D%/packages/patches/symmetrica-bruch.patch \ @@ -1904,6 +1922,7 @@ dist_patch_DATA = \ %D%/packages/patches/tcsh-fix-autotest.patch \ %D%/packages/patches/teensy-loader-cli-help.patch \ %D%/packages/patches/tensorflow-c-api-fix.patch \ + %D%/packages/patches/texinfo-headings-single.patch \ %D%/packages/patches/texinfo-5-perl-compat.patch \ %D%/packages/patches/telegram-desktop-allow-disable-libtgvoip.patch \ %D%/packages/patches/telegram-purple-adjust-test.patch \ @@ -1935,6 +1954,7 @@ dist_patch_DATA = \ %D%/packages/patches/tuxpaint-stamps-path.patch \ %D%/packages/patches/twinkle-bcg729.patch \ %D%/packages/patches/u-boot-allow-disabling-openssl.patch \ + %D%/packages/patches/u-boot-fix-build-python-3.10.patch \ %D%/packages/patches/u-boot-infodocs-target.patch \ %D%/packages/patches/u-boot-patman-guix-integration.patch \ %D%/packages/patches/u-boot-nintendo-nes-serial.patch \ @@ -1986,10 +2006,7 @@ dist_patch_DATA = \ %D%/packages/patches/unzip-32bit-zipbomb-fix.patch \ %D%/packages/patches/ustr-fix-build-with-gcc-5.patch \ %D%/packages/patches/util-linux-tests.patch \ - %D%/packages/patches/util-linux-CVE-2021-3995.patch \ - %D%/packages/patches/util-linux-CVE-2021-3996.patch \ %D%/packages/patches/valgrind-enable-arm.patch \ - %D%/packages/patches/valgrind-fix-default-debuginfo-path.patch \ %D%/packages/patches/vboot-utils-fix-format-load-address.patch \ %D%/packages/patches/vboot-utils-fix-tests-show-contents.patch \ %D%/packages/patches/vboot-utils-skip-test-workbuf.patch \ @@ -2041,7 +2058,9 @@ dist_patch_DATA = \ %D%/packages/patches/xterm-370-explicit-xcursor.patch \ %D%/packages/patches/xygrib-fix-finding-data.patch \ %D%/packages/patches/yggdrasil-extra-config.patch \ - %D%/packages/patches/zig-use-system-paths.patch + %D%/packages/patches/zig-do-not-link-against-librt.patch \ + %D%/packages/patches/zig-use-system-paths.patch \ + %D%/packages/patches/zsh-egrep-failing-test.patch MISC_DISTRO_FILES = \ %D%/packages/ld-wrapper.in diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index 1c2b2122ce..54e7403460 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -156,6 +156,7 @@ #:use-module (gnu packages polkit) #:use-module (gnu packages popt) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) @@ -328,12 +329,9 @@ interface and is based on GNU Guile.") (license license:gpl3+) (home-page "https://www.gnu.org/software/shepherd/"))) -;; Update on the next rebuild cycle. -(define-public shepherd shepherd-0.8) - (define-public shepherd-0.9 (package - (inherit shepherd) + (inherit shepherd-0.8) (version "0.9.3") (source (origin (method url-fetch) @@ -368,6 +366,8 @@ interface and is based on GNU Guile.") guile-fibers-1.1)) ;for cross-compilation (inputs (list guile-3.0-latest guile-fibers-1.1)))) +(define-public shepherd shepherd-0.9) + (define-public guile2.2-shepherd (package (inherit shepherd-0.9) @@ -897,14 +897,14 @@ re-executing them as necessary.") (define-public inetutils (package (name "inetutils") - (version "2.0") + (version "2.3") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/inetutils/inetutils-" - version ".tar.gz")) - (sha256 - (base32 - "0j1nb69bhg29cm4xkqqjh2ln1zqcj2lnpm92v638lpwrs11dypxl")))) + (method url-fetch) + (uri (string-append "mirror://gnu/inetutils/inetutils-" + version ".tar.gz")) + (sha256 + (base32 + "1dj4ilxy1wrfxhxc85iya3x28h1mhjpqc5nv862xcq3ww2gqkv8w")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--localstatedir=/var" @@ -928,19 +928,21 @@ re-executing them as necessary.") ;; Make sure that canonical "coreutils" package is not referred. #:make-flags (list (string-append "CPPFLAGS=-DPATHDEF_CP=\\\"" - (assoc-ref %build-inputs "coreutils*") - "/bin/cp\\\"")) + (search-input-file %build-inputs "bin/cp") + "\\\"")) ;; On some systems, 'libls.sh' may fail with an error such as: ;; "Failed to tell switch -a apart from -A". #:parallel-tests? #f)) - (inputs `(("coreutils*" ,coreutils) - ("shadow" ,shadow) ;for login (used in telnetd and rlogind) - ("ncurses" ,ncurses) - ("readline" ,readline))) ;for 'ftp' - (native-inputs (if (member (%current-system) - (package-supported-systems net-tools)) - `(("netstat" ,net-tools)) ;for tests - '())) + (inputs + (list coreutils + shadow ;for login (used in telnetd and rlogind) + ncurses + readline)) ;for 'ftp' + (native-inputs + (if (member (%current-system) + (package-supported-systems net-tools)) + (list net-tools) ;for tests + '())) (home-page "https://www.gnu.org/software/inetutils/") (synopsis "Basic networking utilities") (description @@ -952,15 +954,15 @@ hostname.") (define-public shadow (package (name "shadow") - (version "4.9") + (version "4.13") (source (origin (method url-fetch) (uri (string-append "https://github.com/shadow-maint/shadow/releases/" - "download/v" version "/shadow-" version ".tar.xz")) + "download/" version "/shadow-" version ".tar.xz")) (sha256 (base32 - "0i4iijbshnwnsrskxzrh18xgmzff0hdpsnnkmyc2gdn1x4n1zv7y")))) + "0b6xz415b4y3y5nk3pw9xibv05kln4cjbmhybyncmrx2g5fj9zls")))) (build-system gnu-build-system) (arguments `(;; Assume System V `setpgrp (void)', which is the default on GNU @@ -1002,7 +1004,13 @@ hostname.") (substitute* "lib/nscd.c" (("/usr/sbin/nscd") (string-append libc "/sbin/nscd")))))) - (add-after 'install 'remove-groups + (add-after 'install 'install-man-pages + (lambda _ + ;; The top-level Makefile.am wrongfully has "SUBDIRS += man" + ;; under "if ENABLE_REGENERATE_MAN", even though prebuilt man + ;; pages are available. Thus, install them manually. + (invoke "make" "-C" "man" "install"))) + (add-after 'install-man-pages 'remove-groups (lambda* (#:key outputs #:allow-other-keys) ;; Remove `groups', which is already provided by Coreutils. (let* ((out (assoc-ref outputs "out")) @@ -1023,27 +1031,10 @@ hostname.") "Shadow provides a number of authentication-related tools, including: login, passwd, su, groupadd, and useradd.") - (properties '((hidden? . #t))) ;see below - ;; The `vipw' program is GPLv2+. ;; libmisc/salt.c is public domain. (license license:bsd-3))) -(define-public shadow-with-man-pages - ;; TODO: Merge with 'shadow' on the next core-updates cycle. - (package/inherit shadow - (properties '()) ;not hidden - (arguments - (substitute-keyword-arguments (package-arguments shadow) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-after 'install 'install-man-pages - (lambda _ - ;; The top-level Makefile.am wrongfully has "SUBDIRS += man" - ;; under "if ENABLE_REGENERATE_MAN", even though prebuilt man - ;; pages are available. Thus, install them manually. - (invoke "make" "-C" "man" "install"))))))))) - (define-public mingetty (package (name "mingetty") @@ -1536,7 +1527,7 @@ connection alive.") (list config perl file)) (inputs `(("inetutils" ,inetutils) - ("bash" ,(canonical-package bash-minimal)) ;for wrap-program + ("bash" ,bash-minimal) ,@(if (hurd-target?) '() `(("net-tools" ,net-tools) ("iproute" ,iproute))) @@ -2959,7 +2950,7 @@ provides the following commands: ;; variable in the tests/cpan.scm test. (list (search-path-specification (variable "GUIX_PYTHONPATH") - (files (list "lib/python3.9/site-packages"))))) + (files (list "lib/python3.10/site-packages"))))) (home-page "https://www.ansible.com/") (synopsis "Radically simple IT automation") (description "Ansible aims to be a radically simple IT automation system. diff --git a/gnu/packages/adns.scm b/gnu/packages/adns.scm index 5703016549..913d885af4 100644 --- a/gnu/packages/adns.scm +++ b/gnu/packages/adns.scm @@ -65,7 +65,7 @@ scripts.") (define-public c-ares (package (name "c-ares") - (version "1.17.2") + (version "1.18.1") (source (origin (method url-fetch) (uri (string-append @@ -73,12 +73,10 @@ scripts.") ".tar.gz")) (sha256 (base32 - "0gcincjvpll2qmlc906jx6mfq97s87mgi0zby0753ki0rr2ch0s8")))) + "1kxviskwsaa7dcgscvssxa8ps88pdq7kq4z93gxvz7sam2l54z8s")))) (build-system gnu-build-system) (arguments - '(;; FIXME: Some tests require network access - #:tests? #f - #:phases + '(#:phases (modify-phases %standard-phases (add-before 'check 'filter-live-tests (lambda _ diff --git a/gnu/packages/algebra.scm b/gnu/packages/algebra.scm index 76b3da8084..e070af956d 100644 --- a/gnu/packages/algebra.scm +++ b/gnu/packages/algebra.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2013, 2015, 2017, 2018, 2021 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2016-2023 Nicolas Goaziou <mail@nicolasgoaziou.fr> ;;; Copyright © 2014, 2018 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2016, 2018, 2019, 2021 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2016, 2018, 2019, 2021, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017, 2020-2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> @@ -687,7 +687,7 @@ binary.") (patches (search-patches "bc-fix-cross-compilation.patch")))) (build-system gnu-build-system) (native-inputs - (list automake autoconf ed flex texinfo)) + (list automake autoconf ed flex readline texinfo)) (inputs (list readline)) (arguments @@ -1148,9 +1148,12 @@ features, and more.") (substitute-keyword-arguments (package-arguments eigen) ((#:phases phases) `(modify-phases ,phases - (delete 'disable-some-tests))))) - (native-inputs - (list gcc-7))))) + (delete 'disable-some-tests) + ;; This test cannot be compiled + (add-after 'unpack 'gcc-compatibility + (lambda _ + (substitute* "test/CMakeLists.txt" + (("ei_add_test\\(stddeque") "#"))))))))))) (define-public eigen-for-tensorflow-lite ;; This commit was taken from diff --git a/gnu/packages/android.scm b/gnu/packages/android.scm index 1a0e804a44..f35c2398bd 100644 --- a/gnu/packages/android.scm +++ b/gnu/packages/android.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2017, 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2019, 2020 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2019, 2020, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2020 Sergey Trofimov <sarg@sarg.org.ru> ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net> @@ -1059,36 +1059,17 @@ safest way, on a file image.") useful for reverse engineering, analysis of Android applications and more.") (license license:asl2.0))) -(define-public python-android-backup - (package - (name "python-android-backup") - (version "0.2.0") - (source - (origin - (method url-fetch) - (uri (pypi-uri "android_backup" version)) - (sha256 - (base32 - "15wb2lyjj2fpf7bhvmgpqn0mglsjj11zfvbjycx7mnidisgnljw6")))) - (build-system python-build-system) - (propagated-inputs (list python-pycrypto)) - (home-page "https://github.com/bluec0re/android-backup-tools") - (synopsis "Unpack and repack android backups") - (description "This package allows you to unpack and repack Android -backups. It supports encrypted archives.") - (license license:asl2.0))) - (define-public python-miio (package (name "python-miio") - (version "0.5.11") + (version "0.5.12") (source (origin (method url-fetch) (uri (pypi-uri "python-miio" version)) (sha256 (base32 - "1dyzzywfa5h6q8clmzxsqmszlby8757ajmvkhdyvq6719z4bn46n")))) + "05kc0icap3a4iw4910zfqi61zphcf6x958v2b5x68fy51ld3b704")))) (build-system python-build-system) (arguments `(#:phases @@ -1098,12 +1079,6 @@ backups. It supports encrypted archives.") (substitute* "setup.py" (("cryptography>=35") "cryptography")))) - (add-after 'unpack 'adjust-for-click-8 - (lambda _ - (substitute* '("miio/integrations/vacuum/roborock/vacuum.py" - "miio/integrations/vacuum/roborock/vacuum_cli.py") - (("resultcallback") - "result_callback")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -1116,8 +1091,7 @@ backups. It supports encrypted archives.") python-sphinx-rtd-theme python-sphinxcontrib-apidoc)) (propagated-inputs - (list python-android-backup - python-appdirs + (list python-appdirs python-attrs python-click python-construct diff --git a/gnu/packages/animation.scm b/gnu/packages/animation.scm index 33fc3fcce9..4c03b78717 100644 --- a/gnu/packages/animation.scm +++ b/gnu/packages/animation.scm @@ -260,7 +260,7 @@ contains the graphical user interface for synfig.") ("python" ,python-wrapper))) (inputs `(("agg" ,agg) - ("atk" ,atk) + ("at-spi2-core" ,at-spi2-core) ("boost" ,boost) ("curl" ,curl) ("ffmpeg" ,ffmpeg-2.8) diff --git a/gnu/packages/aspell.scm b/gnu/packages/aspell.scm index 3482a756e0..83b54a2986 100644 --- a/gnu/packages/aspell.scm +++ b/gnu/packages/aspell.scm @@ -49,7 +49,6 @@ (package (name "aspell") (version "0.60.8") - (replacement aspell/replacement) (source (origin (method url-fetch) @@ -58,7 +57,8 @@ (sha256 (base32 "1wi60ankalmh8ds7nplz434jd7j94gdvbahdwsr539rlad8pxdzr")) - (patches (search-patches "aspell-default-dict-dir.patch")))) + (patches (search-patches "aspell-default-dict-dir.patch" + "aspell-CVE-2019-25051.patch")))) (build-system gnu-build-system) (arguments `(#:phases @@ -95,16 +95,6 @@ documents written in the UTF-8 encoding and its ability to use multiple dictionaries, including personal ones.") (license lgpl2.1+))) -;; Replacement package with security fixes. -(define aspell/replacement - (package - (inherit aspell) - (source - (origin - (inherit (package-source aspell)) - (patches (append (origin-patches (package-source aspell)) - (search-patches "aspell-CVE-2019-25051.patch"))))))) - ;;; ;;; Dictionaries. ;;; diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 97a3255ef9..888e5bb1d7 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1196,7 +1196,7 @@ accurately in real time at any rate desired.") python-ipython python-jplephem python-objgraph - python-pytest-7.1 + python-pytest python-pytest-astropy python-pytest-xdist python-setuptools-scm @@ -2680,7 +2680,7 @@ datetime object.") python-importlib-metadata python-importlib-resources python-jmespath - python-jsonschema-next + python-jsonschema python-lz4 python-numpy python-pyyaml)) @@ -2715,9 +2715,9 @@ implementation of the ASDF Standard.") (list "tests/test_manifests.py" "tests/test_integration.py"))))))) (native-inputs (list python-astropy - python-jsonschema-next + python-jsonschema python-pypa-build - python-pytest-7.1 + python-pytest python-packaging python-setuptools-scm)) (propagated-inputs (list python-importlib-resources)) @@ -2962,7 +2962,7 @@ install an implementation package such as gwcs.") (base32 "0v9qcq6zl74d6s882s6xmas144jfalvll6va8rvrxmvpx4vqjzhg")))) (build-system pyproject-build-system) (native-inputs - (list python-jsonschema-next + (list python-jsonschema python-jmespath python-pytest python-pytest-doctestplus diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 473b248c2e..33bc074a13 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -113,6 +113,7 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages pulseaudio) ;libsndfile, libsamplerate #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-science) #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) diff --git a/gnu/packages/autogen.scm b/gnu/packages/autogen.scm index 9751e11a64..f9575b0dc9 100644 --- a/gnu/packages/autogen.scm +++ b/gnu/packages/autogen.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2023 Kaelyn Takata <kaelyn.alexi@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -43,10 +44,15 @@ (base32 "16mlbdys8q4ckxlvxyhwkdnh1ay9f6g0cyp1kylkpalgnik398gq")) (modules '((guix build utils))) (snippet - ;; Address '-Werror=format-overflow' error. - '(substitute* "getdefs/getdefs.c" - (("def_bf\\[[[:space:]]*MAXNAMELEN[[:space:]]*\\]") - "def_bf[MAXNAMELEN + 10]"))))) + '(begin + ;; Address '-Werror=format-overflow' error. + (substitute* "getdefs/getdefs.c" + (("def_bf\\[[[:space:]]*MAXNAMELEN[[:space:]]*\\]") + "def_bf[MAXNAMELEN + 10]")) + ;; Address '-Werror=format-truncation' error on i686. + (substitute* "autoopts/usage.c" + (("vfmt\\[sizeof\\(vfmtfmt\\)\\]") + "vfmt[sizeof(vfmtfmt) + 6]")))))) (build-system gnu-build-system) (native-inputs (list pkg-config which)) (inputs (list guile-3.0 perl)) ; for doc generator mdoc diff --git a/gnu/packages/autotools.scm b/gnu/packages/autotools.scm index 006a9e202b..14fa42eefa 100644 --- a/gnu/packages/autotools.scm +++ b/gnu/packages/autotools.scm @@ -6,12 +6,13 @@ ;;; Copyright © 2015, 2017, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2016 David Thompson <davet@gnu.org> ;;; Copyright © 2017 Nikita <nikita@n0.is> -;;; Copyright © 2017, 2019, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017, 2019, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2019 Pierre-Moana Levesque <pierre.moana.levesque@gmail.com> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -40,6 +41,7 @@ #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) + #:use-module (guix gexp) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) #:use-module (ice-9 match) @@ -51,55 +53,55 @@ (version "2.69") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/autoconf/autoconf-" - version ".tar.xz")) - (sha256 - (base32 - "113nlmidxy9kjr45kg9x3ngar4951mvag1js2a3j8nxcz34wxsv4")))) + (method url-fetch) + (uri (string-append "mirror://gnu/autoconf/autoconf-" + version ".tar.xz")) + (sha256 + (base32 + "113nlmidxy9kjr45kg9x3ngar4951mvag1js2a3j8nxcz34wxsv4")))) (build-system gnu-build-system) (inputs - `(("bash" ,bash-minimal) - ("perl" ,perl) - ("m4" ,m4))) + (list bash-minimal m4 perl)) (native-inputs (list perl m4)) (arguments - `(;; XXX: testsuite: 209 and 279 failed. The latter is an impurity. It - ;; should use our own "cpp" instead of "/lib/cpp". - #:tests? #f - #:phases - (modify-phases %standard-phases - ,@(if (%current-target-system) - '((add-after 'install 'patch-non-shebang-references - (lambda* (#:key build inputs outputs #:allow-other-keys) - ;; `patch-shebangs' patches shebangs only, and the Perl - ;; scripts use a re-exec feature that references the - ;; build hosts' perl. Also, BASH and M4 store references - ;; hide in the scripts. - (let ((bash (assoc-ref inputs "bash")) - (m4 (assoc-ref inputs "m4")) - (perl (assoc-ref inputs "perl")) - (out (assoc-ref outputs "out")) - (store-directory (%store-directory))) - (substitute* (find-files (string-append out "/bin")) - (((string-append store-directory "/[^/]*-bash-[^/]*")) - bash) - (((string-append store-directory "/[^/]*-m4-[^/]*")) - m4) - (((string-append store-directory "/[^/]*-perl-[^/]*")) - perl)))))) - '()) - (add-after 'install 'unpatch-shebangs - (lambda* (#:key outputs #:allow-other-keys) - ;; Scripts that "autoconf -i" installs (config.guess, - ;; config.sub, and install-sh) must use a regular shebang - ;; rather than a reference to the store. Restore it. - (let* ((out (assoc-ref outputs "out")) - (build-aux (string-append - out "/share/autoconf/build-aux"))) - (substitute* (find-files build-aux) - (("^#!.*/bin/sh") "#!/bin/sh")))))))) + (list + ;; XXX: testsuite: 209 and 279 failed. The latter is an impurity. It + ;; should use our own "cpp" instead of "/lib/cpp". + #:tests? #f + #:phases + #~(modify-phases %standard-phases + #$@(if (%current-target-system) + '((add-after 'install 'patch-non-shebang-references + (lambda* (#:key build inputs #:allow-other-keys) + ;; `patch-shebangs' patches shebangs only, and the Perl + ;; scripts use a re-exec feature that references the + ;; build hosts' perl. Also, BASH and M4 store references + ;; hide in the scripts. + (let ((bash (dirname (dirname + (search-input-file inputs "bin/bash")))) + (m4 (dirname (dirname + (search-input-file inputs "bin/m4")))) + (perl (dirname (dirname + (search-input-file inputs "bin/perl")))) + (store-directory (%store-directory))) + (substitute* (find-files (string-append #$output "/bin")) + (((string-append store-directory "/[^/]*-bash-[^/]*")) + bash) + (((string-append store-directory "/[^/]*-m4-[^/]*")) + m4) + (((string-append store-directory "/[^/]*-perl-[^/]*")) + perl)))))) + '()) + (add-after 'install 'unpatch-shebangs + (lambda _ + ;; Scripts that "autoconf -i" installs (config.guess, + ;; config.sub, and install-sh) must use a regular shebang + ;; rather than a reference to the store. Restore it. + (let ((build-aux (string-append #$output + "/share/autoconf/build-aux"))) + (substitute* (find-files build-aux) + (("^#!.*/bin/sh") "#!/bin/sh")))))))) (home-page "https://www.gnu.org/software/autoconf/") (synopsis "Create source code configuration scripts") (description @@ -129,17 +131,17 @@ know anything about Autoconf or M4.") ;; FIXME: To run the test suite, fix all the instances where scripts ;; generates "#! /bin/sh" shebangs. #f) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-before 'check 'prepare-tests - (lambda _ - (for-each patch-shebang - (append (find-files "tests" - (lambda (file stat) - (executable-file? file))) - (find-files "bin" - (lambda (file stat) - (executable-file? file))))))))))))) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-before 'check 'prepare-tests + (lambda _ + (for-each patch-shebang + (append (find-files "tests" + (lambda (file stat) + (executable-file? file))) + (find-files "bin" + (lambda (file stat) + (executable-file? file))))))))))))) (define-public autoconf autoconf-2.69) @@ -203,70 +205,65 @@ know anything about Autoconf or M4.") use our own Bash instead of /bin/sh in shebangs. For that reason, it should only be used internally---users should not end up distributing `configure' files with a system-specific shebang." - (package (inherit autoconf) + (package + (inherit autoconf) (name (string-append (package-name autoconf) "-wrapper")) (build-system trivial-build-system) - (inputs `(("guile" - ;; XXX: Kludge to hide the circular dependency. - ,(module-ref (resolve-interface '(gnu packages guile)) - 'guile-3.0/pinned)) - ("autoconf" ,autoconf) - ("bash" ,bash-minimal))) + (inputs + (list + ;; XXX: Kludge to hide the circular dependency. + (module-ref (resolve-interface '(gnu packages guile)) + 'guile-3.0/pinned) + autoconf + bash-minimal)) (arguments - '(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin")) - (autoconf (string-append - (assoc-ref %build-inputs "autoconf") - "/bin/autoconf")) - (guile (string-append - (assoc-ref %build-inputs "guile") - "/bin/guile")) - (sh (string-append - (assoc-ref %build-inputs "bash") - "/bin/sh")) + (list + #:modules '((guix build utils)) + #:builder + #~(begin + (use-modules (guix build utils)) + (let ((bin (string-append #$output "/bin")) + (autoconf (search-input-file %build-inputs "/bin/autoconf")) + (guile (search-input-file %build-inputs "/bin/guile")) + (sh (search-input-file %build-inputs "/bin/sh")) (modules ((compose dirname dirname dirname) (search-path %load-path "guix/build/utils.scm")))) - (mkdir-p bin) - - ;; Symlink all the binaries but `autoconf'. - (with-directory-excursion bin - (for-each (lambda (file) - (unless (string=? (basename file) "autoconf") - (symlink file (basename file)))) - (find-files (dirname autoconf) ".*"))) - - ;; Add an `autoconf' binary that wraps the real one. - (call-with-output-file (string-append bin "/autoconf") - (lambda (port) - ;; Shamefully, Guile can be used in shebangs only if a - ;; single argument is passed (-ds); otherwise it gets - ;; them all as a single argument and fails to parse them. - (format port "#!~a + (mkdir-p bin) + + ;; Symlink all the binaries but `autoconf'. + (with-directory-excursion bin + (for-each (lambda (file) + (unless (string=? (basename file) "autoconf") + (symlink file (basename file)))) + (find-files (dirname autoconf) ".*"))) + + ;; Add an `autoconf' binary that wraps the real one. + (call-with-output-file (string-append bin "/autoconf") + (lambda (port) + ;; Shamefully, Guile can be used in shebangs only if a + ;; single argument is passed (-ds); otherwise it gets + ;; them all as a single argument and fails to parse them. + (format port "#!~a export GUILE_LOAD_PATH=\"~a\" export GUILE_LOAD_COMPILED_PATH=\"~a\" exec ~a --no-auto-compile \"$0\" \"$@\" !#~%" - sh modules modules guile) - (write - `(begin - (use-modules (guix build utils)) - (let ((result (apply system* ,autoconf - (cdr (command-line))))) - (when (and (file-exists? "configure") - (not (file-exists? "/bin/sh"))) - ;; Patch regardless of RESULT, because `autoconf - ;; -Werror' can both create a `configure' file and - ;; return a non-zero exit code. - (patch-shebang "configure")) - (exit (status:exit-val result)))) - port))) - (chmod (string-append bin "/autoconf") #o555) - #t)))) + sh modules modules guile) + (write + `(begin + (use-modules (guix build utils)) + (let ((result (apply system* ,autoconf + (cdr (command-line))))) + (when (and (file-exists? "configure") + (not (file-exists? "/bin/sh"))) + ;; Patch regardless of RESULT, because `autoconf + ;; -Werror' can both create a `configure' file and + ;; return a non-zero exit code. + (patch-shebang "configure")) + (exit (status:exit-val result)))) + port))) + (chmod (string-append bin "/autoconf") #o555))))) ;; Do not show it in the UI since it's meant for internal use. (properties '((hidden? . #t))))) @@ -279,7 +276,7 @@ exec ~a --no-auto-compile \"$0\" \"$@\" (define-public autoconf-archive (package (name "autoconf-archive") - (version "2021.02.19") + (version "2022.09.03") (source (origin (method url-fetch) @@ -287,7 +284,7 @@ exec ~a --no-auto-compile \"$0\" \"$@\" version ".tar.xz")) (sha256 (base32 - "1gcwqspcxiygnyk02smsk8ivzs9r69ji38izxzzsijyx52fyp9p8")))) + "08zl68xdd907fb1r8kb88ycq09w9g53hfbflpq3pkblc1pq58x70")))) (build-system gnu-build-system) (home-page "https://www.gnu.org/software/autoconf-archive/") (synopsis "Collection of freely reusable Autoconf macros") @@ -324,107 +321,104 @@ output is indexed in many ways to simplify browsing.") (define-public automake (package (name "automake") - (version "1.16.3") + (version "1.16.5") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/automake/automake-" - version ".tar.xz")) - (sha256 - (base32 - "0fmz2fhmzcpacnprl5msphvaflwiy0hvpgmqlgfny72ddijzfazz")) - (patches - (search-patches "automake-skip-amhello-tests.patch")))) + (method url-fetch) + (uri (string-append "mirror://gnu/automake/automake-" + version ".tar.xz")) + (sha256 + (base32 + "0sdl32qxdy7m06iggmkkvf7j520rmmgbsjzbm7fgnxwxdp6mh7gh")) + (patches + (search-patches "automake-skip-amhello-tests.patch")))) (build-system gnu-build-system) (inputs - `(("autoconf" ,autoconf-wrapper) - ("bash" ,bash-minimal) - ("perl" ,perl))) + (list autoconf-wrapper bash-minimal perl)) (native-inputs - `(("autoconf" ,autoconf-wrapper) - ("perl" ,perl))) + (list autoconf-wrapper perl)) (native-search-paths (list (search-path-specification (variable "ACLOCAL_PATH") (files '("share/aclocal"))))) (arguments - `(#:modules ((guix build gnu-build-system) + (list + #:modules '((guix build gnu-build-system) (guix build utils) (srfi srfi-1) (srfi srfi-26) (rnrs io ports)) - #:phases - (modify-phases %standard-phases - (add-before 'patch-source-shebangs 'patch-tests-shebangs - (lambda _ - (let ((sh (which "sh"))) - (substitute* (find-files "t" "\\.(sh|tap)$") - (("#![[:blank:]]?/bin/sh") - (string-append "#!" sh))) - - ;; Set these variables for all the `configure' runs - ;; that occur during the test suite. - (setenv "SHELL" sh) - (setenv "CONFIG_SHELL" sh) - #t))) - - (add-before 'check 'skip-test - (lambda _ - ;; This test requires 'etags' and fails if it's missing. - ;; Skip it. - (substitute* "t/tags-lisp-space.sh" - (("^required.*" all) - (string-append "exit 77\n" all "\n"))) - #t)) - - ,@(if (%current-target-system) - `((add-after 'install 'patch-non-shebang-references - (lambda* (#:key build inputs outputs #:allow-other-keys) - ;; `patch-shebangs' patches shebangs only, and the Perl - ;; scripts use a re-exec feature that references the - ;; build hosts' perl. Also, AUTOCONF and BASH store - ;; references hide in the scripts. - (let ((autoconf (assoc-ref inputs "autoconf")) - (bash (assoc-ref inputs "bash")) - (perl (assoc-ref inputs "perl")) - (out (assoc-ref outputs "out")) + #:phases + #~(modify-phases %standard-phases + (add-before 'patch-source-shebangs 'patch-tests-shebangs + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (let ((sh (search-input-file (or native-inputs inputs) "bin/sh"))) + (substitute* (find-files "t" "\\.(sh|tap)$") + (("#![[:blank:]]?/bin/sh") + (string-append "#!" sh))) + + ;; Set these variables for all the `configure' runs + ;; that occur during the test suite. + (setenv "SHELL" sh) + (setenv "CONFIG_SHELL" sh)))) + (add-before 'check 'skip-test + (lambda _ + ;; This test requires 'etags' and fails if it's missing. + ;; Skip it. + (substitute* "t/tags-lisp-space.sh" + (("^required.*" all) + (string-append "exit 77\n" all "\n"))))) + + #$@(if (%current-target-system) + '((add-after 'install 'patch-non-shebang-references + (lambda* (#:key inputs #:allow-other-keys) + ;; `patch-shebangs' patches shebangs only, and the Perl + ;; scripts use a re-exec feature that references the + ;; build hosts' perl. Also, AUTOCONF and BASH store + ;; references hide in the scripts. + (let ((autoconf + (dirname (dirname + (search-input-file inputs "bin/autoconf")))) + (bash + (dirname (dirname + (search-input-file inputs "bin/bash")))) + (perl + (dirname (dirname + (search-input-file inputs "bin/perl")))) (store-directory (%store-directory))) - (substitute* (find-files (string-append out "/bin")) + (substitute* (find-files (string-append #$output "/bin")) (((string-append store-directory "/[^/]*-autoconf-[^/]*")) autoconf) (((string-append store-directory "/[^/]*-bash-[^/]*")) bash) (((string-append store-directory "/[^/]*-perl-[^/]*")) - perl)) - #t)))) + perl)))))) '()) - ;; Files like `install-sh', `mdate.sh', etc. must use - ;; #!/bin/sh, otherwise users could leak erroneous shebangs - ;; in the wild. See <http://bugs.gnu.org/14201> for an - ;; example. - (add-after 'install 'unpatch-shebangs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (dir (string-append out "/share"))) - (define (starts-with-shebang? file) - (equal? (call-with-input-file file - (lambda (p) - (list (get-u8 p) (get-u8 p)))) - (map char->integer '(#\# #\!)))) - - (for-each (lambda (file) - (when (and (starts-with-shebang? file) - (executable-file? file)) - (format #t "restoring shebang on `~a'~%" - file) - (substitute* file - (("^#!.*/bin/sh") - "#!/bin/sh") - (("^#!.*/bin/env(.*)$" _ args) - (string-append "#!/usr/bin/env" - args))))) - (find-files dir ".*")) - #t)))))) + ;; Files like `install-sh', `mdate.sh', etc. must use + ;; #!/bin/sh, otherwise users could leak erroneous shebangs + ;; in the wild. See <http://bugs.gnu.org/14201> for an + ;; example. + (add-after 'install 'unpatch-shebangs + (lambda _ + (let ((dir (string-append #$output "/share"))) + (define (starts-with-shebang? file) + (equal? (call-with-input-file file + (lambda (p) + (list (get-u8 p) (get-u8 p)))) + (map char->integer '(#\# #\!)))) + + (for-each (lambda (file) + (when (and (starts-with-shebang? file) + (executable-file? file)) + (format #t "restoring shebang on `~a'~%" + file) + (substitute* file + (("^#!.*/bin/sh") + "#!/bin/sh") + (("^#!.*/bin/env(.*)$" _ args) + (string-append "#!/usr/bin/env" + args))))) + (find-files dir ".*")))))))) (home-page "https://www.gnu.org/software/automake/") (synopsis "Making GNU standards-compliant Makefiles") (description @@ -434,42 +428,30 @@ intuitive format and then Automake works with Autoconf to produce a robust Makefile, simplifying the entire process for the developer.") (license gpl2+))) ; some files are under GPLv3+ -(define-public automake-1.16.5 - (package - (inherit automake) - (version "1.16.5") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/automake/automake-" - version ".tar.xz")) - (sha256 - (base32 - "0sdl32qxdy7m06iggmkkvf7j520rmmgbsjzbm7fgnxwxdp6mh7gh")) - (patches - (search-patches "automake-skip-amhello-tests.patch")))))) - (define-public libtool (package (name "libtool") - (version "2.4.6") + (version "2.4.7") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/libtool/libtool-" version ".tar.xz")) (sha256 (base32 - "0vxj52zm709125gwv9qqlw02silj8bnjnh4y07arrz60r31ai1vw")) - (patches (search-patches "libtool-skip-tests2.patch")))) + "0pb3l4x37k6fj1lwnpzws55gi3pxl0hx56jm4bzmbrkw0mzj2zsg")) + (patches (search-patches "libtool-skip-tests2.patch" + "libtool-grep-compat.patch")))) (build-system gnu-build-system) (propagated-inputs (list m4)) - (native-inputs `(("m4" ,m4) - ("perl" ,perl) - ;; XXX: this shouldn't be necessary, but without it test - ;; 102 fails because it cannot find ltdl/libltdl.la. - ("libltdl" ,libltdl) - ("help2man" ,help2man) ;because we modify ltmain.sh - ("automake" ,automake) ;some tests rely on 'aclocal' - ("autoconf" ,autoconf-wrapper))) ;others on 'autom4te' + (native-inputs + (list m4 + perl + ;; XXX: this shouldn't be necessary, but without it test + ;; 102 fails because it cannot find ltdl/libltdl.la. + libltdl + help2man ; because we modify ltmain.sh + automake ; some tests rely on 'aclocal' + autoconf-wrapper)) ; others on 'autom4te' (arguments `(;; Libltdl is provided as a separate package, so don't install it here. @@ -485,18 +467,18 @@ Makefile, simplifying the entire process for the developer.") #:phases (modify-phases %standard-phases (add-before 'check 'pre-check - (lambda* (#:key inputs native-inputs #:allow-other-keys) + (lambda* (#:key inputs native-inputs parallel-tests? #:allow-other-keys) ;; Run the test suite in parallel, if possible. (setenv "TESTSUITEFLAGS" (string-append "-j" - (number->string (parallel-job-count)))) + (if parallel-tests? + (number->string (parallel-job-count)) + "1"))) ;; Patch references to /bin/sh. - (let ((bash (assoc-ref (or native-inputs inputs) "bash"))) + (let ((/bin/sh (search-input-file (or native-inputs inputs) "bin/sh"))) (substitute* "tests/testsuite" - (("/bin/sh") - (string-append bash "/bin/sh"))) - #t))) + (("/bin/sh") /bin/sh))))) ;; These files may be copied into source trees by libtoolize, ;; therefore they must not point to store file names that would be ;; leaked with tarballs generated by make dist. @@ -508,8 +490,7 @@ Makefile, simplifying the entire process for the developer.") (format #t "restoring shebang on `~a'~%" file) (substitute* file (("^#!.*/bin/sh") "#!/bin/sh"))) - (find-files dir ".*")) - #t)))))) + (find-files dir)))))))) (synopsis "Generic shared library support tools") (description @@ -519,18 +500,6 @@ complexity of working with shared libraries across platforms.") (license gpl3+) (home-page "https://www.gnu.org/software/libtool/"))) -(define-public libtool-2.4.7 - (package - (inherit libtool) - (version "2.4.7") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/libtool/libtool-" - version ".tar.xz")) - (sha256 - (base32 - "0pb3l4x37k6fj1lwnpzws55gi3pxl0hx56jm4bzmbrkw0mzj2zsg")))))) - (define-public config (let ((revision "1") (commit "c8ddc8472f8efcadafc1ef53ca1d863415fddd5f")) @@ -585,20 +554,20 @@ configuration in nearly all GNU packages (and many others).") ;; Libtool's extensive test suite isn't run. (package (name "libltdl") - (version "2.4.6") + (version "2.4.7") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/libtool/libtool-" version ".tar.xz")) (sha256 (base32 - "0vxj52zm709125gwv9qqlw02silj8bnjnh4y07arrz60r31ai1vw")))) + "0pb3l4x37k6fj1lwnpzws55gi3pxl0hx56jm4bzmbrkw0mzj2zsg")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--enable-ltdl-install") ;really install it #:phases (modify-phases %standard-phases (add-before 'configure 'change-directory - (lambda _ (chdir "libltdl") #t))))) + (lambda _ (chdir "libltdl")))))) (synopsis "System-independent dlopen wrapper of GNU libtool") (description (package-description libtool)) diff --git a/gnu/packages/aux-files/python/sanity-check-next.py b/gnu/packages/aux-files/python/sanity-check-next.py deleted file mode 100644 index a206b51d0a..0000000000 --- a/gnu/packages/aux-files/python/sanity-check-next.py +++ /dev/null @@ -1,99 +0,0 @@ -# -*- coding: utf-8 -*- -# GNU Guix --- Functional package management for GNU -# Copyright © 2021, 2022 Lars-Dominik Braun <lars@6xq.net> -# -# This file is part of GNU Guix. -# -# GNU Guix is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or (at -# your option) any later version. -# -# GNU Guix is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. - -# This version adds a small change to accommodate missing python-setuptools. -# TODO: Merge with sanity-check.py in the next core-updates cycle. - -from __future__ import print_function # Python 2 support. -import importlib -import sys -import traceback -try: - import pkg_resources -except ImportError: - print('Warning: Skipping, because python-setuptools are not available.') - sys.exit(0) - -try: - from importlib.machinery import PathFinder -except ImportError: - PathFinder = None - -ret = 0 - -# Only check site-packages installed by this package, but not dependencies -# (which pkg_resources.working_set would include). Path supplied via argv. -ws = pkg_resources.find_distributions(sys.argv[1]) - -for dist in ws: - print('validating', repr(dist.project_name), dist.location) - try: - print('...checking requirements: ', end='') - req = str(dist.as_requirement()) - # dist.activate() is not enough to actually check requirements, we - # have to .require() it. - pkg_resources.require(req) - print('OK') - except Exception as e: - print('ERROR:', req, repr(e)) - ret = 1 - continue - - # Try to load top level modules. This should not have any side-effects. - try: - metalines = dist.get_metadata_lines('top_level.txt') - except (KeyError, EnvironmentError): - # distutils (i.e. #:use-setuptools? #f) will not install any metadata. - # This file is also missing for packages built using a PEP 517 builder - # such as poetry. - print('WARNING: cannot determine top-level modules') - continue - for name in metalines: - # Only available on Python 3. - if PathFinder and PathFinder.find_spec(name) is None: - # Ignore unavailable modules, often C modules, which were not - # installed at the top-level. Cannot use ModuleNotFoundError, - # because it is raised by failed imports too. - continue - try: - print('...trying to load module', name, end=': ') - importlib.import_module(name) - print('OK') - except Exception: - print('ERROR:') - traceback.print_exc(file=sys.stdout) - ret = 1 - - # Try to load entry points of console scripts too, making sure they - # work. They should be removed if they don't. Other groups may not be - # safe, as they can depend on optional packages. - for group, v in dist.get_entry_map().items(): - if group not in {'console_scripts', 'gui_scripts'}: - continue - for name, ep in v.items(): - try: - print('...trying to load endpoint', group, name, end=': ') - ep.load() - print('OK') - except Exception: - print('ERROR:') - traceback.print_exc(file=sys.stdout) - ret = 1 - -sys.exit(ret) diff --git a/gnu/packages/aux-files/python/sanity-check.py b/gnu/packages/aux-files/python/sanity-check.py index 182133bb3d..9c39709e18 100644 --- a/gnu/packages/aux-files/python/sanity-check.py +++ b/gnu/packages/aux-files/python/sanity-check.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- # GNU Guix --- Functional package management for GNU -# Copyright © 2021 Lars-Dominik Braun <lars@6xq.net> +# Copyright © 2021, 2022 Lars-Dominik Braun <lars@6xq.net> # # This file is part of GNU Guix. # @@ -19,9 +19,13 @@ from __future__ import print_function # Python 2 support. import importlib -import pkg_resources import sys import traceback +try: + import pkg_resources +except ImportError: + print('Warning: Skipping, because python-setuptools are not available.') + sys.exit(0) try: from importlib.machinery import PathFinder diff --git a/gnu/packages/aux-files/xml/docbook-xml/catalog-4.1.2.xml b/gnu/packages/aux-files/xml/docbook-xml/catalog-4.1.2.xml new file mode 100644 index 0000000000..cfb1849202 --- /dev/null +++ b/gnu/packages/aux-files/xml/docbook-xml/catalog-4.1.2.xml @@ -0,0 +1,31 @@ +<?xml version="1.0"?> +<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd"> +<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog"> + <public publicId="-//OASIS//DTD DocBook XML V4.1.2//EN" uri="docbookx.dtd"/> + <public publicId="-//OASIS//DTD DocBook XML CALS Table Model V4.1.2//EN" uri="calstblx.dtd"/> + <public publicId="-//OASIS//DTD XML Exchange Table Model 19990315//EN" uri="soextblx.dtd"/> + <public publicId="-//OASIS//ELEMENTS DocBook XML Information Pool V4.1.2//EN" uri="dbpoolx.mod"/> + <public publicId="-//OASIS//ELEMENTS DocBook XML Document Hierarchy V4.1.2//EN" uri="dbhierx.mod"/> + <public publicId="-//OASIS//ENTITIES DocBook XML Additional General Entities V4.1.2//EN" uri="dbgenent.mod"/> + <public publicId="-//OASIS//ENTITIES DocBook XML Notations V4.1.2//EN" uri="dbnotnx.mod"/> + <public publicId="-//OASIS//ENTITIES DocBook XML Character Entities V4.1.2//EN" uri="dbcentx.mod"/> + <public publicId="ISO 8879:1986//ENTITIES Diacritical Marks//EN" uri="ent/iso-dia.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Numeric and Special Graphic//EN" uri="ent/iso-num.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Publishing//EN" uri="ent/iso-pub.ent"/> + <public publicId="ISO 8879:1986//ENTITIES General Technical//EN" uri="ent/iso-tech.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Latin 1//EN" uri="ent/iso-lat1.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Latin 2//EN" uri="ent/iso-lat2.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Greek Letters//EN" uri="ent/iso-grk1.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Monotoniko Greek//EN" uri="ent/iso-grk2.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Greek Symbols//EN" uri="ent/iso-grk3.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Alternative Greek Symbols//EN" uri="ent/iso-grk4.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Arrow Relations//EN" uri="ent/iso-amsa.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Binary Operators//EN" uri="ent/iso-amsb.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Delimiters//EN" uri="ent/iso-amsc.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Negated Relations//EN" uri="ent/iso-amsn.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Ordinary//EN" uri="ent/iso-amso.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Added Math Symbols: Relations//EN" uri="ent/iso-amsr.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Box and Line Drawing//EN" uri="ent/iso-box.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Russian Cyrillic//EN" uri="ent/iso-cyr1.ent"/> + <public publicId="ISO 8879:1986//ENTITIES Non-Russian Cyrillic//EN" uri="ent/iso-cyr2.ent"/> +</catalog> diff --git a/gnu/packages/aux-files/xml/patch-catalog-xml.xsl b/gnu/packages/aux-files/xml/patch-catalog-xml.xsl new file mode 100644 index 0000000000..947517476d --- /dev/null +++ b/gnu/packages/aux-files/xml/patch-catalog-xml.xsl @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- +SPDX-FileCopyrightText: 2023 Bruno Victal <mirai@makinata.eu> +SPDX-License-Identifier: ISC + +Fix uri attributes to point to paths in the store. +--> +<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> + <xsl:output method="xml"/> + <xsl:param name="prefix">/</xsl:param> + <!-- begin identity transform --> + <xsl:template match="@*|node()"> + <xsl:copy> + <xsl:apply-templates select="@*|node()"/> + </xsl:copy> + </xsl:template> + <!-- end identity transform --> + + <xsl:template match="@uri"> + <xsl:attribute name="uri"> + <xsl:value-of select="concat('file://', $prefix, '/', .)"/> + </xsl:attribute> + </xsl:template> +</xsl:stylesheet> diff --git a/gnu/packages/avr.scm b/gnu/packages/avr.scm index a741f183d7..44d6e0ebbb 100644 --- a/gnu/packages/avr.scm +++ b/gnu/packages/avr.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014, 2016 Manolis Fragkiskos Ragkousis <manolis837@gmail.com> -;;; Copyright © 2015, 2017 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2015, 2017, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2016 David Thompson <davet@gnu.org> ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> @@ -24,6 +24,7 @@ (define-module (gnu packages avr) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix download) #:use-module (guix git-download) @@ -52,34 +53,32 @@ (arguments (substitute-keyword-arguments (package-arguments xgcc) ((#:phases phases) - `(modify-phases ,phases - (add-after 'set-paths 'augment-CPLUS_INCLUDE_PATH - (lambda* (#:key inputs #:allow-other-keys) - (let ((gcc (assoc-ref inputs "gcc"))) - ;; Remove the default compiler from CPLUS_INCLUDE_PATH to - ;; prevent header conflict with the GCC from native-inputs. - (setenv "CPLUS_INCLUDE_PATH" - (string-join - (delete (string-append gcc "/include/c++") - (string-split (getenv "CPLUS_INCLUDE_PATH") - #\:)) - ":")) - (format #t - "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%" - (getenv "CPLUS_INCLUDE_PATH")) - #t))) - ;; Without a working multilib build, the resulting GCC lacks - ;; support for nearly every AVR chip. - (add-after 'unpack 'fix-genmultilib - (lambda _ - ;; patch-shebang doesn't work here because there are actually - ;; several scripts inside this script, each with a #!/bin/sh - ;; that needs patching. - (substitute* "gcc/genmultilib" - (("#!/bin/sh") (string-append "#!" (which "sh")))) - #t)))) + #~(modify-phases #$phases + (add-after 'set-paths 'augment-CPLUS_INCLUDE_PATH + (lambda* (#:key inputs #:allow-other-keys) + (let ((gcc (assoc-ref inputs "gcc"))) + ;; Remove the default compiler from CPLUS_INCLUDE_PATH to + ;; prevent header conflict with the GCC from native-inputs. + (setenv "CPLUS_INCLUDE_PATH" + (string-join + (delete (string-append gcc "/include/c++") + (string-split (getenv "CPLUS_INCLUDE_PATH") + #\:)) + ":")) + (format #t + "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%" + (getenv "CPLUS_INCLUDE_PATH"))))) + ;; Without a working multilib build, the resulting GCC lacks + ;; support for nearly every AVR chip. + (add-after 'unpack 'fix-genmultilib + (lambda _ + ;; patch-shebang doesn't work here because there are actually + ;; several scripts inside this script, each with a #!/bin/sh + ;; that needs patching. + (substitute* "gcc/genmultilib" + (("#!/bin/sh") (string-append "#!" (which "sh")))))))) ((#:configure-flags flags) - `(delete "--disable-multilib" ,flags)))) + #~(delete "--disable-multilib" #$flags)))) (native-search-paths (list (search-path-specification (variable "CROSS_C_INCLUDE_PATH") diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm index 134647d33d..b545b9c370 100644 --- a/gnu/packages/backup.scm +++ b/gnu/packages/backup.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2018 Oleg Pykhalov <go.wigust@gmail.com> ;;; Copyright © 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2019 Alex Vong <alexvong1995@gmail.com> -;;; Copyright © 2019 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2019, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020, 2022 Nicolas Goaziou <mail@nicolasgoaziou.fr> ;;; Copyright © 2020 Marcin Karpezo <sirmacik@wioo.waw.pl> @@ -238,7 +238,7 @@ backups (called chunks) to allow easy burning to CD/DVD.") (define-public libarchive (package (name "libarchive") - (version "3.5.1") + (version "3.6.1") (source (origin (method url-fetch) @@ -249,7 +249,7 @@ backups (called chunks) to allow easy burning to CD/DVD.") version ".tar.xz"))) (sha256 (base32 - "16r95rlmikll1k8vbhh06vq6x3srkc10hzxjjf3021mjs2ld65qf")))) + "1rj8q5v26lxxr8x4b4nqbrj7p06qvl91hb8cdxi3xx3qp771lhas")))) (build-system gnu-build-system) (inputs (list bzip2 @@ -260,69 +260,59 @@ backups (called chunks) to allow easy burning to CD/DVD.") zlib `(,zstd "lib"))) (arguments - `(#:configure-flags '("--disable-static") - #:phases - (modify-phases %standard-phases - (add-before 'build 'patch-pwd - (lambda _ - (substitute* "Makefile" - (("/bin/pwd") (which "pwd"))) - #t)) - (replace 'check - (lambda* (#:key (tests? #t) #:allow-other-keys) - (if tests? - ;; XXX: The test_owner_parse, test_read_disk, and - ;; test_write_disk_lookup tests expect user 'root' to - ;; exist, but the chroot's /etc/passwd doesn't have - ;; it. Turn off those tests. - ;; - ;; XXX: Adjust test that fails with zstd 1.4.1 - ;; because the default options compresses two bytes - ;; better than this test expects. - ;; https://github.com/libarchive/libarchive/issues/1226 - (begin - (substitute* "libarchive/test/test_write_filter_zstd.c" - (("compression-level\", \"6\"") - "compression-level\", \"7\"")) - - ;; The tests allow one to disable tests matching a globbing pattern. - (invoke "make" - "libarchive_test" - "bsdcpio_test" - "bsdtar_test") + (list + #:configure-flags #~'("--disable-static") + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'patch-pwd + (lambda _ + (substitute* "Makefile" + (("/bin/pwd") (which "pwd"))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (if tests? + ;; XXX: The test_owner_parse, test_read_disk, and + ;; test_write_disk_lookup tests expect user 'root' to + ;; exist, but the chroot's /etc/passwd doesn't have + ;; it. Turn off those tests. + (begin + ;; The tests allow one to disable tests matching a globbing pattern. + (invoke "make" + "libarchive_test" + "bsdcpio_test" + "bsdtar_test") - ;; XXX: This glob disables too much. - (invoke "./libarchive_test" "^test_*_disk*") - (invoke "./bsdcpio_test" "^test_owner_parse") - (invoke "./bsdtar_test")) - ;; Tests may be disabled if cross-compiling. - (format #t "Test suite not run.~%")))) - (add-after 'install 'add--L-in-libarchive-pc - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lib (string-append out "/lib")) - (nettle (assoc-ref inputs "nettle")) - (libxml2 (assoc-ref inputs "libxml2")) - (xz (assoc-ref inputs "xz")) - (zlib (assoc-ref inputs "zlib")) - (zstd (assoc-ref inputs "zstd")) - (bzip2 (assoc-ref inputs "bzip2"))) - ;; Embed absolute references to these inputs to avoid propagation. - (substitute* (list (string-append lib "/pkgconfig/libarchive.pc") - (string-append lib "/libarchive.la")) - (("-lnettle") - (string-append "-L" nettle "/lib -lnettle")) - (("-lxml2") - (string-append "-L" libxml2 "/lib -lxml2")) - (("-llzma") - (string-append "-L" xz "/lib -llzma")) - (("-lz") - (string-append "-L" zlib "/lib -lz")) - (("-lzstd") - (string-append "-L" zstd "/lib -lzstd")) - (("-lbz2") - (string-append "-L" bzip2 "/lib -lbz2"))) - #t)))))) + ;; XXX: This glob disables too much. + (invoke "./libarchive_test" "^test_*_disk*") + (invoke "./bsdcpio_test" "^test_owner_parse") + (invoke "./bsdtar_test")) + ;; Tests may be disabled if cross-compiling. + (format #t "Test suite not run.~%")))) + (add-after 'install 'add--L-in-libarchive-pc + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out #$output) + (lib (string-append out "/lib")) + (nettle (assoc-ref inputs "nettle")) + (libxml2 (assoc-ref inputs "libxml2")) + (xz (assoc-ref inputs "xz")) + (zlib (assoc-ref inputs "zlib")) + (zstd (assoc-ref inputs "zstd")) + (bzip2 (assoc-ref inputs "bzip2"))) + ;; Embed absolute references to these inputs to avoid propagation. + (substitute* (list (string-append lib "/pkgconfig/libarchive.pc") + (string-append lib "/libarchive.la")) + (("-lnettle") + (string-append "-L" nettle "/lib -lnettle")) + (("-lxml2") + (string-append "-L" libxml2 "/lib -lxml2")) + (("-llzma") + (string-append "-L" xz "/lib -llzma")) + (("-lz") + (string-append "-L" zlib "/lib -lz")) + (("-lzstd") + (string-append "-L" zstd "/lib -lzstd")) + (("-lbz2") + (string-append "-L" bzip2 "/lib -lbz2"))))))))) (home-page "https://libarchive.org/") (synopsis "Multi-format archive and compression library") (description diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm index fa5f1ef32b..6911ea78be 100644 --- a/gnu/packages/base.scm +++ b/gnu/packages/base.scm @@ -5,12 +5,12 @@ ;;; Copyright © 2014, 2015, 2016, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2014 Alex Kost <alezost@gmail.com> ;;; Copyright © 2014, 2015 Manolis Fragkiskos Ragkousis <manolis837@gmail.com> -;;; Copyright © 2016, 2017, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2017, 2019-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2016, 2018 Alex Vong <alexvong1995@gmail.com> ;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org> ;;; Copyright © 2017, 2020 Mathieu Othacehe <m.othacehe@gmail.com> -;;; Copyright © 2017, 2018, 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2017, 2018, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018, 2019, 2022 Ricardo Wurmus <rekado@elephly.net> @@ -20,6 +20,7 @@ ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022 zamfofex <zamfofex@twdb.moe> ;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com> ;;; ;;; This file is part of GNU Guix. @@ -106,14 +107,14 @@ command-line arguments, multiple languages, and so on.") (define-public grep (package (name "grep") - (version "3.6") + (version "3.8") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/grep/grep-" version ".tar.xz")) (sha256 (base32 - "0gipv6bzkm1aihj0ncqpyh164xrzgcxcv9r1kwzyk2g1mzl1azk6")) + "10n3mc9n1xmg85hpxyr4wiqzfp27ffxzwhvkv021j27vnk0pr3a9")) (patches (search-patches "grep-timing-sensitive-test.patch")))) (build-system gnu-build-system) (native-inputs (list perl)) ;some of the tests require it @@ -215,9 +216,10 @@ implementation offers several extensions over the standard utility.") (build-system gnu-build-system) ;; Note: test suite requires ~1GiB of disk space. (arguments - `(,@(if (hurd-target?) - '(#:make-flags - (list (string-append + `(,@(cond + ((hurd-target?) + '(#:make-flags + (list (string-append "TESTSUITEFLAGS= -k '" "!sparse" ",!renamed dirs in incrementals" @@ -230,8 +232,13 @@ implementation offers several extensions over the standard utility.") ",!renamed subdirectories" ",!chained renames" ",!Directory" - "'"))) - '()) + "'")))) + ;; https://lists.gnu.org/archive/html/bug-tar/2021-10/msg00007.html + ;; tar-1.34 isn't aware of 64-bit time_t and upstream suggests + ;; skipping the test for this release on 32-bit systems. + ((not (target-64bit?)) + '(#:make-flags (list "TESTSUITEFLAGS= -k '!tricky time stamps'"))) + (else '())) #:phases (modify-phases %standard-phases (add-before 'build 'set-shell-file-name (lambda* (#:key inputs #:allow-other-keys) @@ -319,14 +326,14 @@ interactive means to merge two files.") (define-public findutils (package (name "findutils") - (version "4.8.0") + (version "4.9.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/findutils/findutils-" version ".tar.xz")) (sha256 (base32 - "0r3i72hnw0a30khlczi9k2c51aamaj6kfmp5mk3844nrjxz7n4jp")) + "1zk2sighc26bfdsm97bv7cd1cnvq7r4gll4zqpnp0rs3kp0bigx2")) (patches (search-patches "findutils-localstatedir.patch")))) (build-system gnu-build-system) (arguments @@ -357,16 +364,14 @@ used to apply commands with arbitrarily long arguments.") (define-public coreutils (package (name "coreutils") - (version "8.32") + (version "9.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/coreutils/coreutils-" version ".tar.xz")) (sha256 (base32 - "1yjcrh5hw70c0yn8zw55pd6j51dj90anpq8mmg649ps9g3gdhn24")) - (patches (search-patches "coreutils-ls.patch" - "coreutils-gnulib-tests.patch")))) + "08q4b0w7mwfxbqjs712l6wrwl2ijs7k50kssgbryg9wbsw8g98b1")))) (build-system gnu-build-system) (inputs `(,acl ;TODO: add SELinux ,attr ;for xattrs in ls, mv, etc @@ -411,6 +416,10 @@ used to apply commands with arbitrarily long arguments.") " test-renameatu" " test-utimensat"))) '()) + ,@(if (not (target-64bit?)) + ;; Not all software is ready for 64bit time_t. + '(#:configure-flags (list "--disable-year2038")) + '()) #:phases (modify-phases %standard-phases (add-before 'build 'patch-shell-references (lambda _ @@ -554,17 +563,15 @@ change. GNU make offers many powerful extensions over the standard utility.") (define-public binutils (package (name "binutils") - (version "2.37") + (version "2.38") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/binutils/binutils-" version ".tar.bz2")) (sha256 - (base32 "1m3b2rdfv1dmdpd0bzg1hy7i8a2qng53szc6livyi3nh6101mz37")) - (patches (search-patches "binutils-loongson-workaround.patch" - "binutils-2.37-file-descriptor-leak.patch" - "binutils-CVE-2021-45078.patch")))) + (base32 "1y0fb4qgxaxfyf81x9fqq9w5609mkah0b7wm1f7ab9kpy0fcf3h7")) + (patches (search-patches "binutils-loongson-workaround.patch")))) (build-system gnu-build-system) (arguments `(#:out-of-source? #t ;recommended in the README @@ -593,7 +600,16 @@ change. GNU make offers many powerful extensions over the standard utility.") "--enable-compressed-debug-sections=all" "--enable-lto" "--enable-separate-code" - "--enable-threads"))) + "--enable-threads") + ;; XXX: binutils 2.38 was released without generated manuals: + ;; <https://sourceware.org/bugzilla/show_bug.cgi?id=28909>. To avoid + ;; a circular dependency on texinfo, prevent the build system from + ;; creating the manuals by calling "true" instead of "makeinfo" ... + #:make-flags '("MAKEINFO=true"))) + + ;; ... and "hide" this package such that users who install binutils get + ;; the version with documentation defined below. + (properties '((hidden? . #t))) (synopsis "Binary utilities: bfd gas gprof ld") (description @@ -606,6 +622,16 @@ included.") (license gpl3+) (home-page "https://www.gnu.org/software/binutils/"))) +(define-public binutils+documentation + (package/inherit binutils + (native-inputs + (list texinfo)) + (arguments + (substitute-keyword-arguments (package-arguments binutils) + ((#:make-flags flags ''()) + ''()))) + (properties '()))) + ;; FIXME: ath9k-firmware-htc-binutils.patch do not apply on 2.34 because of a ;; big refactoring of xtensa-modules.c (commit 567607c11fbf7105 upstream). ;; Keep this version around until the patch is updated. @@ -627,7 +653,7 @@ included.") (properties '()))) (define-public binutils-gold - (package/inherit binutils + (package/inherit binutils+documentation (name "binutils-gold") (arguments (substitute-keyword-arguments (package-arguments binutils) @@ -729,18 +755,29 @@ the store.") (home-page "https://www.gnu.org/software/guix//") (license gpl3+))) +(define-public %glibc/hurd-configure-flags + ;; 'configure' in glibc 2.35 omits to pass '-ffreestanding' when detecting + ;; Mach headers. This is fixed in glibc commits + ;; 8b8c768e3c701ed1993789bb46acb8a12c7a93df and + ;; 7685630b98ca2a3f5de86eadf130993e6cf998a0; as a workaround, bypass those + ;; tests. + '("ac_cv_header_mach_mach_types_defs=yes" + "ac_cv_header_mach_mach_types_h=yes" + "ac_cv_header_mach_machine_ndr_def_h=no" + "libc_cv_mach_task_creation_time=yes")) + (define-public glibc ;; This is the GNU C Library, used on GNU/Linux and GNU/Hurd. Prior to ;; version 2.28, GNU/Hurd used a different glibc branch. (package (name "glibc") - (version "2.33") + (version "2.35") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/glibc/glibc-" version ".tar.xz")) (sha256 (base32 - "1zvp0qdfbdyqrzydz18d9zg3n5ygy8ps7cmny1bvsp8h1q05c99f")) + "0bpm1kfi09dxl4c6aanc5c9951fmf6ckkzay60cx7k37dcpp68si")) (patches (search-patches "glibc-ldd-powerpc.patch" "glibc-ldd-x86_64.patch" "glibc-dl-cache.patch" @@ -778,10 +815,15 @@ the store.") #:validate-runpath? #f #:modules ((ice-9 ftw) + (srfi srfi-1) (srfi srfi-26) (guix build utils) (guix build gnu-build-system)) + ;; Strip binaries but preserve the symbol table needed by Valgrind: + ;; <https://lists.gnu.org/archive/html/help-guix/2022-03/msg00036.html>. + #:strip-flags '("--strip-debug") + #:configure-flags (list "--sysconfdir=/etc" @@ -823,7 +865,8 @@ the store.") ;; On GNU/Hurd we get discarded-qualifiers warnings for ;; 'device_write_inband' among other things. Ignore them. ,@(if (hurd-target?) - '("--disable-werror") + `("--disable-werror" + ,@%glibc/hurd-configure-flags) '())) #:tests? #f ; XXX @@ -888,13 +931,34 @@ the store.") (add-after 'install 'move-static-libs (lambda* (#:key outputs #:allow-other-keys) ;; Move static libraries to the "static" output. + ;; Note: As of GNU libc 2.34, the contents of some ".a" + ;; files have been moved into "libc.so", and *both* empty + ;; ".so" and ".a" files have been introduced to avoid + ;; breaking existing executables and existing builds + ;; respectively. The intent of the seemingly redundant + ;; empty ".a" files is to avoid newly-compiled executables + ;; from having dependencies on the empty shared libraries, + ;; and as such, it is useful to have these ".a" files in + ;; OUT in addition to STATIC. + + ;; XXX: It might be better to determine whether a static + ;; library is empty by some criterion (such as their file + ;; size equaling eight bytes) rather than hardcoding them + ;; by name. + (define empty-static-libraries + '("libpthread.a" "libdl.a" "libutil.a" "libanl.a")) + (define (empty-static-library? file) + (any (lambda (s) + (string=? file s)) empty-static-libraries)) + (define (static-library? file) ;; Return true if FILE is a static library. The ;; "_nonshared.a" files are referred to by libc.so, ;; libpthread.so, etc., which are in fact linker ;; scripts. (and (string-suffix? ".a" file) - (not (string-contains file "_nonshared")))) + (not (string-contains file "_nonshared")) + (not (empty-static-library? file)))) (define (linker-script? file) ;; Guess whether FILE, a ".a" file, is actually a @@ -905,6 +969,7 @@ the store.") (let* ((out (assoc-ref outputs "out")) (lib (string-append out "/lib")) (files (scandir lib static-library?)) + (empty (scandir lib empty-static-library?)) (static (assoc-ref outputs "static")) (slib (string-append static "/lib"))) (mkdir-p slib) @@ -912,6 +977,10 @@ the store.") (rename-file (string-append lib "/" base) (string-append slib "/" base))) files) + (for-each (lambda (base) + (copy-file (string-append lib "/" base) + (string-append slib "/" base))) + empty) ;; Usually libm.a is a linker script so we need to ;; change the file names in there to refer to STATIC @@ -984,6 +1053,33 @@ with the Linux kernel.") ;; Below are old libc versions, which we use mostly to build locale data in ;; the old format (which the new libc cannot cope with.) + +(define-public glibc-2.33 + (package + (inherit glibc) + (name "glibc") + (version "2.33") + (source (origin + (method url-fetch) + (uri (string-append "mirror://gnu/glibc/glibc-" version ".tar.xz")) + (sha256 + (base32 + "1zvp0qdfbdyqrzydz18d9zg3n5ygy8ps7cmny1bvsp8h1q05c99f")) + (patches + ;; Remove a patch that's become irrelevant and that does not + ;; apply to this version. + (remove (lambda (patch) + (string=? (basename patch) + "glibc-hurd-clock_gettime_monotonic.patch")) + (origin-patches (package-source glibc)))))) + (arguments + (substitute-keyword-arguments (package-arguments glibc) + ((#:configure-flags flags ''()) + ;; There are undefined references to pthread symbols while linking + ;; 'support/links-dso-program.cc'. Since this isn't needed here, turn + ;; off C++ tests. + `(cons "libc_cv_cxx_link_ok=no" ,flags)))))) + (define-public glibc-2.32 (package (inherit glibc) @@ -1335,9 +1431,10 @@ command.") (arguments (substitute-keyword-arguments (package-arguments glibc) ;; We just pass the flags really needed to build the headers. - ((#:configure-flags _) + ((#:configure-flags flags) `(list "--enable-add-ons" - "--host=i586-pc-gnu")) + "--host=i586-pc-gnu" + ,@%glibc/hurd-configure-flags)) ((#:phases _) '(modify-phases %standard-phases (replace 'install @@ -1488,7 +1585,7 @@ package needs iconv ,@(libiconv-if-needed) should be added." ;; POSIX C libraries provide iconv. Platforms with an incomplete libc ;; without iconv, such as MinGW, must return the then clause. (if (target-mingw? target) - `(("libiconv" ,libiconv)) + (list libiconv) '())) (define-public (canonical-package package) diff --git a/gnu/packages/bash.scm b/gnu/packages/bash.scm index 7545f331e6..43f38303f7 100644 --- a/gnu/packages/bash.scm +++ b/gnu/packages/bash.scm @@ -1,8 +1,8 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2019, 2020 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012-2017, 2019-2020, 2022, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015, 2017 Leo Famulari <leo@famulari.name> -;;; Copyright © 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2017, 2018, 2019, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Zhu Zihao <all_but_last@163.com> @@ -74,7 +74,7 @@ ...)) (define %patch-series-5.1 - ;; This is the current patches series for 5.0, generated using + ;; This is the current patches series for 5.1, generated using ;; 'download-patches' below. (patch-series (1 "1ymm8ppss6gyh9ifznjwiabrb4k91npd09c10y7mk66xp8yppc7b") @@ -84,7 +84,15 @@ (5 "19bdyigdr81824nxvqr6a7k0cax60wq7376j6b91afbnwvlvbjyc") (6 "051x8wlwrqk0yr0zg378vh824iklfl5g9pkmcdf62qp8gn9pvqbm") (7 "0fir80pp1gmlpadmqcgkrv4y119pc7xllchjzg05fd7px73viz5c") - (8 "1lfjgshk8i9vch92p5wgc9r90j3phw79aa7gbai89w183b2z6b7j"))) + (8 "1lfjgshk8i9vch92p5wgc9r90j3phw79aa7gbai89w183b2z6b7j") + (9 "1vn36dzd9g4y1h3jiss6418crla0rbcd0d6wwsyv9d5l7aaxlp74") + (10 "0amfmvbzsand7bdypylkjdpcp88fa3cplfshn7vyzv2ff2rdgj52") + (11 "0yq24abb4fzfxqnwl20b330sxl9lr9ds0nc4yi30f81l94b1y6aq") + (12 "165bff97ffih49vfs4mkr5w3z5gn1w6zfyrf773iajkw6v48kw8h") + (13 "1bfmgv3lagbk3aq9a831d29xv7jz4sjq7jhn9hq89limyinvdb67") + (14 "1l43dw4kpddn7l41i8wmj406z9abxky1wb3rk8krcys33g4f0kka") + (15 "1w40vzadzx019v0zhs4q6yqycrk04x1k8xs6qb73vk7ny4p6jdqv") + (16 "0krqqljz4bkp9wrdnwfx51bxkb8rkwf8ivc93as1znx5fr7i96c8"))) (define (download-patches store count) "Download COUNT Bash patches into store. Return a list of @@ -111,7 +119,8 @@ number/base32-hash tuples, directly usable in the 'patch-series' form." "-DSSH_SOURCE_BASHRC") " ")) (configure-flags - ``("--with-installed-readline" + ``("--without-bash-malloc" + "--with-installed-readline" ,,(string-append "CPPFLAGS=" cppflags) ,(string-append "LDFLAGS=-Wl,-rpath -Wl," @@ -261,15 +270,15 @@ without modification.") (substitute-keyword-arguments `(#:allowed-references ("out") ,@(package-arguments bash)) ((#:phases phases) - `(modify-phases ,phases - (add-after 'strip 'remove-everything-but-the-binary - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin"))) - (remove-store-references (string-append bin "/bash")) - (delete-file (string-append bin "/bashbug")) - (delete-file-recursively (string-append out "/share")) - #t)))))))))) + #~(modify-phases #$phases + (add-after 'strip 'remove-everything-but-the-binary + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin"))) + (remove-store-references (string-append bin "/bash")) + (delete-file (string-append bin "/bashbug")) + (delete-file-recursively (string-append out "/share")) + #t)))))))))) (define-public bash-with-syslog (package @@ -291,7 +300,7 @@ variant logs the history to syslog."))) (define-public bash-completion (package (name "bash-completion") - (version "2.8") + (version "2.11") (source (origin (method url-fetch) (uri (string-append @@ -299,38 +308,12 @@ variant logs the history to syslog."))) version "/" name "-" version ".tar.xz")) (sha256 (base32 - "0kgmflrr1ga9wfk770vmakna3nj46ylb5ky9ipd0v2k9ymq5a7y0")) + "1b0iz7da1sgifx1a5wdyx1kxbzys53v0kyk8nhxfipllmm5qka3k")) (patches (search-patches "bash-completion-directories.patch")))) (build-system gnu-build-system) - (native-inputs (list util-linux)) (arguments - `(#:phases (modify-phases %standard-phases - (add-after - 'install 'remove-redundant-completions - (lambda* (#:key - inputs native-inputs - outputs #:allow-other-keys) - ;; Util-linux comes with a bunch of completion files for - ;; its own commands which are more sophisticated and - ;; up-to-date than those of bash-completion. Remove those - ;; from bash-completion. - (let* ((out (assoc-ref outputs "out")) - (util-linux (assoc-ref (or native-inputs inputs) - "util-linux")) - (completions (string-append out - "/share/bash-completion" - "/completions")) - (already (find-files - (string-append - util-linux - "/etc/bash_completion.d")))) - (with-directory-excursion completions - (for-each (lambda (file) - (when (file-exists? file) - (delete-file file))) - (map basename already))) - #t)))))) + `(#:tests? #f)) ; Unclear how to make tests pass. (synopsis "Bash completions for common commands") (description "This package provides extensions that allow Bash to provide adapted diff --git a/gnu/packages/bdw-gc.scm b/gnu/packages/bdw-gc.scm index ae0d761ac3..5ff4649716 100644 --- a/gnu/packages/bdw-gc.scm +++ b/gnu/packages/bdw-gc.scm @@ -3,8 +3,8 @@ ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2016, 2018 Leo Famulari <leo@famulari.name> ;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org> -;;; Copyright © 2019, 2020 Marius Bakke <mbakke@fastmail.com> -;;; Copyright © 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2022, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; ;;; This file is part of GNU Guix. ;;; @@ -25,6 +25,7 @@ #:use-module (guix licenses) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix build-system gnu) #:use-module (gnu packages pkg-config) @@ -33,7 +34,7 @@ (define-public libgc (package (name "libgc") - (version "8.0.4") + (version "8.2.2") (source (origin (method url-fetch) (uri (list (string-append "https://github.com/ivmai/bdwgc/releases" @@ -43,33 +44,43 @@ "/gc-" version ".tar.gz"))) (sha256 (base32 - "1798rp3mcfkgs38ynkbg2p47bq59pisrc6mn0l20pb5iczf0ssj3")))) + "181ni2rn9qjbl4ilqdjrd1a4h8siv5bgmzqgg4595q32n2y0f0gk")))) (build-system gnu-build-system) (arguments - `(#:configure-flags - (list - ;; Install gc_cpp.h et al. - "--enable-cplusplus" + (append + (list + #:configure-flags + #~(list + ;; Install gc_cpp.h et al. + "--enable-cplusplus" - ;; Work around <https://github.com/ivmai/bdwgc/issues/353>. - "--disable-munmap" - - ;; In GNU/Hurd systems during the 'check' phase, - ;; there is a deadlock caused by the 'gctest' test. - ;; To disable the error set "--disable-gcj-support" - ;; to configure script. See bug report and discussion: - ;; <https://lists.opendylan.org/pipermail/bdwgc/2017-April/006275.html> - ;; <https://lists.gnu.org/archive/html/bug-hurd/2017-01/msg00008.html> - ,@(if (target-hurd? (or (%current-system) - (%current-target-system))) - '("--disable-gcj-support") - '())))) + ;; In GNU/Hurd systems during the 'check' phase, + ;; there is a deadlock caused by the 'gctest' test. + ;; To disable the error set "--disable-gcj-support" + ;; to configure script. See bug report and discussion: + ;; <https://lists.opendylan.org/pipermail/bdwgc/2017-April/006275.html> + ;; <https://lists.gnu.org/archive/html/bug-hurd/2017-01/msg00008.html> + #$@(if (target-hurd? (or (%current-system) + (%current-target-system))) + #~("--disable-gcj-support") + #~()))) + (cond + ((target-ppc64le?) + (list #:make-flags + ;; This is a known workaround upstream. + ;; https://github.com/ivmai/bdwgc/issues/479 + #~(list "CFLAGS_EXTRA=-DNO_SOFT_VDB"))) + ((target-ppc32?) + (list #:make-flags + ;; Similar to above. + #~(list "CFLAGS_EXTRA=-DNO_MPROTECT_VDB"))) + (else '())))) (native-inputs (list pkg-config)) (propagated-inputs (if (%current-target-system) ;; The build system refuses to check for compiler intrinsics when ;; cross-compiling, and demands using libatomic-ops instead. - `(("libatomic-ops" ,libatomic-ops)) + (list libatomic-ops) '())) (outputs '("out" "debug")) (properties @@ -100,9 +111,11 @@ C or C++ programs, though that is not its primary goal.") (define-public libgc/static-libs (package/inherit libgc - (arguments (substitute-keyword-arguments (package-arguments libgc) - ((#:configure-flags flags ''()) - `(cons "--enable-static" ,flags)))) + (arguments + (substitute-keyword-arguments (package-arguments libgc) + ((#:configure-flags flags #~'()) + #~(cons "--enable-static" #$flags)))) + (properties '((hidden? . #t))))) (define-public libgc-7 @@ -123,9 +136,9 @@ C or C++ programs, though that is not its primary goal.") libgc (name "libgc-back-pointers") (arguments - `(#:make-flags - (list "CPPFLAGS=-DKEEP_BACK_PTRS=1") - ,@(package-arguments libgc))) + (substitute-keyword-arguments (package-arguments libgc) + ((#:make-flags _ #~'()) + #~(list "CPPFLAGS=-DKEEP_BACK_PTRS=1")))) (synopsis "The BDW garbage collector, with back-pointer tracking"))) (define-public libatomic-ops diff --git a/gnu/packages/benchmark.scm b/gnu/packages/benchmark.scm index 0cc8def918..733078d875 100644 --- a/gnu/packages/benchmark.scm +++ b/gnu/packages/benchmark.scm @@ -634,39 +634,19 @@ its features are: ;; Do not attempt to invoke the cram command via ;; Python, as on Guix it is a shell script (wrapper). (("\\$\\(command -v cram\\)") - "-m cram")))) + "-m cram")) + (substitute* "tests/t/opt_report_checkpoints.t" + ;; egrep outputs a deprecation warning, which breaks + ;; the test. + (("egrep") + "grep -E")))) (add-after 'unpack 'disable-test-installation (lambda _ (substitute* "tests/Makefile.am" (("install-data-local") "do-not-install-data-local") (("^test_SCRIPTS.*") - "")))) - (add-after 'unpack 'fix-docbook - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (substitute* "m4/ax_check_docbook.m4" - (("DOCBOOK_ROOT=.*" all) - (string-append - all "XML_CATALOG=" - (search-input-file (or native-inputs inputs) - "xml/dtd/docbook/catalog.xml") - "\n"))) - (substitute* "doc/xsl/xhtml.xsl" - (("http://docbook.sourceforge.net/release/xsl\ -/current/xhtml/docbook.xsl") - (search-input-file - (or native-inputs inputs) - (string-append "xml/xsl/docbook-xsl-" - #$(package-version docbook-xsl) - "/xhtml/docbook.xsl")))) - (substitute* "doc/xsl/xhtml-chunk.xsl" - (("http://docbook.sourceforge.net/release/xsl\ -/current/xhtml/chunk.xsl") - (search-input-file - (or native-inputs inputs) - (string-append "xml/xsl/docbook-xsl-" - #$(package-version docbook-xsl) - "/xhtml/chunk.xsl"))))))))) + ""))))))) (native-inputs (list autoconf automake libtool diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 8813bbe308..68c1406fc3 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -4226,10 +4226,10 @@ data and settings.") texlive-fonts-ec texlive-latex-examplep texlive-hyperref - texlive-latex-ms + texlive-ms texlive-latex-natbib - texlive-bibtex ; style files used by natbib - texlive-pgf ; tikz + texlive-bibtex ;style files used by natbib + texlive-pgf ;tikz texlive-latex-verbatimbox))) ("imagemagick" ,imagemagick))) (home-page "https://dorina.mdc-berlin.de/public/rajewsky/discrover/") @@ -11208,11 +11208,11 @@ programs for inferring phylogenies (evolutionary trees).") (texlive-updmap.cfg (list texlive-amsfonts texlive-caption texlive-cite + texlive-fancyvrb texlive-fonts-ec + texlive-graphics texlive-grfext texlive-hyperref - texlive-latex-fancyvrb - texlive-latex-graphics texlive-latex-psfrag texlive-xcolor)))) (home-page "https://github.com/stephaneguindon/phyml") @@ -11320,7 +11320,7 @@ applications for tackling some common problems in a user-friendly way.") (lambda* (#:key outputs #:allow-other-keys) (substitute* "src/test/Makefile" (("^CFLAGS=") "CFLAGS= -fcommon")) - + ;; Don't attempt to install the bash completions to ;; the home directory. (rename-file "extras/.bash_completion" @@ -16038,7 +16038,7 @@ to an artifact/contaminant file.") (inputs (list openmpi zlib)) (native-inputs - `(("texlive" ,(texlive-updmap.cfg (list texlive-latex-graphics + `(("texlive" ,(texlive-updmap.cfg (list texlive-graphics texlive-fonts-ec texlive-hyperref))))) (home-page "https://www.ebi.ac.uk/~zerbino/velvet/") @@ -18553,7 +18553,7 @@ aligner.") ;; /tmp/guix-build-*. (with-directory-excursion (string-append (assoc-ref outputs "out") - "/lib/python3.9/site-packages/scvelo/core/tests/") + "/lib/python3.10/site-packages/scvelo/core/tests/") (invoke "pytest" "-v")))))))) (propagated-inputs (list python-anndata diff --git a/gnu/packages/bison.scm b/gnu/packages/bison.scm index 5fd25452ff..6cd7abe420 100644 --- a/gnu/packages/bison.scm +++ b/gnu/packages/bison.scm @@ -33,7 +33,7 @@ (define-public bison (package (name "bison") - (version "3.7.6") + (version "3.8.2") (source (origin (method url-fetch) @@ -41,7 +41,7 @@ version ".tar.xz")) (sha256 (base32 - "1kzkxrd3z4262k2sbxmyh9k5g5r2lakw0gv44l2hb4i1wbhqrmk7")))) + "1wjvbbzrr16k1jlby3l436an3kvv492h08arbnf0gwgprha05flv")))) (build-system gnu-build-system) (arguments '(;; Building in parallel on many-core systems may cause an error such as diff --git a/gnu/packages/bittorrent.scm b/gnu/packages/bittorrent.scm index bfe524366c..06d4b25a57 100644 --- a/gnu/packages/bittorrent.scm +++ b/gnu/packages/bittorrent.scm @@ -526,7 +526,7 @@ features.") (native-inputs (list intltool python-wheel (if (string-prefix? "x86_64-" (%current-system)) - librsvg-bootstrap + librsvg librsvg-2.40))) ;; TODO: Enable tests. ;; After "pytest-twisted" is packaged, HOME is set, and an X server is diff --git a/gnu/packages/boost.scm b/gnu/packages/boost.scm index 40e4ca399e..d2b676cc73 100644 --- a/gnu/packages/boost.scm +++ b/gnu/packages/boost.scm @@ -12,12 +12,11 @@ ;;; Copyright © 2018, 2020 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2019, 2020 Giacomo Leidi <goodoldpaul@autistici.org> -;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Jonathan Brielmaier <jonathan.brielmaier@web.de> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> -;;; Copyright © 2021 Greg Hogan <code@greghogan.com> +;;; Copyright © 2021, 2022 Greg Hogan <code@greghogan.com> ;;; Copyright © 2021 Franck Pérignon <franck.perignon@univ-grenoble-alpes.fr> -;;; Copyright © 2021 Greg Hogan <code@greghogan.com> ;;; Copyright © 2021 Aleksandr Vityazev <avityazev@posteo.org> ;;; ;;; This file is part of GNU Guix. @@ -38,6 +37,7 @@ (define-module (gnu packages boost) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix utils) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -68,122 +68,155 @@ (define-public boost (package (name "boost") - (version "1.77.0") + (version "1.80.0") (source (origin (method url-fetch) (uri (string-append "https://boostorg.jfrog.io/artifactory/main/release/" version "/source/boost_" (version-with-underscores version) ".tar.bz2")) + (patches + (list (boost-patch + ;; Boost.Filesystem directory iterators may fail to + ;; construct for a network share on Windows prior to 10: + ;; https://github.com/boostorg/filesystem/pull/246, + ;; https://github.com/boostorg/filesystem/issues/245 + "0001-filesystem-win-fix-dir-it-net-share.patch" version + "067hhylqkzzdbqzc1hkbpaqmvz248lxqrdhb2yi6iq9qabsik3lk") + (boost-patch + ;; In Boost.Filesystem on Windows, weakly_canonical fails + ;; to process paths that start with the "\\?\" prefix: + ;; https://github.com/boostorg/filesystem/issues/247 + "0002-filesystem-fix-weakly-canonical-long-paths.patch" version + "00w3albf8527glclx85p5b2ml3vr06xpwwmfyzg005v1cp8avcpi") + (boost-patch + ;; Boost.Unordered containers are not in a valid state + ;; after moving: + ;; https://github.com/boostorg/unordered/issues/139 + "0003-unordered-valid-after-move.patch" version + "0dw839w22cawqawfpsx7j7v9y0x2vn66m732iidpxvdxbjn2kzva") + (boost-patch + ;; Fixed a missing include on POSIX systems that don't + ;; support *at APIs: + ;; https://github.com/boostorg/filesystem/issues/250 + "0004-filesystem-posix-fix-no-at-apis-missing-include.patch" version + "09k8k3b1306jkjls12wfghj820n828j6aaxzmcr0wpnjhp8fzi1v"))) (sha256 (base32 - "0m08hhk3l7zvzajyk39qlw566q3fhixayhc2j11328qf0gy8b7zw")))) + "1h00qp4z5k6lfz310xjwsmqs8fwxi6ngas51169cafz4h9fmc68y")))) (build-system gnu-build-system) - (inputs (list icu4c zlib)) + (inputs + (append + (list icu4c zlib) + (if (%current-target-system) + '() + (list python-minimal-wrapper)))) (native-inputs - `(("perl" ,perl) - ,@(if (%current-target-system) - '() - `(("python" ,python-minimal-wrapper))) - ("tcsh" ,tcsh))) + (list perl tcsh)) (arguments - `(#:imported-modules ((guix build python-build-system) + (list + #:imported-modules `((guix build python-build-system) ,@%gnu-build-system-modules) - #:modules (((guix build python-build-system) #:select (python-version)) + #:modules `(((guix build python-build-system) #:select (python-version)) ,@%gnu-build-system-modules) - #:tests? #f - #:make-flags - (list "threading=multi" "link=shared" + #:tests? #f + #:configure-flags + #~(let ((icu (dirname (dirname (search-input-file + %build-inputs "bin/uconv"))))) + (list + ;; Auto-detection looks for ICU only in traditional + ;; install locations. + (string-append "--with-icu=" icu) + ;; Ditto for Python. + #$@(if (%current-target-system) + #~() + #~((let ((python (dirname (dirname (search-input-file + %build-inputs + "bin/python"))))) + (string-append "--with-python-root=" python) + (string-append "--with-python=" python + "/bin/python") + (string-append "--with-python-version=" + (python-version python))))) + "--with-toolset=gcc")) + #:make-flags + #~(list "threading=multi" "link=shared" - ;; Set the RUNPATH to $libdir so that the libs find each other. - (string-append "linkflags=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - ,@(if (%current-target-system) - `("--user-config=user-config.jam" - ;; Python is not supported when cross-compiling. - "--without-python" - "binary-format=elf" - "target-os=linux" - ,@(cond - ((string-prefix? "arm" (%current-target-system)) - '("abi=aapcs" - "address-model=32" - "architecture=arm")) - ((string-prefix? "aarch64" (%current-target-system)) - '("abi=aapcs" - "address-model=64" - "architecture=arm")) - (else '()))) - '())) - #:phases - (modify-phases %standard-phases - (delete 'bootstrap) - (replace 'configure - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((icu (assoc-ref inputs "icu4c")) - (python (assoc-ref inputs "python")) - (out (assoc-ref outputs "out"))) - (substitute* '("libs/config/configure" - "libs/spirit/classic/phoenix/test/runtest.sh" - "tools/build/src/engine/execunix.cpp") - (("/bin/sh") (which "sh"))) - - (setenv "SHELL" (which "sh")) - (setenv "CONFIG_SHELL" (which "sh")) + ;; Set the RUNPATH to $libdir so that the libs find each other. + (string-append "linkflags=-Wl,-rpath=" + #$output "/lib") + #$@(if (%current-target-system) + #~("--user-config=user-config.jam" + ;; Python is not supported when cross-compiling. + "--without-python" + "binary-format=elf" + "target-os=linux" + #$@(cond + ((string-prefix? "arm" (%current-target-system)) + #~("abi=aapcs" + "address-model=32" + "architecture=arm")) + ((string-prefix? "aarch64" (%current-target-system)) + #~("abi=aapcs" + "address-model=64" + "architecture=arm")) + (else #~()))) + #~())) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-shells + (lambda _ + (substitute* '("libs/config/configure" + "libs/spirit/classic/phoenix/test/runtest.sh" + "tools/build/src/engine/execunix.cpp") + (("/bin/sh") (which "sh"))))) + (delete 'bootstrap) + (replace 'configure + (lambda* (#:key (configure-flags ''()) #:allow-other-keys) + (setenv "SHELL" (which "sh")) + (setenv "CONFIG_SHELL" (which "sh")) - ,@(if (%current-target-system) - `((call-with-output-file "user-config.jam" + #$@(if (%current-target-system) + #~((call-with-output-file "user-config.jam" (lambda (port) (format port "using gcc : cross : ~a-c++ ;" - ,(%current-target-system))))) - '()) + #$(%current-target-system))))) + #~()) - ;; Change an #ifdef __MACH__ that really targets macOS. - (substitute* "boost/test/utils/timer.hpp" - (("defined\\(__MACH__\\)") - "(defined __MACH__ && !defined __GNU__)")) - - (invoke "./bootstrap.sh" - (string-append "--prefix=" out) - ;; Auto-detection looks for ICU only in traditional - ;; install locations. - (string-append "--with-icu=" icu) - ;; Ditto for Python. - ,@(if (%current-target-system) - '() - `((string-append "--with-python-root=" python) - (string-append "--with-python=" python "/bin/python") - (string-append "--with-python-version=" - (python-version python)))) - "--with-toolset=gcc")))) - (replace 'build - (lambda* (#:key make-flags #:allow-other-keys) - (apply invoke "./b2" - (format #f "-j~a" (parallel-job-count)) - make-flags))) - (replace 'install - (lambda* (#:key make-flags #:allow-other-keys) - (apply invoke "./b2" "install" make-flags))) - ,@(if (%current-target-system) - '() - '((add-after 'install 'provide-libboost_python - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (python-version (python-version - (assoc-ref inputs "python"))) - (libboost_pythonNN.so - (string-append "libboost_python" - (string-join (string-split - python-version #\.) - "") - ".so"))) - (with-directory-excursion (string-append out "/lib") - (symlink libboost_pythonNN.so "libboost_python.so") - ;; Some packages only look for the major version. - (symlink libboost_pythonNN.so - (string-append "libboost_python" - (string-take python-version 1) - ".so"))))))))))) + (apply invoke "./bootstrap.sh" + (string-append "--prefix=" #$output) + configure-flags))) + (replace 'build + (lambda* (#:key make-flags #:allow-other-keys) + (apply invoke "./b2" + (format #f "-j~a" (parallel-job-count)) + make-flags))) + (replace 'install + (lambda* (#:key make-flags #:allow-other-keys) + (apply invoke "./b2" "install" make-flags))) + #$@(if (%current-target-system) + #~() + #~((add-after 'install 'provide-libboost_python + (lambda* (#:key make-flags inputs outputs #:allow-other-keys) + (let* ((static? (member "link=static" make-flags)) + (libext (if static? ".a" ".so")) + (python (dirname (dirname (search-input-file + inputs "bin/python")))) + (python-version (python-version python)) + (libboost_pythonNN + (string-append "libboost_python" + (string-join (string-split + python-version #\.) + "") + libext))) + (with-directory-excursion (string-append #$output "/lib") + (symlink libboost_pythonNN + (string-append "libboost_python" libext)) + ;; Some packages only look for the major version. + (symlink libboost_pythonNN + (string-append "libboost_python" + (string-take python-version 1) + libext))))))))))) (home-page "https://www.boost.org") (synopsis "Peer-reviewed portable C++ source libraries") @@ -285,23 +318,7 @@ across a broad spectrum of applications.") (arguments (substitute-keyword-arguments (package-arguments boost) ((#:make-flags flags) - `(cons "link=static" (delete "link=shared" ,flags))) - ((#:phases phases) - `(modify-phases ,phases - (replace 'provide-libboost_python - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (python-version (python-version - (assoc-ref inputs "python"))) - (libboost_pythonNN.a - (string-append "libboost_python" - (string-join (string-split - python-version #\.) - "") - ".a"))) - (with-directory-excursion (string-append out "/lib") - (symlink libboost_pythonNN.a "libboost_python.a")) - #t))))))))) + #~(cons "link=static" (delete "link=shared" #$flags))))))) (define-public boost-for-mysql ;; Older version for MySQL 5.7.23. @@ -317,43 +334,33 @@ across a broad spectrum of applications.") (sha256 (base32 "1jj1aai5rdmd72g90a3pd8sw9vi32zad46xv5av8fhnr48ir6ykj")))) - (arguments (substitute-keyword-arguments (package-arguments boost) - ((#:phases phases) - `(modify-phases ,phases - (replace 'configure - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((icu (assoc-ref inputs "icu4c")) - (out (assoc-ref outputs "out"))) + (arguments + (substitute-keyword-arguments (package-arguments boost) + ((#:configure-flags _ #~'()) + #~(let ((icu (dirname (dirname (search-input-file + %build-inputs "bin/uconv"))))) + (list + ;; Auto-detection looks for ICU only in traditional + ;; install locations. + (string-append "--with-icu=" icu) + "--with-toolset=gcc"))) + ((#:phases phases) + #~(modify-phases #$phases + (replace 'patch-shells + (lambda _ (substitute* (append - (find-files "tools/build/src/engine/" "execunix\\.c.*") - '("libs/config/configure" - "libs/spirit/classic/phoenix/test/runtest.sh" - "tools/build/doc/bjam.qbk" - "tools/build/src/engine/Jambase")) - (("/bin/sh") (which "sh"))) - - (setenv "SHELL" (which "sh")) - (setenv "CONFIG_SHELL" (which "sh")) - - ,@(if (%current-target-system) - `((call-with-output-file "user-config.jam" - (lambda (port) - (format port - "using gcc : cross : ~a-c++ ;" - ,(%current-target-system))))) - '()) - - (invoke "./bootstrap.sh" - (string-append "--prefix=" out) - ;; Auto-detection looks for ICU only in traditional - ;; install locations. - (string-append "--with-icu=" icu) - "--with-toolset=gcc")))) - (delete 'provide-libboost_python))) - ((#:make-flags make-flags) - `(cons* "--without-python" ,make-flags)))) - (native-inputs - (alist-delete "python" (package-native-inputs boost))) + (find-files "tools/build/src/engine/" "execunix\\.c.*") + '("libs/config/configure" + "libs/spirit/classic/phoenix/test/runtest.sh" + "tools/build/doc/bjam.qbk" + "tools/build/src/engine/Jambase")) + (("/bin/sh") (which "sh"))))) + (delete 'provide-libboost_python))) + ((#:make-flags make-flags) + #~(cons* "--without-python" #$make-flags)))) + (inputs + (modify-inputs (package-inputs boost) + (delete "python-minimal-wrapper"))) (properties '((hidden? . #t))))) (define-public boost-sync @@ -421,22 +428,19 @@ signals and slots system.") (package (inherit boost) (name "boost-mpi") - (native-inputs - `(("perl" ,perl) - ,@(if (%current-target-system) - '() - `(("python" ,python-wrapper))) - ("openmpi" , openmpi))) + (inputs + (modify-inputs (package-inputs boost) + (append openmpi))) (arguments (substitute-keyword-arguments (package-arguments boost) - ((#:phases phases) - `(modify-phases ,phases - (add-after 'configure 'update-jam - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((output-port (open-file "project-config.jam" "a"))) - (display "using mpi ;" output-port) - (newline output-port) - (close output-port)))))))) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'configure 'update-jam + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((output-port (open-file "project-config.jam" "a"))) + (display "using mpi ;" output-port) + (newline output-port) + (close output-port)))))))) (home-page "https://www.boost.org") (synopsis "Message Passing Interface (MPI) library for C++"))) diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index ac269807be..a9685a9ef9 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -655,6 +655,7 @@ tree binary files. These are board description files used by Linux and BSD.") %u-boot-allow-disabling-openssl-patch %u-boot-sifive-prevent-relocating-initrd-fdt %u-boot-rk3399-enable-emmc-phy-patch + (search-patch "u-boot-fix-build-python-3.10.patch") (search-patch "u-boot-infodocs-target.patch") (search-patch "u-boot-patman-guix-integration.patch"))) (method url-fetch) diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm index 75980f2148..9a46f97c81 100644 --- a/gnu/packages/bootstrap.scm +++ b/gnu/packages/bootstrap.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2018, 2019 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2017, 2020 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2018, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> +;;; Copyright © 2018, 2020, 2022 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2019 Carl Dong <contact@carldong.me> ;;; Copyright © 2019 Léo Le Bouter <lle-bout@zaclys.net> ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net> @@ -60,8 +60,6 @@ %bootstrap-gcc %bootstrap-glibc %bootstrap-inputs - %bootstrap-mescc-tools - %bootstrap-mes %bootstrap-inputs-for-tests)) @@ -929,112 +927,12 @@ exec ~a/bin/.gcc-wrapped -B~a/lib \ (home-page #f) (license gpl3+))) -(define %bootstrap-mescc-tools - ;; The initial MesCC tools. Uses binaries from a tarball typically built by - ;; %MESCC-TOOLS-BOOTSTRAP-TARBALL. - (package - (name "bootstrap-mescc-tools") - (version "0.5.2") - (source #f) - (build-system trivial-build-system) - (arguments - `(#:guile ,%bootstrap-guile - #:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils) - (ice-9 popen)) - (let ((out (assoc-ref %outputs "out")) - (tar (assoc-ref %build-inputs "tar")) - (xz (assoc-ref %build-inputs "xz")) - (tarball (assoc-ref %build-inputs "tarball"))) - - (mkdir out) - (copy-file tarball "binaries.tar.xz") - (invoke xz "-d" "binaries.tar.xz") - (let ((builddir (getcwd)) - (bindir (string-append out "/bin"))) - (with-directory-excursion out - (invoke tar "xvf" - (string-append builddir "/binaries.tar")))))))) - (inputs - `(("tar" ,(bootstrap-executable "tar" (%current-system))) - ("xz" ,(bootstrap-executable "xz" (%current-system))) - ("tarball" - ,(bootstrap-origin - (origin - (method url-fetch) - (uri (map - (cute string-append <> - "/i686-linux/20190815/" - "mescc-tools-static-stripped-0.5.2-i686-linux.tar.xz") - %bootstrap-base-urls)) - (sha256 - (base32 - "0c3kklgghzh4q2dbpl6asb74cimp7hp6jscdwqwmzxbapgcl6582"))))))) - (synopsis "Bootstrap binaries of MesCC Tools") - (description synopsis) - (home-page #f) - (supported-systems '("i686-linux" "x86_64-linux")) - (license gpl3+))) - -(define %bootstrap-mes - ;; The initial Mes. Uses binaries from a tarball typically built by - ;; %MES-BOOTSTRAP-TARBALL. - (package - (name "bootstrap-mes") - (version "0") - (source #f) - (build-system trivial-build-system) - (arguments - `(#:guile ,%bootstrap-guile - #:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils) - (ice-9 popen)) - (let ((out (assoc-ref %outputs "out")) - (tar (assoc-ref %build-inputs "tar")) - (xz (assoc-ref %build-inputs "xz")) - (tarball (assoc-ref %build-inputs "tarball"))) - - (mkdir out) - (copy-file tarball "binaries.tar.xz") - (invoke xz "-d" "binaries.tar.xz") - (let ((builddir (getcwd)) - (bindir (string-append out "/bin"))) - (with-directory-excursion out - (invoke tar "xvf" - (string-append builddir "/binaries.tar")))))))) - (inputs - `(("tar" ,(bootstrap-executable "tar" (%current-system))) - ("xz" ,(bootstrap-executable "xz" (%current-system))) - ("tarball" - ,(bootstrap-origin - (origin - (method url-fetch) - (uri (map - (cute string-append <> - "/i686-linux/20190815/" - "mes-minimal-stripped-0.19-i686-linux.tar.xz") - %bootstrap-base-urls)) - (sha256 - (base32 - "1q4xjpx6nbn44kxnilpgl12bhpmwy2bblzwszc2ci7xkf400jcpv"))))))) - (supported-systems '("i686-linux" "x86_64-linux")) - (synopsis "Bootstrap binaries of Mes") - (description synopsis) - (home-page #f) - (license gpl3+))) - (define (%bootstrap-inputs) ;; The initial, pre-built inputs. From now on, we can start building our ;; own packages. (match (%current-system) ((or "i686-linux" "x86_64-linux") - `(("linux-libre-headers" ,%bootstrap-linux-libre-headers) - ("bootstrap-mescc-tools" ,%bootstrap-mescc-tools) - ("mes" ,%bootstrap-mes))) + `(("linux-libre-headers" ,%bootstrap-linux-libre-headers))) (_ `(("libc" ,%bootstrap-glibc) ("gcc" ,%bootstrap-gcc) @@ -1046,7 +944,7 @@ exec ~a/bin/.gcc-wrapped -B~a/lib \ (define %bootstrap-inputs-for-tests ;; These are bootstrap inputs that are cheap to produce (no compilation ;; needed) and that are meant to be used for testing. (These are those we - ;; used before the Mes-based reduced bootstrap.) + ;; used before the Mes-based full-source bootstrap.) `(("libc" ,%bootstrap-glibc) ("gcc" ,%bootstrap-gcc) ("binutils" ,%bootstrap-binutils) diff --git a/gnu/packages/build-tools.scm b/gnu/packages/build-tools.scm index 8a6cfae692..bcca229466 100644 --- a/gnu/packages/build-tools.scm +++ b/gnu/packages/build-tools.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net> ;;; Copyright © 2020 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 qblade <qblade@protonmail.com> -;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022, 2023 Juliana Sims <jtsims@protonmail.com> ;;; ;;; This file is part of GNU Guix. @@ -77,6 +77,7 @@ #:use-module (gnu packages unicode) #:use-module (gnu packages version-control) #:use-module (guix build-system gnu) + #:use-module (guix build-system pyproject) #:use-module (guix build-system python)) (define-public bam @@ -170,41 +171,47 @@ generate such a compilation database.") (define-public bmake (package (name "bmake") - (version "20211212") + (version "20230321") (source (origin (method url-fetch) (uri (string-append "http://www.crufty.net/ftp/pub/sjg/bmake-" version ".tar.gz")) (sha256 - (base32 "17lywks7fy5538vwyyvbvxcq5mgnd5si7f2qgw85sgqj7mdr4xdd")))) + (base32 "0ml2z9ij674bd4227566n0547pcpxpmimp4xw4hj52kl1265czgd")))) (build-system gnu-build-system) (inputs (list bash-minimal)) (native-inputs (list coreutils)) (arguments - `(#:tests? #f ; test during build - #:phases - (modify-phases %standard-phases - (add-after 'configure 'fix-test ; fix from nixpkgs - (lambda _ - (substitute* "unit-tests/unexport-env.mk" - (("PATH=\t/bin:/usr/bin:/sbin:/usr/sbin") - "PATH := ${PATH}")))) - (add-after 'configure 'remove-fail-tests - (lambda _ - (substitute* "unit-tests/Makefile" - (("cmd-interrupt") "") - (("varmod-localtime") ""))))) - #:configure-flags - (list - (string-append - "--with-defshell=" (assoc-ref %build-inputs "bash") "/bin/bash") - (string-append - "--with-default-sys-path=" (assoc-ref %outputs "out") "/share/mk")) - #:make-flags - (list "INSTALL=install"))) ;; use coreutils install + (list + #:tests? #f ; test during build + #:phases + #~(modify-phases %standard-phases + (add-after 'configure 'fix-test ; fix from nixpkgs + (lambda* (#:key inputs native-inputs #:allow-other-keys) + (substitute* "unit-tests/unexport-env.mk" + (("PATH=\t/bin:/usr/bin:/sbin:/usr/sbin") + "PATH := ${PATH}")) + (substitute* '("unit-tests/opt-keep-going-indirect.mk" + "unit-tests/opt-keep-going-indirect.exp") + (("false") + (search-input-file (or native-inputs inputs) "/bin/false"))))) + (add-after 'configure 'remove-fail-tests + (lambda _ + (substitute* "unit-tests/Makefile" + (("cmd-interrupt") "") + (("deptgt-interrupt") "") + (("varmod-localtime") ""))))) + #:configure-flags + #~(list + (string-append + "--with-defshell=" #$(this-package-input "bash-minimal") "/bin/bash") + (string-append + "--with-default-sys-path=" #$output "/share/mk")) + #:make-flags + #~(list "INSTALL=install"))) ;; use coreutils install (home-page "http://www.crufty.net/help/sjg/bmake.htm") (synopsis "BSD's make") (description @@ -283,10 +290,10 @@ files and generates build instructions for the Ninja build system.") ;; X11 license. (license (list license:bsd-3 license:x11))))) -(define-public meson-0.63 +(define-public meson (package (name "meson") - (version "0.63.2") + (version "1.1.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/mesonbuild/meson/" @@ -294,28 +301,23 @@ files and generates build instructions for the Ninja build system.") version ".tar.gz")) (sha256 (base32 - "1gwba75z47m2hv3w08gw8sgqgbknjr7rj1qwr510bgknxwbjy8hn")))) + "17w2zymmvrffhfpqsaj7qcbjwgv9iaawcpzhz2gnhlvcrm26qqfr")))) (build-system python-build-system) (arguments - `(;; FIXME: Tests require many additional inputs and patching many - ;; hard-coded file system locations in "run_unittests.py". - #:tests? #f - #:phases (modify-phases %standard-phases - ;; Meson calls the various executables in out/bin through the - ;; Python interpreter, so we cannot use the shell wrapper. - (replace 'wrap - (lambda* (#:key outputs inputs #:allow-other-keys) - (let ((python-version - (python-version (assoc-ref inputs "python"))) - (output (assoc-ref outputs "out"))) - (substitute* (string-append output "/bin/meson") - (("# EASY-INSTALL-ENTRY-SCRIPT") - (format #f "\ + (list #:tests? #f ;disabled to avoid extra dependencies + #:phases + #~(modify-phases %standard-phases + ;; Meson calls the various executables in out/bin through the + ;; Python interpreter, so we cannot use the shell wrapper. + (replace 'wrap + (lambda* (#:key inputs outputs #:allow-other-keys) + (substitute* (search-input-file outputs "bin/meson") + (("# EASY-INSTALL-ENTRY-SCRIPT") + (format #f "\ import sys -sys.path.insert(0, '~a/lib/python~a/site-packages') -# EASY-INSTALL-ENTRY-SCRIPT" - output python-version))))))))) - (inputs (list python-wrapper ninja)) +sys.path.insert(0, '~a') +# EASY-INSTALL-ENTRY-SCRIPT" (site-packages inputs outputs))))))))) + (inputs (list python ninja)) (home-page "https://mesonbuild.com/") (synopsis "Build system designed to be fast and user-friendly") (description @@ -327,97 +329,28 @@ files}, are written in a custom domain-specific language (@dfn{DSL}) that resembles Python.") (license license:asl2.0))) -(define-public meson-0.60 - (package - (inherit meson-0.63) - (version "0.60.3") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/mesonbuild/meson/" - "releases/download/" version "/meson-" - version ".tar.gz")) - (sha256 - (base32 - "13mrrizg4vl6n5k7fz6amyafnn3i097dcarr552qc0ca6nlmzjl7")) - (patches (search-patches - "meson-allow-dirs-outside-of-prefix.patch")))))) - -;;; This older Meson variant is kept for now for gtkmm and others that may -;;; have problems with 0.60. -(define-public meson-0.59 - (package - (inherit meson-0.60) - (version "0.59.4") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/mesonbuild/meson/" - "releases/download/" version "/meson-" - version ".tar.gz")) - (sha256 - (base32 - "117cm8794h291lca1wljz1pwnzidgbvrpg3mw3np6ksma368hyd7")) - (patches (search-patches - "meson-allow-dirs-outside-of-prefix.patch")))))) - -;; TODO: Bump this in the next rebuild cycle. -(define-public meson meson-0.60) - (define-public meson-python (package (name "meson-python") - (version "0.8.1") + (version "0.12.1") (source (origin (method url-fetch) (uri (pypi-uri "meson_python" version)) (sha256 (base32 - "0k2yn0iws1n184sdznzmfw4xgbqgq5cn02hpc7m0xdaxryj1ybs4")))) - (build-system python-build-system) + "1hpjw9qj6ff8ixjs0pz7qysc8v57jxgaf5n1p6bqm9bh3mc3wnrx")))) + (build-system pyproject-build-system) (arguments - (list #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'avoid-ninja-dependency - (lambda _ - ;; Avoid dependency on the "ninja" PyPI distribution, - ;; which is a meta-package that simply downloads and - ;; installs ninja from the web ... - (substitute* "pyproject.toml" - (("'ninja',") - "")))) - (replace 'build - (lambda _ - ;; ZIP does not support timestamps before 1980. - (setenv "SOURCE_DATE_EPOCH" "315532800") - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'install - (lambda _ - (let ((whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" #$output whl)))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "pytest" "-vv" "tests" "-k" - (string-append - "not " - ;; These tests require a git checkout. - (string-join '("test_contents_unstaged" - "test_no_pep621" - "test_pep621" - "test_dynamic_version" - "test_contents" - "test_contents_subdirs") - " and not "))))))))) + ;; The project is configured to use itself to build ('mesonpy') and fails; + ;; use another PEP 517 build system. + (list #:build-backend "setuptools.build_meta" + #:test-flags #~(list "tests" + ;; The test_pep518 tries to install + ;; dependencies from the network using pip. + "-k" "not test_pep518"))) (propagated-inputs - (list meson-0.63 ;>=0.62 required + (list meson ninja - ;; XXX: python-meson forcefully sets the RUNPATH of binaries - ;; for vendoring purposes, and uses PatchELF for that(!). This - ;; functionality is not useful in Guix, but removing this - ;; dependency is tricky. There is discussion upstream about making - ;; it optional, but for now we'll just carry it: - ;; https://github.com/FFY00/meson-python/issues/125 - patchelf python-colorama python-pyproject-metadata python-tomli @@ -427,14 +360,16 @@ resembles Python.") python-wheel ;; For tests. + git-minimal/pinned + patchelf pkg-config + python-cython python-gitpython python-pytest python-pytest-mock)) - (home-page "https://github.com/FFY00/mesonpy") + (home-page "https://github.com/mesonbuild/meson-python") (synopsis "Meson-based build backend for Python") - (description - "meson-python is a PEP 517 build backend for Meson projects.") + (description "Meson-python is a PEP 517 build backend for Meson projects.") (license license:expat))) (define-public premake4 diff --git a/gnu/packages/calendar.scm b/gnu/packages/calendar.scm index cf4286100d..7cd4911824 100644 --- a/gnu/packages/calendar.scm +++ b/gnu/packages/calendar.scm @@ -11,6 +11,7 @@ ;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org> ;;; Copyright © 2020 Peng Mei Yu <pengmeiyu@riseup.net> ;;; Copyright © 2021 Wamm K. D. <jaft.r@outlook.com> +;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -29,6 +30,7 @@ (define-module (gnu packages calendar) #:use-module (gnu packages) + #:use-module (guix gexp) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix git-download) #:use-module (guix packages) @@ -132,32 +134,26 @@ the <tz.h> library for handling time zones and leap seconds.") "0cqc1wpalxmxjx8dmcaga9w8kd5l7944hqmidz43hifaf7fhaixl")))) (build-system cmake-build-system) (arguments - '(#:tests? #f ; test suite appears broken - #:parallel-build? #f ;may cause GIR generation failure - #:configure-flags '("-DSHARED_ONLY=true" - ;; required by evolution-data-server - "-DGOBJECT_INTROSPECTION=true" - "-DICAL_GLIB_VAPI=true") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-reference - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "doc/reference/libical-glib/libical-glib-docs.sgml.in" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/"))))) - (add-before 'configure 'patch-paths - (lambda* (#:key inputs #:allow-other-keys) - ;; TODO: libical 3.1.0 supports using TZDIR instead of a hard-coded - ;; zoneinfo database. When that is released we can drop - ;; the tzdata dependency. - (let ((tzdata (assoc-ref inputs "tzdata"))) - (substitute* "src/libical/icaltz-util.c" - (("\\\"/usr/share/zoneinfo\\\",") - (string-append "\"" tzdata "/share/zoneinfo\"")) - (("\\\"/usr/lib/zoneinfo\\\",") "") - (("\\\"/etc/zoneinfo\\\",") "") - (("\\\"/usr/share/lib/zoneinfo\\\"") "")))))))) + (list + #:configure-flags #~(list "-DSHARED_ONLY=true" + ;; required by evolution-data-server + "-DGOBJECT_INTROSPECTION=true" + "-DICAL_GLIB_VAPI=true") + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'patch-paths + (lambda* (#:key inputs #:allow-other-keys) + (define zoneinfo (search-input-directory inputs "share/zoneinfo")) + ;; The timezones test fails if TZDIR is not set, for some + ;; reason. If only TZDIR is set, tests checking the timezone + ;; fallback fail, so also patch the source. + (setenv "TZDIR" zoneinfo) ;for tests + (substitute* "src/libical/icaltz-util.c" + (("\\\"/usr/share/zoneinfo\\\",") + (format #f "~s" zoneinfo)) + (("\\\"/usr/lib/zoneinfo\\\",") "") + (("\\\"/etc/zoneinfo\\\",") "") + (("\\\"/usr/share/lib/zoneinfo\\\"") ""))))))) (native-inputs (list docbook-xml-4.3 gobject-introspection diff --git a/gnu/packages/cdrom.scm b/gnu/packages/cdrom.scm index dcb90a634d..16f3efec25 100644 --- a/gnu/packages/cdrom.scm +++ b/gnu/packages/cdrom.scm @@ -251,7 +251,7 @@ reconstruction capability.") (define-public cdrdao (package (name "cdrdao") - (version "1.2.4") + (version "1.2.5") (source (origin (method git-fetch) @@ -261,7 +261,7 @@ reconstruction capability.") (string-append "rel_" (string-replace-substring version "." "_"))))) (file-name (git-file-name name version)) (sha256 - (base32 "1gcl8ibyylamy2d1piq3749nw3xrlp12r0spzp2gmni57b8a6b7j")))) + (base32 "1hh1lm4wr1vhsq2brczn94h88h3bppvjidj9cfqkl20jhaj38968")))) (build-system gnu-build-system) (arguments '(#:configure-flags @@ -275,9 +275,12 @@ reconstruction capability.") (modify-phases %standard-phases (add-before 'bootstrap 'fix-configure.ac (lambda _ - ;; Remove reference to missing macro. - (substitute* "configure.ac" (("^AM_GCONF_SOURCE_2.*") "")) - #t))))) + ;; Remove references to missing macros. + (substitute* "configure.ac" + (("^AM_GCONF_SOURCE_2.*") "") + ;; This was introduced in autoconf-2.70, but is described + ;; as usually not needed in the autoconf documentation. + (("^AC_CHECK_INCLUDES_DEFAULT") ""))))))) (native-inputs (list autoconf automake pkg-config)) (inputs diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 990c6d52df..1ac87578ce 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2015, 2017 Cyril Roelandt <tipecaml@gmail.com> ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch> ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr> -;;; Copyright © 2015, 2016, 2018-2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2015, 2016, 2018-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org> ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org> @@ -35,7 +35,7 @@ ;;; Copyright © 2020 Josh Marshall <joshua.r.marshall.1991@gmail.com> ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net> ;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org> -;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Hugo Lecomte <hugo.lecomte@inria.fr> ;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2022 David Elsing <david.elsing@posteo.net> @@ -100,6 +100,7 @@ #:use-module (guix build-system pyproject) #:use-module (guix build-system python) #:use-module (guix build-system trivial) + #:use-module (guix deprecation) #:use-module (srfi srfi-1)) (define-public pict @@ -257,6 +258,9 @@ source code editors and IDEs.") (base32 "0d22h8xshmbpl9hba9ch3xj8vb9ybm5akpsbbh7yj07fic4h2hj6")))))) +;;; XXX: This project is abandoned upstream, and included in modern catch2 +;;; releases. It is still depended by the restinio test suite at this time, +;;; so keep it (see: https://github.com/Stiffstream/restinio/issues/181). (define-public clara (package (name "clara") @@ -269,16 +273,28 @@ source code editors and IDEs.") (file-name (git-file-name name version)) (sha256 (base32 - "08mlm9ax5d7wkmsihm1xnlgp7rfgff0bfl4ly4850xmrdaxmmkl3")))) + "08mlm9ax5d7wkmsihm1xnlgp7rfgff0bfl4ly4850xmrdaxmmkl3")) + (modules '((guix build utils))) + (snippet '(begin + ;; Un-bundle catch2. + (delete-file-recursively "third_party") + (substitute* "CMakeLists.txt" + (("include_directories\\( include third_party )") + "include_directories( include )")))))) (build-system cmake-build-system) (arguments (list + #:configure-flags + #~(list (string-append "-DCMAKE_CXX_FLAGS=-I" + (search-input-directory %build-inputs + "include/catch2"))) #:phases #~(modify-phases %standard-phases (replace 'install (lambda _ (install-file (string-append #$source "/single_include/clara.hpp") (string-append #$output "/include"))))))) + (native-inputs (list catch2)) (home-page "https://github.com/catchorg/Clara") (synopsis "Simple command line parser for C++") (description "Clara is a simple to use, composable, command line parser @@ -721,7 +737,7 @@ format.") (define-public cppcheck (package (name "cppcheck") - (version "2.3") + (version "2.10") (source (origin (method git-fetch) (uri (git-reference @@ -729,7 +745,7 @@ format.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "03ic5mig3ryzkf85r95ryagf84s7y5nd6sqr915l3zj30apnifvz")))) + (base32 "0riq7jlv21v2p77r01i36ll3klbgnkpsfk1wx4q8p1v5h5zgkkaa")))) (build-system cmake-build-system) (arguments '(#:configure-flags '("-DBUILD_TESTS=ON"))) @@ -943,7 +959,7 @@ test coverage and has a web user interface that will refresh automatically.") (define-public googletest (package (name "googletest") - (version "1.11.0") + (version "1.12.1") (source (origin (method git-fetch) @@ -952,7 +968,7 @@ test coverage and has a web user interface that will refresh automatically.") (commit (string-append "release-" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0pd4y1gpx1z8fiyarkvqlmk6hbv0lc8fr00ivnsvqzi1xg34jfaa")))) + (base32 "1cv55x3amwrvfan9pr8dfnicwr8r6ar3yf6cg9v6nykd6m2v3qsv")))) (build-system cmake-build-system) (arguments `(#:configure-flags '("-DBUILD_SHARED_LIBS=ON"))) @@ -1084,13 +1100,13 @@ syntax validation, ... (define-public python-parameterized (package (name "python-parameterized") - (version "0.7.4") + (version "0.8.1") (source (origin (method url-fetch) (uri (pypi-uri "parameterized" version)) (sha256 - (base32 "1444fdz5bj0k10nmhxv0bv2gfrfisi7hfzqdndb0pvhf4g3qq3qr")))) + (base32 "0p1vhfw552rgd7gb2vy4l4l4k8mnbdz7f3chgzvk0r0qsqvzzfs1")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -1245,57 +1261,55 @@ standard library.") (define-public python-pytest (package (name "python-pytest") - (version "6.2.5") + (version "7.1.3") (source (origin (method url-fetch) (uri (pypi-uri "pytest" version)) (sha256 (base32 - "12cyi0lnyaq8sdqfnqlppd76gkw6zcg10gyih5knx9v611l3c6qk")))) + "0f8c31v5r2kgjixvy267n0nhc4xsy65g3n9lz1i1377z5pn5ydjg")) + (patches (search-patches "pytest-fix-unstrable-exception-test.patch")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'build 'pretend-version - ;; The version string is usually derived via setuptools-scm, but - ;; without the git metadata available, the version string is set to - ;; '0.0.0'. - (lambda _ - (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" ,version))) - (replace 'check - (lambda* (#:key (tests? #t) #:allow-other-keys) - (setenv "TERM" "dumb") ;attempt disabling markup tests - (if tests? - (invoke "pytest" "-vv" "-k" - (string-append - ;; This test involves the /usr directory, and fails. - " not test_argcomplete" - ;; These test do not honor the isatty detection and - ;; fail. - " and not test_code_highlight" - " and not test_color_yes")) - (format #t "test suite not run~%"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, but + ;; without the git metadata available, the version string is set to + ;; '0.0.0'. + (lambda _ + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" + #$(package-version this-package)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (setenv "TERM" "dumb") ;attempt disabling markup tests + (if tests? + (invoke "pytest" "-vv" "-k" + (string-append + ;; This test involves the /usr directory, and fails. + " not test_argcomplete" + ;; These test do not honor the isatty detection and + ;; fail. + " and not test_code_highlight" + " and not test_color_yes")) + (format #t "test suite not run~%"))))))) (propagated-inputs - `(("python-attrs" ,python-attrs-bootstrap) - ("python-iniconfig" ,python-iniconfig) - ("python-more-itertools" ,python-more-itertools) - ("python-packaging" ,python-packaging-bootstrap) - ("python-pluggy" ,python-pluggy) - ("python-py" ,python-py) - ("python-six" ,python-six-bootstrap) - ("python-toml" ,python-toml) - ("python-wcwidth" ,python-wcwidth))) + (list python-attrs-bootstrap + python-iniconfig + python-packaging-bootstrap + python-pluggy + python-py + python-tomli)) (native-inputs - `(;; Tests need the "regular" bash since 'bash-final' lacks `compgen`. - ("bash" ,bash) - ("python-hypothesis" ,python-hypothesis) - ("python-nose" ,python-nose) - ("python-mock" ,python-mock) - ("python-pytest" ,python-pytest-bootstrap) - ("python-setuptools-scm" ,python-setuptools-scm) - ("python-toml" ,python-toml) - ("python-xmlschema" ,python-xmlschema))) + ;; Tests need the "regular" bash since 'bash-final' lacks `compgen`. + (list bash + python-hypothesis + python-nose + python-pytest-bootstrap + python-setuptools-scm + python-xmlschema)) (home-page "https://docs.pytest.org/en/latest/") (synopsis "Python testing library") (description @@ -1304,40 +1318,18 @@ and functions, detailed info on failing assert statements, modular fixtures, and many external plugins.") (license license:expat))) -(define-public python-pytest-6 python-pytest) +(define-deprecated python-pytest-6 python-pytest) +(export python-pytest-6) -;; Astropy started using hard dependencies for Pytest 7+, which might -;; happen for some other projects. It could be set as default in staging. -(define-public python-pytest-7.1 - (package - (inherit python-pytest) - (version "7.1.3") - (name "python-pytest") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pytest" version)) - (sha256 - (base32 - "0f8c31v5r2kgjixvy267n0nhc4xsy65g3n9lz1i1377z5pn5ydjg")))) - (arguments - (substitute-keyword-arguments (package-arguments python-pytest) - ((#:phases phases #~%standard-phases) - #~(modify-phases #$phases - (add-before 'build 'pretend-version - (lambda _ - (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version))))))) - (propagated-inputs - (modify-inputs (package-propagated-inputs python-pytest) - (replace "python-pluggy" python-pluggy-next) - (replace "python-toml" python-tomli))))) +(define-deprecated python-pytest-7 python-pytest) +(export python-pytest-7) (define-public python-pytest-bootstrap (package (inherit python-pytest) (name "python-pytest-bootstrap") (native-inputs (list python-iniconfig python-setuptools-scm - python-toml)) + python-tomli)) (arguments `(#:tests? #f)))) (define-public python-pytest-assume @@ -1527,28 +1519,39 @@ Python's @code{random.seed}.") (define-public python-pytest-runner (package (name "python-pytest-runner") - (version "5.2") + (version "6.0.0") (source (origin (method url-fetch) (uri (pypi-uri "pytest-runner" version)) (sha256 (base32 - "0awll1bva5zy8cspsxcpv7pjcrdf5c6pf56nqn4f74vvmlzfgiwn")))) + "11dnhxnjmh4nf1j8rnvx944ha3wg8ggrgrwdcx4c7d19xmi57n5l")))) (build-system python-build-system) (arguments - '(;; FIXME: The test suite requires 'python-flake8' and 'python-black', - ;; but that introduces a circular dependency. - #:tests? #f - #:phases (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (if tests? - (invoke "pytest" "-vv") - (format #t "test suite not run~%")) - #t))))) + (list + ;; FIXME: The test suite requires 'python-flake8' and 'python-black', + ;; but that introduces a circular dependency. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (replace 'build + (lambda _ + (let ((circa-1980 (* 10 366 24 60 60))) + (setenv "SOURCE_DATE_EPOCH" (number->string circa-1980)) + (invoke "python" "-m" "build" "--wheel" "--no-isolation" ".")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (if tests? + (invoke "pytest" "-vv") + (format #t "test suite not run~%"))))))) (native-inputs - (list python-setuptools-scm)) + (list python-pypa-build python-setuptools-scm python-wheel)) (home-page "https://github.com/pytest-dev/pytest-runner") (synopsis "Invoke py.test as a distutils command") (description @@ -1632,44 +1635,26 @@ same arguments.") (define-public python-pytest-xdist (package (name "python-pytest-xdist") - (version "2.1.0") + (version "2.5.0") (source (origin (method url-fetch) (uri (pypi-uri "pytest-xdist" version)) (sha256 (base32 - "0wh6pn66nncfs6ay0n863bgyriwsgppn8flx5l7551j1lbqkinc2")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Remove pre-compiled .pyc files from source. - (for-each delete-file-recursively - (find-files "." "__pycache__" #:directories? #t)) - (for-each delete-file (find-files "." "\\.pyc$")) - #t)))) + "1psf5dqxvc38qzxvc305mkg5xpdmdkbkkfiyqlmdnkgh7z5dx025")))) (build-system python-build-system) (arguments - '(#:tests? #f ; Lots of tests fail. - #:phases + '(#:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-setup-py - (lambda _ - ;; Relax pytest requirement. - (substitute* "setup.py" - (("pytest>=6\\.0\\.0") "pytest")))) (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) (invoke "pytest" "-vv" "-n" (number->string (parallel-job-count))))))))) - (native-inputs - (list python-setuptools-scm)) - (propagated-inputs - (list python-execnet python-pytest python-py python-pytest-forked)) - (home-page - "https://github.com/pytest-dev/pytest-xdist") + (native-inputs (list python-setuptools-scm python-filelock python-pytest)) + (propagated-inputs (list python-execnet python-pytest-forked)) + (home-page "https://github.com/pytest-dev/pytest-xdist") (synopsis "Plugin for py.test with distributed testing and loop-on-failing modes") (description @@ -1681,20 +1666,6 @@ program code to a remote location, executes there, and then syncs the result back.") (license license:expat))) -(define-public python-pytest-xdist-next - (package/inherit python-pytest-xdist - (name "python-pytest-xdist") - (version "2.5.0") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pytest-xdist" version)) - (sha256 - (base32 - "1psf5dqxvc38qzxvc305mkg5xpdmdkbkkfiyqlmdnkgh7z5dx025")))) - (propagated-inputs (list python-execnet python-pytest - python-pytest-forked-next)))) - (define-public python-pytest-timeout (package (name "python-pytest-timeout") @@ -1728,7 +1699,7 @@ timeout has been exceeded.") (define-public python-pytest-forked (package (name "python-pytest-forked") - (version "1.3.0") + (version "1.6.0") (source (origin (method git-fetch) ;for tests @@ -1738,29 +1709,23 @@ timeout has been exceeded.") (file-name (git-file-name name version)) (sha256 (base32 - "1aip4kx50ynvykl7kq2mlbsi82vx701dvb8mm64lhp69bbv105rc")))) - (build-system python-build-system) + "1y93q914gwf0nshql1qix6sj826q163b04vw17zmwhsnbv00c2d3")))) + (build-system pyproject-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-setuptools-scm - (lambda _ - (substitute* "setup.py" - (("use_scm_version=True") - (format #f "version=~s" ,version)) - (("setup_requires=\\['setuptools_scm'\\],.*") - "")))) - (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv"))))))) + (list #:phases + #~(modify-phases %standard-phases + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, + ;; but without the git metadata available, the version string + ;; is set to '0.0.0'. + (lambda _ + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version)))))) (native-inputs ;; XXX: The bootstrap variant of Pytest is used to ensure the ;; 'hypothesis' plugin is not in the environment (due to ;; <http://issues.guix.gnu.org/25235>), which would cause the test suite ;; to fail (see: https://github.com/pytest-dev/pytest-forked/issues/54). - `(("python-pytest" ,python-pytest-bootstrap))) + (list python-pytest-bootstrap python-setuptools-scm)) (home-page "https://github.com/pytest-dev/pytest-forked") (synopsis "Pytest plugin to run tests in isolated forked subprocesses") (description "This package provides a Pytest plugin which enables running @@ -1769,23 +1734,6 @@ can be useful to isolate tests against undesirable global environment side-effects (such as setting environment variables).") (license license:expat))) -(define-public python-pytest-forked-next - (package - (inherit python-pytest-forked) - (name "python-pytest-forked") - (version "1.4.0") - (source - (origin - (method git-fetch) ;for tests - (uri (git-reference - (url "https://github.com/pytest-dev/pytest-forked") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0j9bbjny7h3b4fig6l26f26c697r67mm62fzdd9m9rqyy2bmnqjs")))) - (native-inputs (list python-pytest-bootstrap python-setuptools-scm)))) - (define-public python-scripttest (package (name "python-scripttest") @@ -1811,19 +1759,18 @@ subprocess and see the output as well as any file modifications.") (define-public python-testtools-bootstrap (package (name "python-testtools-bootstrap") - (version "2.5.0") + (version "2.6.0") (source (origin (method url-fetch) (uri (pypi-uri "testtools" version)) (sha256 (base32 - "0gxjbjk93jjqi491k4s9rh3ia37v21yifd35pvizv7sgv4rk9hap")))) + "02mkphygx8897617m8qnmj0alksyvvfcjmazzfxyrlzjq0a5xdi8")))) (build-system python-build-system) (arguments '(#:tests? #f)) (propagated-inputs - `(("python-extras" ,python-extras) - ("python-fixtures" ,python-fixtures-bootstrap) + `(("python-fixtures" ,python-fixtures-bootstrap) ("python-pbr" ,python-pbr-minimal))) (home-page "https://github.com/testing-cabal/testtools") (synopsis @@ -1845,7 +1792,7 @@ subprocess and see the output as well as any file modifications.") (invoke "python" "-m" "testtools.run" "testtools.tests.test_suite"))))))) (propagated-inputs - (list python-extras python-fixtures python-pbr)) + (list python-fixtures python-pbr)) (native-inputs `(("python-testscenarios" ,python-testscenarios-bootstrap))) (description @@ -1985,7 +1932,7 @@ protocol."))) ;; Package is not loadable on its own at this stage. (delete 'sanity-check)))) (propagated-inputs - (list python-pbr-minimal python-six)) + (list python-pbr-minimal python-six python-extras)) (home-page "https://launchpad.net/python-fixtures") (synopsis "Python test fixture library") (description @@ -2007,7 +1954,7 @@ python-fixtures package instead.") "fixtures.test_suite"))))))) (propagated-inputs ;; Fixtures uses pbr at runtime to check versions, etc. - (list python-pbr python-six)) + (list python-pbr python-six python-extras)) (native-inputs `(("python-mock" ,python-mock) ("python-testtools" ,python-testtools-bootstrap))) @@ -2058,18 +2005,20 @@ have failed since the last commit or what tests are currently failing."))) (define-public python-coverage (package (name "python-coverage") - (version "5.5") + (version "6.4.3") (source (origin (method url-fetch) (uri (pypi-uri "coverage" version)) (sha256 (base32 - "0b112ly7vvplvm9l411aqknxhr7fzfyp28xhflhkcx78l3lqzrzb")))) + "157vndwrzyv9ypn2w3b6g8gv7vw07v994hq8nxasdb75k3ry2apc")))) (build-system python-build-system) (arguments ;; FIXME: 95 tests failed, 539 passed, 6 skipped, 2 errors. '(#:tests? #f)) + (propagated-inputs + (list python-tomli)) (home-page "https://coverage.readthedocs.io") (synopsis "Code coverage measurement for Python") (description @@ -2082,7 +2031,7 @@ executed.") (define-public python-pytest-asyncio (package (name "python-pytest-asyncio") - (version "0.17.2") + (version "0.21.0") (source (origin (method git-fetch) ;for tests @@ -2091,24 +2040,18 @@ executed.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0sl0ckc23m40q6r2xcidsizrgqbbsfa7rwmr80fss359xsydf073")))) - (build-system python-build-system) + (base32 "03wljn0gdwyfr5s1795w3h2mfvvi23bn42nwjv5568rgphqyldqq")))) + (build-system pyproject-build-system) (arguments - (list #:phases + (list #:tests? #f ;XXX: to avoid a cycle with python-pytest-trio + #:phases #~(modify-phases %standard-phases (add-after 'unpack 'pretend-version (lambda _ (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" - #$(package-version this-package)))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (invoke "pytest" "-vv" "tests")))))) - (native-inputs - (list python-async-generator - python-flaky - python-hypothesis - python-pytest - python-setuptools-scm)) + #$(package-version this-package))))))) + (native-inputs (list python-setuptools-scm)) + (propagated-inputs (list python-pytest)) (home-page "https://github.com/pytest-dev/pytest-asyncio") (synopsis "Pytest support for asyncio") (description "Python asyncio code is usually written in the form of @@ -2250,13 +2193,13 @@ the last py.test invocation.") (define-public python-pytest-localserver (package (name "python-pytest-localserver") - (version "0.5.0") + (version "0.7.1") (source (origin (method url-fetch) (uri (pypi-uri "pytest-localserver" version)) (sha256 (base32 - "1hpgpxrpfq5c731ndnsay2lc0y9nh2wy9fn1f83s3z8xkn82fm1s")))) + "0fzysfzvlc2p5dh6lhs5sq3h8g4mypwvqm4w44fr6f5lbialcyz7")))) (build-system python-build-system) (arguments '(#:phases @@ -2341,20 +2284,24 @@ instantly.") (define-public python-hypothesis (package (name "python-hypothesis") - (version "6.0.2") + (version "6.54.5") (source (origin (method url-fetch) (uri (pypi-uri "hypothesis" version)) (sha256 (base32 - "0wj7ip779naf2n076nylf2gi0sjz68z1ir9d9r2rgs7br18naqdf")))) + "1ivyrjpnahvj359pfndnk8x3h0gw37kqm02fmnzibx4mas15d44a")))) (build-system python-build-system) (arguments ;; XXX: Tests are not distributed with the PyPI archive. - '(#:tests? #f)) + (list #:tests? #f + #:phases + #~(modify-phases %standard-phases + ;; XXX: hypothesis requires pytest at runtime, but we can + ;; not propagate it due to a circular dependency. + (delete 'sanity-check)))) (propagated-inputs - `(("python-attrs" ,python-attrs-bootstrap) - ("python-sortedcontainers" ,python-sortedcontainers))) + (list python-attrs-bootstrap python-exceptiongroup python-sortedcontainers)) (synopsis "Library for property based testing") (description "Hypothesis is a library for testing your Python code against a much larger range of examples than you would ever want to write by hand. It’s @@ -2363,20 +2310,8 @@ seamlessly into your existing Python unit testing work flow.") (home-page "https://hypothesis.works/") (license license:mpl2.0))) -;;; TODO: Make the default python-hypothesis in the next rebuild cycle. -(define-public python-hypothesis-next - (package - (inherit python-hypothesis) - (version "6.43.3") - (source (origin - (method url-fetch) - (uri (pypi-uri "hypothesis" version)) - (sha256 - (base32 - "0d67dlc5a47i48fxzmji2mnybzby0h1wdscmj54555fghcyp1045")))) - (propagated-inputs - (modify-inputs (package-propagated-inputs python-hypothesis) - (append python-pytest))))) ;to satisfy the sanity-check phase +(define-deprecated python-hypothesis-next python-hypothesis) +(export python-hypothesis-next) (define-public python-hypothesmith (package @@ -2402,23 +2337,24 @@ programs, something like CSmith, a random generator of C programs.") (define-public python-lit (package (name "python-lit") - (version "14.0.3") + (version "16.0.0") (source (origin (method url-fetch) (uri (pypi-uri "lit" version)) (sha256 (base32 - "162x7pddwl395c3mdb0mfn3f5z24x1jz6g27x303lfxpzidnn4m4")))) + "04dyv8b2nbdbn61zdgm042a21dwidyapn9zbinlf879a29rc6jiw")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check - (lambda _ - (invoke "python" "lit.py" "tests")))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "lit.py" "tests"))))))) (native-inputs - (list llvm)) + (list llvm-14)) (home-page "https://llvm.org/") (synopsis "LLVM Software Testing Tool") (description "@code{lit} is a portable tool for executing LLVM and Clang @@ -2628,13 +2564,13 @@ each of the environments.") (define-public python-pytest-flakes (package (name "python-pytest-flakes") - (version "4.0.1") + (version "4.0.5") (source (origin (method url-fetch) (uri (pypi-uri "pytest-flakes" version)) (sha256 (base32 - "0045h3hnrkn2jwr42jgy2j98npx4amwr6wxzi9j0nppaqz33l49p")))) + "0959qfxb4ayvfxvmpargvh4zfhwdq5l77gczhzv33bhmfblk8ccm")))) (build-system python-build-system) (arguments `(#:phases @@ -2647,8 +2583,7 @@ each of the environments.") (add-installed-pythonpath inputs outputs) (invoke "py.test" "-vv" "-k" "not test_syntax_error")))))) (native-inputs - (list python-coverage python-pytest python-pytest-cache - python-pytest-pep8)) + (list python-coverage python-pytest python-pytest-pep8)) (propagated-inputs (list python-pyflakes)) (home-page "https://github.com/fschulze/pytest-flakes") @@ -2689,7 +2624,7 @@ statements in the module it tests.") (define-public python-pylint (package (name "python-pylint") - (version "2.12.2") + (version "2.14.5") (source (origin (method git-fetch) @@ -2698,7 +2633,7 @@ statements in the module it tests.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0spmy7j1vvh55shzgma80q61y0d1cj45dcgslb4g5w3y602miq5i")))) + (base32 "0ljfvyzr2i07pi7m19kbshlc3cfnwr53mjhcpydaa0w8bak4cc95")))) (build-system python-build-system) (arguments `(#:phases @@ -2717,10 +2652,11 @@ statements in the module it tests.") (list python-pytest python-pytest-xdist)) (propagated-inputs (list python-astroid + python-dill python-isort python-mccabe python-platformdirs - python-toml + python-tomlkit python-typing-extensions)) (home-page "https://github.com/PyCQA/pylint") (synopsis "Advanced Python code static checker") @@ -3192,7 +3128,7 @@ portable to just about any platform.") (define-public libfaketime (package (name "libfaketime") - (version "0.9.9") + (version "0.9.10") (home-page "https://github.com/wolfcw/libfaketime") (source (origin (method git-fetch) @@ -3201,42 +3137,40 @@ portable to just about any platform.") (commit (string-append "v" version)))) (sha256 (base32 - "1gi1xciqga5hl2xlk7rc3j8wy47ag97pi7ngmdl6ny1d11b2wn1z")) + "112l7x2gv4f47hpffpb8djfwvgrs8w5h9s266h1fshi1c916x10d")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (arguments - `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'embed-date-reference - (lambda* (#:key inputs #:allow-other-keys) - (let ((coreutils (assoc-ref inputs "coreutils"))) - (substitute* "src/faketime.c" - (("\"date\"") - (string-append "\"" coreutils "/bin/date\"")))))) - (replace 'configure - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (setenv "CC" ,(cc-for-target)) - (setenv "PREFIX" out) - - ;; XXX: Without this flag, the CLOCK_REALTIME test hangs - ;; indefinitely. See README.packagers for more information. - ;; There are specific instructions to not enable more flags - ;; than absolutely needed. - ,(if (or (target-ppc64le?) - (target-riscv64?)) - `(setenv "FAKETIME_COMPILE_CFLAGS" - "-DFORCE_MONOTONIC_FIX -DFORCE_PTHREAD_NONVER") - `(setenv "FAKETIME_COMPILE_CFLAGS" - "-DFORCE_MONOTONIC_FIX"))))) - (add-before 'check 'pre-check - (lambda _ - (substitute* "test/functests/test_exclude_mono.sh" - (("/bin/bash") (which "bash")))))) - #:test-target "test")) - (native-inputs - (list perl)) ;for tests - (inputs - (list coreutils)) + (list + #:test-target "test" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'embed-date-reference + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "src/faketime.c" + (("\"date\"") + (format #f "~s" (search-input-file inputs "bin/date")))))) + (replace 'configure + (lambda* (#:key outputs #:allow-other-keys) + (setenv "CC" #$(cc-for-target)) + (setenv "PREFIX" #$output) + + ;; XXX: Without this flag, the CLOCK_REALTIME test hangs + ;; indefinitely. See README.packagers for more information. + ;; There are specific instructions to not enable more flags + ;; than absolutely needed. + #$@(if (or (target-ppc64le?) + (target-riscv64?)) + #~((setenv "FAKETIME_COMPILE_CFLAGS" + "-DFORCE_MONOTONIC_FIX -DFORCE_PTHREAD_NONVER")) + #~((setenv "FAKETIME_COMPILE_CFLAGS" + "-DFORCE_MONOTONIC_FIX"))))) + (add-before 'check 'pre-check + (lambda _ + (substitute* "test/functests/test_exclude_mono.sh" + (("/bin/bash") (which "bash")))))))) + (native-inputs (list perl)) ;for tests + (inputs (list coreutils-minimal)) (synopsis "Fake the system time for single applications") (description "The libfaketime library allows users to modify the system time that an @@ -3340,7 +3274,7 @@ grew out of the @dfn{Vc} project.") (define-public python-pyfakefs (package (name "python-pyfakefs") - (version "3.7.1") + (version "4.6.3") (source (origin (method url-fetch) ;; We use the PyPI URL because there is no proper release @@ -3349,22 +3283,13 @@ grew out of the @dfn{Vc} project.") (uri (pypi-uri "pyfakefs" version)) (sha256 (base32 - "1cp2yw96fa2qkgi39xa3nlr3inf8wb5rgh9kdq53256ca2r8pdhy")) + "18bcv8yalg80zgigx40fk692yr3wf9ch1hkb0cdplqspyry2mwbd")) (patches (search-patches "python-pyfakefs-remove-bad-test.patch")) (file-name (string-append name "-" version ".tar.gz")))) (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-testsuite - (lambda _ - ;; Time difference is larger than expected. - (substitute* "pyfakefs/tests/fake_filesystem_unittest_test.py" - (("(\\s+)def test_copy_real_file" all indent) - (string-append - indent - "@unittest.skip('disabled by guix')\n" - all))))) ;; The default test suite does not run these extra tests. (add-after 'check 'check-pytest-plugin (lambda _ diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm index 3c6d47464a..cddccf8aea 100644 --- a/gnu/packages/chemistry.scm +++ b/gnu/packages/chemistry.scm @@ -900,7 +900,7 @@ emphasis on quality rather than speed.") (native-inputs (list gfortran (texlive-updmap.cfg (list texlive-fonts-ec - texlive-latex-graphics + texlive-graphics texlive-latex-geometry)))) (home-page "https://github.com/greglandrum/yaehmop") (synopsis "Perform extended Hückel calculations") diff --git a/gnu/packages/chromium.scm b/gnu/packages/chromium.scm index 94e22d8c21..22e22cdbf8 100644 --- a/gnu/packages/chromium.scm +++ b/gnu/packages/chromium.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019-2023 Marius Bakke <marius@gnu.org> ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com> +;;; Copyright © 2023 Andreas Enge <andreas@enge.fr> ;;; ;;; This file is part of GNU Guix. ;;; @@ -318,7 +319,9 @@ (define %chromium-version "109.0.5414.119") (define %ungoogled-revision (string-append %chromium-version "-1")) -(define %debian-revision "debian/102.0.5005.61-1") +(define %debian-revision "debian/103.0.5060.53-1") + ;; This is the first release supporting openjpeg@2.5 in openjpeg.patch; + ;; it still includes jsoncpp.patch, which also appears to be needed. (define %arch-revision "a0b214b3bdfbc7ee3d9004a70494a2b9e3da2c80") (define %ungoogled-origin @@ -342,7 +345,7 @@ ((_ version) version)))) (sha256 (base32 - "1ln6r1qzlr7dsgvcbssvvc34my4mpkwv9hmvlb2dhjncs7isp65j")))) + "0bmbp1y0cykcbjhvsk330d11f7qnwmapcwxv76vdbl8cjfb6h60w")))) (define (origin-file origin file) (computed-file @@ -355,7 +358,8 @@ (define %debian-patches (map debian-patch - '("system/jsoncpp.patch" + '("fixes/clang-and-gcc11.patch" + "system/jsoncpp.patch" "system/zlib.patch" "system/openjpeg.patch"))) @@ -894,8 +898,7 @@ wayland)) (inputs (list alsa-lib - atk - at-spi2-atk + at-spi2-core cups curl dbus @@ -909,8 +912,8 @@ gdk-pixbuf glib gtk+ - harfbuzz-5 - icu4c-71 + harfbuzz + icu4c jsoncpp lcms libevent diff --git a/gnu/packages/cluster.scm b/gnu/packages/cluster.scm index 4db64d5d19..6e4055736a 100644 --- a/gnu/packages/cluster.scm +++ b/gnu/packages/cluster.scm @@ -132,7 +132,7 @@ ;; For the documentation. docbook-xml docbook-xml-4.4 ;used by documentation/ra2refentry.xsl - docbook-xsl-next + docbook-xsl libxml2 ;for XML_CATALOG_FILES libxslt ;for xsltproc ruby-asciidoctor)) diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index d9b996986b..bccb035854 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -31,6 +31,7 @@ (define-module (gnu packages cmake) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix utils) @@ -99,8 +100,7 @@ using the CMake build system.") (lambda _ (delete-file "Auxiliary/cmake-mode.el") (substitute* "Auxiliary/CMakeLists.txt" - ((".*cmake-mode.el.*") "")) - #t)) + ((".*cmake-mode.el.*") "")))) ,@(if (target-x86-32?) '((add-after 'unpack 'skip-cpack-txz-test (lambda _ @@ -124,8 +124,7 @@ using the CMake build system.") "Source/cmExecProgramCommand.cxx" "Tests/CMakeLists.txt" "Tests/RunCMake/File_Generate/RunCMakeTest.cmake") - (("/bin/sh") (which "sh"))) - #t)))) + (("/bin/sh") (which "sh"))))))) (define %common-disabled-tests '(;; This test copies libgcc_s.so.1 from GCC and tries to modify its RPATH, @@ -143,6 +142,8 @@ using the CMake build system.") ;; be available along with the required headers. "Utilities/cmlibarchive/libarchive/archive_getdate.c" "Utilities/cmlibarchive/libarchive/archive_getdate.h" + ;; ELF headers. + "Utilities/cmelf" ;; CMake header wrappers. "Utilities/cm3p")) @@ -151,7 +152,7 @@ using the CMake build system.") (define-public cmake-bootstrap (package (name "cmake-bootstrap") - (version "3.21.4") + (version "3.24.2") (source (origin (method url-fetch) (uri (string-append "https://cmake.org/files/v" @@ -159,71 +160,71 @@ using the CMake build system.") "/cmake-" version ".tar.gz")) (sha256 (base32 - "0y2rk316j9m1iqimgwah0z1ii3ggli65dw6hdn4ckx0mqaahlmyr")) - (patches (search-patches "cmake-curl-certificates.patch")))) + "1ny8y2dzc6fww9gzb1ml0vjpx4kclphjihkxagxigprxdzq2140d")) + (patches (search-patches "cmake-curl-certificates-3.24.patch")))) (build-system gnu-build-system) (arguments - `(#:test-target "test" - #:configure-flags - (let ((out (assoc-ref %outputs "out")) - (parallel-job-count (number->string (parallel-job-count)))) - (list "--verbose" - (string-append "--parallel=" parallel-job-count) - (string-append "--prefix=" out) - "--system-libs" - "--no-system-jsoncpp" - ;; By default, the man pages and other docs land - ;; in PREFIX/man and PREFIX/doc, but we want them - ;; in share/{man,doc}. Note that unlike - ;; autoconf-generated configure scripts, cmake's - ;; configure prepends "PREFIX/" to what we pass - ;; to --mandir and --docdir. - "--mandir=share/man" - ,(string-append "--docdir=share/doc/cmake-" - (version-major+minor version)) + (list + #:test-target "test" + #:configure-flags + #~(let ((parallel-job-count (number->string (parallel-job-count)))) + (list "--verbose" + (string-append "--parallel=" parallel-job-count) + (string-append "--prefix=" #$output) + "--system-libs" + ;; By default, the man pages and other docs land + ;; in PREFIX/man and PREFIX/doc, but we want them + ;; in share/{man,doc}. Note that unlike + ;; autoconf-generated configure scripts, cmake's + ;; configure prepends "PREFIX/" to what we pass + ;; to --mandir and --docdir. + "--mandir=share/man" + (string-append "--docdir=share/doc/cmake-" + #$(version-major+minor version)) - ;; By default CMake is built without any optimizations. Use - ;; the recommended Release target for a ~2.5x speedup. - "--" "-DCMAKE_BUILD_TYPE=Release")) - #:make-flags - (let ((skipped-tests - (list ,@%common-disabled-tests - "CTestTestSubdir" ; This test fails to build 2 of the 3 tests. - ;; This test fails when ARGS (below) is in use, see - ;; <https://gitlab.kitware.com/cmake/cmake/issues/17165>. - "CTestCoverageCollectGCOV"))) - (list - (string-append - ;; These arguments apply for the tests only. - "ARGS=-j " (number->string (parallel-job-count)) - " --output-on-failure" - " --exclude-regex ^\\(" (string-join skipped-tests "\\|") "\\)$"))) - #:phases - (modify-phases %standard-phases - ,@(%common-build-phases) - (add-before 'configure 'set-paths - (lambda _ - ;; Help cmake's bootstrap process to find system libraries - (begin - (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH")) - (setenv "CMAKE_INCLUDE_PATH" (or (getenv "CPATH") - (getenv "C_INCLUDE_PATH"))) - #t))) - ;; CMake uses its own configure script. - (replace 'configure - (lambda* (#:key (configure-flags '()) #:allow-other-keys) - (apply invoke "./configure" configure-flags)))))) + ;; By default CMake is built without any optimizations. Use + ;; the recommended Release target for a ~2.5x speedup. + "--" "-DCMAKE_BUILD_TYPE=Release")) + #:make-flags + #~(let ((skipped-tests + (list #$@%common-disabled-tests + "CTestTestSubdir" ; This test fails to build 2 of the 3 tests. + ;; This test fails when ARGS (below) is in use, see + ;; <https://gitlab.kitware.com/cmake/cmake/issues/17165>. + "CTestCoverageCollectGCOV"))) + (list + (string-append + ;; These arguments apply for the tests only. + "ARGS=-j " (number->string (parallel-job-count)) + " --output-on-failure" + " --exclude-regex ^\\(" (string-join skipped-tests "\\|") "\\)$"))) + #:phases + #~(modify-phases %standard-phases + #$@(%common-build-phases) + (add-before 'configure 'set-paths + (lambda _ + ;; Help cmake's bootstrap process to find system libraries + (begin + (setenv "CMAKE_LIBRARY_PATH" (getenv "LIBRARY_PATH")) + (setenv "CMAKE_INCLUDE_PATH" (or (getenv "CPATH") + (getenv "C_INCLUDE_PATH")))))) + ;; CMake uses its own configure script. + (replace 'configure + (lambda* (#:key (configure-flags '()) #:allow-other-keys) + (apply invoke "./configure" configure-flags)))))) (inputs - `(("bzip2" ,bzip2) - ("curl" ,curl) - ("expat" ,expat) - ("file" ,file) - ("libarchive" ,libarchive) - ,@(if (hurd-target?) - '() - `(("libuv" ,libuv))) ;not supported on the Hurd - ("rhash" ,rhash) - ("zlib" ,zlib))) + (append + (if (hurd-target?) + '() + (list libuv)) ;not supported on the Hurd + (list bzip2 + curl + expat + file + jsoncpp + libarchive + rhash + zlib))) (native-search-paths (list (search-path-specification (variable "CMAKE_PREFIX_PATH") @@ -284,49 +285,45 @@ and workspaces that can be used in the compiler environment of your choice.") "Utilities" lstat) #t)))) - (inputs - (modify-inputs (package-inputs cmake-bootstrap) - (prepend jsoncpp))) (build-system cmake-build-system) (arguments - `(#:configure-flags - (list "-DCMAKE_USE_SYSTEM_LIBRARIES=ON" - (string-append "-DCMAKE_DOC_DIR=share/doc/cmake-" - ,(version-major+minor (package-version - cmake-bootstrap)))) + (list + #:configure-flags + #~(list "-DCMAKE_USE_SYSTEM_LIBRARIES=ON" + (string-append "-DCMAKE_DOC_DIR=share/doc/cmake-" + #$(version-major+minor (package-version + cmake-bootstrap)))) - ;; This is the CMake used in cmake-build-system. Ensure compiler - ;; optimizations are enabled to save size and CPU cycles. - #:build-type "Release" - #:phases - (modify-phases %standard-phases - ,@(%common-build-phases) - (add-after 'install 'delete-help-documentation - (lambda* (#:key outputs #:allow-other-keys) - (delete-file-recursively - (string-append (assoc-ref outputs "out") + ;; This is the CMake used in cmake-build-system. Ensure compiler + ;; optimizations are enabled to save size and CPU cycles. + #:build-type "Release" + #:phases + #~(modify-phases %standard-phases + #$@(%common-build-phases) + (add-after 'install 'delete-help-documentation + (lambda _ + (delete-file-recursively + (string-append #$output "/share/cmake-" - ,(version-major+minor + #$(version-major+minor (package-version cmake-bootstrap)) - "/Help")) - #t)) - (replace 'check - (lambda* (#:key tests? parallel-tests? #:allow-other-keys) - (let ((skipped-tests (list ,@%common-disabled-tests - ;; This test requires the bundled libuv. - "BootstrapTest"))) - (if tests? - (begin - (invoke "ctest" "-j" (if parallel-tests? - (number->string (parallel-job-count)) - "1") - "--exclude-regex" - (string-append "^(" (string-join skipped-tests "|") ")$"))) - (format #t "test suite not run~%")) - #t)))) - ,@(if (%current-target-system) - '() - `(#:cmake ,cmake-bootstrap)))))) + "/Help")))) + (replace 'check + (lambda* (#:key tests? parallel-tests? #:allow-other-keys) + (let ((skipped-tests (list #$@%common-disabled-tests + ;; This test requires the bundled libuv. + "BootstrapTest"))) + (if tests? + (begin + (invoke "ctest" "-j" (if parallel-tests? + (number->string (parallel-job-count)) + "1") + "--exclude-regex" + (string-append "^(" (string-join skipped-tests "|") ")$"))) + (format #t "test suite not run~%")))))) + #:cmake (if (%current-target-system) + cmake-minimal-cross + cmake-bootstrap))))) ;;; The "user-facing" CMake, now with manuals and HTML documentation. (define-public cmake @@ -363,27 +360,25 @@ and workspaces that can be used in the compiler environment of your choice.") ((#:build-type _ #f) "RelWithDebInfo") ((#:configure-flags flags ''()) - `(append (list "-DSPHINX_INFO=ON" "-DSPHINX_MAN=ON" "-DSPHINX_HTML=ON" - (string-append "-DCMAKE_DOC_DIR=share/doc/cmake-" - ,(version-major+minor (package-version - cmake-minimal))) - "-DCMAKE_INFO_DIR=share/info" - "-DCMAKE_MAN_DIR=share/man") - ,flags)) + #~(append (list "-DSPHINX_INFO=ON" "-DSPHINX_MAN=ON" "-DSPHINX_HTML=ON" + (string-append "-DCMAKE_DOC_DIR=share/doc/cmake-" + #$(version-major+minor (package-version + cmake-minimal))) + "-DCMAKE_INFO_DIR=share/info" + "-DCMAKE_MAN_DIR=share/man") + #$flags)) ((#:phases phases) - `(modify-phases ,phases - (delete 'delete-help-documentation) - (add-after 'install 'move-html-doc - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc")) - (html (string-append "/share/doc/cmake-" - ,(version-major+minor - (package-version cmake-minimal)) - "/html"))) - (copy-recursively (string-append out html) - (string-append doc html)) - (delete-file-recursively (string-append out html))))))))) + #~(modify-phases #$phases + (delete 'delete-help-documentation) + (add-after 'install 'move-html-doc + (lambda _ + (let ((html (string-append "/share/doc/cmake-" + #$(version-major+minor + (package-version cmake-minimal)) + "/html"))) + (copy-recursively (string-append #$output html) + (string-append #$output:doc html)) + (delete-file-recursively (string-append #$output html))))))))) (inputs (modify-inputs (package-inputs cmake-minimal) (prepend ncurses))) ;required for ccmake @@ -411,13 +406,12 @@ and workspaces that can be used in the compiler environment of your choice.") (outputs '("out")) (build-system emacs-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'chdir-elisp - ;; Elisp directory is not in root of the source. - (lambda _ - (chdir "Auxiliary") - #t))))) + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'chdir-elisp + ;; Elisp directory is not in root of the source. + (lambda _ + (chdir "Auxiliary")))))) (synopsis "Emacs major mode for editing Cmake expressions") (description "@code{cmakeos-mode} provides an Emacs major mode for editing Cmake files. It supports syntax highlighting, indenting and refilling of diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index ea3a0afc23..25e96b1aa6 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -1,13 +1,13 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2022 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012-2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org> ;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2017, 2018, 2019, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2018, 2019, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> -;;; Copyright © 2019, 2020, 2021 Marius Bakke <marius@gnu.org> -;;; Copyright © 2020 Timothy Sample <samplet@ngyro.com> +;;; Copyright © 2018, 2019, 2020, 2021, 2022, 2023 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> +;;; Copyright © 2019-2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2020, 2022 Timothy Sample <samplet@ngyro.com> ;;; Copyright © 2020 Guy Fleury Iteriteka <gfleury@disroot.org> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Chris Marusich <cmmarusich@gmail.com> @@ -92,7 +92,7 @@ (define bootar (package (name "bootar") - (version "1a") + (version "1b") (source (origin (method url-fetch) (uri (list (string-append @@ -102,7 +102,7 @@ version ".ses"))) (sha256 (base32 - "0mvp6vgx0q316fvy3z2lddlc5xgq5np3bm1fypgvj6dnayibg9np")))) + "0cf5vj5yxfvkgzvjvh2l7b2nz5ji5l534n9g4mfp8f5jsjqdrqjc")))) (build-system gnu-build-system) (arguments `(#:implicit-inputs? #f @@ -121,9 +121,10 @@ (guile (string-append guile-dir "/bin/guile"))) (invoke guile "--no-auto-compile" source) (chdir "bootar")))) - (replace 'configure (bootstrap-configure ,version "." "scripts")) - (replace 'build (bootstrap-build ".")) - (replace 'install (bootstrap-install "." "scripts")))))) + (replace 'configure (bootstrap-configure "Bootar" ,version + '(".") "scripts")) + (replace 'build (bootstrap-build '("."))) + (replace 'install (bootstrap-install '(".") "scripts")))))) (inputs `(("guile" ,%bootstrap-guile))) (home-page "https://git.ngyro.com/bootar") (synopsis "Tar decompression and extraction in Guile Scheme") @@ -143,9 +144,6 @@ pure Scheme to Tar and decompression in one easy step.") (package (inherit gash) (name "gash-boot") - (source (origin - (inherit (package-source gash)) - (snippet #f))) ;discard snippet for Guile 3.0 support (arguments `(#:implicit-inputs? #f #:tests? #f @@ -157,9 +155,10 @@ pure Scheme to Tar and decompression in one easy step.") (use-modules (guix build gnu-bootstrap)) (modify-phases %standard-phases (replace 'configure - (bootstrap-configure ,(package-version gash) "gash" "scripts")) - (replace 'build (bootstrap-build "gash")) - (replace 'install (bootstrap-install "gash" "scripts")) + (bootstrap-configure "Gash" ,(package-version gash) + '("gash") "scripts")) + (replace 'build (bootstrap-build '("gash"))) + (replace 'install (bootstrap-install '("gash") "scripts")) (add-after 'install 'install-symlinks (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) @@ -174,10 +173,6 @@ pure Scheme to Tar and decompression in one easy step.") (package (inherit gash-utils) (name "gash-utils-boot") - (source (origin - (inherit (package-source gash-utils)) - (patches '()) - (snippet #f))) ;discard snippet for Guile 3.0 support (arguments `(#:implicit-inputs? #f #:tests? #f @@ -209,9 +204,9 @@ pure Scheme to Tar and decompression in one easy step.") (substitute* target (("@UTILITY@") script)))) '("awk" "basename" "cat" "chmod" "cmp" "command" - "compress" "cp" "cut" "diff" "dirname" "expr" - "false" "find" "grep" "head" "ln" "ls" "mkdir" - "mv" "printf" "pwd" "reboot" "rm" "rmdir" + "compress" "cp" "cut" "diff" "dirname" "env" + "expr" "false" "find" "grep" "head" "ln" "ls" + "mkdir" "mv" "printf" "pwd" "reboot" "rm" "rmdir" "sed" "sleep" "sort" "tar" "test" "touch" "tr" "true" "uname" "uniq" "wc" "which")) (format #t "Creating scripts/[.in~%") @@ -220,10 +215,11 @@ pure Scheme to Tar and decompression in one easy step.") (("@UTILITY@") "testb")) (delete-file "scripts/template.in"))) (replace 'configure - (bootstrap-configure ,(package-version gash-utils) - "gash" "scripts")) - (replace 'build (bootstrap-build "gash")) - (replace 'install (bootstrap-install "gash" "scripts")) + (bootstrap-configure "Gash-Utils" ,(package-version gash-utils) + '("gash" "gash-utils") "scripts")) + (replace 'build (bootstrap-build '("gash" "gash-utils"))) + (replace 'install + (bootstrap-install '("gash" "gash-utils") "scripts")) ;; XXX: The scripts should add Gash to their load paths and ;; this phase should not exist. (add-after 'install 'copy-gash @@ -247,7 +243,19 @@ pure Scheme to Tar and decompression in one easy step.") (copy-file (string-append gash-godir "/gash/compat.go") (string-append godir "/gash/compat.go")) (copy-recursively (string-append gash-godir "/gash/compat") - (string-append godir "/gash/compat"))))))))) + (string-append godir "/gash/compat"))))) + ;; We need an external echo. + (add-after 'install 'make-echo + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (gash (assoc-ref inputs "gash"))) + (with-output-to-file (string-append out "/bin/echo") + (lambda () + (display (string-append "#!" gash "/bin/gash\n")) + (newline) + (display "echo \"$@\"") + (newline))) + (chmod (string-append out "/bin/echo") #o755)))))))) (inputs `(("gash" ,gash-boot) ("guile" ,%bootstrap-guile))) (native-inputs `(("bootar" ,bootar))))) @@ -258,186 +266,239 @@ pure Scheme to Tar and decompression in one easy step.") ("bootar" ,bootar) ("guile" ,%bootstrap-guile))) -(define %bootstrap-mes-rewired +(define bootstrap-seeds (package - (inherit mes) - (name "bootstrap-mes-rewired") - (version "0.19") - (source #f) - (native-inputs `(("mes" ,%bootstrap-mes) - ("gash" ,gash-boot))) - (inputs '()) - (propagated-inputs '()) - (outputs '("out")) + (name "bootstrap-seeds") + (version "1.0.0") + (source (origin + (method url-fetch) + (uri (list + (string-append "mirror://gnu/guix/mirror/" + "bootstrap-seeds-" version ".tar.gz") + (string-append + "https://lilypond.org/janneke/guix/20220501/" + "bootstrap-seeds-" version ".tar.gz"))) + (sha256 + (base32 + "0scz2bx8fd8c821h6y1j3x6ywgxxns7iinyn9z32dnkiacfdcpfn")))) + (native-inputs (list bootar)) (build-system trivial-build-system) (arguments - `(#:guile ,%bootstrap-guile - #:modules ((guix build utils)) - - #:builder (begin - (use-modules (guix build utils) - (srfi srfi-26)) - - (let* ((mes (assoc-ref %build-inputs "mes")) - (gash (assoc-ref %build-inputs "gash")) - (mes-bin (string-append mes "/bin")) - (guile (string-append mes-bin "/mes")) - (mes-module (string-append mes "/share/mes/module")) - (out (assoc-ref %outputs "out")) - (bin (string-append out "/bin")) - (mescc (string-append bin "/mescc")) - (module (string-append out "/share/mes/module"))) - (define (rewire file) - (substitute* file - ((mes) out) - (("/gnu/store[^ ]+mes-minimal-[^/)}\"]*") out) - (("/gnu/store[^ ]+guile-[^/]*/bin/guile") guile) - (("/gnu/store[^ ]+bash-[^/)}\"]*") gash))) - - (mkdir-p bin) - (for-each (lambda (file) (install-file file bin)) - (find-files mes-bin)) - (mkdir-p module) - (copy-recursively (string-append mes-module "/mes") - (string-append module "/mes")) - (copy-recursively (string-append mes-module "/srfi") - (string-append module "/srfi")) - (for-each rewire - ;; Cannot easily rewire "mes" because it - ;; contains NUL characters; would require - ;; remove-store-references alike trick - (filter (negate (cut string-suffix? "/mes" <>)) - (find-files bin))) - (rewire (string-append module "/mes/boot-0.scm")) - - (delete-file mescc) - (with-output-to-file mescc - (lambda _ - (display (string-append - "\ -#! " gash "/bin/sh -LANG=C -LC_ALL=C -export LANG LC_ALL - -MES_PREFIX=${MES_REWIRED_PREFIX-" out "/share/mes} -MES=" bin "/mes -export MES MES_PREFIX - -MES_ARENA=${MES_REWIRED_ARENA-10000000} -MES_MAX_ARENA=${MES_REWIRED_ARENA-10000000} -MES_STACK=${MES_REWIRED_STACK-1000000} -export MES_ARENA MES_MAX_ARENA MES_STACK - -$MES -e '(mescc)' module/mescc.scm -- \"$@\" -")))) - (chmod mescc #o555) - - (with-directory-excursion module - (chmod "mes/base.mes" #o644) - (copy-file "mes/base.mes" "mes/base.mes.orig") - (let ((base.mes (open-file "mes/base.mes" "a"))) - (display " -;; A fixed map, from Mes 0.21, required to bootstrap Mes 0.21 -(define (map f h . t) - (if (or (null? h) - (and (pair? t) (null? (car t))) - (and (pair? t) (pair? (cdr t)) (null? (cadr t)))) '() - (if (null? t) (cons (f (car h)) (map f (cdr h))) - (if (null? (cdr t)) - (cons (f (car h) (caar t)) (map f (cdr h) (cdar t))) - (if (null? (cddr t)) - (cons (f (car h) (caar t) (caadr t)) (map f (cdr h) (cdar t) (cdadr t))) - (error 'unsupported (cons* 'map-4: f h t))b ))))) -" base.mes) - (close base.mes)) - - (chmod "mes/guile.mes" #o644) - (copy-file "mes/guile.mes" "mes/guile.mes.orig") - (let ((guile.mes (open-file "mes/guile.mes" "a"))) - (display " -;; After booting guile.scm; use Mes 0.21; especially: MesCC 0.21 -(let* ((self (car (command-line))) - (prefix (dirname (dirname self)))) - (set! %moduledir (string-append prefix \"/mes/module/\")) - (setenv \"%numbered_arch\" \"true\")) + (list #:guile %bootstrap-guile + #:modules '((guix build utils)) + #:builder + #~(begin + (use-modules (guix build utils)) + (let ((source #$(package-source this-package)) + (tar #$(this-package-native-input "bootar")) + (out #$output)) + (setenv "PATH" (string-append tar "/bin:")) + (invoke "tar" "xvf" source) + (mkdir-p out) + (copy-recursively "bootstrap-seeds" out))))) + (home-page "https://github.com/oriansj/bootstrap-seeds") + (synopsis "The initial bootstrap seeds: 357-byte hex0 and kaem shell") + (description + "This package provides pre-built binaries of the bootstrap seeds. It +contains a hex0-seed and an optional kaem-minimal shell. The size of the hex0 +seeds are for knight: 250 bytes, x86-linux: 357 bytes, x86_64-linux: 431 +bytes, and aarch64-linux 526 bytes. These can be used to build stage0: hex0, +hex1, hex2, M1, and M2-Planet.") + (license license:gpl3+))) -" guile.mes) - (close guile.mes))) - #t)))))) +(define stage0-posix + ;; The initial bootstrap package: no binary inputs except those from + ;; `bootstrap-seeds, for x86 a 357 byte binary seed: `x86/hex0-seed'. + (let* ((mescc-tools-version "1.4.0") + (m2-planet-version "1.9.0") + (mescc-tools + (origin + (method url-fetch) + (uri (list + (string-append + "mirror://gnu/guix/mirror/" + "mescc-tools-" mescc-tools-version ".tar.gz") + (string-append + "https://lilypond.org/janneke/guix/20220502/" + "mescc-tools-" mescc-tools-version ".tar.gz"))) + (sha256 + (base32 + "1xi6f48pf5bhajhfis189gpizxij7nbp1vzvsb1aafhz4skkiqvg")))) + (m2-planet + (origin + (method url-fetch) + (uri (list + (string-append + "mirror://gnu/guix/mirror/" + "M2-Planet-" m2-planet-version ".tar.gz") + (string-append + "https://lilypond.org/janneke/guix/20220502/" + "M2-Planet-" m2-planet-version ".tar.gz"))) + (sha256 + (base32 + "1xrn69sc5nz4hwaishqyrcidp1ncxwib9zswl45x378ddz3mmk7g"))))) + (package + (name "stage0-posix") + (version "1.4") + (source (origin + (method url-fetch) + (uri (list + (string-append "mirror://gnu/guix/mirror/" + "stage0-posix-" version ".tar.gz") + (string-append + "https://lilypond.org/janneke/guix/20220502/" + "stage0-posix-" version ".tar.gz"))) + (sha256 + (base32 + "1ammifkj33205qrpfm84yb1c99lwgbn4jsl1hd08aab8c9ffz6p4")))) + (supported-systems '("i686-linux" "x86_64-linux" + "aarch64-linux" + "riscv64-linux")) + (native-inputs + `(("bootstrap-seeds" ,bootstrap-seeds) + ,@(%boot-gash-inputs))) + (build-system trivial-build-system) + (arguments + (list + #:guile %bootstrap-guile + #:modules '((guix build utils)) + #:builder + #~(begin + (use-modules (guix build utils)) + (let* ((bootstrap-seeds #$(this-package-native-input + "bootstrap-seeds")) + (source #$(package-source this-package)) + (tar #$(this-package-native-input "bootar")) + (bash #$(this-package-native-input "bash")) + (coreutils #$(this-package-native-input "coreutils")) + (guile #$(this-package-input "guile")) + (out #$output) + (bindir (string-append out "/bin")) + (target (or #$(%current-target-system) + #$(%current-system))) + (stage0-cpu + (cond + ((or #$(target-x86-64?) #$(target-x86-32?)) + "x86") + (#$(target-aarch64?) + "AArch64") + (#$(target-riscv64?) + "riscv64") + (else + (error "stage0-posix: system not supported" target)))) + (kaem (string-append "../bootstrap-seeds/POSIX/" + stage0-cpu "/kaem-optional-seed"))) + (setenv "PATH" (string-append tar "/bin:" + coreutils "/bin:" + bash "/bin")) + (invoke "tar" "xvf" source) + (chdir (string-append "stage0-posix-" #$version)) + (copy-recursively bootstrap-seeds "bootstrap-seeds") + (invoke "tar" "xvf" #$mescc-tools) + (rmdir "mescc-tools") + (symlink (string-append "mescc-tools-" #$mescc-tools-version) + "mescc-tools") + (invoke "tar" "xvf" #$m2-planet) + (rmdir "M2-Planet") + (symlink (string-append "M2-Planet-" #$m2-planet-version) + "M2-Planet") + (rmdir "M2libc") + (symlink "M2-Planet/M2libc" "M2libc") + (mkdir-p bindir) + (with-directory-excursion stage0-cpu + (with-output-to-file "mes-m2.kaem" + (lambda _ (display ""))) + (with-output-to-file "mescc-tools-extra.kaem" + (lambda _ (display ""))) + (invoke kaem "kaem.run")) + (with-directory-excursion "bin" + (install-file "hex2" bindir) + (install-file "M1" bindir) + (install-file "blood-elf" bindir) + (install-file "kaem" bindir) + (install-file "get_machine" bindir) + (install-file "M2-Planet" bindir)))))) + (home-page "https://github.com/oriansj/stage0-posix/") + (synopsis "The initial bootstrap package, builds stage0 up to M2-Planet") + (description "Starting from the 357-byte hex0-seed binary provided by +the bootstrap-seeds, the stage0-posix package first builds hex0 and then all +the way up: hex1, catm, hex2, M0, cc_x86, M1, M2, get_machine (that's all of +MesCC-Tools), and finally M2-Planet.") + (license license:gpl3+)))) (define mes-boot (package (inherit mes) (name "mes-boot") - (version "0.22") + (version "0.24.2") (source (origin (method url-fetch) - (uri (string-append "mirror://gnu/mes/" - "mes-" version ".tar.gz")) + (uri (list (string-append "mirror://gnu/mes/" + "mes-" version ".tar.gz") + (string-append "https://lilypond.org/janneke/mes/" + "mes-" version ".tar.gz"))) (sha256 (base32 - "0p1jsrrmcbc0zrvbvnjbb6iyxr0in71km293q8qj6gnar6bw09av")))) + "0vp8v88zszh1imm3dvdfi3m8cywshdj7xcrsq4cgmss69s2y1nkx")))) (inputs '()) (propagated-inputs '()) + (supported-systems '("i686-linux" "x86_64-linux")) (native-inputs - `(("nyacc-source" ,(origin (inherit (package-source nyacc-0.99)) - (snippet #f))) - ("mes" ,%bootstrap-mes-rewired) - ("mescc-tools" ,%bootstrap-mescc-tools) + `(("m2-planet" ,stage0-posix) + ("nyacc-source" ,(bootstrap-origin + (origin (inherit (package-source nyacc-1.00.2)) + (snippet #f)))) ,@(%boot-gash-inputs))) (arguments - `(#:implicit-inputs? #f - #:tests? #f - #:guile ,%bootstrap-guile - #:strip-binaries? #f ; binutil's strip b0rkes MesCC/M1/hex2 binaries - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'unpack-seeds - (lambda _ - (let ((nyacc-source (assoc-ref %build-inputs "nyacc-source"))) - (with-directory-excursion ".." - (invoke "tar" "-xvf" nyacc-source))))) - (replace 'configure - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref %outputs "out")) - (gash (assoc-ref %build-inputs "bash")) - (mes (assoc-ref %build-inputs "mes")) - (dir (with-directory-excursion ".." (getcwd)))) - (setenv "AR" (string-append "gash " (getcwd) "/scripts/mesar")) - (setenv "BASH" (string-append gash "/bin/bash")) - (setenv "CC" (string-append mes "/bin/mescc")) - (setenv "GUILE_LOAD_PATH" - (string-append - mes "/share/mes/module" - ":" dir "/nyacc-0.99.0/module")) - (invoke "gash" "configure.sh" - (string-append "--prefix=" out) - (string-append "--host=i686-linux-gnu"))))) - (replace 'build - (lambda _ - (invoke "sh" "bootstrap.sh"))) - (delete 'check) - (replace 'install - (lambda _ - (substitute* "install.sh" ; show some progress - ((" -xf") " -xvf") - (("^( *)((cp|mkdir|tar) [^']*[^\\])\n" all space cmd) - (string-append space "echo '" cmd "'\n" - space cmd "\n"))) - (invoke "sh" "install.sh") - ;; Keep ASCII output, for friendlier comparison and bisection - (let* ((out (assoc-ref %outputs "out")) - (cache (string-append out "/lib/cache"))) - (define (objects-in-dir dir) - (find-files dir - (lambda (name stat) - (and (equal? (dirname name) dir) - (or (string-suffix? ".o" name) - (string-suffix? ".s" name)))))) - (for-each (lambda (x) (install-file x cache)) - (append (objects-in-dir ".") - (objects-in-dir "mescc-lib"))))))))) + (list + #:implicit-inputs? #f + #:tests? #f + #:guile %bootstrap-guile + #:strip-binaries? #f ;no strip yet + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'unpack-seeds + (lambda _ + (let ((nyacc-source #$(this-package-native-input "nyacc-source"))) + (with-directory-excursion ".." + (invoke "tar" "-xvf" nyacc-source))))) + (replace 'configure + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out #$output) + (gash #$(this-package-native-input "bash")) + (dir (with-directory-excursion ".." (getcwd)))) + (setenv "GUILE_LOAD_PATH" (string-append + dir "/nyacc-1.00.2/module")) + (invoke "gash" "configure.sh" + (string-append "--prefix=" out) + "--host=i686-linux-gnu")))) + (replace 'build + (lambda _ + (invoke "gash" "bootstrap.sh"))) + (delete 'check) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "install.sh" ; show some progress + ((" -xf") " -xvf") + (("^( *)((cp|mkdir|tar) [^']*[^\\])\n" all space cmd) + (string-append space "echo '" cmd "'\n" + space cmd "\n"))) + (invoke "gash" "install.sh") + ;; Keep ASCII output, for friendlier comparison and bisection + (let* ((out #$output) + (cache (string-append out "/lib/cache"))) + (define (objects-in-dir dir) + (find-files dir + (lambda (name stat) + (and (equal? (dirname name) dir) + (or (string-suffix? ".M1" name) + (string-suffix? ".hex2" name) + (string-suffix? ".o" name) + (string-suffix? ".s" name)))))) + (for-each (lambda (x) (install-file x cache)) + (append (objects-in-dir "m2") + (objects-in-dir ".") + (objects-in-dir "mescc-lib"))))))))) (native-search-paths (list (search-path-specification (variable "C_INCLUDE_PATH") @@ -452,7 +513,7 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (define tcc-boot0 - ;; Pristine tcc cannot be built by MesCC, we are keeping a delta of 11 + ;; Pristine tcc cannot be built by MesCC, we are keeping a delta of 30 ;; patches. In a very early and rough form they were presented to the ;; TinyCC developers, who at the time showed no interest in supporting the ;; bootstrappable effort; we will try again later. These patches have been @@ -461,82 +522,83 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (package (inherit tcc) (name "tcc-boot0") - (version "0.9.26-1103-g6e62e0e") + (version "0.9.26-1136-g5bba73cc") (source (origin (method url-fetch) - (uri (list (string-append "mirror://gnu/guix/mirror/tcc-" - version ".tar.gz") - (string-append - "http://lilypond.org/janneke/mes/20191117/" - "/tcc-" version ".tar.gz"))) + (uri (list + (string-append "mirror://gnu/guix/mirror/" + "tcc-" version ".tar.gz") + (string-append "https://lilypond.org/janneke/tcc/" + "tcc-" version ".tar.gz"))) (sha256 (base32 - "1qbybw7mxbgkv3sazvz1v7c8byq998vk8f1h25ik8w3d2l63lxng")))) + "1y2f04qwdqg7dgxiscbf0ibybx2gclniwbbcsxpayazzii2cvji3")))) (build-system gnu-build-system) (supported-systems '("i686-linux" "x86_64-linux")) (inputs '()) (propagated-inputs '()) (native-inputs `(("mes" ,mes-boot) - ("nyacc-source" ,(origin (inherit (package-source nyacc-0.99)) - (snippet #f))) - ("mescc-tools" ,%bootstrap-mescc-tools) + ("mescc-tools" ,stage0-posix) + ("nyacc-source" ,(bootstrap-origin + (origin (inherit (package-source nyacc-1.00.2)) + (snippet #f)))) ,@(%boot-gash-inputs))) (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:validate-runpath? #f ; no dynamic executables - #:strip-binaries? #f ; no strip yet - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'unpack-seeds - (lambda* (#:key outputs #:allow-other-keys) - (let ((nyacc-source (assoc-ref %build-inputs "nyacc-source"))) - (with-directory-excursion ".." - (invoke "tar" "-xvf" nyacc-source))))) - (replace 'configure - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref %outputs "out")) - (dir (with-directory-excursion ".." (getcwd))) - (interpreter "/lib/mes-loader")) - - (setenv "prefix" out) - (setenv "GUILE_LOAD_PATH" - (string-append dir "/nyacc-0.99.0/module")) - - (substitute* "conftest.c" - (("volatile") "")) - - (invoke "sh" "configure" - "--cc=mescc" - (string-append "--prefix=" out) - (string-append "--elfinterp=" interpreter) - "--crtprefix=." - "--tccdir=.")))) - (replace 'build - (lambda _ - (substitute* "bootstrap.sh" ; Show some progress - (("^( *)((cp|ls|mkdir|rm|[.]/tcc|[.]/[$][{PROGRAM_PREFIX[}]tcc) [^\"]*[^\\])\n" all space cmd) - (string-append space "echo \"" cmd "\"\n" - space cmd "\n"))) - (invoke "sh" "bootstrap.sh"))) - (replace 'check - (lambda _ - ;; fail fast tests - (system* "./tcc" "--help") ; --help exits 1 - ;; (invoke "sh" "test.sh" "mes/scaffold/tests/30-strlen") - ;; (invoke "sh" "-x" "test.sh" "mes/scaffold/tinycc/00_assignment") - ;; TODO: add sensible check target (without depending on make) - ;; (invoke "sh" "check.sh") - #t)) - (replace 'install - (lambda _ - (substitute* "install.sh" ; Show some progress - (("^( *)((cp|ls|mkdir|rm|tar|./[$][{PROGRAM_PREFIX[}]tcc) [^\"]*[^\\])\n" all space cmd) - (string-append space "echo \"" cmd "\"\n" - space cmd "\n"))) - - (invoke "sh" "install.sh")))))) + (list + #:implicit-inputs? #f + #:guile %bootstrap-guile + #:validate-runpath? #f ; no dynamic executables + #:strip-binaries? #f ; no strip yet + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'unpack-extra-sources + (lambda* (#:key outputs #:allow-other-keys) + (let ((nyacc-source #$(this-package-native-input "nyacc-source"))) + (with-directory-excursion ".." + (invoke "tar" "-xvf" nyacc-source))))) + (replace 'configure + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out #$output) + (dir (with-directory-excursion ".." (getcwd))) + (interpreter "/lib/mes-loader") + (mes #$(this-package-native-input "mes")) + (mescc (string-append mes "/bin/mescc"))) + (substitute* "conftest.c" + (("volatile") "")) + (setenv "prefix" out) + (setenv "GUILE_LOAD_PATH" + (string-append dir "/nyacc-1.00.2/module")) + (invoke "sh" "configure" + "--cc=mescc" + (string-append "--prefix=" out) + (string-append "--elfinterp=" interpreter) + "--crtprefix=." + "--tccdir=.")))) + (replace 'build + (lambda _ + (substitute* "bootstrap.sh" ; Show some progress + (("^( *)((cp|ls|mkdir|rm|[.]/tcc|[.]/[$][{program_prefix[}]tcc) [^\"]*[^\\])\n" all space cmd) + (string-append space "echo \"" cmd "\"\n" + space cmd "\n"))) + (invoke "sh" "bootstrap.sh"))) + (replace 'check + (lambda _ + ;; fail fast tests + (system* "./tcc" "--help") ; --help exits 1 + ;; (invoke "sh" "test.sh" "mes/scaffold/tests/30-strlen") + ;; (invoke "sh" "-x" "test.sh" "mes/scaffold/tinycc/00_assignment") + ;; TODO: add sensible check target (without depending on make) + ;; (invoke "sh" "check.sh") + )) + (replace 'install + (lambda _ + (substitute* "install.sh" ; Show some progress + (("^( *)((cp|ls|mkdir|rm|tar|./[$][{PROGRAM_PREFIX[}]tcc) [^\"]*[^\\])\n" all space cmd) + (string-append space "echo \"" cmd "\"\n" + space cmd "\n"))) + + (invoke "sh" "install.sh")))))) (native-search-paths (list (search-path-specification (variable "C_INCLUDE_PATH") @@ -657,152 +719,6 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" ("tcc" ,tcc-boot0) ,@(%boot-gash-inputs))) -(define bzip2-mesboot - ;; The initial bzip2 - (package - (inherit bzip2) - (name "bzip2-mesboot") - (version (package-version bzip2)) - (source (bootstrap-origin (package-source bzip2))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-tcc0-inputs)) - (outputs '("out")) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:tests? #f ; check is naive, also checks non-built PROGRAMS - #:strip-binaries? #f ; no strip yet - #:make-flags (list "CC=tcc -I ." "AR=tcc -ar" "bzip2" - (string-append "PREFIX=" - (assoc-ref %outputs "out"))) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'scripted-patch - (lambda _ - (substitute* "Makefile" - (("\tln " all) - (string-append "\t#" all))) - (substitute* "bzip2.c" - (("struct utimbuf uTimBuf;" all) - (string-append "// " all)) - (("uTimBuf[.]" all) - (string-append "// " all)) - (("retVal = utime [(] dstName, &uTimBuf [)];" all) - (string-append "retVal = 0; // " all))))) - (replace 'configure - (lambda _ - (with-output-to-file "utime.h" - (lambda _ (display " -#define fchown(filedes, owner, group) 0 -#define fchmod(filedes, mode) 0 -"))))) - (replace 'check - (lambda _ - (invoke "./bzip2" "--help"))) - ;; FIXME: no compressing gzip yet - (delete 'compress-documentation)))))) - -(define bash-mesboot0 - ;; The initial Bash - (package - (inherit static-bash) - (name "bash-mesboot0") - (version "2.05b") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/bash/bash-" - version ".tar.gz")) - (sha256 - (base32 - "1r1z2qdw3rz668nxrzwa14vk2zcn00hw7mpjn384picck49d80xs")))) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-tcc0-inputs)) - (outputs '("out")) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:strip-binaries? #f ; no strip yet - #:configure-flags - (list "--build=i686-unknown-linux-gnu" - "--host=i686-unknown-linux-gnu" - - "--without-bash-malloc" - "--disable-readline" - "--disable-history" - "--disable-help-builtin" - "--disable-progcomp" - "--disable-net-redirections" - "--disable-nls" - - ;; Pretend 'dlopen' is missing so we don't build loadable - ;; modules and related code. - "ac_cv_func_dlopen=no") - #:make-flags '("bash") - #:phases - (modify-phases %standard-phases - (add-before 'configure 'setenv - (lambda _ - (let* ((gash (assoc-ref %build-inputs "bash")) - (shell (string-append gash "/bin/gash"))) - (setenv "CONFIG_SHELL" shell) - (setenv "SHELL" shell) - (setenv "CC" "tcc") - (setenv "LD" "tcc") - (setenv "AR" "tcc -ar") - (setenv "CFLAGS" "-D _POSIX_VERSION=1")))) - (add-after 'unpack 'scripted-patch - (lambda _ - (substitute* "Makefile.in" - (("mksyntax\\.c\n") "mksyntax.c -lgetopt\n") - (("buildversion[.]o\n") "buildversion.o -lgetopt\n") - ;; No size in Gash - (("\tsize ") "#\tsize")) - (substitute* "lib/sh/oslib.c" - (("int name, namelen;") "char *name; int namelen;")) - (substitute* "lib/sh/snprintf.c" - (("^#if (defined [(]HAVE_LOCALE_H[)])" all define) (string-append "#if 0 //" define))) - (substitute* "configure" - ((" egrep") " grep")))) - (replace 'configure - (lambda* (#:key configure-flags #:allow-other-keys) - (let ((configure-flags (filter (lambda (x) - (and (not (string-prefix? "CONFIG_SHELL=" x)) - (not (string-prefix? "SHELL=" x)))) - configure-flags))) - (format (current-error-port) - "running ./configure ~a\n" (string-join configure-flags))) - (apply invoke (cons "./configure" configure-flags)))) - (add-after 'configure 'configure-fixups - (lambda _ - (substitute* "config.h" - (("#define GETCWD_BROKEN 1") "#undef GETCWD_BROKEN")) - (let ((config.h (open-file "config.h" "a"))) - (display " -// tcc: error: undefined symbol 'enable_hostname_completion' -#define enable_hostname_completion(on_or_off) 0 - -// /gnu/store/…-tcc-boot0-0.9.26-6.c004e9a/lib/libc.a: error: 'sigprocmask' defined twice -#define HAVE_POSIX_SIGNALS 1 -#define endpwent(x) 0 -" - config.h) - (close config.h)))) - (replace 'check - (lambda _ - (invoke "./bash" "--version"))) - (replace 'install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (mkdir-p bin) - (copy-file "bash" (string-append bin "/bash")) - (copy-file "bash" (string-append bin "/sh")))))))))) - (define tcc-boot ;; The final tcc. (package @@ -819,7 +735,7 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (build-system gnu-build-system) (inputs '()) (propagated-inputs '()) - (native-inputs `(("bzip2" ,bzip2-mesboot) + (native-inputs `(("mes" ,mes-boot) ,@(%boot-tcc0-inputs))) (arguments `(#:implicit-inputs? #f @@ -828,14 +744,6 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" #:strip-binaries? #f ; no strip yet #:phases (modify-phases %standard-phases - ;; tar xvf ..bz2 gives - ;; bzip2: PANIC -- internal consistency error - (replace 'unpack - (lambda* (#:key source #:allow-other-keys) - (copy-file source "tarball.tar.bz2") - (invoke "bzip2" "-d" "tarball.tar.bz2") - (invoke "tar" "xvf" "tarball.tar") - (chdir (string-append "tcc-" ,version)))) (add-after 'unpack 'scripted-patch (lambda* (#:key inputs #:allow-other-keys) (substitute* "libtcc.c" @@ -887,8 +795,26 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (= 1 (status:exit-val (system* "./tcc" "--help"))))) (replace 'install (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref %outputs "out")) - (tcc (assoc-ref %build-inputs "tcc"))) + (let* ((out (assoc-ref %outputs "out")) + (mes (assoc-ref %build-inputs "mes")) + (tcc (assoc-ref %build-inputs "tcc")) + (interpreter "/mes/loader") + (cppflags + (list + "-D" "BOOTSTRAP=1" + "-D" "ONE_SOURCE=1" + "-D" "TCC_TARGET_I386=1" + "-D" "CONFIG_TCCBOOT=1" + "-D" "CONFIG_TCC_STATIC=1" + "-D" "CONFIG_USE_LIBGCC=1" + "-D" (string-append "CONFIG_TCCDIR=\"" out "/lib/tcc\"") + "-D" (string-append "CONFIG_TCC_CRTPREFIX=\"" out "/lib:{B}/lib:.\"") + "-D" (string-append "CONFIG_TCC_ELFINTERP=\"" interpreter "\"") + "-D" (string-append "CONFIG_TCC_LIBPATHS=\"" tcc "/lib:{B}/lib:{B}/lib/tcc:.\"") + "-D" (string-append "CONFIG_TCC_SYSINCLUDEPATHS=\"" + tcc "/include" ":/include:{B}/include\"") + "-D" (string-append "TCC_LIBGCC=\"" tcc "/lib/libc.a\"") + "-D" (string-append "TCC_LIBTCC1_MES=\"libtcc1-mes.a\"")))) (and (mkdir-p (string-append out "/bin")) (copy-file "tcc" (string-append out "/bin/tcc")) @@ -897,12 +823,21 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (string-append out "/include")) (copy-recursively (string-append tcc "/lib") (string-append out "/lib")) - (invoke "tcc" "-D" "TCC_TARGET_I386=1" "-c" "-o" "libtcc1.o" "lib/libtcc1.c") - (invoke "tcc" "-ar" "rc" "libtcc1.a" "libtcc1.o") + (invoke "./tcc" "-D" "TCC_TARGET_I386=1" "-c" "-o" "libtcc1.o" "lib/libtcc1.c") + (invoke "./tcc" "-ar" "rc" "libtcc1.a" "libtcc1.o") (copy-file "libtcc1.a" (string-append out "/lib/libtcc1.a")) (delete-file (string-append out "/lib/tcc/libtcc1.a")) (copy-file "libtcc1.a" - (string-append out "/lib/tcc/libtcc1.a"))))))))))) + (string-append out "/lib/tcc/libtcc1.a")) + + (delete-file (string-append out "/lib/libc.a")) + (apply invoke "./tcc" "-c" "-o" "libc.o" + "-I" (string-append tcc "/include") + "-I" (string-append tcc "/include/linux/x86") + (string-append mes "/lib/libc+gnu.c") + cppflags) + (invoke "./tcc" "-ar" "rc" "libc.a" "libc.o") + (copy-file "libc.a" (string-append out "/lib/libc.a"))))))))))) (define patch-mesboot ;; The initial patch. @@ -939,56 +874,9 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" ;; FIXME: no compressing gzip yet (delete 'compress-documentation)))))) -(define sed-mesboot0 - ;; The initial sed. - (package - (inherit sed) - (name "sed-mesboot0") - (version "1.18") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/sed/sed-" - version ".tar.gz")) - (sha256 - (base32 - "1hyv7i82jd0q18xcql51ylc8jwadp3gb3irgcqlis3v61p35jsv2")))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-tcc0-inputs)) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:configure-flags '("CC=tcc") - #:make-flags '("CC=tcc" "extra_objs=" "DEFS=-D HAVE_BCOPY") - #:strip-binaries? #f ; no strip yet - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'scripted-patch - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (substitute* "configure" - (("/bin/sh") shell))))) - (replace 'check - (lambda _ - (invoke "./sed" "--version"))) - (replace 'install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (install-file "sed" bin))))))))) - (define (%boot-tcc-inputs) - `(("bash" ,bash-mesboot0) - ("bzip2" ,bzip2-mesboot) - ("gzip" ,gzip-mesboot) + `(("gzip" ,gzip-mesboot) ("patch" ,patch-mesboot) - ("sed" ,sed-mesboot0) - ;; Place lower than sed so we don't override it. - ("gash-utils" ,gash-utils-boot) ("tcc" ,tcc-boot) ,@(alist-delete "tcc" (%boot-tcc0-inputs)))) @@ -997,14 +885,17 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" (package (inherit binutils) (name "binutils-mesboot0") - (version "2.14") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/binutils/binutils-" - version ".tar.gz")) - (sha256 - (base32 - "1w8xp7k44bkijr974x9918i4p1sw4g2fcd5mxvspkjpg38m214ds")))) + (version "2.20.1a") + (source (bootstrap-origin + (origin + (method url-fetch) + (uri (string-append "mirror://gnu/binutils/binutils-" + version ".tar.bz2")) + (patches (search-patches "binutils-boot-2.20.1a.patch")) + (patch-guile %bootstrap-guile) + (sha256 + (base32 + "0r7dr0brfpchh5ic0z9r4yxqn4ybzmlh25sbp30cacqk8nb7rlvi"))))) (inputs '()) (propagated-inputs '()) (native-inputs (%boot-tcc-inputs)) @@ -1016,40 +907,21 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\" #:parallel-build? #f #:strip-binaries? #f ; no strip yet #:configure-flags - (let ((out (assoc-ref %outputs "out"))) - `("--disable-nls" + (let ((cppflags (string-append " -D __GLIBC_MINOR__=6" + " -D MES_BOOTSTRAP=1")) + (bash (assoc-ref %build-inputs "bash"))) + `(,(string-append "CONFIG_SHELL=" bash "/bin/sh") + ,(string-append "CPPFLAGS=" cppflags) + "AR=tcc -ar" + "CXX=false" + "RANLIB=true" + ,(string-append "CC=tcc" cppflags) + "--disable-nls" "--disable-shared" "--disable-werror" - "--build=i386-unknown-linux" - "--host=i386-unknown-linux" - "--target=i386-unknown-linux" - "--with-sysroot=/" - ,(string-append "--prefix=" out))) - #:phases - (modify-phases %standard-phases - (add-before 'configure 'setenv - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (setenv "CONFIG_SHELL" shell) - (setenv "SHELL" shell) - (setenv "AR" "tcc -ar") - (setenv "RANLIB" "true") - (setenv "CC" "tcc -D __GLIBC_MINOR__=6")))) - (add-after 'unpack 'scripted-patch - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "bfd/configure" - (("^sed -e '/SRC-POTFILES.*" all) - "echo -e 'all:\\n\\ttrue\\n\\ninstall:\\n\\ttrue\\n' > po/Makefile\n")))) - (replace 'configure ; needs classic invocation of configure - (lambda* (#:key configure-flags #:allow-other-keys) - (format (current-error-port) - "running ./configure ~a\n" (string-join configure-flags)) - (apply system* "./configure" configure-flags) - (substitute* "config.status" - (("[.]//dev/null") "/dev/null")) - (invoke "sh" "./config.status")))))))) + "--build=i686-unknown-linux-gnu" + "--host=i686-unknown-linux-gnu" + "--with-sysroot=/")))))) (define gcc-core-mesboot0 ;; Gcc-2.95.3 is the most recent GCC that is supported by what the Mes C @@ -1176,7 +1048,6 @@ ac_cv_c_float_format='IEEE (little-endian)' (define (%boot-mesboot-core-inputs) `(("binutils" ,binutils-mesboot0) - ("gawk" ,gawk-mesboot0) ("gcc" ,gcc-core-mesboot0) ,@(alist-delete "tcc" (%boot-tcc-inputs)))) @@ -1207,72 +1078,6 @@ ac_cv_c_float_format='IEEE (little-endian)' (copy-recursively "include" out) (copy-recursively headers out))))))))) -(define gawk-mesboot0 - ;; The initial Gawk. - (package - (inherit gawk) - (name "gawk-mesboot0") - (version "3.0.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/gawk/gawk-" - version ".tar.gz")) - (sha256 - (base32 - "087s7vpc8zawn3l7bwv9f44bf59rc398hvaiid63klw6fkbvabr3")))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-tcc-inputs)) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:configure-flags '("--build=i686-unknown-linux-gnu" - "--host=i686-unknown-linux-gnu" - "--disable-nls") - #:make-flags '("gawk") - #:parallel-build? #f - #:parallel-tests? #f - #:strip-binaries? #f ; no strip yet - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'scripted-patch - (lambda _ - (substitute* "Makefile.in" - (("date ") "echo today ") - ((" autoheader") "true") - ((" -lm ") " ")) - (substitute* "test/Makefile.in" - (("^bigtest:.*") "bigtest: basic\n") - (("( |\t)(childin|convfmt|fflush|longwrds|math|negexp)" all sep) sep)))) - (add-before 'configure 'setenv - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (setenv "CONFIG_SHELL" shell) - (setenv "SHELL" shell) - (setenv "CC" "tcc") - (setenv "CPP" "tcc -E") - (setenv "LD" "tcc") - (setenv "ac_cv_func_getpgrp_void" "yes") - (setenv "ac_cv_func_tzset" "yes")))) - (replace 'configure ; needs classic invocation of configure - (lambda* (#:key configure-flags #:allow-other-keys) - (let* ((out (assoc-ref %outputs "out")) - (configure-flags - `(,@configure-flags - ,(string-append "--prefix=" out)))) - (format (current-error-port) "running ./configure ~a\n" (string-join configure-flags)) - (system* "touch" "configure") ; aclocal.m4 is newer than configure - (apply invoke (cons "./configure" configure-flags))))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin"))) - (install-file "gawk" bin) - (symlink "gawk" (string-append bin "/awk")))))))))) - (define glibc-mesboot0 ;; GNU C Library 2.2.5 is the most recent glibc that we managed to build ;; using gcc-2.95.3. Newer versions (2.3.x, 2.6, 2.1x) seem to need a newer @@ -1417,97 +1222,6 @@ ac_cv_c_float_format='IEEE (little-endian)' ("libc" ,glibc-mesboot0) ,@(alist-delete "gcc" (%boot-mesboot-core-inputs)))) -(define tar-mesboot - ;; Initial tar with support for xz compression. - (package - (inherit tar) - (name "tar-mesboot") - (version "1.22") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/tar/tar-" - version ".tar.gz")) - (sha256 - (base32 - "19nvix64y95n5v6rr5g9g3fn08zz85cb5anzd7csfv4a4sz9lw4y")))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-mesboot0-inputs)) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:tests? #f ; check is naive, also checks non-built PROGRAMS - #:strip-binaries? #f ; no strip yet - #:configure-flags '("--build=i686-unknown-linux-gnu" - "--host=i686-unknown-linux-gnu" - "--disable-nls") - #:phases - (modify-phases %standard-phases - (replace 'configure - (lambda* (#:key configure-flags #:allow-other-keys) - (let* ((out (assoc-ref %outputs "out")) - (bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (setenv "CONFIG_SHELL" shell) - (setenv "SHELL" shell) - (setenv "LIBS" "-lc -lnss_files -lnss_dns -lresolv") - (setenv "gl_cv_func_rename_dest_works" "yes") - (format (current-error-port) - "running ./configure ~a\n" (string-join configure-flags)) - (apply invoke (cons "./configure" configure-flags))))) - (add-after 'unpack 'scripted-patch - (lambda _ - (let* ((bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (substitute* "configure" - ((" /bin/sh") shell))) - (substitute* "Makefile.in" - (("^SUBDIRS = doc") "SUBDIRS =")))) - (replace 'install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (install-file "src/tar" bin))))))))) - -(define grep-mesboot - ;; The initial grep. - (package - (inherit grep) - (name "grep-mesboot") - (version "2.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/grep/grep-" - version ".tar.gz")) - (sha256 - (base32 - "1w862l80lgc5mxvpiy4cfwk761d6xxavn0m3xd2l7xs2kmzvp6lq")))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-mesboot0-inputs)) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:phases - (modify-phases %standard-phases - (add-before 'configure 'patch-configure - (lambda _ - (let* ((bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (substitute* "configure" - ((" [|][|] ./config.status") " || sh ./config.status"))))) - (replace 'install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (install-file "grep" bin) - (symlink "grep" (string-append bin "/egrep")) - (symlink "grep" (string-append bin "/fgrep")))))))))) - (define binutils-mesboot1 (package (inherit binutils-mesboot0) @@ -1523,46 +1237,7 @@ ac_cv_c_float_format='IEEE (little-endian)' "--build=i686-unknown-linux-gnu" "--host=i686-unknown-linux-gnu" "--with-sysroot=/" - ,(string-append "--prefix=" out)))) - ((#:phases phases) - `(modify-phases ,phases - (replace 'setenv - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (setenv "CONFIG_SHELL" shell)))))))))) - -(define coreutils-mesboot0 - (package - (inherit coreutils) - (name "coreutils-mesboot0") - ;; The latest .gz release of Coreutils is 8.13; which does not build with gcc-2.95.3: - ;; randperm.c: In function `sparse_swap': - ;; randperm.c:117: invalid lvalue in unary `&' - (version "5.0") ; 2003-04 - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/coreutils/coreutils-" - version ".tar.gz")) - (sha256 - (base32 - "10wq6k66i8adr4k08p0xmg87ff4ypiazvwzlmi7myib27xgffz62")))) - (native-inputs (%boot-mesboot0-inputs)) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (arguments - `(#:implicit-inputs? #f - #:tests? #f ; WARNING: `perl' is needed, ... - #:parallel-build? #f - #:strip-binaries? #f ; strip: unrecognized option `--only-keep-debug' - #:guile ,%bootstrap-guile - #:configure-flags - '("--disable-doc" - "LIBS=-lc -lnss_files -lnss_dns -lresolv" - "ac_cv_func_gethostbyname=no" - "gl_cv_func_rename_dest_works=yes"))))) + ,(string-append "--prefix=" out)))))))) (define gnu-make-mesboot (package @@ -1596,150 +1271,11 @@ ac_cv_c_float_format='IEEE (little-endian)' (bin (string-append out "/bin"))) (install-file "make" bin))))))))) -(define gawk-mesboot - (package - (inherit gawk) - (name "gawk-mesboot") - (version "3.1.8") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/gawk/gawk-" - version ".tar.gz")) - (sha256 - (base32 - "03d5y7jabq7p2s7ys9alay9446mm7i5g2wvy8nlicardgb6b6ii1")))) - (native-inputs `(,@(%boot-mesboot0-inputs) - ("mesboot-headers" ,mesboot-headers))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (arguments - `(#:implicit-inputs? #f - #:parallel-build? #f - #:guile ,%bootstrap-guile - #:configure-flags '("ac_cv_func_connect=no") - #:make-flags '("gawk") - #:phases - (modify-phases %standard-phases - (replace 'check - (lambda _ - (invoke "./gawk" "--version"))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin"))) - (install-file "gawk" bin) - (symlink "gawk" (string-append bin "/awk")))))))))) - -(define sed-mesboot - (package - (inherit sed) - (name "sed-mesboot") - (version "4.0.6") ; 2003-04 - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/sed/sed-" - version ".tar.gz")) - (sha256 - (base32 - "0861ij94cqc4vaaki6r2wlapwcmhpx4ggp4r70f46mb21a8fkvf1")))) - (native-inputs (%boot-mesboot0-inputs)) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (propagated-inputs '()) - (arguments - `(#:implicit-inputs? #f - #:parallel-build? #f - #:guile ,%bootstrap-guile - #:tests? #f ; 8to7 fails - #:phases - (modify-phases %standard-phases - (add-after 'unpack '/bin/sh - (lambda _ - (let* ((bash (assoc-ref %build-inputs "bash")) - (shell (string-append bash "/bin/bash"))) - (substitute* "testsuite/Makefile.tests" - (("^SHELL = /bin/sh") - (string-append "SHELL = " shell))))))))))) - -(define bash-mesboot - (package - (inherit bash-mesboot0) - (version "4.4") - (name "bash-mesboot") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/bash/bash-" - version ".tar.gz")) - (sha256 - (base32 - "1jyz6snd63xjn6skk7za6psgidsd53k05cr3lksqybi0q6936syq")))) - (inputs '()) - (propagated-inputs '()) - (native-inputs (%boot-mesboot0-inputs)) - (outputs '("out")) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:configure-flags - '("--build=i686-unknown-linux-gnu" - "--host=i686-unknown-linux-gnu" - - "--without-bash-malloc" - "--disable-readline" - "--disable-history" - "--disable-help-builtin" - "--disable-progcomp" - "--disable-net-redirections" - "--disable-nls" - - ;; Pretend 'dlopen' is missing so we don't build loadable - ;; modules and related code. - "ac_cv_func_dlopen=no") - #:make-flags '("bash") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'scripted-patch - (lambda _ - (substitute* "shell.c" - ((";;") ";")))) - (add-before 'configure 'setenv - (lambda _ - (setenv "AWK" "gawk") - (setenv "LIBS" "-lc -lnss_files -lnss_dns -lresolv") - (setenv "gl_cv_func_rename_dest_works" "yes"))) - (add-after 'configure 'configure-fixups - (lambda _ - (let ((config.h (open-file "config.h" "a"))) - (display (string-append " -#define enable_hostname_completion(on_or_off) 0 -") - config.h) - (close config.h)))) - (replace 'check - (lambda _ - (invoke "./bash" "--version"))) - (replace 'install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (mkdir-p bin) - (copy-file "bash" (string-append bin "/bash")) - (copy-file "bash" (string-append bin "/sh")))))))))) - (define (%boot-mesboot1-inputs) - `(("bash" ,bash-mesboot) - ("binutils" ,binutils-mesboot1) - ("coreutils" ,coreutils-mesboot0) - ("gawk" ,gawk-mesboot) - ("grep" ,grep-mesboot) + `(("binutils" ,binutils-mesboot1) ("make" ,gnu-make-mesboot) - ("sed" ,sed-mesboot) - ("tar" ,tar-mesboot) ,@(fold alist-delete (%boot-mesboot0-inputs) - '("bash" "binutils" "bootar" "coreutils" "gash" - "gawk" "grep" "guile" "make" "sed" "tar")))) + '("binutils" "make")))) (define gmp-boot (let ((version "4.3.2")) @@ -1933,57 +1469,22 @@ ac_cv_c_float_format='IEEE (little-endian)' `(("gcc" ,gcc-mesboot1) ,@(alist-delete "gcc" (%boot-mesboot1-inputs)))) -(define xz-mesboot - ;; Finally, we can build xz. - (package - (inherit xz) - (name "xz-mesboot") - (version "5.0.0") - (source (bootstrap-origin - (origin - (method url-fetch) - (uri (list (string-append "http://tukaani.org/xz/xz-" version - ".tar.gz") - (string-append "http://multiprecision.org/guix/xz-" - version ".tar.gz"))) - (sha256 - (base32 - "0kf40ggbs1vaaj5s9k4csycahzqcf65n20pa6lngqhm6j0cj3agb"))))) - (supported-systems '("i686-linux" "x86_64-linux")) - (inputs '()) - (outputs '("out")) - (propagated-inputs '()) - (native-inputs (%boot-mesboot2-inputs)) - (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:parallel-build? #f - #:configure-flags - `("--disable-assembler" - "--disable-shared" - "--enable-small" - "--disable-threads" - "--disable-xzdec" - "--disable-lzmadec" - "--disable-lzmainfo" - "--disable-lzma-links" - "--disable-scripts" - "--disable-doc" - "--disable-nls" - "--disable-symbol-versions" - ;; configure disqualifies BASH, CPP, GCC and GREP - ;; all of which seem fine for the build - "ac_cv_prog_cc_c99=-std=gnu9x" - "ac_cv_path_GREP=grep" - "gl_cv_posix_shell=bash" - "ac_cv_have_decl_optreset=no" - "CPPFLAGS=-D__GNUC__=1"))))) - (define hello-mesboot - ;; Check for Scheme-only bootstrap. + ;; Check for Scheme-only bootstrap. Note that newer versions of Hello + ;; break due to the way that newer versions of Gnulib handle + ;; "limits.h". Hence, we stick to 2.10. (package (inherit hello) (name "hello-mesboot") + (version "2.10") + (source + (origin + (inherit (package-source hello)) + (uri (string-append "mirror://gnu/hello/hello-" version + ".tar.gz")) + (sha256 + (base32 + "0ssi1wpaf7plaswqqjwigppsg5fyh99vdlb9kzl7c9lng89ndq1i")))) (supported-systems '("i686-linux" "x86_64-linux")) (inputs '()) (propagated-inputs '()) @@ -2003,76 +1504,51 @@ ac_cv_c_float_format='IEEE (little-endian)' (define binutils-mesboot (package - (inherit binutils) + (inherit binutils-mesboot1) (name "binutils-mesboot") - (version "2.20.1a") - (source (bootstrap-origin - (origin - (method url-fetch) - (uri (string-append "mirror://gnu/binutils/binutils-" - version ".tar.bz2")) - (patches (search-patches "binutils-boot-2.20.1a.patch")) - (sha256 - (base32 - "0r7dr0brfpchh5ic0z9r4yxqn4ybzmlh25sbp30cacqk8nb7rlvi"))))) + (native-inputs (%boot-mesboot2-inputs)))) + +;; Sadly we have to introduce Gawk here. The "versions.awk" script of +;; glibc 2.16.0 is too complicated for Gash-Utils. This is the version +;; of Gawk used previously during bootstrap. It's possible that a newer +;; version would work, too, but this one was already ready to go. +(define gawk-mesboot + (package + (inherit gawk) + (name "gawk-mesboot") + (version "3.1.8") + (source (origin + (method url-fetch) + (uri (string-append "mirror://gnu/gawk/gawk-" + version ".tar.gz")) + (sha256 + (base32 + "03d5y7jabq7p2s7ys9alay9446mm7i5g2wvy8nlicardgb6b6ii1")))) + (native-inputs (%boot-mesboot2-inputs)) + (supported-systems '("i686-linux" "x86_64-linux")) (inputs '()) (propagated-inputs '()) - (native-inputs `(("xz" ,xz-mesboot) - ,@(%boot-mesboot2-inputs))) - (supported-systems '("i686-linux" "x86_64-linux")) (arguments `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:tests? #f ; runtest: command not found #:parallel-build? #f - #:strip-binaries? #f ; no strip yet - #:configure-flags - `("CC=gcc" - "CXX=false" - "RANLIB=true" - "--disable-doc" - "--disable-nls" - "--disable-shared" - "--disable-werror" - "--build=i686-unknown-linux-gnu" - "--host=i686-unknown-linux-gnu" - "--with-sysroot=/" - ;; checking for grep that handles long lines and -e - "ac_cv_path_GREP=grep") - ;; FIXME: ac_cv_path_GREP=grep doesn't seem to be forwarded to - ;; cascading configure's? - #:make-flags '("ac_cv_path_GREP=grep") + #:guile ,%bootstrap-guile + #:configure-flags '("ac_cv_func_connect=no") + #:make-flags '("gawk") #:phases (modify-phases %standard-phases - (add-after 'unpack 'scripted-patch + (replace 'check (lambda _ - ;; sed-mesboot0 cannot build these - (copy-file "binutils/Makefile.in" "binutils/Makefile.in.orig") - (substitute* "binutils/Makefile.in" - ;; binutils/binutils uses an amazingly complex install - ;; command, using FOR, SED, READ, IF, ECHO, SED, SED, AWK, - ;; READ, and then LIBTOOL (to do something like - ;; `mkdir $DESTDIR$bindir; cp readline $DESTDIR$bindir ...') - - ;; Some tool [debugme!] cannot handle two escaped newlines - ;; (bash?), and the install stops after $(am__EXEEXT_11) - ;; ("objcopy"), so $(am__EXEEXT_13) ("readelf") and others do - ;; not get installed. Remove the stray newline: - (("^\t@BUILD_NLMCONV@ @BUILD_SRCONV@ @BUILD_DLLTOOL@ @BUILD_WINDRES@ .*") "")) - (substitute* "opcodes/Makefile.in" - (("^SUBDIRS = [.] po") "SUBDIRS = .")) - (substitute* "binutils/Makefile.in" - (("^SUBDIRS = doc po") "SUBDIRS =")) - (substitute* "gas/Makefile.in" - (("^SUBDIRS = doc po") "SUBDIRS =")) - (substitute* "gprof/Makefile.in" - (("^SUBDIRS = po") "SUBDIRS =")) - (substitute* "ld/Makefile.in" - (("^SUBDIRS = po") "SUBDIRS ="))))))))) + (invoke "./gawk" "--version"))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin"))) + (install-file "gawk" bin) + (symlink "gawk" (string-append bin "/awk")))))))))) (define (%boot-mesboot3-inputs) `(("binutils" ,binutils-mesboot) - ("xz" ,xz-mesboot) + ("gawk" ,gawk-mesboot) ,@(alist-delete "binutils" (%boot-mesboot2-inputs)))) (define glibc-headers-mesboot @@ -2149,6 +1625,11 @@ ac_cv_c_float_format='IEEE (little-endian)' (out (assoc-ref outputs "out"))) (apply invoke "make" make-flags) (copy-recursively kernel-headers out)))) + (add-before 'configure 'remove-bashism + (lambda _ + (substitute* "sysdeps/unix/make-syscalls.sh" + (("\\$[{]vdso_symver//\\./_[}]") + "$(echo $vdso_symver | sed -e 's/\\./_/g')")))) (replace 'configure (lambda* (#:key configure-flags #:allow-other-keys) (format (current-error-port) "running ../configure ~a\n" @@ -2194,6 +1675,17 @@ SHELL := " shell " (list (string-append "SHELL=" bash "/bin/sh")))) ((#:phases phases) #~(modify-phases #$phases + (add-after 'unpack 'simplify-intl-tests + (lambda _ + ;; The bootstrap Guile (2.0.9) crashes trying to + ;; perform a regex on non-ASCII text. This gets + ;; triggered by 'intl/po2test.sed' running over + ;; 'po/de.po'. If we ever remove the bootstrap + ;; Guile or add pure-Scheme regex to Gash, this can + ;; be removed. + (substitute* '("catgets/Makefile" + "intl/Makefile") + (("de\\.po") "en_GB.po")))) (replace 'install (lambda* (#:key outputs make-flags #:allow-other-keys) (let* ((kernel-headers (assoc-ref %build-inputs "kernel-headers")) @@ -2215,8 +1707,8 @@ SHELL := " shell " (name "gcc-mesboot1-wrapper") (source #f) (inputs '()) - (native-inputs `(("bash" ,bash-mesboot) - ("coreutils" ,coreutils-mesboot0) + (native-inputs `(("bash" ,gash-boot) + ("coreutils" ,gash-utils-boot) ("libc" ,glibc-mesboot) ("gcc" ,gcc-mesboot1))) (arguments @@ -2354,8 +1846,8 @@ exec " gcc "/bin/" program (version (package-version gcc-mesboot)) (source #f) (inputs '()) - (native-inputs `(("bash" ,bash-mesboot) - ("coreutils" ,coreutils-mesboot0) + (native-inputs `(("bash" ,gash-boot) + ("coreutils" ,gash-utils-boot) ("libc" ,glibc-mesboot) ("gcc" ,gcc-mesboot))))) @@ -2364,24 +1856,74 @@ exec " gcc "/bin/" program ("gcc" ,gcc-mesboot) ,@(fold alist-delete (%boot-mesboot4-inputs) '("gcc" "gcc-wrapper")))) -(define coreutils-mesboot +(define (mesboot-package name pkg) (package - (inherit coreutils) - (name "coreutils-mesboot") - (source (bootstrap-origin (package-source coreutils))) + (inherit pkg) + (name name) + (source (bootstrap-origin (package-source pkg))) (native-inputs (%boot-mesboot5-inputs)) (supported-systems '("i686-linux" "x86_64-linux")) (inputs '()) (propagated-inputs '()) (arguments - `(#:implicit-inputs? #f - #:guile ,%bootstrap-guile - #:tests? #f)))) + (ensure-keyword-arguments (package-arguments pkg) + `(#:implicit-inputs? #f + #:guile ,%bootstrap-guile + #:tests? #f))))) + +;; These packages are needed to complete the rest of the bootstrap. +;; In the future, Gash et al. could handle it directly, but it's not +;; ready yet. +(define bash-mesboot (mesboot-package "bash-mesboot" static-bash)) +(define sed-mesboot (mesboot-package "sed-mesboot" sed)) + +;; "sed" from Gash-Utils lacks the 'w' command as of 0.2.0. +(define coreutils-mesboot + (let ((pkg (mesboot-package "coreutils-mesboot" coreutils))) + (package + (inherit pkg) + (native-inputs + `(("sed" ,sed-mesboot) + ,@(package-native-inputs pkg)))))) + +(define grep-mesboot + (let ((pkg (mesboot-package "grep-mesboot" grep))) + (package + (inherit pkg) + (native-inputs + `(("sed" ,sed-mesboot) + ,@(package-native-inputs pkg)))))) + +;; The XZ implementation in Bootar cannot decompress 'tar'. +(define xz-mesboot + (let ((pkg (mesboot-package "xz-mesboot" xz))) + (package + (inherit pkg) + (arguments + (ensure-keyword-arguments (package-arguments pkg) + ;; XXX: This fails even though the + ;; actual runpaths seem fine. + `(#:validate-runpath? #f)))))) + +;; We don't strictly need Tar here, but it allows us to get rid of +;; Bootar and Gash-Utils and continue with the standard GNU tools. +(define tar-mesboot + (let ((pkg (mesboot-package "tar-mesboot" tar))) + (package + (inherit pkg) + (native-inputs + `(("xz" ,xz-mesboot) + ,@(package-native-inputs pkg)))))) (define (%boot-mesboot6-inputs) - `(("coreutils" ,coreutils-mesboot) + `(("bash" ,bash-mesboot) + ("coreutils" ,coreutils-mesboot) + ("grep" ,grep-mesboot) + ("sed" ,sed-mesboot) + ("tar" ,tar-mesboot) + ("xz" ,xz-mesboot) ,@(fold alist-delete (%boot-mesboot5-inputs) - '("coreutils" "kernel-headers")))) + '("bash" "coreutils" "bootar" "kernel-headers")))) (define (%bootstrap-inputs+toolchain) ;; The traditional bootstrap-inputs. For the i686-linux, x86_64-linux @@ -2458,7 +2000,21 @@ exec " gcc "/bin/" program `(#:tests? #f #:implicit-inputs? #f #:guile ,%bootstrap-guile - ,@(package-arguments coreutils))))) + ,@(package-arguments coreutils) + ;; The %bootstrap-glibc for aarch64 and armhf doesn't have + ;; $output/include/linux/prctl.h which causes some binaries + ;; to fail to build with coreutils-9.0+. + ,@(if (target-arm?) + `(#:configure-flags '(,(string-append + "--enable-no-install-program=" + ;; the defaults to not install. + "arch,coreutils,hostname" + ;; fails due to missing headers. + ",timeout,sort") + ,@(if (target-arm32?) + `("--disable-year2038") + `()))) + '()))))) (define diffutils-boot0 (package @@ -2554,6 +2110,7 @@ exec " gcc "/bin/" program #:implicit-inputs? #f #:guile ,%bootstrap-guile #:configure-flags '("--disable-bzlib") + #:make-flags '("CFLAGS+=-std=c11") #:strip-binaries? #f #:validate-runpath? #f ,@(package-arguments file))))) @@ -2709,7 +2266,13 @@ exec " gcc "/bin/" program (lambda _ (substitute* "libstdc++-v3/configure" (("g\\+\\+ -v") "true")))))))) - (_ (package-arguments lib))))) + (_ (package-arguments lib))) + + ;; Explicitly add #:modules so MAKE-LIBSTDC++ can be changed + ;; without a full bootstrap. + #:modules ((guix build gnu-build-system) + (guix build utils)))) + (inputs (%boot0-inputs)) (native-inputs '())))) @@ -2762,7 +2325,18 @@ exec " gcc "/bin/" program (inherit gcc) (name "gcc-cross-boot0") (outputs (delete "debug" (package-outputs gcc))) - (source (bootstrap-origin (package-source gcc))) + (source + (bootstrap-origin + (origin + (inherit (package-source gcc)) + (snippet + #~(begin + ;; XXX: The GCC test suite contains files with non-ASCII file + ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor + ;; can it be deleted from Guile, so resort to this evil hack. + #$(origin-snippet (package-source gcc)) + (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" + "gcc/testsuite/go.test/test/fixedbugs/issue27836.dir")))))) (arguments `(#:guile ,%bootstrap-guile #:implicit-inputs? #f @@ -2918,7 +2492,9 @@ exec " gcc "/bin/" program (arguments `(#:guile ,%bootstrap-guile #:implicit-inputs? #f - ,@(package-arguments m4))))) + ,@(package-arguments m4) + ;; Ignore test failure in gnulib for armhf/aarch64. + #:tests? ,(not (target-arm?)))))) (define bison-boot0 ;; This Bison is needed to build MiG so we need it early in the process. @@ -2997,7 +2573,18 @@ memoized as a function of '%current-system'." (arguments `(#:guile ,%bootstrap-guile #:implicit-inputs? #f - ,@(package-arguments linux-libre-headers))) + ,@(substitute-keyword-arguments (package-arguments linux-libre-headers) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'unpack 'lower-version-requirements + (lambda _ + ;; Pacify version checks so it works with the bootstrap + ;; toolchain, since we are not building the full kernel. + (substitute* "scripts/min-tool-version.sh" + (("echo 5\\.1\\.0") ;GCC + "echo 4.8.4") + (("echo 2\\.23\\.0") ;binutils + "echo 2.20.1"))))))))) (native-inputs `(("perl" ,perl-boot0) @@ -3093,6 +2680,7 @@ memoized as a function of '%current-system'." ;; Also, use (%BOOT0-INPUTS) to avoid building Perl once more. (package (inherit texinfo) + (source (bootstrap-origin (package-source texinfo))) (native-inputs '()) (inputs `(,@(%boot0-inputs) ("perl" ,perl-boot0))) @@ -3160,8 +2748,7 @@ memoized as a function of '%current-system'." `(,@(%boot0-inputs) ("expat" ,expat-sans-tests))) ;remove OpenSSL, zlib, etc. (native-inputs ;and pkg-config - `(("sitecustomize.py" ,(local-file (search-auxiliary-file - "python/sitecustomize.py"))))) + `()) (arguments `(#:implicit-inputs? #f #:guile ,%bootstrap-guile @@ -3187,6 +2774,13 @@ memoized as a function of '%current-system'." ;; Prevent the 'ossaudiodev' extension from being ;; built, since it requires Linux headers. (("'linux', ") "")))) + (add-after 'install 'remove-tests + (lambda* (#:key outputs #:allow-other-keys) + (delete-file-recursively + (string-append (assoc-ref outputs "out") + "/lib/python" + ,(version-major+minor version) + "/test")))) ,@(if (hurd-system?) `((add-before 'build 'fix-regen (lambda* (#:key inputs #:allow-other-keys) @@ -3194,11 +2788,14 @@ memoized as a function of '%current-system'." (substitute* "Lib/plat-generic/regen" (("/usr/include/") (string-append libc "/include/"))))))) - '()) - (add-after 'install 'install-sitecustomize.py - ,(customize-site version))))) + '())))) (native-search-paths - (list (guix-pythonpath-search-path version))))) + (list (search-path-specification + (variable "PYTHONPATH") + (files (list (string-append + "lib/python" + (version-major+minor version) + "/site-packages")))))))) (define/system-dependent ld-wrapper-boot0 ;; The first 'ld' wrapper, defined with 'define/system-dependent' because @@ -3352,14 +2949,14 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" #:guile ,%bootstrap-guile ,@(substitute-keyword-arguments (package-arguments static-bash) - ((#:configure-flags flags '()) + ((#:configure-flags flags #~'()) ;; Add a '-L' flag so that the pseudo-cross-ld of ;; BINUTILS-BOOT0 can find libc.a. - `(append ,flags - (list (string-append "LDFLAGS=-static -L" - (assoc-ref %build-inputs - "libc:static") - "/lib"))))))))) + #~(append #$flags + (list (string-append "LDFLAGS=-static -L" + (assoc-ref %build-inputs + "libc:static") + "/lib"))))))))) (define gettext-boot0 ;; A minimal gettext used during bootstrap. @@ -3465,7 +3062,7 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" (define libstdc++ ;; Intermediate libstdc++ that will allow us to build the final GCC ;; (remember that GCC-BOOT0 cannot build libstdc++.) - (let ((lib (make-libstdc++ gcc))) + (let ((lib (make-libstdc++ gcc-boot0))) (package (inherit lib) (source (bootstrap-origin (package-source lib))) @@ -3495,6 +3092,7 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" ;; Zlib used by GCC-FINAL. (package (inherit zlib) + (source (bootstrap-origin (package-source zlib))) (arguments `(#:guile ,%bootstrap-guile #:implicit-inputs? #f @@ -3532,6 +3130,11 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" ;; positive, so turn it off. #:validate-runpath? #f + ;; Additional modules for the libstdc++ phase below. + #:modules ((srfi srfi-1) + (srfi srfi-26) + ,@%gnu-build-system-modules) + ,@(substitute-keyword-arguments (package-arguments gcc) ((#:make-flags flags) ;; Since $LIBRARY_PATH is not honored, add the relevant flags. @@ -3569,7 +3172,26 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" (package-full-name lib "-") char-set:letter) ,(package-name lib))) - (list gmp-6.0 mpfr mpc)))))))))) + (list gmp-6.0 mpfr mpc))))) + (add-after 'unpack 'fix-build-with-external-libstdc++ + (lambda* (#:key inputs #:allow-other-keys) + (let ((libstdc++ (assoc-ref inputs "libstdc++"))) + ;; Fix a regression in GCC 11 where the libstc++ input + ;; shadows glibc headers when building libstdc++. An + ;; upstream fix was added in GCC 11.3.0, but it only + ;; hides system include directories, not those on + ;; CPLUS_INCLUDE_PATH. See discussion at + ;; <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100017>. + (substitute* "libstdc++-v3/src/c++17/Makefile.in" + (("AM_CXXFLAGS = ") + (string-append "CPLUS_INCLUDE_PATH = " + (string-join + (remove (cut string-prefix? libstdc++ <>) + (string-split + (getenv "CPLUS_INCLUDE_PATH") + #\:)) + ":") + "\nAM_CXXFLAGS = "))))))))))) ;; This time we want Texinfo, so we get the manual. Add ;; STATIC-BASH-FOR-GLIBC so that it's used in the final shebangs of @@ -3704,11 +3326,19 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" (inputs (alist-delete "pcre" (package-inputs grep))) (native-inputs `(("perl" ,perl-boot0)))))) +(define xz-final + ;; The final xz. We need to replace the bootstrap xz with a newer one + ;; before we get to the %final-inputs so file doesn't try to link to it. + (let ((xz (with-boot5 (package-with-bootstrap-guile xz)))) + (package/inherit xz))) + (define (%boot6-inputs) ;; Now use the final Coreutils. `(("coreutils" ,coreutils-final) ("grep" ,grep-final) - ,@(%boot5-inputs))) + ("xz" ,xz-final) + ,@(fold alist-delete (%boot5-inputs) + '("coreutils" "xz")))) (define with-boot6 (package-with-explicit-inputs %boot6-inputs)) @@ -3731,7 +3361,6 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" `(("tar" ,tar) ("gzip" ,gzip) ("bzip2" ,bzip2) - ("xz" ,xz) ("file" ,file) ("diffutils" ,diffutils) ("patch" ,patch) @@ -3739,6 +3368,7 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%" ("gawk" ,gawk))) ("sed" ,sed-final) ("grep" ,grep-final) + ("xz" ,xz-final) ("coreutils" ,coreutils-final) ("make" ,gnu-make-final) ("bash" ,bash-final) @@ -3880,10 +3510,10 @@ is the GNU Compiler Collection.") (make-gcc-toolchain gcc-9)) (define-public gcc-toolchain-10 - gcc-toolchain) + (make-gcc-toolchain gcc-10)) (define-public gcc-toolchain-11 - (make-gcc-toolchain gcc-11)) + gcc-toolchain) (define-public gcc-toolchain-12 (make-gcc-toolchain gcc-12)) @@ -3891,7 +3521,7 @@ is the GNU Compiler Collection.") (define-public gcc-toolchain-aka-gcc ;; It's natural for users to try "guix install gcc". This package ;; automatically "redirects" them to 'gcc-toolchain'. - (deprecated-package "gcc" gcc-toolchain-10)) + (deprecated-package "gcc" gcc-toolchain-11)) (define-public gdc-toolchain-10 @@ -3902,6 +3532,14 @@ D lang development to be installed in user profiles. This includes gdc, as well as libc (headers and binaries, plus debugging symbols in the @code{debug} output), and binutils."))) +(define-public gdc-toolchain-11 + (package (inherit (make-gcc-toolchain gdc-11)) + (synopsis "Complete GCC tool chain for D lang development") + (description "This package provides a complete GCC tool chain for +D lang development to be installed in user profiles. This includes +gdc, as well as libc (headers and binaries, plus debugging symbols +in the @code{debug} output), and binutils."))) + ;; Provide the Fortran toolchain package only for the version of gfortran that ;; is used by Guix internally to build Fortran libraries, because combining ;; code compiled with different versions can cause problems. diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm index e9d7338bb4..7283a05050 100644 --- a/gnu/packages/compression.scm +++ b/gnu/packages/compression.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2017, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012, 2013, 2014, 2015, 2017, 2019, 2020, 2021, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com> @@ -13,7 +13,7 @@ ;;; Copyright © 2016–2022 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2016 David Craven <david@craven.ch> ;;; Copyright © 2016, 2019, 2020 Kei Kebreau <kkebreau@posteo.net> -;;; Copyright © 2016, 2018, 2019, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2016, 2018-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Nikita <nikita@n0.is> ;;; Copyright © 2017 Manolis Fragkiskos Ragkousis <manolis837@gmail.com> ;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org> @@ -35,6 +35,7 @@ ;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Ahmad Jarara <git@ajarara.io> +;;; Copyright © 2022 Greg Hogan <code@greghogan.com> ;;; Copyright © 2022 Zhu Zihao <all_but_last@163.com> ;;; Copyright © 2021 Foo Chuan Wei <chuanwei.foo@hotmail.com> ;;; @@ -104,54 +105,53 @@ (define-public zlib (package (name "zlib") - (replacement zlib-1.2.12) - (version "1.2.11") + (version "1.2.13") (source (origin - (method url-fetch) - (uri (list (string-append "http://zlib.net/zlib-" + (method url-fetch) + (uri (list (string-append "http://zlib.net/zlib-" version ".tar.gz") - (string-append "mirror://sourceforge/libpng/zlib/" - version "/zlib-" version ".tar.gz"))) - (sha256 - (base32 - "18dighcs333gsvajvvgqp8l4cx7h1x7yx9gd5xacnk80spyykrf3")))) + (string-append "mirror://sourceforge/libpng/zlib/" + version "/zlib-" version ".tar.gz"))) + (sha256 + (base32 + "0c5b8vw40dy178xlpddw65q9gf1h2186jcc3p4swinwggbllv8mk")))) (build-system gnu-build-system) (outputs '("out" "static")) (arguments - `(#:make-flags - ,(if (target-mingw?) - `(list ,(string-append "PREFIX=" (%current-target-system) "-") - "BINARY_PATH = $(prefix)/bin" - "INCLUDE_PATH = $(prefix)/include" - "LIBRARY_PATH = $(prefix)/lib" - "SHARED_MODE = 1" - (string-append "prefix = " (assoc-ref %outputs "out"))) - ''()) - #:phases - (modify-phases %standard-phases - (replace 'configure - (lambda* (#:key outputs #:allow-other-keys) - ;; Zlib's home-made `configure' fails when passed - ;; extra flags like `--enable-fast-install', so we need to - ;; invoke it with just what it understand. - (let ((out (assoc-ref outputs "out"))) - ;; 'configure' doesn't understand '--host'. - ,@(if (%current-target-system) - `((setenv "CHOST" ,(%current-target-system))) - '()) - ,@(if (target-mingw?) - `((rename-file "win32/Makefile.gcc" "Makefile")) - `((invoke "./configure" - (string-append "--prefix=" out))))))) - (add-after 'install 'move-static-library - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (static (assoc-ref outputs "static"))) - (with-directory-excursion (string-append out "/lib") - (install-file "libz.a" (string-append static "/lib")) - (delete-file "libz.a") - #t))))))) + (list + #:make-flags + (if (target-mingw?) + #~(list #$(string-append "PREFIX=" (%current-target-system) "-") + "BINARY_PATH = $(prefix)/bin" + "INCLUDE_PATH = $(prefix)/include" + "LIBRARY_PATH = $(prefix)/lib" + "SHARED_MODE = 1" + (string-append "prefix = " #$output)) + #~'()) + #:phases + #~(modify-phases %standard-phases + (replace 'configure + (lambda _ + ;; Zlib's home-made `configure' fails when passed + ;; extra flags like `--enable-fast-install', so we need to + ;; invoke it with just what it understand. + (setenv "CC" #$(cc-for-target)) + ;; 'configure' doesn't understand '--host'. + #$@(if (%current-target-system) + #~((setenv "CHOST" #$(%current-target-system))) + #~()) + + #$@(if (target-mingw?) + #~((rename-file "win32/Makefile.gcc" "Makefile")) + #~((invoke "./configure" + (string-append "--prefix=" #$output)))))) + (add-after 'install 'move-static-library + (lambda _ + (with-directory-excursion (string-append #$output "/lib") + (install-file "libz.a" (string-append #$output:static + "/lib")) + (delete-file "libz.a"))))))) (home-page "https://zlib.net/") (synopsis "Compression library") (description @@ -166,21 +166,6 @@ independent of the input data and can be reduced, if necessary, at some cost in compression.") (license license:zlib))) -(define-public zlib-1.2.12 - (package - (inherit zlib) - (version "1.2.12") - (source - (origin - (method url-fetch) - (uri (list (string-append "http://zlib.net/zlib-" - version ".tar.gz") - (string-append "mirror://sourceforge/libpng/zlib/" - version "/zlib-" version ".tar.gz"))) - (sha256 - (base32 - "1n9na4fq4wagw1nzsfjr6wyly960jfa94460ncbf6p1fac44i14i")))))) - (define-public minizip (package (name "minizip") @@ -265,43 +250,28 @@ adding and extracting files to/from a tar archive.") (define-public gzip (package (name "gzip") - (version "1.10") + (version "1.12") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gzip/gzip-" version ".tar.xz")) (sha256 (base32 - "1h6p374d3j8d4cdfydzls021xa2yby8myc0h8d6m8bc7k6ncq9c4")))) + "0mhrx5wk9gazmxdw7vmbpg036yzqqhsww6h12kwf2dzn37jh6pnf")))) (build-system gnu-build-system) (synopsis "General file (de)compression (using lzw)") (arguments ;; FIXME: The test suite wants `less', and optionally Perl. '(#:tests? #f + #:configure-flags '("ac_cv_prog_LESS=\"less\"") #:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-for-glibc-2.28 - (lambda _ - ;; Adjust the bundled gnulib to work with glibc 2.28. See e.g. - ;; "m4-gnulib-libio.patch". This is a phase rather than patch - ;; or snippet to work around <https://bugs.gnu.org/32347>. - (substitute* (find-files "lib" "\\.c$") - (("#if defined _IO_ftrylockfile") - "#if defined _IO_EOF_SEEN")) - (substitute* "lib/stdio-impl.h" - (("^/\\* BSD stdio derived implementations") - (string-append "#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN\n" - "# define _IO_IN_BACKUP 0x100\n" - "#endif\n\n" - "/* BSD stdio derived implementations"))) - #t)) (add-after 'unpack 'use-absolute-name-of-gzip (lambda* (#:key outputs #:allow-other-keys) (substitute* "gunzip.in" - (("exec gzip") + (("exec 'gzip'") (string-append "exec " (assoc-ref outputs "out") - "/bin/gzip"))) - #t))))) + "/bin/gzip")))))))) (inputs `(,@(if (%current-target-system) `(("bash" ,bash-minimal)) @@ -327,93 +297,91 @@ file; as a result, it is often used in conjunction with \"tar\", resulting in "0s92986cv0p692icqlw1j42y9nld8zd83qwhzbqd61p1dqbh6nmb")))) (build-system gnu-build-system) (arguments - `(#:modules ((guix build gnu-build-system) - (guix build utils) - (ice-9 ftw) - (srfi srfi-1)) - #:phases - (modify-phases %standard-phases - (add-after 'set-paths 'hide-input-bzip2 - (lambda* (#:key inputs #:allow-other-keys) - (let ((bzip2 (assoc-ref inputs "bzip2"))) - (if bzip2 - ;; Prevent the build system from retaining a reference to - ;; BZIP2 from INPUTS. - (begin - (setenv "LIBRARY_PATH" - (string-join (delete (string-append bzip2 "/lib") - (string-split (getenv "LIBRARY_PATH") - #\:)) - ":")) - (format #t "environment variable `LIBRARY_PATH' set to `~a'~%" - (getenv "LIBRARY_PATH"))) - (format #t "no bzip2 found, nothing done~%")) - #t))) - (replace 'configure - (lambda* (#:key target #:allow-other-keys) - (when ,(%current-target-system) - ;; Cross-compilation: use the cross tools. - (substitute* (find-files "." "Makefile") - (("CC=.*$") - (string-append "CC = " target "-gcc\n")) - (("AR=.*$") - (string-append "AR = " target "-ar\n")) - (("RANLIB=.*$") - (string-append "RANLIB = " target "-ranlib\n")) - (("^all:(.*)test" _ prerequisites) - ;; Remove 'all' -> 'test' dependency. - (string-append "all:" prerequisites "\n")))) - #t)) - (add-before 'build 'build-shared-lib - (lambda* (#:key inputs #:allow-other-keys) - (patch-makefile-SHELL "Makefile-libbz2_so") - (invoke "make" "-f" "Makefile-libbz2_so"))) - (add-after 'install 'install-shared-lib - (lambda* (#:key outputs #:allow-other-keys) - ;; The Makefile above does not have an 'install' target, nor does - ;; it create all the (un)versioned symlinks, so we handle it here. - (let* ((out (assoc-ref outputs "out")) - (libdir (string-append out "/lib")) - (soname "libbz2.so") - ;; Locate the built library (e.g. "libbz2.so.1.0.6"). - (lib (car (scandir "." - (lambda (file) - (and (string-prefix? soname file) - (eq? 'regular - (stat:type (lstat file)))))))) - (soversion (string-drop lib (+ 1 (string-length soname))))) - (install-file lib libdir) - (with-directory-excursion libdir - ;; Create symlinks libbz2.so.1 -> libbz2.so.1.0, etc. - (let loop ((base soname) - (numbers (string-split soversion #\.))) - (unless (null? numbers) - (let ((so-file (string-append base "." (car numbers)))) - (symlink so-file base) - (loop so-file (cdr numbers)))))) - #t))) - (add-after 'install-shared-lib 'move-static-lib - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (static (assoc-ref outputs "static"))) - (with-directory-excursion (string-append out "/lib") - (install-file "libbz2.a" (string-append static "/lib")) - (delete-file "libbz2.a") - #t)))) - (add-after 'install-shared-lib 'patch-scripts - (lambda* (#:key outputs inputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out"))) - (substitute* (string-append out "/bin/bzdiff") - (("/bin/rm") "rm"))) - #t))) - - #:make-flags (list (string-append "PREFIX=" - (assoc-ref %outputs "out"))) - - ;; Don't attempt to run the tests when cross-compiling. - ,@(if (%current-target-system) - '(#:tests? #f) - '()))) + (list #:modules '((guix build gnu-build-system) + (guix build utils) + (ice-9 ftw) + (srfi srfi-1)) + #:phases + #~(modify-phases %standard-phases + (add-after 'set-paths 'hide-input-bzip2 + (lambda* (#:key inputs #:allow-other-keys) + (let ((bzip2 (assoc-ref inputs "bzip2"))) + (if bzip2 + ;; Prevent the build system from retaining a reference to + ;; BZIP2 from INPUTS. + (begin + (setenv "LIBRARY_PATH" + (string-join (delete (string-append bzip2 "/lib") + (string-split (getenv "LIBRARY_PATH") + #\:)) + ":")) + (format #t "environment variable `LIBRARY_PATH' set to `~a'~%" + (getenv "LIBRARY_PATH"))) + (format #t "no bzip2 found, nothing done~%")) + #t))) + (replace 'configure + (lambda* (#:key target #:allow-other-keys) + (when #$(%current-target-system) + ;; Cross-compilation: use the cross tools. + (substitute* (find-files "." "Makefile") + (("CC=.*$") + (string-append "CC = " target "-gcc\n")) + (("AR=.*$") + (string-append "AR = " target "-ar\n")) + (("RANLIB=.*$") + (string-append "RANLIB = " target "-ranlib\n")) + (("^all:(.*)test" _ prerequisites) + ;; Remove 'all' -> 'test' dependency. + (string-append "all:" prerequisites "\n")))) + #t)) + (add-before 'build 'build-shared-lib + (lambda* (#:key inputs #:allow-other-keys) + (patch-makefile-SHELL "Makefile-libbz2_so") + (invoke "make" "-f" "Makefile-libbz2_so"))) + (add-after 'install 'install-shared-lib + (lambda* (#:key outputs #:allow-other-keys) + ;; The Makefile above does not have an 'install' target, nor does + ;; it create all the (un)versioned symlinks, so we handle it here. + (let* ((out (assoc-ref outputs "out")) + (libdir (string-append out "/lib")) + (soname "libbz2.so") + ;; Locate the built library (e.g. "libbz2.so.1.0.6"). + (lib (car (scandir "." + (lambda (file) + (and (string-prefix? soname file) + (eq? 'regular + (stat:type (lstat file)))))))) + (soversion (string-drop lib (+ 1 (string-length soname))))) + (install-file lib libdir) + (with-directory-excursion libdir + ;; Create symlinks libbz2.so.1 -> libbz2.so.1.0, etc. + (let loop ((base soname) + (numbers (string-split soversion #\.))) + (unless (null? numbers) + (let ((so-file (string-append base "." (car numbers)))) + (symlink so-file base) + (loop so-file (cdr numbers)))))) + #t))) + (add-after 'install-shared-lib 'move-static-lib + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (static (assoc-ref outputs "static"))) + (with-directory-excursion (string-append out "/lib") + (install-file "libbz2.a" (string-append static "/lib")) + (delete-file "libbz2.a") + #t)))) + (add-after 'install-shared-lib 'patch-scripts + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out"))) + (substitute* (string-append out "/bin/bzdiff") + (("/bin/rm") "rm"))) + #t))) + + #:make-flags #~(list (string-append "PREFIX=" + (assoc-ref %outputs "out"))) + + ;; Don't attempt to run the tests when cross-compiling. + #:tests? (not (%current-target-system)))) (inputs `(,@(if (%current-target-system) `(("bash" ,bash-minimal)) @@ -525,7 +493,7 @@ compressed with pbzip2 can be decompressed with bzip2).") (define-public xz (package (name "xz") - (version "5.2.5") + (version "5.2.8") (source (origin (method url-fetch) (uri (list (string-append "http://tukaani.org/xz/xz-" version @@ -534,7 +502,7 @@ compressed with pbzip2 can be decompressed with bzip2).") version ".tar.gz"))) (sha256 (base32 - "045s9agl3bpv3swlwydhgsqh7791957vmgw2plw8f1rks07r3x7n")))) + "0z9056ydsy76ib5cl1z60jkcqgr0x12d3lw1p2qnlcwi1fgxlp7c")))) (build-system gnu-build-system) (arguments `(#:phases @@ -656,14 +624,14 @@ some compression ratio).") (define-public lzip (package (name "lzip") - (version "1.22") + (version "1.23") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/lzip/lzip-" version ".tar.gz")) (sha256 (base32 - "0j59hx72258334rmkwn57ahr6s69nlrx0a5ip1jw2fbiwr12sd63")))) + "03985xc696210irdzv475mlvf30ylahni3msanfz4ppivm3w14j7")))) (build-system gnu-build-system) (arguments ;; The configure script doesn't recognise the --build or --host @@ -1371,6 +1339,7 @@ for most inputs, but the resulting compressed files are anywhere from 20% to "switch(static_cast<HRESULT>(errorCode)) {")))) (patches (search-patches "p7zip-CVE-2016-9296.patch" "p7zip-CVE-2017-17969.patch" + "p7zip-fix-build-with-gcc-11.patch" "p7zip-remove-unused-code.patch")))) (build-system gnu-build-system) (arguments @@ -1635,35 +1604,21 @@ or junctions, and always follows hard links.") (define-public zstd (package (name "zstd") - ;; Replace to avoid the data corruption bug fixed in Zstd 1.5.5. - ;; https://github.com/facebook/zstd/releases/tag/v1.5.5 - (replacement zstd-1.5.5) - ;; Hide this buggy package in the Guix UI. If you add another - ;; property to this package, adjust the properties in the package - ;; replacement accordingly. - (properties `((hidden? . #true))) - (version "1.5.0") + (version "1.5.2") (source (origin (method url-fetch) (uri (string-append "https://github.com/facebook/zstd/releases/download/" "v" version "/zstd-" version ".tar.gz")) (sha256 - (base32 "150y541303vnvfhd8wkbih00lfvvm98rd12yijwlbkqzg3xgp52i")))) + (base32 "1l1zm1imcc2ixayykyh4y421shdj3pzp7g2xm2k2js8jmipxahkw")))) (build-system gnu-build-system) - (outputs '("out" ;1.2MiB executables and documentation + (outputs '("out" ;1.5MiB executables and documentation "lib" ;1.2MiB shared library and headers "static")) ;1.2MiB static library (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'remove-bogus-check - (lambda _ - ;; lib/Makefile falsely claims that no .pc file can be created. - (substitute* "lib/Makefile" - (("error configured .*dir ") - "true ")) - #t)) (add-after 'unpack 'patch-command-file-names ;; Don't require hard requirements to be in $PATH. (lambda* (#:key outputs #:allow-other-keys) @@ -1834,7 +1789,6 @@ Compression ratios of 2:1 to 3:1 are common for text files.") (package (inherit zip) (name "unzip") (version "6.0") - (replacement unzip/fixed) (source (origin (method url-fetch) @@ -1880,7 +1834,9 @@ Compression ratios of 2:1 to 3:1 are common for text files.") "unzip-zipbomb-part3.patch" ;; https://github.com/madler/unzip/issues/2 - "unzip-32bit-zipbomb-fix.patch")))) + "unzip-32bit-zipbomb-fix.patch" + + "unzip-CVE-2022-0529+CVE-2022-0530.patch")))) (build-system gnu-build-system) ;; no inputs; bzip2 is not supported, since not compiled with BZ_NO_STDIO (arguments @@ -1925,15 +1881,6 @@ recreates the stored directory structure by default.") (license (license:non-copyleft "file://LICENSE" "See LICENSE in the distribution.")))) -(define unzip/fixed - (package (inherit unzip) - (source - (origin - (inherit (package-source unzip)) - (patches (append - (origin-patches (package-source unzip)) - (search-patches "unzip-CVE-2022-0529+CVE-2022-0530.patch"))))))) - (define-public ziptime (let ((commit "2a5bc9dfbf7c6a80e5f7cb4dd05b4036741478bc") (revision "0")) diff --git a/gnu/packages/cpp.scm b/gnu/packages/cpp.scm index ed6ae69198..bb1f216e2a 100644 --- a/gnu/packages/cpp.scm +++ b/gnu/packages/cpp.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2017 Ethan R. Jones <doubleplusgood23@gmail.com> ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Fis Trivial <ybbs.daans@hotmail.com> -;;; Copyright © 2018, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2018, 2021, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2019, 2020, 2022 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz> ;;; Copyright © 2019 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl> @@ -1048,6 +1048,11 @@ point and then, after each tween step, plugging back the result.") "-DCMAKE_EXE_LINKER_FLAGS=-lgtest -lpthread -lgmock") #:phases (modify-phases %standard-phases + (add-after 'unpack 'fix-max + (lambda _ + (substitute* "absl/debugging/failure_signal_handler.cc" + (("std::max\\(SIGSTKSZ, 65536\\)") + "std::max<size_t>(SIGSTKSZ, 65536)")))) (add-before 'configure 'remove-gtest-check ;; The CMakeLists fails to find our googletest for some reason, but ;; it works nonetheless. @@ -1065,6 +1070,29 @@ augment the C++ standard library. The Abseil library code is collected from Google's C++ code base.") (license license:asl2.0))) +;; This is for grpc-for-python-grpcio; keep this in sync with its actual +;; requirements. +(define-public abseil-cpp-20211102.0 + (let ((base abseil-cpp-20200923.3)) + (package + (inherit base) + (name "abseil-cpp") + (version "20211102.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/abseil/abseil-cpp") + (commit "215105818dfde3174fe799600bb0f3cae233d0bf"))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "028vlxpmh65kb7s0cpba38qcwk1abyn5br0ffhvvjjh97vld69di")))) + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:tests? _ #false) #false) + ((#:configure-flags flags) + #~(cons* "-DCMAKE_CXX_STANDARD=11" #$flags))))))) + (define-public abseil-cpp (let ((base abseil-cpp-20200923.3)) (package @@ -1083,17 +1111,25 @@ Google's C++ code base.") (arguments (substitute-keyword-arguments (package-arguments base) ((#:configure-flags flags) - `(cons* "-DBUILD_TESTING=ON" + `(cons* "-DABSL_BUILD_TESTING=ON" (delete "-DABSL_RUN_TESTS=ON" ,flags)))))))) -(define-public abseil-cpp-cxxstd17 +(define (abseil-cpp-for-c++-standard version) (let ((base abseil-cpp)) (hidden-package (package/inherit base (arguments (substitute-keyword-arguments (package-arguments base) ((#:configure-flags flags) - #~(cons* "-DCMAKE_CXX_STANDARD=17" #$flags)))))))) + #~(cons* #$(string-append "-DCMAKE_CXX_STANDARD=" + (number->string version)) + #$flags)))))))) + +(define-public abseil-cpp-cxxstd17 + (abseil-cpp-for-c++-standard 17)) ;XXX: the default with GCC 11? + +(define-public abseil-cpp-cxxstd11 + (abseil-cpp-for-c++-standard 11)) (define-public pegtl (package @@ -1642,6 +1678,8 @@ almost every type of file containing key/value pairs.") (inputs (list ;;("boost ,boost) expat)) + (native-inputs + (list gcc-10)) ;does not build with gcc-12 (home-page "https://www.codesynthesis.com/projects/libcutl/") (synopsis "C++ utility library with generic and independent components") (description "libcutl is a C++ utility library. It contains a collection @@ -1686,7 +1724,7 @@ pointers, containers, compiler building blocks, etc.") #:include-regexp ("\\.so$"))) args)))))) (native-inputs - (list build)) + (list build gcc-10)) (inputs `(("libcutl" ,libcutl) ("libxerces-c" ,xerces-c))) @@ -1734,7 +1772,7 @@ and a traversal mechanism.") (string-append "edge_dispatcher::" all))))) (delete 'configure)))) (native-inputs - (list build)) + (list build gcc-10)) (inputs (list libcutl)) (synopsis "C++ Command Line Interface (CLI) definition language") @@ -1777,7 +1815,7 @@ documentation.") ,version))))) (delete 'configure)))) (native-inputs - (list build cli)) + (list build cli gcc-10)) (inputs (list libcutl libnsl libxsd-frontend)) (propagated-inputs diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 588448a2b0..1ade46e95d 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -35315,13 +35315,13 @@ package online.") texlive-amsmath texlive-booktabs texlive-etoolbox - texlive-generic-iftex - texlive-latex-fancyhdr - texlive-latex-fancyvrb + texlive-iftex + texlive-fancyhdr + texlive-fancyvrb texlive-latex-geometry - texlive-latex-graphics + texlive-graphics texlive-latex-threeparttable - texlive-latex-titlesec + texlive-titlesec texlive-latex-upquote texlive-listings texlive-polyglossia diff --git a/gnu/packages/crates-gtk.scm b/gnu/packages/crates-gtk.scm index 403c1f2aef..1c99c87bb6 100644 --- a/gnu/packages/crates-gtk.scm +++ b/gnu/packages/crates-gtk.scm @@ -60,7 +60,7 @@ ("rust-tempfile" ,rust-tempfile-3)))) (native-inputs (list pkg-config)) (inputs - (list atk glib)) + (list at-spi2-core glib)) (home-page "https://gtk-rs.org/") (synopsis "FFI bindings to libatk-1") (description "FFI bindings to libatk-1") @@ -90,7 +90,7 @@ ("rust-tempfile" ,rust-tempfile-3)))) (native-inputs (list pkg-config)) (inputs - (list atk glib)))) + (list at-spi2-core glib)))) (define-public rust-atk-sys-0.9 (package @@ -138,7 +138,7 @@ #:cargo-development-inputs (("rust-gir-format-check" ,rust-gir-format-check-0.1)))) (inputs - (list atk glib)) + (list at-spi2-core glib)) (home-page "https://gtk-rs.org/") (synopsis "Rust bindings for the ATK library") (description "Rust bindings for the ATK library") @@ -1469,7 +1469,7 @@ (("rust-gir-format-check" ,rust-gir-format-check-0.1)))) (native-inputs (list pkg-config)) (inputs - (list atk cairo glib gtk+ pango)) + (list at-spi2-core cairo glib gtk+ pango)) (home-page "https://gtk-rs.org/") (synopsis "Rust bindings for the GTK+ 3 library") (description "This package provides Rust bindings for the GTK+ 3 library.") diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9d06fc8561..a8f4c83336 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -60181,6 +60181,33 @@ into mod, giving clear and readable test results.") for TLS).") (license (list license:expat license:asl2.0)))) +(define-public rust-test-generator-0.3 + (package + (name "rust-test-generator") + (version "0.3.0") + (source (origin + (method url-fetch) + (uri (crate-uri "test-generator" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1h03y4503jhhrks4m7xqfjya9lsx3ip5dlbldr7mgcws6j8bx5za")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-glob" ,rust-glob-0.3) + ("rust-proc-macro2" ,rust-proc-macro2-0.4) + ("rust-quote" ,rust-quote-0.6) + ("rust-syn" ,rust-syn-0.15)))) + (home-page "https://github.com/frehberg/test-generator") + (synopsis "Generate parameterized tests from different input parameters") + (description + "This crate provides @code{#[test_resources]} and @code{#[bench_resources]} +procedural macro attributes that generates multiple parameterized tests using +one body with different resource input parameters. A test is generated for +each resource matching the specific resource location pattern.") + (license license:asl2.0))) + (define-public rust-tester-0.9 (package (name "rust-tester") @@ -69470,6 +69497,23 @@ library.") for locating fonts.") (license license:expat))) +(define-public rust-yeslogic-fontconfig-sys-2 + (package + (inherit rust-yeslogic-fontconfig-sys-3) + (name "rust-yeslogic-fontconfig-sys") + (version "2.11.2") + (source (origin + (method url-fetch) + (uri (crate-uri "yeslogic-fontconfig-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "13bzwn12dmxnc8iqd6za6q3j2ililnqjcplnlrfblbca4ia73r1q")))) + (arguments + `(#:cargo-inputs + (("rust-const-cstr" ,rust-const-cstr-0.3) + ("rust-pkg-config" ,rust-pkg-config-0.3)))))) + (define-public rust-zbase32-0.1 (package (name "rust-zbase32") diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index 2959616af6..8d0b41180b 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -46,6 +46,7 @@ #:export (cross-binutils cross-libc cross-gcc + cross-mig cross-kernel-headers)) (define-syntax %xgcc @@ -147,69 +148,69 @@ base compiler and using LIBC (which may be either a libc package or #f.)" ,@(package-arguments xgcc)))) (substitute-keyword-arguments args ((#:configure-flags flags) - `(append (list ,(string-append "--target=" target) - ,@(if libc - `( ;; Disable libcilkrts because it is not - ;; ported to GNU/Hurd. - "--disable-libcilkrts" - ;; When building a cross compiler, --with-sysroot is - ;; implicitly set to "$gcc_tooldir/sys-root". This does - ;; not work for us, because --with-native-system-header-dir - ;; is searched for relative to this location. Thus, we set - ;; it to "/" so GCC is able to find the target libc headers. - ;; This is safe because in practice GCC uses CROSS_CPATH - ;; & co to separate target and host libraries. - "--with-sysroot=/") - `( ;; Disable features not needed at this stage. - "--disable-shared" "--enable-static" - "--enable-languages=c,c++" - - ;; libstdc++ cannot be built at this stage - ;; ("Link tests are not allowed after - ;; GCC_NO_EXECUTABLES."). - "--disable-libstdc++-v3" - - "--disable-threads" ;libgcc, would need libc - "--disable-libatomic" - "--disable-libmudflap" - "--disable-libgomp" - "--disable-libmpx" - "--disable-libssp" - "--disable-libquadmath" - "--disable-decimal-float" ;would need libc - "--disable-libcilkrts" - - ;; When target is any OS other than 'none' these - ;; libraries will fail if there is no libc - ;; present. See - ;; <https://lists.gnu.org/archive/html/guix-devel/2016-02/msg01311.html> - "--disable-libitm" - "--disable-libvtv" - "--disable-libsanitizer" - )) - - ;; Install cross-built libraries such as libgcc_s.so in - ;; the "lib" output. - ,@(if libc - `((string-append "--with-toolexeclibdir=" - (assoc-ref %outputs "lib") - "/" ,target "/lib")) - '())) - - ,(if libc - flags - `(remove (cut string-match "--enable-languages.*" <>) - ,flags)))) + #~(append (list #$(string-append "--target=" target) + #$@(if libc + #~( ;; Disable libcilkrts because it is not + ;; ported to GNU/Hurd. + "--disable-libcilkrts" + ;; When building a cross compiler, --with-sysroot is + ;; implicitly set to "$gcc_tooldir/sys-root". This does + ;; not work for us, because --with-native-system-header-dir + ;; is searched for relative to this location. Thus, we set + ;; it to "/" so GCC is able to find the target libc headers. + ;; This is safe because in practice GCC uses CROSS_CPATH + ;; & co to separate target and host libraries. + "--with-sysroot=/") + #~( ;; Disable features not needed at this stage. + "--disable-shared" "--enable-static" + "--enable-languages=c,c++" + + ;; libstdc++ cannot be built at this stage + ;; ("Link tests are not allowed after + ;; GCC_NO_EXECUTABLES."). + "--disable-libstdc++-v3" + + "--disable-threads" ;libgcc, would need libc + "--disable-libatomic" + "--disable-libmudflap" + "--disable-libgomp" + "--disable-libmpx" + "--disable-libssp" + "--disable-libquadmath" + "--disable-decimal-float" ;would need libc + "--disable-libcilkrts" + + ;; When target is any OS other than 'none' these + ;; libraries will fail if there is no libc + ;; present. See + ;; <https://lists.gnu.org/archive/html/guix-devel/2016-02/msg01311.html> + "--disable-libitm" + "--disable-libvtv" + "--disable-libsanitizer" + )) + + ;; Install cross-built libraries such as libgcc_s.so in + ;; the "lib" output. + #$@(if libc + #~((string-append "--with-toolexeclibdir=" + (assoc-ref %outputs "lib") + "/" #$target "/lib")) + #~())) + + #$(if libc + flags + #~(remove (cut string-match "--enable-languages.*" <>) + #$flags)))) ((#:make-flags flags) (if libc - `(let ((libc (assoc-ref %build-inputs "libc"))) + #~(let ((libc (assoc-ref %build-inputs "libc"))) ;; FLAGS_FOR_TARGET are needed for the target libraries to receive ;; the -Bxxx for the startfiles. - (cons (string-append "FLAGS_FOR_TARGET=-B" libc "/lib") - ,flags)) + (cons (string-append "FLAGS_FOR_TARGET=-B" libc "/lib") + #$flags)) flags)) ((#:phases phases) - `(cross-gcc-build-phases ,target ,phases)))))) + #~(cross-gcc-build-phases #$target #$phases)))))) (define (cross-gcc-patches xgcc target) "Return GCC patches needed for XGCC and TARGET." @@ -365,6 +366,52 @@ target that libc." #:xgcc xgcc #:xbinutils xbinutils)) +(define* (cross-gnumach-headers target + #:key + (xgcc (cross-gcc target)) + (xbinutils (cross-binutils target))) + (package + (inherit gnumach-headers) + (name (string-append (package-name gnumach-headers) + "-cross-" target)) + (native-inputs + (modify-inputs (package-native-inputs gnumach-headers) + (prepend xgcc xbinutils))))) + +(define* (cross-mig target + #:key + (xgcc (cross-gcc target)) + (xbinutils (cross-binutils target))) + "Return a cross-mig for TARGET, where TARGET is a GNU triplet. Use XGCC as +the base compiler. Use XBINUTILS as the associated cross-Binutils." + (define xgnumach-headers + (cross-gnumach-headers target + #:xgcc xgcc + #:xbinutils xbinutils)) + (package + (inherit mig) + (name (string-append "mig-cross")) + (arguments + (substitute-keyword-arguments (package-arguments mig) + ((#:configure-flags flags #~'()) + #~(list #$(string-append "--target=" target))) + ((#:tests? _ #f) + #f) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-before 'configure 'set-cross-headers-path + (lambda* (#:key inputs #:allow-other-keys) + (let* ((mach #+xgnumach-headers) + (cpath (string-append mach "/include"))) + (for-each (lambda (variable) + (setenv variable cpath)) + '#$%gcc-cross-include-paths)))))))) + (propagated-inputs + (list xgnumach-headers)) + (native-inputs + (modify-inputs (package-native-inputs mig) + (prepend xgcc xbinutils))))) + (define* (cross-kernel-headers* target #:key (linux-headers linux-libre-headers) @@ -399,40 +446,11 @@ target that libc." ("cross-binutils" ,xbinutils) ,@(package-native-inputs linux-headers))))) - (define xgnumach-headers-name - (string-append (package-name gnumach-headers) "-cross-" target)) + (define xmig + (cross-mig target #:xgcc xgcc #:xbinutils xbinutils)) (define xgnumach-headers - (package - (inherit gnumach-headers) - (name xgnumach-headers-name) - (native-inputs - (modify-inputs (package-native-inputs gnumach-headers) - (prepend xgcc xbinutils))))) - - (define xmig - (package - (inherit mig) - (name (string-append "mig-cross")) - (arguments - (substitute-keyword-arguments (package-arguments mig) - ((#:configure-flags flags #~'()) - #~(list #$(string-append "--target=" target))) - ((#:tests? _ #f) - #f) - ((#:phases phases #~%standard-phases) - #~(modify-phases #$phases - (add-before 'configure 'set-cross-headers-path - (lambda* (#:key inputs #:allow-other-keys) - (let* ((mach #+(this-package-input xgnumach-headers-name)) - (cpath (string-append mach "/include"))) - (for-each (lambda (variable) - (setenv variable cpath)) - '#$%gcc-cross-include-paths)))))))) - (propagated-inputs (list xgnumach-headers)) - (native-inputs - (modify-inputs (package-native-inputs mig) - (prepend xgcc xbinutils))))) + (cross-gnumach-headers target #:xgcc xgcc #:xbinutils xbinutils)) (define xhurd-headers (package @@ -440,10 +458,17 @@ target that libc." (name (string-append (package-name hurd-headers) "-cross-" target)) + (arguments + (substitute-keyword-arguments (package-arguments hurd-headers) + ((#:configure-flags flags) + `(cons* ,(string-append "--build=" (%current-system)) + ,(string-append "--host=" target) + ,flags)))) + (native-inputs `(("cross-gcc" ,xgcc) ("cross-binutils" ,xbinutils) ("cross-mig" ,xmig) - ,@(alist-delete "mig"(package-native-inputs hurd-headers)))))) + ,@(alist-delete "mig" (package-native-inputs hurd-headers)))))) (define xglibc/hurd-headers (package @@ -488,6 +513,10 @@ target that libc." (guix build utils) (srfi srfi-26)) ,@(package-arguments hurd-minimal)) + ((#:configure-flags flags) + `(cons* ,(string-append "--build=" (%current-system)) + ,(string-append "--host=" target) + ,flags)) ((#:phases phases) `(modify-phases ,phases (add-before 'configure 'set-cross-headers-path @@ -513,12 +542,7 @@ target that libc." (inputs `(("gnumach-headers" ,xgnumach-headers) ("hurd-headers" ,xhurd-headers) - ("hurd-minimal" ,xhurd-minimal))) - - (native-inputs `(("cross-gcc" ,xgcc) - ("cross-binutils" ,xbinutils) - ("cross-mig" ,xmig) - ,@(package-native-inputs hurd-core-headers))))) + ("hurd-minimal" ,xhurd-minimal))))) (match target ((or "i586-pc-gnu" "i586-gnu") xhurd-core-headers) @@ -577,7 +601,9 @@ and the cross tool chain." ((#:configure-flags flags) `(cons ,(string-append "--host=" target) ,(if (target-hurd? target) - `(cons "--disable-werror" ,flags) + `(append (list "--disable-werror" + ,@%glibc/hurd-configure-flags) + ,flags) flags))) ((#:phases phases) `(modify-phases ,phases @@ -609,8 +635,9 @@ and the cross tool chain." ("cross-binutils" ,xbinutils) ,@(if (target-hurd? target) `(("cross-mig" - ,@(assoc-ref (package-native-inputs xheaders) - "cross-mig"))) + ,(cross-mig target + #:xgcc xgcc + #:xbinutils xbinutils))) '()) ,@(package-inputs libc) ;FIXME: static-bash ,@(package-native-inputs libc)))))) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index 1ed14d9092..935a77be04 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -901,7 +901,7 @@ SHA-1, SHA-2, and SHA-3, yet is at least as secure as SHA-3.") (define-public rhash (package (name "rhash") - (version "1.4.2") + (version "1.4.3") (source (origin (method url-fetch) @@ -910,7 +910,7 @@ SHA-1, SHA-2, and SHA-3, yet is at least as secure as SHA-3.") (file-name (string-append "rhash-" version ".tar.gz")) (sha256 (base32 - "0qpc1fq7gdxxl11zya1gqhl9628jjk3x60q9sna43w0yz7sh03b0")))) + "0glaghjvwh9ziiqf599v0fdr6jrgc7lcnriq0h7r41k3jrkglh0y")))) (build-system gnu-build-system) (arguments (list #:configure-flags diff --git a/gnu/packages/cups.scm b/gnu/packages/cups.scm index 3299cd1160..133d7debf4 100644 --- a/gnu/packages/cups.scm +++ b/gnu/packages/cups.scm @@ -38,6 +38,7 @@ #:use-module (gnu packages groff) #:use-module (gnu packages image) #:use-module (gnu packages libusb) + #:use-module (gnu packages linux) #:use-module (gnu packages pdf) #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) @@ -129,109 +130,102 @@ driver is known to work with these printers: (define-public cups-filters (package (name "cups-filters") - (version "1.28.9") - (source(origin - (method url-fetch) - (uri - (string-append "https://openprinting.org/download/cups-filters/" - "cups-filters-" version ".tar.xz")) - (sha256 - (base32 - "1bk0x1rrb8wqbhh5c979ppgy6s2kqss8mjdlahgcjvd79wm3fs9g")) - (modules '((guix build utils))) - (snippet - ;; install backends, banners and filters to cups-filters output - ;; directory, not the cups server directory - '(begin - (substitute* "Makefile.in" - (("CUPS_DATADIR = @CUPS_DATADIR@") - "CUPS_DATADIR = $(PREFIX)/share/cups") - (("pkgcupsserverrootdir = \\$\\(CUPS_SERVERROOT\\)") - "pkgcupsserverrootdir = $(PREFIX)") - ;; Choose standard directories notably so that binaries are - ;; stripped. - (("pkgbackenddir = \\$\\(CUPS_SERVERBIN\\)/backend") - "pkgbackenddir = $(PREFIX)/lib/cups/backend") - (("pkgfilterdir = \\$\\(CUPS_SERVERBIN\\)/filter") - "pkgfilterdir = $(PREFIX)/lib/cups/filter")) - ;; Find bannertopdf data such as the print test page in our - ;; output directory, not CUPS's prefix. - (substitute* "configure" - (("\\{CUPS_DATADIR\\}/data") - "{prefix}/share/cups/data")) - #t)))) + (version "1.28.15") + (source + (origin + (method url-fetch) + (uri + (string-append "https://openprinting.org/download/cups-filters/" + "cups-filters-" version ".tar.xz")) + (sha256 + (base32 "12s7s2jgnh4q7ws7r2is6xp3pqq818jhnm4vpyzyywmvkxvfq1x9")) + (modules '((guix build utils))) + (snippet + ;; Install backends, banners and filters to cups-filters output + ;; directory, not the cups server directory. + #~(begin + (substitute* "Makefile.in" + (("CUPS_DATADIR = @CUPS_DATADIR@") + "CUPS_DATADIR = $(PREFIX)/share/cups") + (("pkgcupsserverrootdir = \\$\\(CUPS_SERVERROOT\\)") + "pkgcupsserverrootdir = $(PREFIX)") + ;; Choose standard directories notably so that binaries are + ;; stripped. + (("^pkg(.*)dir = \\$\\(CUPS_SERVERBIN\\)/(.*)" _ type suffix) + (format #f "pkg~adir = $(PREFIX)/lib/cups/~a" type suffix))) + ;; Find bannertopdf data such as the print test page in our + ;; output directory, not CUPS's prefix. + (substitute* "configure" + (("\\{CUPS_DATADIR\\}/data") + "{prefix}/share/cups/data")))))) (build-system gnu-build-system) (arguments - `(#:make-flags (list (string-append "PREFIX=" %output)) - #:configure-flags - `("--disable-driverless" ; TODO: enable this - "--disable-mutool" ; depends on yet another PDF library (mupdf) - - ;; Look for the "domain socket of CUPS" in /var/run/cups. - "--localstatedir=/var" - - ;; Free software for the win. - "--with-acroread-path=evince" - - ,(string-append "--with-test-font-path=" - (assoc-ref %build-inputs "font-dejavu") - "/share/fonts/truetype/DejaVuSans.ttf") - ,(string-append "--with-gs-path=" - (assoc-ref %build-inputs "ghostscript") - "/bin/gsc") - ,(string-append "--with-shell=" - (assoc-ref %build-inputs "bash") - "/bin/bash") - ,(string-append "--with-rcdir=" - (assoc-ref %outputs "out") "/etc/rc.d")) - - #:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-foomatic-hardcoded-file-names - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Foomatic has hardcoded file names we need to fix. - (let ((out (assoc-ref outputs "out")) - (gs (assoc-ref inputs "ghostscript"))) - (substitute* "filter/foomatic-rip/foomaticrip.c" - (("/usr/local/lib/cups/filter") - (string-append out "/lib/cups/filter"))) - #t))) - (add-after 'install 'wrap-filters - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Some filters expect to find things in $PATH. We cannot - ;; just hard-code all absolute file names in the source - ;; because foomatic-rip, for example, has tests like - ;; 'startswith(cmd, "gs")'. - (let ((out (assoc-ref outputs "out")) - (ghostscript (assoc-ref inputs "ghostscript")) - (grep (assoc-ref inputs "grep"))) - (for-each (lambda (file) - (wrap-program file - `("PATH" ":" prefix - (,(string-append ghostscript "/bin:" - grep "/bin"))))) - (find-files (string-append - out "/lib/cups/filter"))) - #t)))))) + (list #:make-flags + #~(list (string-append "PREFIX=" #$output)) + #:configure-flags + #~(list "--disable-mutool" ; needs yet another PDF library (mupdf) + + ;; Look for the "domain socket of CUPS" in /var/run/cups. + "--localstatedir=/var" + + ;; Free software for the win. + "--with-acroread-path=evince" + + (string-append "--with-test-font-path=" + #$(this-package-input "font-dejavu") + "/share/fonts/truetype/DejaVuSans.ttf") + (string-append "--with-gs-path=" + #$(this-package-input "ghostscript-with-cups") + "/bin/gsc") + (string-append "--with-shell=" + (assoc-ref %build-inputs "bash") + "/bin/bash") + (string-append "--with-rcdir=" + #$output "/etc/rc.d")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-foomatic-hardcoded-file-names + (lambda _ + ;; Foomatic has hard-coded file names we need to fix. + (substitute* "filter/foomatic-rip/foomaticrip.c" + (("/usr/local(/lib/cups/filter)" _ file) + (string-append #$output file))))) + (add-after 'install 'wrap-filters + (lambda _ + ;; Some filters expect to find things in $PATH. We cannot + ;; just hard-code all absolute file names in the source + ;; because foomatic-rip, for example, has tests like + ;; 'startswith(cmd, "gs")'. + (for-each + (lambda (file) + (wrap-program file + `("PATH" ":" prefix + (,(string-append + #$(this-package-input "ghostscript-with-cups") + "/bin:" + #$(this-package-input "grep") "/bin"))))) + (find-files (string-append #$output + "/lib/cups/filter")))))))) (native-inputs - (list `(,glib "bin") ; for gdbus-codegen + (list `(,glib "bin") ; for gdbus-codegen pkg-config)) (inputs - `(("avahi" ,avahi) - ("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("font-dejavu" ,font-dejavu) ; also needed by test suite - ("ghostscript" ,ghostscript/cups) - ("grep" ,grep) - ("ijs" ,ijs) - ("dbus" ,dbus) - ("lcms" ,lcms) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("libtiff" ,libtiff) - ("glib" ,glib) - ("qpdf" ,qpdf) - ("poppler" ,poppler) - ("cups-minimal" ,cups-minimal))) + (list avahi + fontconfig + freetype + font-dejavu ; also needed by test suite + ghostscript/cups + grep + ijs + dbus + lcms + libjpeg-turbo + libpng + libtiff + glib + qpdf + poppler + cups-minimal)) (home-page "https://wiki.linuxfoundation.org/openprinting/cups-filters") (synopsis "OpenPrinting CUPS filters and backends") (description @@ -254,97 +248,90 @@ filters for the PDF-centric printing workflow introduced by OpenPrinting.") (define-public cups-minimal (package (name "cups-minimal") - (version "2.3.3op2") + (version "2.4.2") (source (origin (method git-fetch) - ;; Version maintained by the OpenPrinting organization, NOT a fork. The - ;; CUPS author tracks the current Apple CUPS sources and includes common - ;; changes and bug fixes for GNU/Linux. See its README and for example - ;; <https://github.com/apple/cups/issues/5917#issuecomment-819465891>. (uri (git-reference (url "https://github.com/OpenPrinting/cups") (commit (string-append "v" version)))) - (file-name (git-file-name name version)) + ;; Avoid NAME confusion: these are the complete CUPS sources. + (file-name (git-file-name "cups" version)) (sha256 - (base32 "126d6kd3pkhmsvbcflkcpk3y30iqlkdqyvrk9aqq88vbxzjd5ia6")))) + (base32 "01nn6ij7kpf2vzikinn7mk4crjx4ab8m4pplvsccc8gg30a2q9y9")))) (build-system gnu-build-system) (arguments - `(#:configure-flags - '("--disable-launchd" - "--disable-systemd" - "--disable-avahi" - "--disable-dnssd") - ;; Seven tests fail, mostly because of files that are provided by the - ;; cups-filters package. - #:tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'never-cupsAdminGetServerSettings - ;; Instead of querying the daemon directly, this part of CUPS assumes - ;; that (1) it has access to a cupsd.conf under CUPS_SERVERROOT, and - ;; (2) the file's contents apply to the running daemon. (1) is false - ;; at least on Guix Systems resulting in extremely long delays when - ;; loading the Web interface's /admin page. (2) isn't valid anywhere - ;; because it ignores, e.g., -c FILE. - ;; Upstream considers this code on ‘life support’ so just neuter it. - (lambda _ - (substitute* "cgi-bin/admin.c" - (("!cupsAdminGetServerSettings" match) - (string-append "0 && " match))))) - (add-after 'unpack 'remove-Web-UI-server-settings - ;; The /admin page's server configuration form is questionable for - ;; the same reason as cupsAdminGetServerSettings, and won't work at - ;; all on Guix Systems. Remove it entirely. - (lambda _ - ;; SUBSTITUTE* and a patch both have (dis)advantages. This is - ;; shorter & should ensure that no translation is forgotten. - (substitute* (find-files "templates" "^admin\\.tmpl$") - ((" class=\"halves\"") "") - (("<FORM.* ACTION=\"/jobs.*</FORM>" match) - (string-append match "</P>{BROKEN? ")) - (("</FORM>}" match) - (string-append match "}"))))) - (add-before 'configure 'patch-makedefs - (lambda _ - (substitute* "Makedefs.in" - (("INITDIR.*=.*@INITDIR@") "INITDIR = @prefix@/@INITDIR@") - (("/bin/sh") (which "sh"))) - #t)) - (add-before 'build 'patch-tests - (lambda _ - (substitute* "tools/ippeveprinter.c" - (("# else /\\* HAVE_AVAHI \\*/") - "#elif defined(HAVE_AVAHI)")) - #t)) - ,@(if (target-riscv64?) - `((add-after 'unpack 'update-config-scripts + (list #:configure-flags + ;; This package isn't maximally minimal: "--with-components=libcups" + ;; breaks cups-filters. Disable some other unnecessary features. + #~(list "--without-icondir" + "--without-languages" + "--without-menudir") + ;; Seven tests fail, mostly because of files that are provided by the + ;; cups-filters package. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'update-config-scripts (lambda* (#:key native-inputs inputs #:allow-other-keys) (for-each (lambda (file) (install-file (search-input-file (or native-inputs inputs) (string-append "/bin/" file)) ".")) - '("config.guess" "config.sub"))))) - '())))) - (native-inputs - (append (if (target-riscv64?) - (list config) - '()) - (list pkg-config))) - (inputs - (list zlib gnutls)) - (home-page "https://openprinting.github.io/") + '("config.guess" "config.sub")))) + (add-after 'unpack 'never-cupsAdminGetServerSettings + ;; Rather than just ask the daemon, this part of CUPS assumes + ;; that (1) it has access to a cupsd.conf under CUPS_SERVERROOT + ;; and (2) the file's contents apply to the running daemon. + ;; (1) is false at least on Guix Systems resulting in extremely + ;; long delays when loading the Web interface's /admin page. + ;; (2) is never valid: it ignores, e.g., -c FILE. Upstream + ;; considers this code on ‘life support’ so just neuter it. + (lambda _ + (substitute* "cgi-bin/admin.c" + (("!cupsAdminGetServerSettings" match) + (string-append "0 && " match))))) + (add-after 'unpack 'remove-Web-UI-server-settings + ;; The /admin page's server configuration form is questionable + ;; for the same reason as cupsAdminGetServerSettings, and won't + ;; work at all on Guix Systems. Remove it entirely. + (lambda _ + ;; SUBSTITUTE* & patches both have (dis)advantages. This is + ;; shorter & should ensure that no translation is forgotten. + (substitute* (find-files "templates" "^admin\\.tmpl$") + ((" class=\"halves\"") "") + (("<FORM.* ACTION=\"/jobs.*</FORM>" match) + (string-append match "</P>{BROKEN? ")) + (("</FORM>}" match) + (string-append match "}"))))) + (add-before 'configure 'patch-makedefs + (lambda _ + (substitute* "Makedefs.in" + (("INITDIR.*=.*@INITDIR@") "INITDIR = @prefix@/@INITDIR@") + (("/bin/sh") (which "sh"))))) + (add-before 'check 'skip-failing-tests + (lambda _ + (substitute* "test/run-stp-tests.sh" + ;; The number of error/warning lines differs, probably due + ;; to a missing font. Substitute the last observed count. + (("(\\$count != )33" _ prefix) + (string-append prefix "39")))))))) + (native-inputs (list config pkg-config)) + (inputs (list zlib gnutls)) + (home-page "https://openprinting.github.io/cups") (synopsis "The Common Unix Printing System") (description - "CUPS is a printing system that uses the Internet Printing Protocol -(@dfn{IPP}). It provides System V and BSD command-line interfaces, as well -as a Web interface and a C programming interface to manage printers and print -jobs. It supports printing to both local (parallel, serial, USB) and -networked printers, and printers can be shared from one computer to another. -Internally, CUPS uses PostScript Printer Description (@dfn{PPD}) files to -describe printer capabilities and features, and a wide variety of generic and -device-specific programs to convert and print many types of files.") + "CUPS is a printing system that uses @acronym{IPP, the Internet Printing +Protocol} to talk to printers and network clients. It also provides the old +@command{lp} and @command{lpr} commands, a Web interface, and a C programming +interface to manage printers and print jobs. + +CUPS can print to both local (USB, serial, even parallel) and networked +printers. Almost any modern printer supports IPP@tie{}Everywhere, sometimes +sold as AirPrint, and is supported out of the box. Older printers can be +supported through legacy PPD-based printer drivers called ``printer +applications''. These must be installed separately.") ;; CUPS is Apache 2.0 with exceptions, see the NOTICE file. (license license:asl2.0))) @@ -354,127 +341,124 @@ device-specific programs to convert and print many types of files.") (arguments (substitute-keyword-arguments (package-arguments cups-minimal) ((#:tests? _ #t) - ;; Three tests fail: - ;; * two tests in ipp-1.1.test related to "RFC 2911 section 3.2.6: - ;; Get-Jobs Operation" - ;; * test of number of error/warning messages, probably related to a - ;; missing font. - #f) - ((#:configure-flags _ '()) - `(list "--disable-launchd" - "--disable-systemd")) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-before 'check 'patch-tests - (lambda _ - (let ((filters (assoc-ref %build-inputs "cups-filters")) - (catpath (string-append - (assoc-ref %build-inputs "coreutils") "/bin/")) - (testdir (string-append (getcwd) "/tmp/"))) - (mkdir testdir) - (substitute* "test/run-stp-tests.sh" - ((" *BASE=/tmp/") (string-append "BASE=" testdir)) - - ;; Allow installation of filters from the output directory - ;; and from cups-filters. - (("for dir in /usr/libexec/cups/filter /usr/lib/cups/filter") - (string-append - "for dir in " - (assoc-ref %outputs "out") "/lib/cups/filter " - filters "/lib/cups/filter")) - - ;; Check for charsets in the default cups-filters output. - (("/usr/share/cups/charsets") - (string-append filters "/share/cups/charsets")) - - ;; Install additional required filters. - (("instfilter texttopdf texttopdf pdf") - (string-append - "instfilter texttopdf texttopdf pdf;" - "instfilter imagetoraster imagetoraster raster;" - "instfilter gstoraster gstoraster raster;" - "instfilter urftopdf urftopdf pdf;" - "instfilter rastertopdf rastertopdf pdf;" - "instfilter pstopdf pstopdf pdf")) - - ;; Specify the location of the lpstat binary. - (("description=\"`lpstat -l") - "description=\"`../systemv/lpstat -l") - - ;; Patch the shebangs of embedded scripts. - (("#!/bin/sh") (string-append "#!" (which "sh"))) - - ;; Also link MIME definitions from cups-filters - ;; to enable the additional filters for the test suite. - (("ln -s \\$root/conf/mime\\.types") - (string-append - "ln -s " filters - "/share/cups/mime/cupsfilters.types $BASE/share/mime; " - "ln -s $root/conf/mime.types")) - (("ln -s \\$root/conf/mime\\.convs") - (string-append - "ln -s " filters - "/share/cups/mime/cupsfilters.convs $BASE/share/mime; " - "ln -s $root/conf/mime.convs"))) - - ;; Fix the search path for the "cat" command. - (substitute* "cups/testfile.c" - (("cupsFileFind\\(\"cat\", \"/bin\"") - (string-append "cupsFileFind(\"cat\", \"" catpath "\"")) - (("cupsFileFind\\(\"cat\", \"/bin:/usr/bin\"") - (string-append "cupsFileFind(\"cat\", \"" catpath "\"")))))) - (add-after 'install 'install-cups-filters-symlinks - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (cups-filters (assoc-ref inputs "cups-filters"))) - ;; Charsets. - (symlink - (string-append cups-filters "/share/cups/charsets") - (string-append out "/share/charsets")) - - ;; MIME types, driver files, and PPDs. - (for-each - (lambda (f) - (symlink (string-append cups-filters f) - (string-append out f))) - '("/share/cups/mime/cupsfilters.types" - "/share/cups/mime/cupsfilters.convs" - "/share/cups/drv/cupsfilters.drv" - "/share/ppd")) - - ;; Filters. - (for-each - (lambda (f) - (symlink f - (string-append out "/lib/cups/filter" - (basename f)))) - (find-files (string-append cups-filters "/lib/cups/filter"))) - - ;; Backends. - (for-each - (lambda (f) - (symlink (string-append cups-filters f) - (string-append out "/lib/cups/backend/" - (basename f)))) - '("/lib/cups/backend/parallel" - "/lib/cups/backend/serial")) - - ;; Banners. - (let ((banners "/share/cups/banners")) - (delete-file-recursively (string-append out banners)) - (symlink (string-append cups-filters banners) - (string-append out banners))) - - ;; Assorted data. - (let ((data "/share/cups/data")) - (delete-file-recursively (string-append out data)) - (symlink (string-append cups-filters data) - (string-append out data)))))))))) + #t) + ((#:configure-flags flags #~'()) + #~(append #$flags + (list "--with-languages=all"))) ; no ‘=all’ means none(!) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-before 'check 'patch-tests + (lambda* (#:key outputs #:allow-other-keys) + (let ((filters #$(this-package-input "cups-filters")) + (catpath (string-append + #$(this-package-input "coreutils") "/bin/")) + (testdir (string-append (getcwd) "/tmp/"))) + (mkdir testdir) + (substitute* "test/run-stp-tests.sh" + ((" *BASE=/tmp/") (string-append "BASE=" testdir)) + + ;; Allow installation of filters from the output directory + ;; and from cups-filters. + (("for dir in /usr/libexec/cups/filter /usr/lib/cups/filter") + (string-append + "for dir in " + (assoc-ref outputs "out") "/lib/cups/filter " + filters "/lib/cups/filter")) + + ;; Check for charsets in the default cups-filters output. + (("/usr/share/cups/charsets") + (string-append filters "/share/cups/charsets")) + + ;; Install additional required filters. + (("instfilter texttopdf texttopdf pdf") + (string-append + "instfilter texttopdf texttopdf pdf;" + "instfilter imagetoraster imagetoraster raster;" + "instfilter gstoraster gstoraster raster;" + "instfilter urftopdf urftopdf pdf;" + "instfilter rastertopdf rastertopdf pdf;" + "instfilter pstopdf pstopdf pdf")) + + ;; Specify the location of the lpstat binary. + (("description=\"`lpstat -l") + "description=\"`../systemv/lpstat -l") + + ;; Patch the shebangs of embedded scripts. + (("#!/bin/sh") (string-append "#!" (which "sh"))) + + ;; Also link MIME definitions from cups-filters + ;; to enable the additional filters for the test suite. + (("ln -s \\$root/conf/mime\\.types") + (string-append + "ln -s " filters + "/share/cups/mime/cupsfilters.types $BASE/share/mime; " + "ln -s $root/conf/mime.types")) + (("ln -s \\$root/conf/mime\\.convs") + (string-append + "ln -s " filters + "/share/cups/mime/cupsfilters.convs $BASE/share/mime; " + "ln -s $root/conf/mime.convs"))) + + ;; Fix the search path for the "cat" command. + (substitute* "cups/testfile.c" + (("cupsFileFind\\(\"cat\", \"/bin\"") + (string-append "cupsFileFind(\"cat\", \"" catpath "\"")) + (("cupsFileFind\\(\"cat\", \"/bin:/usr/bin\"") + (string-append "cupsFileFind(\"cat\", \"" catpath "\"")))))) + (add-after 'install 'install-cups-filters-symlinks + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (cups-filters #$(this-package-input "cups-filters"))) + ;; Charsets. + (symlink + (string-append cups-filters "/share/cups/charsets") + (string-append out "/share/charsets")) + + ;; MIME types, driver files, and PPDs. + (for-each + (lambda (f) + (symlink (string-append cups-filters f) + (string-append out f))) + '("/share/cups/mime/cupsfilters.types" + "/share/cups/mime/cupsfilters.convs" + "/share/cups/drv/cupsfilters.drv" + "/share/ppd")) + + ;; Filters. + (for-each + (lambda (f) + (symlink f + (string-append out "/lib/cups/filter" + (basename f)))) + (find-files (string-append cups-filters "/lib/cups/filter"))) + + ;; Backends. + (for-each + (lambda (f) + (symlink (string-append cups-filters f) + (string-append out "/lib/cups/backend/" + (basename f)))) + '("/lib/cups/backend/parallel" + "/lib/cups/backend/serial")) + + ;; Banners. + (let ((banners "/share/cups/banners")) + (delete-file-recursively (string-append out banners)) + (symlink (string-append cups-filters banners) + (string-append out banners))) + + ;; Assorted data. + (let ((data "/share/cups/data")) + (delete-file-recursively (string-append out data)) + (symlink (string-append cups-filters data) + (string-append out data)))))))))) (inputs - `(("avahi" ,avahi) - ("gnutls" ,gnutls) - ("cups-filters" ,cups-filters) - ("zlib" ,zlib))))) + (list avahi + coreutils + cups-filters + gnutls + linux-pam + zlib)))) (define-public cups-pk-helper (package @@ -505,7 +489,7 @@ device-specific programs to convert and print many types of files.") (native-inputs (list intltool pkg-config `(,glib "bin"))) (inputs - (list glib polkit-duktape cups-minimal)) + (list glib polkit cups-minimal)) (home-page "https://www.freedesktop.org/wiki/Software/cups-pk-helper/") (synopsis "PolicyKit helper to configure CUPS with fine-grained privileges") (description @@ -517,14 +501,14 @@ should only be used as part of the Guix cups-pk-helper service.") (define-public hplip (package (name "hplip") - (version "3.21.10") + (version "3.23.3") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/hplip/hplip/" version "/hplip-" version ".tar.gz")) (sha256 (base32 - "0q3adcp8iygravp4bq4gw14jk20c5rhnawj1333qyw8yvlghw8yy")) + "1dh7gqhzv03a6j1kbkiaksy9a752k90xwqi5x0hqvn5ilac0l9p4")) (modules '((guix build utils))) (snippet '(begin @@ -555,199 +539,153 @@ should only be used as part of the Guix cups-pk-helper service.") "dat2drvdir = $(pkglibexecdir)\n") (("^locatedriverdir =.*") "locatedriverdir = $(pkglibexecdir)\n")))))) - (build-system gnu-build-system) (outputs (list "out" "ppd")) - (home-page "https://developers.hp.com/hp-linux-imaging-and-printing") - (synopsis "HP printer drivers") - (description - "Hewlett-Packard printer drivers and PostScript Printer Descriptions -(@dfn{PPD}s).") - - ;; The 'COPYING' file lists directories where each of these 3 licenses - ;; applies. - (license (list license:gpl2+ license:bsd-3 license:expat)) - - ;; TODO install apparmor profile files eventually. + (build-system gnu-build-system) (arguments - `(#:configure-flags - `("--disable-imageProcessor-build" - "--disable-network-build" - ,(string-append "--prefix=" (assoc-ref %outputs "out")) - ,(string-append "--sysconfdir=" (assoc-ref %outputs "out") "/etc") - ,(string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - ;; Disable until mime.types merging works (FIXME). - "--disable-fax-build" - "--enable-new-hpcups" - ;; TODO add foomatic drv install eventually. - ;; TODO --enable-policykit eventually. - ,(string-append "--with-cupsfilterdir=" - (assoc-ref %outputs "out") "/lib/cups/filter") - ,(string-append "--with-cupsbackenddir=" - (assoc-ref %outputs "out") "/lib/cups/backend") - ,(string-append "--with-hpppddir=" - (assoc-ref %outputs "ppd") "/share/ppd/HP") - ,(string-append "--with-icondir=" - (assoc-ref %outputs "out") "/share/applications") - ,(string-append "--with-systraydir=" - (assoc-ref %outputs "out") "/etc/xdg") - "--enable-qt5" "--disable-qt4") - - #:imported-modules ((guix build python-build-system) + (list + #:imported-modules `((guix build python-build-system) ,@%gnu-build-system-modules) - #:modules ((guix build gnu-build-system) + #:modules '((guix build gnu-build-system) (guix build utils) ((guix build python-build-system) #:prefix python:)) - - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-hard-coded-file-names - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - ;; FIXME: use merged ppds (I think actually only - ;; drvs need to be merged). - (cupsdir (assoc-ref inputs "cups-minimal"))) - (substitute* "base/g.py" - (("'/usr/share;[^']*'") - (string-append "'" cupsdir "/share'")) - (("'/etc/hp/hplip.conf'") - (string-append "'" out - "/etc/hp/hplip.conf" "'"))) - - (substitute* "Makefile.in" - (("[[:blank:]]check-plugin\\.py[[:blank:]]") " ") - ;; FIXME Use beginning-of-word in regexp. - (("[[:blank:]]plugin\\.py[[:blank:]]") " ") - (("/usr/include/libusb-1.0") - (search-input-directory inputs "/include/libusb-1.0")) - (("hplip_statedir =.*$") - ;; Don't bail out while trying to create - ;; /var/lib/hplip. We can safely change its value - ;; here because it's hard-coded in the code anyway. - "hplip_statedir = $(prefix)\n") - (("hplip_confdir = /etc/hp") - ;; This is only used for installing the default config. - (string-append "hplip_confdir = " out - "/etc/hp")) - (("halpredir = /usr/share/hal/fdi/preprobe/10osvendor") - ;; We don't use hal. - (string-append "halpredir = " out - "/share/hal/fdi/preprobe/10osvendor")) - (("rulesdir = /etc/udev/rules.d") - ;; udev rules will be merged by base service. - (string-append "rulesdir = " out - "/lib/udev/rules.d")) - (("rulessystemdir = /usr/lib/systemd/system") - ;; We don't use systemd. - (string-append "rulessystemdir = " out - "/lib/systemd/system")) - (("/etc/sane.d") - (string-append out "/etc/sane.d")))))) - (add-before 'configure 'fix-build-with-python-3.8 - (lambda* (#:key inputs #:allow-other-keys) - (let ((python (assoc-ref inputs "python"))) - ;; XXX: The configure script looks for Python headers in the - ;; wrong places as of version 3.20.3. Help it by adding the - ;; include directory on C_INCLUDE_PATH. - (when python - (setenv "C_INCLUDE_PATH" - (string-append python "/include/python" - (python:python-version python) - ":" (getenv "C_INCLUDE_PATH"))))))) - (add-after 'install 'install-models-dat - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (models-dir (string-append out - "/share/hplip/data/models"))) - (install-file "data/models/models.dat" models-dir)))) - (add-after 'install 'wrap-binaries - ;; Scripts in /bin are all symlinks to .py files in /share/hplip. - ;; Symlinks are immune to the Python build system's 'WRAP phase, - ;; and the .py files can't be wrapped because they are reused as - ;; modules. Replacing the symlinks in /bin with copies and - ;; wrapping them also doesn't work (“ModuleNotFoundError: - ;; No module named 'base'”). Behold: a custom WRAP-PROGRAM. - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin")) - (site (python:site-packages inputs outputs))) - (with-directory-excursion bin - (for-each (lambda (file) - (let ((target (readlink file))) - (delete-file file) - (with-output-to-file file - (lambda _ - (format #t - "#!~a~@ + #:configure-flags + #~(list "--disable-imageProcessor-build" + "--disable-network-build" + (string-append "--prefix=" #$output) + (string-append "--sysconfdir=" #$output "/etc") + (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib") + ;; Disable until mime.types merging works (FIXME). + "--disable-fax-build" + "--enable-new-hpcups" + ;; TODO add foomatic drv install eventually. + ;; TODO --enable-policykit eventually. + (string-append "--with-cupsfilterdir=" #$output + "/lib/cups/filter") + (string-append "--with-cupsbackenddir=" #$output + "/lib/cups/backend") + (string-append "--with-hpppddir=" #$output:ppd "/share/ppd/HP") + (string-append "--with-icondir=" #$output "/share/applications") + (string-append "--with-systraydir=" #$output "/etc/xdg") + "--enable-qt5" + "--disable-qt4") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-hard-coded-file-names + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out #$output) + ;; FIXME: use merged ppds (I think actually only + ;; drvs need to be merged). + (cupsdir #$(this-package-input "cups-minimal"))) + (substitute* (find-files "." "\\.py$") + ;; Refer to the correct default configuration file name. + (("/etc/hp/hplip.conf") + (string-append out "/etc/hp/hplip.conf"))) + (substitute* "base/g.py" + (("'/usr/share;[^']*'") + (string-append "'" cupsdir "/share'")) + (("'/etc/hp/hplip.conf'") + (string-append "'" out "/etc/hp/hplip.conf" "'"))) + + (substitute* "Makefile.in" + (("[[:blank:]]check-plugin\\.py[[:blank:]]") " ") + ;; FIXME Use beginning-of-word in regexp. + (("[[:blank:]]plugin\\.py[[:blank:]]") " ") + (("/usr/include/libusb-1.0") + (search-input-directory inputs "/include/libusb-1.0")) + (("hplip_statedir =.*$") + ;; Don't bail out while trying to create + ;; /var/lib/hplip. We can safely change its value + ;; here because it's hard-coded in the code anyway. + "hplip_statedir = $(prefix)\n") + (("hplip_confdir = /etc/hp") + ;; This is only used for installing the default config. + (string-append "hplip_confdir = " out "/etc/hp")) + (("halpredir = /usr/share/hal/fdi/preprobe/10osvendor") + ;; We don't use hal. + (string-append "halpredir = " out + "/share/hal/fdi/preprobe/10osvendor")) + (("rulesdir = /etc/udev/rules.d") + ;; udev rules will be merged by base service. + (string-append "rulesdir = " out "/lib/udev/rules.d")) + (("rulessystemdir = /usr/lib/systemd/system") + ;; We don't use systemd. + (string-append "rulessystemdir = " out "/lib/systemd/system")) + (("/etc/sane.d") + (string-append out "/etc/sane.d")))))) + (add-after 'install 'install-models-dat + (lambda* (#:key outputs #:allow-other-keys) + (install-file "data/models/models.dat" + (string-append #$output "/share/hplip/data/models")))) + (add-after 'install 'wrap-binaries + ;; Scripts in /bin are all symlinks to .py files in /share/hplip. + ;; Symlinks are immune to the Python build system's 'WRAP phase, + ;; and the .py files can't be wrapped because they are reused as + ;; modules. Replacing the symlinks in /bin with copies and + ;; wrapping them also doesn't work (“ModuleNotFoundError: + ;; No module named 'base'”). Behold: a custom WRAP-PROGRAM. + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin")) + (site (python:site-packages inputs outputs))) + (with-directory-excursion bin + (for-each (lambda (file) + (let ((target (readlink file))) + (delete-file file) + (with-output-to-file file + (lambda _ + (format #t + "#!~a~@ export GUIX_PYTHONPATH=\"~a:~a\"~@ exec -a \"$0\" \"~a/~a\" \"$@\"~%" - (which "bash") - site - (getenv "GUIX_PYTHONPATH") - bin target))) - (chmod file #o755))) - (find-files "." (lambda (file stat) - (eq? 'symlink (stat:type stat)))))))))))) - + (which "bash") + site + (getenv "GUIX_PYTHONPATH") + bin target))) + (chmod file #o755))) + (find-files "." (lambda (file stat) + (eq? 'symlink (stat:type stat)))))))))))) ;; Note that the error messages printed by the tools in the case of ;; missing dependencies are often downright misleading. ;; TODO: hp-toolbox still fails to start with: ;; from dbus.mainloop.pyqt5 import DBusQtMainLoop ;; ModuleNotFoundError: No module named 'dbus.mainloop.pyqt5' + (native-inputs (list perl pkg-config)) (inputs - `(("cups-minimal" ,cups-minimal) - ("dbus" ,dbus) - ("libjpeg" ,libjpeg-turbo) - ("libusb" ,libusb) - ("python" ,python) - ("python-dbus" ,python-dbus) - ("python-pygobject" ,python-pygobject) - ("python-pyqt" ,python-pyqt) - ("python-wrapper" ,python-wrapper) - ("sane-backends" ,sane-backends-minimal) - ("zlib" ,zlib))) - (native-inputs - (list perl pkg-config)))) - -;;; TODO: Integrate in base hplip package on core-updates. -(define-public hplip-next - (package - (inherit hplip) - (name "hplip") - (version "3.22.10") - (source (origin - (inherit (package-source hplip)) - (uri (string-append "mirror://sourceforge/hplip/hplip/" version - "/hplip-" version ".tar.gz")) - (sha256 - (base32 - "09366v0x10l35bkda6s5ysh64qdf24givn2gxlyidr2kdcpkyg2k")))) - (arguments - (substitute-keyword-arguments (package-arguments hplip) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'fix-more-hard-coded-file-names - (lambda* (#:key outputs #:allow-other-keys) - (substitute* (find-files "." "\\.py$") - (("/etc/hp/hplip.conf") - (string-append (assoc-ref outputs "out") - "/etc/hp/hplip.conf"))))))))))) + (list cups-minimal + dbus + libjpeg-turbo + libusb + python + python-dbus + python-pygobject + python-pyqt + python-wrapper + sane-backends-minimal + zlib)) + (home-page "https://developers.hp.com/hp-linux-imaging-and-printing") + (synopsis "HP printer drivers") + (description + "Hewlett-Packard printer drivers and PostScript Printer Descriptions +(@dfn{PPD}s).") + ;; The 'COPYING' file lists directories where each of these 3 licenses + ;; applies. + (license (list license:gpl2+ license:bsd-3 license:expat)))) (define-public hplip-minimal (package/inherit hplip (name "hplip-minimal") (arguments - (substitute-keyword-arguments (package-arguments hplip) - ((#:configure-flags cf) - ;; Produce a "light build", meaning that only the printer (CUPS) and - ;; scanner (SANE) support gets built, without all the 'hp-*' - ;; command-line tools. - `(cons "--enable-lite-build" - (delete "--enable-qt5" ,cf))) - ((#:phases phases) - ;; The 'wrap-binaries' is not needed here since the 'hp-*' programs - ;; are not installed. - `(alist-delete 'wrap-binaries ,phases)))) + (substitute-keyword-arguments (package-arguments hplip) + ((#:configure-flags cf) + ;; Produce a "light build", meaning that only the printer (CUPS) and + ;; scanner (SANE) support gets built, without all the 'hp-*' + ;; command-line tools. + #~(cons "--enable-lite-build" + (delete "--enable-qt5" #$cf))) + ((#:phases phases) + ;; The 'wrap-binaries' is not needed here since the 'hp-*' programs + ;; are not installed. + #~(alist-delete 'wrap-binaries #$phases)))) (inputs (remove (match-lambda ((label . _) (string-prefix? "python" label))) diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index bd00a6d274..484937bf0a 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -62,123 +62,91 @@ (define-public curl (package - (name "curl") - (version "7.79.1") - (replacement curl-7.84.0) - (source (origin - (method url-fetch) - (uri (string-append "https://curl.se/download/curl-" - version ".tar.xz")) - (sha256 - (base32 - "129n9hi7rbg3s112chyadhp4y27ppb5i65n12wm77aw2255zf1h6")) - (patches (search-patches "curl-use-ssl-cert-env.patch")))) - (build-system gnu-build-system) - (outputs '("out" - "doc")) ;1.2 MiB of man3 pages - (inputs (list gnutls libidn mit-krb5 - `(,nghttp2 "lib") zlib)) - (native-inputs - `(("nghttp2" ,nghttp2) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("python" ,python-minimal-wrapper))) - (native-search-paths - ;; These variables are introduced by curl-use-ssl-cert-env.patch. - (list $SSL_CERT_DIR - $SSL_CERT_FILE - ;; Note: This search path is respected by the `curl` command-line - ;; tool only. Patching libcurl to read it too would bring no - ;; advantages and require maintaining a more complex patch. - (search-path-specification - (variable "CURL_CA_BUNDLE") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt"))))) - (arguments - `(#:disallowed-references ("doc") - #:configure-flags (list "--with-gnutls" - (string-append "--with-gssapi=" - (assoc-ref %build-inputs "mit-krb5")) - "--disable-static") + (name "curl") + (version "7.85.0") + (source (origin + (method url-fetch) + (uri (string-append "https://curl.se/download/curl-" + version ".tar.xz")) + (sha256 + (base32 + "1rjbn0h5rddclhvxb8p5gddxszcrpbf5cw1whx6wnj4s9dnlmdc8")) + (patches (search-patches "curl-use-ssl-cert-env.patch")))) + (build-system gnu-build-system) + (outputs '("out" + "doc")) ;1.2 MiB of man3 pages + (inputs + (list gnutls libidn mit-krb5 `(,nghttp2 "lib") zlib)) + (native-inputs + (list nghttp2 perl pkg-config python-minimal-wrapper)) + (native-search-paths + ;; These variables are introduced by curl-use-ssl-cert-env.patch. + (list $SSL_CERT_DIR + $SSL_CERT_FILE + ;; Note: This search path is respected by the `curl` command-line + ;; tool only. Patching libcurl to read it too would bring no + ;; advantages and require maintaining a more complex patch. + (search-path-specification + (variable "CURL_CA_BUNDLE") + (file-type 'regular) + (separator #f) ;single entry + (files '("etc/ssl/certs/ca-certificates.crt"))))) + (arguments + (list + #:disallowed-references '("doc") + #:configure-flags + #~(list "--with-gnutls" + (string-append "--with-gssapi=" + (dirname (dirname + (search-input-file + %build-inputs "lib/libgssrpc.so")))) + "--disable-static") #:phases - (modify-phases %standard-phases - (add-after 'unpack 'do-not-record-configure-flags - (lambda _ - ;; Do not save the configure options to avoid unnecessary references. - (substitute* "curl-config.in" - (("@CONFIGURE_OPTIONS@") - "\"not available\"")))) - (add-after - 'install 'move-man3-pages - (lambda* (#:key outputs #:allow-other-keys) - ;; Move section 3 man pages to "doc". - (let ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share/man")) - (rename-file (string-append out "/share/man/man3") - (string-append doc "/share/man/man3"))))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (substitute* "tests/runtests.pl" - (("/bin/sh") (which "sh"))) + #~(modify-phases %standard-phases + (add-after 'unpack 'do-not-record-configure-flags + (lambda _ + ;; Do not save the configure options to avoid unnecessary references. + (substitute* "curl-config.in" + (("@CONFIGURE_OPTIONS@") + "\"not available\"")))) + (add-after 'install 'move-man3-pages + (lambda _ + ;; Move section 3 man pages to "doc". + (mkdir-p (string-append #$output:doc "/share/man")) + (rename-file (string-append #$output "/share/man/man3") + (string-append #$output:doc "/share/man/man3")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (substitute* "tests/runtests.pl" + (("/bin/sh") (which "sh"))) - (when tests? - ;; The top-level "make check" does "make -C tests quiet-test", which - ;; is too quiet. Use the "test" target instead, which is more - ;; verbose. - (invoke "make" "-C" "tests" "test"))))))) - (synopsis "Command line tool for transferring data with URL syntax") - (description - "curl is a command line tool for transferring data with URL syntax, + (when tests? + ;; The top-level "make check" does "make -C tests quiet-test", which + ;; is too quiet. Use the "test" target instead, which is more + ;; verbose. + (invoke "make" "-C" "tests" "test"))))))) + (synopsis "Command line tool for transferring data with URL syntax") + (description + "curl is a command line tool for transferring data with URL syntax, supporting DICT, FILE, FTP, FTPS, Gopher, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMTP, SMTPS, Telnet and TFTP. curl supports SSL certificates, HTTP POST, HTTP PUT, FTP uploading, HTTP form based upload, proxies, cookies, file transfer resume, user+password authentication (Basic, Digest, NTLM, Negotiate, kerberos...), proxy tunneling, and so on.") - (license (license:non-copyleft "file://COPYING" - "See COPYING in the distribution.")) - (home-page "https://curl.haxx.se/"))) - -;; Replacement package with fixes for multiple vulnerabilities. -;; See <https://curl.se/docs/security.html>. -(define curl-7.84.0 - (package - (inherit curl) - (version "7.84.0") - (source (origin - (inherit (package-source curl)) - (uri (string-append "https://curl.se/download/curl-" - version ".tar.xz")) - (sha256 - (base32 - "1f2xgj0wvys9xw50h7vcbaraavjr9rxx9n06x2xfbgs7ym1qn49d")) - (patches (append (origin-patches (package-source curl)) - (search-patches "curl-easy-lock.patch"))))) - (arguments (substitute-keyword-arguments (package-arguments curl) - ((#:phases phases) - (cond - ((not (target-64bit?)) - #~(modify-phases #$phases - (add-after 'unpack 'tweak-lib3026-test - (lambda _ - ;; Have that test create a hundred threads, not a - ;; thousand. - (substitute* "tests/libtest/lib3026.c" - (("NUM_THREADS .*$") - "NUM_THREADS 100\n")))))) - (else phases))))))) + (license (license:non-copyleft "file://COPYING" + "See COPYING in the distribution.")) + (home-page "https://curl.haxx.se/"))) (define-public curl-ssh (package/inherit curl (arguments (substitute-keyword-arguments (package-arguments curl) ((#:configure-flags flags) - `(cons "--with-libssh2" ,flags)))) + #~(cons "--with-libssh2" #$flags)))) (inputs - `(("libssh2" ,libssh2) - ,@(package-inputs curl))) + (modify-inputs (package-inputs curl) + (prepend libssh2))) (properties `((hidden? . #t))))) (define-public kurly diff --git a/gnu/packages/cyrus-sasl.scm b/gnu/packages/cyrus-sasl.scm index 2cd18f3e5e..70d579c127 100644 --- a/gnu/packages/cyrus-sasl.scm +++ b/gnu/packages/cyrus-sasl.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -26,55 +27,48 @@ #:use-module (gnu packages kerberos) #:use-module (gnu packages tls) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix build-system gnu)) (define-public cyrus-sasl (package - (name "cyrus-sasl") - (version "2.1.27") - (source (origin - (method url-fetch) - (uri (list (string-append - "https://cyrusimap.org/releases/cyrus-sasl-" - version ".tar.gz") - (string-append - "ftp://ftp.cyrusimap.org/cyrus-sasl/cyrus-sasl-" - version ".tar.gz"))) - (sha256 (base32 - "1m85zcpgfdhm43cavpdkhb1s2zq1b31472hq1w1gs3xh94anp1i6")) - (patches (search-patches "cyrus-sasl-ac-try-run-fix.patch" - "cyrus-sasl-CVE-2019-19906.patch")))) - (build-system gnu-build-system) - (native-inputs - (list autoconf automake libtool)) - (inputs (list gdbm openssl)) - (propagated-inputs - (list ;; cyrus-sasl.pc refers to -lkrb5, so propagate it. - mit-krb5)) - (arguments - '(#:configure-flags (list (string-append "--with-plugindir=" - (assoc-ref %outputs "out") - "/lib/sasl2")) + (name "cyrus-sasl") + (version "2.1.28") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/cyrusimap/cyrus-sasl" + "/releases/download/cyrus-sasl-" version + "/cyrus-sasl-" version ".tar.gz")) + (sha256 + (base32 + "135kbgyfpa1mwqp5dm223yr6ddzi4vjm7cr414d7rmhys2mwdkvw")))) + (build-system gnu-build-system) + (inputs (list gdbm mit-krb5 openssl)) + (arguments + (list + #:configure-flags #~(list (string-append "--with-plugindir=" + (assoc-ref %outputs "out") + "/lib/sasl2") + ;; When cross-compiling the build system is + ;; unable to determine whether SPNEGO is + ;; supported; Kerberos does, so enable it. + #$@(if (%current-target-system) + '("ac_cv_gssapi_supports_spnego=yes") + '())) ;; The 'plugins' directory has shared source files, such as ;; 'plugin_common.c'. When building the shared libraries there, libtool ;; ends up doing "ln -s plugin_common.lo plugin_common.o", which can ;; fail with EEXIST when building things in parallel. - #:parallel-build? #f - - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'autogen - (lambda _ - (invoke "autoreconf" "-vif")))))) - (synopsis "Simple Authentication Security Layer implementation") - (description - "SASL (Simple Authentication Security Layer) is an Internet + #:parallel-build? #f)) + (synopsis "Simple Authentication Security Layer implementation") + (description + "SASL (Simple Authentication Security Layer) is an Internet standards-track method for remote computers to authenticate. The Cyrus SASL library makes supporting various SASL mechanisms easy for both client and server writers.") - (license (license:non-copyleft "file://COPYING" - "See COPYING in the distribution.")) - (home-page "https://cyrusimap.org/sasl/"))) + (license (license:non-copyleft "file://COPYING" + "See COPYING in the distribution.")) + (home-page "https://cyrusimap.org/sasl/"))) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 0f2dce00a1..4cd0d61da8 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -885,7 +885,7 @@ auto-completion and syntax highlighting.") libaio libtirpc ncurses - openssl + openssl-1.1 procps rpcsvc-proto ; rpcgen sed @@ -1223,7 +1223,7 @@ and high-availability (HA).") (invoke "make" "postgres.info") (install-file "postgres.info" (string-append #$output "/share/info")))))))) - (native-inputs (list docbook-xml docbook2x libxml2 perl texinfo)) + (native-inputs (list docbook-xml-4.5 docbook2x libxml2 perl texinfo)) (inputs (list readline `(,util-linux "lib") openssl zlib)) (home-page "https://www.postgresql.org/") (synopsis "Powerful object-relational database system") @@ -1855,14 +1855,14 @@ changes.") (define-public tdb (package (name "tdb") - (version "1.4.5") + (version "1.4.7") (source (origin (method url-fetch) (uri (string-append "https://www.samba.org/ftp/tdb/tdb-" version ".tar.gz")) (sha256 (base32 - "0h8fkblws3d4vf37yhbrbw2nfxg5vk2v3i5mk04hhcbh9y4fvz5w")))) + "03n2hz4sv003gpkyp57hk5kiw4xk9f2dkxq75kzk2gskxy6idyx4")))) (build-system gnu-build-system) (arguments '(#:phases @@ -4873,7 +4873,7 @@ The drivers officially supported by @code{libdbi} are: (define-public soci (package (name "soci") - (version "4.0.2") + (version "4.0.3") (source (origin (method git-fetch) (uri (git-reference @@ -4882,7 +4882,7 @@ The drivers officially supported by @code{libdbi} are: (file-name (git-file-name name version)) (sha256 (base32 - "0qc6d71lyrfh5zb7pmfihd1hjyazlkgq6p0g06ans77wnnjh0k9l")))) + "12aq7pama96l2c1kmfkclb4bvrsxs9a8ppgk5gmzw45w2lg35i0y")))) (build-system cmake-build-system) (propagated-inputs ;; Headers of soci has include-references to headers of these inputs. @@ -5166,18 +5166,18 @@ mechanism of @code{dogpile}.") python-jinja2 python-mergedeep python-pint - python-pluggy-next + python-pluggy python-pyyaml python-uvicorn)) (native-inputs (list python-beautifulsoup4 python-black python-cogapp - python-pytest-7.1 + python-pytest python-pytest-asyncio python-pytest-runner python-pytest-timeout - python-pytest-xdist-next + python-pytest-xdist python-setuptools python-trustme)) (home-page "https://datasette.io/") diff --git a/gnu/packages/dbm.scm b/gnu/packages/dbm.scm index 2d3cce9e15..19a1b503cf 100644 --- a/gnu/packages/dbm.scm +++ b/gnu/packages/dbm.scm @@ -167,14 +167,14 @@ SQL, Key/Value, XML/XQuery or Java Object storage for their data model.") (define-public gdbm (package (name "gdbm") - (version "1.20") + (version "1.23") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gdbm/gdbm-" version ".tar.gz")) (sha256 (base32 - "14m22j0zndd42yc0ps0bcnnjj2iq7agnp66sl882lj5k91bc1sis")))) + "1kfapds42j1sjq6wl7fygipw5904wpbfa5kwppj3mwgz44fhicbl")))) (arguments `(#:configure-flags '("--enable-libgdbm-compat" "--disable-static"))) (build-system gnu-build-system) diff --git a/gnu/packages/dejagnu.scm b/gnu/packages/dejagnu.scm index 08be5a8afd..579a1a7a40 100644 --- a/gnu/packages/dejagnu.scm +++ b/gnu/packages/dejagnu.scm @@ -1,7 +1,9 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org> -;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flasher.co.il> +;;; Copyright © 2016, 2017, 2022 Efraim Flashner <efraim@flasher.co.il> ;;; Copyright © 2018 Mark H Weaver <mhw@netris.org> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be> ;;; ;;; This file is part of GNU Guix. ;;; @@ -21,60 +23,72 @@ (define-module (gnu packages dejagnu) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix build-system gnu) #:use-module (guix licenses) + #:use-module (gnu packages bash) #:use-module (gnu packages tcl)) (define-public dejagnu (package (name "dejagnu") - (version "1.6.2") + (version "1.6.3") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/dejagnu/dejagnu-" - version ".tar.gz")) - (sha256 - (base32 - "0qfj2wd4qk1yn9yzam6g8nmyxfazcc0knjyyibycb2ainkhp21hd")))) + (method url-fetch) + (uri (string-append "mirror://gnu/dejagnu/dejagnu-" + version ".tar.gz")) + (sha256 + (base32 + "1qx2cv6qkxbiqg87jh217jb62hk3s7dmcs4cz1llm2wmsynfznl7")))) (build-system gnu-build-system) - (inputs (list expect)) + (inputs (list bash-minimal expect)) (arguments - '(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda _ - ;; Note: The test-suite *requires* /dev/pts among the - ;; `build-chroot-dirs' of the build daemon when - ;; building in a chroot. See - ;; <http://thread.gmane.org/gmane.linux.distributions.nixos/1036> - ;; for details. - (if (and (directory-exists? "/dev/pts") - (directory-exists? "/proc")) - (begin - ;; Provide `runtest' with a log name, otherwise it - ;; tries to run `whoami', which fails when in a chroot. - (setenv "LOGNAME" "guix-builder") + (list + ;; Do an out-of-source build to work-around a non-deterministic bug in Expect: + ;; <https://lists.gnu.org/archive/html/bug-dejagnu/2021-06/msg00013.html>. + #:out-of-source? #true + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-/bin/sh + (lambda* (#:key inputs #:allow-other-keys) + ;; Patch embedded /bin/sh references. + (let ((/bin/sh (search-input-file inputs "/bin/sh"))) + (substitute* "dejagnu" + (("exec /bin/sh") + (string-append "exec " /bin/sh))) + (substitute* (find-files "testsuite/report-card.all") + (("/bin/sh") /bin/sh))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + ;; Note: The test-suite *requires* /dev/pts among the + ;; `build-chroot-dirs' of the build daemon when + ;; building in a chroot. See + ;; <http://thread.gmane.org/gmane.linux.distributions.nixos/1036> + ;; for details. + (when tests? + (if (and (directory-exists? "/dev/pts") + (directory-exists? "/proc")) + (begin + ;; Provide `runtest' with a log name, otherwise it + ;; tries to run `whoami', which fails when in a chroot. + (setenv "LOGNAME" "guix-builder") - ;; The test-suite needs to have a non-empty stdin: - ;; <http://lists.gnu.org/archive/html/bug-dejagnu/2003-06/msg00002.html>. - (unless (zero? (system "make check < /dev/zero")) - (error "make check failed"))) - (display "test suite cannot be run, skipping\n")) - #t)) - (add-after 'install 'post-install - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Use the right `expect' binary. - (let ((out (assoc-ref outputs "out")) - (expect (assoc-ref inputs "expect"))) - (substitute* (string-append out "/bin/runtest") - (("^mypath.*$" all) - (string-append all - "export PATH=" - expect "/bin:$PATH\n"))) - #t)))))) - (home-page - "https://www.gnu.org/software/dejagnu/") + ;; The test-suite needs to have a non-empty stdin: + ;; <http://lists.gnu.org/archive/html/bug-dejagnu/2003-06/msg00002.html>. + (unless (zero? (system "make check < /dev/zero")) + (error "make check failed"))) + (display "test suite cannot be run, skipping\n"))))) + (add-after 'install 'post-install + (lambda* (#:key inputs outputs #:allow-other-keys) + ;; Use the right `expect' binary. + (let ((expect (search-input-file inputs "/bin/expect"))) + (substitute* (string-append #$output "/bin/runtest") + (("^mypath.*$" all) + (string-append all + "export PATH=" + (dirname expect) ":$PATH\n"))))))))) + (home-page "https://www.gnu.org/software/dejagnu/") (synopsis "GNU software testing framework") (description "DejaGnu is a framework for testing software. In effect, it serves as diff --git a/gnu/packages/diffoscope.scm b/gnu/packages/diffoscope.scm index c03f17cae8..ee4eec35fc 100644 --- a/gnu/packages/diffoscope.scm +++ b/gnu/packages/diffoscope.scm @@ -35,7 +35,6 @@ #:use-module (gnu packages compression) #:use-module (gnu packages cpio) #:use-module (gnu packages dbm) - #:use-module (gnu packages file) ;for 'file-next' #:use-module (gnu packages gettext) #:use-module (gnu packages ghostscript) #:use-module (gnu packages gnome) @@ -171,11 +170,7 @@ docx2txt dtc e2fsprogs - ffmpeg - - ;; XXX: Must be the same version as python-magic uses; - ;; remove when 'file' is updated. - file-next) + ffmpeg) (match (%current-system) ;; fpc is only available on x86 currently. diff --git a/gnu/packages/django.scm b/gnu/packages/django.scm index dc14cd775a..7ba2ca2a87 100644 --- a/gnu/packages/django.scm +++ b/gnu/packages/django.scm @@ -409,9 +409,7 @@ size and quality.") " and not test_urls_cache_is_cleared"))) (format #t "test suite not run~%"))))))) (native-inputs - (list python-django python-setuptools-scm - ;; For tests. - python-pytest-xdist-next)) + (list python-django python-setuptools-scm python-pytest-xdist)) (propagated-inputs (list python-pytest)) (home-page "https://pytest-django.readthedocs.org/") @@ -1233,7 +1231,7 @@ FileFields during tests.") (invoke "pip" "--no-cache-dir" "--no-input" "install" "--no-deps" "--prefix" #$output whl))))))) (native-inputs - (list openldap-2.6 python-wheel python-setuptools-scm python-toml + (list openldap python-wheel python-setuptools-scm python-toml ;; These can be removed after <https://bugs.gnu.org/46848>. python-pypa-build python-pip)) diff --git a/gnu/packages/djvu.scm b/gnu/packages/djvu.scm index 10974c93cb..00066f82ea 100644 --- a/gnu/packages/djvu.scm +++ b/gnu/packages/djvu.scm @@ -151,7 +151,6 @@ a continuous layout.") (sha256 (base32 "0c595yziz81c9izf9s5sskd00qmgz2n1hp2vdcgg0dx81g3xfidb")))) (build-system gnu-build-system) - (arguments (list #:tests? #f)) ;requires Python 2 (native-inputs (list gettext-minimal pkg-config)) (inputs (list djvulibre @@ -160,6 +159,20 @@ a continuous layout.") poppler poppler-data `(,util-linux "lib"))) ;for libuuid + (arguments + `(#:test-target "test" + #:tests? #f ;requires Python 2 + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-tests + (lambda _ + (substitute* "tests/test-xmp-broken.py" + ;; Error message changed in recent versions of XML parser + (("XML parsing failure") + "Error in XMLValidator")))) + (add-before 'check 'set-home-for-tests + (lambda _ + (setenv "HOME" "/tmp")))))) (synopsis "PDF to DjVu converter") (description "@code{pdf2djvu} creates DjVu files from PDF files. diff --git a/gnu/packages/dlang.scm b/gnu/packages/dlang.scm index 729d6015ae..fad3e683da 100644 --- a/gnu/packages/dlang.scm +++ b/gnu/packages/dlang.scm @@ -137,7 +137,7 @@ to a minimal test case.") (dirname (search-input-file inputs "/bin/gdc")) "\";\n")))))))) (inputs - (list gdc-10 perl)) + (list gdc-11 perl)) (home-page "https://github.com/D-Programming-GDC/gdmd") (synopsis "DMD-like wrapper for GDC") (description "This package provides a DMD-like wrapper for the @@ -190,8 +190,8 @@ to a minimal test case.") ("tzdata" ,tzdata) ("zlib" ,zlib))) (native-inputs - `(("lld-wrapper" ,(make-lld-wrapper lld-11 #:lld-as-ld? #t)) - ("llvm" ,llvm-11) + `(("lld-wrapper" ,(make-lld-wrapper lld-14 #:lld-as-ld? #t)) + ("llvm" ,llvm-14) ("ldc" ,gdmd) ("ninja" ,ninja) ("python-wrapper" ,python-wrapper) @@ -357,7 +357,7 @@ integration tests...\n") (append (delete "llvm" (alist-replace "ldc" (list ldc-bootstrap) (package-native-inputs ldc-bootstrap))) - `(("clang" ,clang-11) ;propagates llvm and clang-runtime + `(("clang" ,clang-14) ;propagates llvm and clang-runtime ("python-lit" ,python-lit)))))) (define-public dub diff --git a/gnu/packages/docbook.scm b/gnu/packages/docbook.scm index 8d4892b93b..070b957339 100644 --- a/gnu/packages/docbook.scm +++ b/gnu/packages/docbook.scm @@ -4,10 +4,11 @@ ;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020 Marius Bakke <marius@gnu.org> -;;; Copyright © 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 Andrew Whatson <whatson@gmail.com> +;;; Copyright © 2023 Bruno Victal <mirai@makinata.eu> ;;; ;;; This file is part of GNU Guix. ;;; @@ -38,6 +39,7 @@ #:use-module (gnu packages web-browsers) #:use-module (gnu packages xml) #:use-module (guix gexp) + #:use-module (guix utils) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) @@ -48,39 +50,45 @@ #:use-module (guix build-system trivial) #:use-module (guix build-system python)) -(define-public docbook-xml-5 +(define-public docbook-xml (package (name "docbook-xml") - (version "5.0.1") + (version "5.1") (source (origin (method url-fetch) (uri (string-append "https://docbook.org/xml/" version - "/docbook-" version ".zip")) + "/docbook-v" version "-os.zip")) (sha256 (base32 - "1iz3hq1lqgnshvlz4j9gvh4jy1ml74qf90vqf2ikbq0h4i2xzybs")))) - (build-system trivial-build-system) + "0zqy9prj9wam9dn7v3mgr7ld1axqxdhgrmv06dviwg00ahv43wxk")))) + (build-system copy-build-system) (arguments - `(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let* ((unzip - (string-append (assoc-ref %build-inputs "unzip") - "/bin/unzip")) - (source (assoc-ref %build-inputs "source")) - (out (assoc-ref %outputs "out")) - (dtd (string-append out "/xml/dtd/docbook"))) - (invoke unzip source) - (mkdir-p dtd) - (copy-recursively (string-append "docbook-" ,version) dtd) - (with-directory-excursion dtd - (substitute* (string-append out "/xml/dtd/docbook/catalog.xml") - (("uri=\"") - (string-append - "uri=\"file://" dtd "/"))) - #t))))) - (native-inputs (list unzip)) + (list + #:modules '((guix build copy-build-system) + (guix build utils) + (srfi srfi-26)) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-permissions + (lambda _ + ;; XXX: These files do not need 0755 permission. + (for-each (cut chmod <> #o644) (find-files ".")))) + (add-before 'install 'patch-catalog-xml + (lambda* (#:key inputs #:allow-other-keys) + (let ((xsltproc (search-input-file inputs "/bin/xsltproc")) + (dtd-path (string-append #$output "/xml/dtd/docbook"))) + (invoke xsltproc "--nonet" "--noout" + "--stringparam" "prefix" dtd-path + "--output" "catalog.xml.new" + #$(local-file + (search-auxiliary-file "xml/patch-catalog-xml.xsl")) + "catalog.xml") + (rename-file "catalog.xml.new" "catalog.xml")))) + (replace 'install + (lambda _ + (let ((dtd-path (string-append #$output "/xml/dtd/docbook"))) + (copy-recursively "." dtd-path))))))) + (native-inputs (list libxslt unzip)) (home-page "https://docbook.org") (synopsis "DocBook XML DTDs for document authoring") (description @@ -89,43 +97,23 @@ suited to books and papers about computer hardware and software (though it is by no means limited to these applications.) This package provides XML DTDs.") (license (license:x11-style "" "See file headers.")))) -(define-public docbook-xml +(define-public docbook-xml-4.5 (package - (inherit docbook-xml-5) - (name "docbook-xml") + (inherit docbook-xml) (version "4.5") (source (origin - (method url-fetch) + (method url-fetch/zipbomb) (uri (string-append "https://docbook.org/xml/" version "/docbook-xml-" version ".zip")) (sha256 (base32 - "1d671lcjckjri28xfbf6dq7y3xnkppa910w1jin8rjc35dx06kjf")))) - (arguments - '(#:builder (begin - (use-modules (guix build utils)) - - (let* ((unzip - (string-append (assoc-ref %build-inputs "unzip") - "/bin/unzip")) - (source (assoc-ref %build-inputs "source")) - (out (assoc-ref %outputs "out")) - (dtd (string-append out "/xml/dtd/docbook"))) - (mkdir-p dtd) - (with-directory-excursion dtd - (invoke unzip source)) - (substitute* (string-append out "/xml/dtd/docbook/catalog.xml") - (("uri=\"") - (string-append - "uri=\"file://" dtd "/"))) - #t)) - #:modules ((guix build utils)))))) + "1d671lcjckjri28xfbf6dq7y3xnkppa910w1jin8rjc35dx06kjf")))))) (define-public docbook-xml-4.4 (package (inherit docbook-xml) (version "4.4") (source (origin - (method url-fetch) + (method url-fetch/zipbomb) (uri (string-append "https://docbook.org/xml/" version "/docbook-xml-" version ".zip")) (sha256 @@ -136,7 +124,7 @@ by no means limited to these applications.) This package provides XML DTDs.") (package (inherit docbook-xml) (version "4.3") (source (origin - (method url-fetch) + (method url-fetch/zipbomb) (uri (string-append "https://docbook.org/xml/" version "/docbook-xml-" version ".zip")) (sha256 @@ -147,7 +135,7 @@ by no means limited to these applications.) This package provides XML DTDs.") (package (inherit docbook-xml) (version "4.2") (source (origin - (method url-fetch) + (method url-fetch/zipbomb) (uri (string-append "https://docbook.org/xml/" version "/docbook-xml-" version ".zip")) (sha256 @@ -155,93 +143,60 @@ by no means limited to these applications.) This package provides XML DTDs.") "18hgwvmywh6a5jh38szjmg3hg2r4v5lb6r3ydc3rd8cp9wg61i5c")))))) (define-public docbook-xml-4.1.2 - (package (inherit docbook-xml) + (package + (inherit docbook-xml) (version "4.1.2") (source (origin - (method url-fetch) + (method url-fetch/zipbomb) (uri (string-append "https://docbook.org/xml/" version "/docbkx412.zip")) (sha256 (base32 "0wkp5rvnqj0ghxia0558mnn4c7s3n501j99q2isp3sp0ci069w1h")))) (arguments - '(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((source (assoc-ref %build-inputs "source")) - (unzip (string-append (assoc-ref %build-inputs "unzip") - "/bin/unzip")) - (dtd (string-append (assoc-ref %outputs "out") - "/xml/dtd/docbook"))) - (mkdir-p dtd) - (invoke unzip source "-d" dtd))))))) + (substitute-keyword-arguments (package-arguments docbook-xml) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'copy-catalog-file + ;; docbook-xml-4.1.2 is unique in the fact that it doesn't come + ;; with a catalog.xml file, requiring it to be generated by hand + ;; from the docbook.cat SGML catalog. We could automatically + ;; generate it here at the cost of enlarging the package + ;; definition with a rudimentary (PEG) parser for the SGML + ;; catalog but this is overkill since this file is unlikely to + ;; change, therefore we ship a pre-generated catalog.xml. + (lambda _ + (copy-file + #$(local-file + (search-auxiliary-file + "xml/docbook-xml/catalog-4.1.2.xml")) + "catalog.xml"))) + (add-after 'patch-catalog-xml 'add-rewrite-entries + (lambda* (#:key inputs #:allow-other-keys) + (let ((xmlcatalog (search-input-file inputs "/bin/xmlcatalog")) + (dtd-path (string-append #$output "/xml/dtd/docbook"))) + (for-each + (lambda (type) + (invoke xmlcatalog "--noout" + "--add" type + "http://www.oasis-open.org/docbook/xml/4.1.2/" + (string-append "file://" dtd-path "/") + "catalog.xml")) + (list "rewriteSystem" "rewriteURI"))))))))) + (native-inputs + (modify-inputs (package-native-inputs docbook-xml) + (prepend libxml2))))) +;;; There's an issue in docbook-xsl 1.79.2 that causes manpages to be +;;; generated incorrectly and embed raw nroff syntax such as '.PP' when there +;;; is a namespace/non-namespace mismatch between the sources and the +;;; stylesheets used (see: +;;; https://github.com/docbook/xslt10-stylesheets/issues/109). (define-public docbook-xsl - (package - (name "docbook-xsl") - (version "1.79.2") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/docbook/xslt10-stylesheets" - "/releases/download/release%2F" version - "/docbook-xsl-" version ".tar.bz2")) - (patches (search-patches "docbook-xsl-support-old-url.patch" - "docbook-xsl-nonrecursive-string-subst.patch")) - (sha256 - (base32 - "0wd33z41kdsybyx3ay21w6bdlmgpd9kyn3mr5y520lsf8km28r9i")) - (modules '((guix build utils))) - (snippet - '(begin - (for-each delete-file (find-files "." "\\.jar$")) - #t)))) - (build-system trivial-build-system) - (arguments - `(#:builder (begin - (use-modules (guix build utils)) - - (define name-version - (string-append ,name "-" ,version)) - - (let* ((bzip2 (assoc-ref %build-inputs "bzip2")) - (xz (assoc-ref %build-inputs "xz")) - (tar (assoc-ref %build-inputs "tar")) - (source (assoc-ref %build-inputs "source")) - (out (assoc-ref %outputs "out")) - (xsl (string-append out "/xml/xsl"))) - (setenv "PATH" (string-append bzip2 "/bin" ":" xz "/bin")) - (invoke (string-append tar "/bin/tar") "xvf" source) - - (mkdir-p xsl) - (copy-recursively name-version - (string-append xsl "/" name-version)) - - (substitute* (string-append xsl "/" name-version "/catalog.xml") - (("rewritePrefix=\"./") - (string-append "rewritePrefix=\"file://" xsl "/" - name-version "/"))) - #t)) - #:modules ((guix build utils)))) - (native-inputs (list bzip2 xz ;needed for repacked tarballs - tar)) - (home-page "https://docbook.org") - (synopsis "DocBook XSL style sheets for document authoring") - (description - "This package provides XSL style sheets for DocBook.") - (license (license:x11-style "" "See 'COPYING' file.")))) - -;;; TODO: Make this the default docbook-xsl on core-updates. There's an issue -;;; in docbook-xsl 1.79.2 that causes manpages to be generated incorrectly and -;;; embed raw nroff syntax such as '.PP' when there is a -;;; namespace/non-namespace mismatch between the sources and the stylesheets -;;; used (see: https://github.com/docbook/xslt10-stylesheets/issues/109). -(define-public docbook-xsl-next (let ((commit "fe16c90013b64e316c3e21ef92d1e8813c10f88c") (revision "0") - (base-version (package-version docbook-xsl))) + (base-version "1.79.2")) (package - (inherit docbook-xsl) (name "docbook-xsl") (version (git-version base-version revision commit)) (source (origin @@ -323,7 +278,12 @@ by no means limited to these applications.) This package provides XML DTDs.") (native-inputs (list libxml2 libxslt perl - perl-xml-xpath))))) + perl-xml-xpath)) + (home-page "https://docbook.org") + (synopsis "DocBook XSL style sheets for document authoring") + (description + "This package provides XSL style sheets for DocBook.") + (license (license:x11-style "" "See 'COPYING' file."))))) (define-public docbook-xsl-1.79.1 (package @@ -581,29 +541,25 @@ the in DocBook SGML DTDs.") texlive-latex-changebar texlive-latex-colortbl texlive-latex-fancybox - texlive-latex-fancyhdr - texlive-latex-fancyvrb + texlive-fancyhdr + texlive-fancyvrb texlive-latex-float texlive-latex-footmisc texlive-hyperref texlive-latex-jknapltx - - ;; TODO: Use non-deprecated name on - ;; next rebuild cycle. - texlive-latex-listings - + texlive-listings texlive-latex-multirow texlive-latex-overpic - texlive-latex-pdfpages - texlive-latex-refcount - texlive-latex-subfigure - texlive-latex-titlesec + texlive-pdfpages + texlive-refcount + texlive-subfigure + texlive-titlesec texlive-wasysym texlive-fonts-rsfs texlive-stmaryrd - texlive-generic-iftex))) + texlive-iftex))) ("imagemagick" ,imagemagick) ;for convert ("inkscape" ,inkscape/stable) ;for svg conversion ("docbook" ,docbook-xml) @@ -751,73 +707,72 @@ Detect the differences in markup between two SGML files. "0ifwzk99rzjws0ixzimbvs83x6cxqk1xzmg84wa1p7bs6rypaxs0")))) (build-system gnu-build-system) (inputs - `(("bash-minimal" ,bash-minimal) - ("docbook-xml" ,docbook-xml) - ("perl" ,perl) - ("perl-xml-namespacesupport" ,perl-xml-namespacesupport) - ("perl-xml-parser" ,perl-xml-parser) - ("perl-xml-sax" ,perl-xml-sax) - ("perl-xml-sax-base" ,perl-xml-sax-base) - ("texinfo" ,texinfo) - ("xsltproc" ,libxslt))) + (list bash-minimal + docbook-xml-4.5 + perl + perl-xml-namespacesupport + perl-xml-parser + perl-xml-sax + perl-xml-sax-base + texinfo + libxslt)) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-sources - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Fix failed substitution in config.pl - (substitute* "perl/config.pl" - (("\\$\\{prefix\\}") - (assoc-ref outputs "out"))) - ;; Fix a failing test (maybe it worked with old texinfo?) - (substitute* "test/complete-manuals/at1.xml" - (("<bridgehead>") - "<bridgehead renderas=\"sect2\">")) - ;; Patch all the tests use DocBook 4.5 - (substitute* (find-files "test" "\\.xml$") - (("\"-//OASIS//DTD DocBook XML V4\\..+//EN\"") - "\"-//OASIS//DTD DocBook XML V4.5//EN\"") - (("\"http://www\\.oasis-open\\.org/docbook/xml/4\\..+/docbookx.dtd\"") - "\"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd\"")) - ;; Set XML catalogs for tests to pass - (setenv "XML_CATALOG_FILES" - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/catalog.xml")))) - (add-after 'install 'wrap-programs - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (programs - (map (lambda (p) - (string-append out "/bin/" p)) - '("db2x_manxml" "db2x_texixml" "db2x_xsltproc" - "docbook2man" "docbook2texi"))) - (perl5lib - (map (lambda (i) - (string-append (assoc-ref inputs i) - "/lib/perl5/site_perl")) - '("perl-xml-namespacesupport" - "perl-xml-parser" - "perl-xml-sax" - "perl-xml-sax-base"))) - (xml-catalog-files - (list (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/catalog.xml")))) - (map (lambda (program) - (wrap-program program - `("PERL5LIB" ":" prefix - ,perl5lib) - `("XML_CATALOG_FILES" " " prefix - ,xml-catalog-files))) - programs)))) - (add-after 'install 'create-symlinks - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - ;; Create db2x_* symlinks to satisfy some configure scripts - ;; which use these names to differentiate from an older - ;; docbook2man script provided by docbook-utils. - (map (lambda (prog) - (symlink prog (string-append out "/bin/db2x_" prog))) - '("docbook2man" "docbook2texi")))))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'configure 'patch-sources + (lambda* (#:key inputs #:allow-other-keys) + ;; Fix failed substitution in config.pl + (substitute* "perl/config.pl" + (("\\$\\{prefix\\}") + #$output)) + ;; Fix a failing test (maybe it worked with old texinfo?) + (substitute* "test/complete-manuals/at1.xml" + (("<bridgehead>") + "<bridgehead renderas=\"sect2\">")) + ;; Patch all the tests use DocBook 4.5 + (substitute* (find-files "test" "\\.xml$") + (("\"-//OASIS//DTD DocBook XML V4\\..+//EN\"") + "\"-//OASIS//DTD DocBook XML V4.5//EN\"") + (("\"http://www\\.oasis-open\\.org/docbook/xml/4\\..+/docbookx.dtd\"") + "\"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd\"")) + ;; Set XML catalogs for tests to pass + (setenv "XML_CATALOG_FILES" + (string-append (assoc-ref inputs "docbook-xml") + "/xml/dtd/docbook/catalog.xml")))) + (add-after 'install 'wrap-programs + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((programs + (map (lambda (p) + (search-input-file outputs + (string-append "bin/" p))) + '("db2x_manxml" "db2x_texixml" "db2x_xsltproc" + "docbook2man" "docbook2texi"))) + (perl5lib + '#$(map (lambda (i) + (file-append (this-package-input i) + "/lib/perl5/site_perl")) + '("perl-xml-namespacesupport" + "perl-xml-parser" + "perl-xml-sax" + "perl-xml-sax-base"))) + (xml-catalog-files + (list (search-input-file + inputs "xml/dtd/docbook/catalog.xml")))) + (map (lambda (program) + (wrap-program program + `("PERL5LIB" ":" prefix ,perl5lib) + `("XML_CATALOG_FILES" " " prefix ,xml-catalog-files))) + programs)))) + (add-after 'install 'create-symlinks + (lambda _ + ;; Create db2x_* symlinks to satisfy some configure scripts + ;; which use these names to differentiate from an older + ;; docbook2man script provided by docbook-utils. + (map (lambda (prog) + (symlink prog (string-append #$output + "/bin/db2x_" prog))) + '("docbook2man" "docbook2texi"))))))) (home-page "https://docbook2x.sourceforge.net") (synopsis "Convert DocBook to man page and Texinfo format") (description diff --git a/gnu/packages/documentation.scm b/gnu/packages/documentation.scm index a372e1a6ca..bbaa01e392 100644 --- a/gnu/packages/documentation.scm +++ b/gnu/packages/documentation.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2020, 2021 Michael Rohleder <mike@rohleder.de> -;;; Copyright © 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2021, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2022 Maxim Cournoyer <maxim.counoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. @@ -140,8 +140,7 @@ pages in HTML.") (("XMLLINT = 'xmllint'") (string-append "XMLLINT = '" xmllint "'")) (("XSLTPROC = 'xsltproc'") - (string-append "XSLTPROC = '" xsltproc "'"))) - #t))) + (string-append "XSLTPROC = '" xsltproc "'")))))) ;; Make asciidoc use the local docbook-xsl package instead of fetching ;; it from the internet at run-time. (add-before 'install 'make-local-docbook-xsl @@ -153,20 +152,16 @@ release/xsl/current") "xsl:import href=\"" (string-append (assoc-ref inputs "docbook-xsl") "/xml/xsl/docbook-xsl-" - ,(package-version docbook-xsl))))) - #t)) + ,(package-version docbook-xsl))))))) ;; Do the same for docbook-xml. (add-before 'install 'make-local-docbook-xml (lambda* (#:key inputs #:allow-other-keys) (substitute* "docbook45.conf" (("http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd") (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/docbookx.dtd"))) - #t))))) - (native-inputs - (list autoconf)) - (inputs - (list python docbook-xml docbook-xsl libxml2 libxslt)) + "/xml/dtd/docbook/docbookx.dtd")))))))) + (native-inputs (list autoconf)) + (inputs (list python docbook-xml-4.5 docbook-xsl libxml2 libxslt)) (home-page "https://asciidoc.org/") (synopsis "Text-based document generation system") (description @@ -185,48 +180,51 @@ markup) can be customized and extended by the user.") (define-public doxygen (package (name "doxygen") - (version "1.9.1") + (version "1.9.5") (home-page "https://www.doxygen.nl/") (source (origin - (method url-fetch) - (uri (list (string-append home-page "files/doxygen-" - version ".src.tar.gz") - (string-append "mirror://sourceforge/doxygen/rel-" - version "/doxygen-" version - ".src.tar.gz"))) - (sha256 - (base32 - "1lcif1qi20gf04qyjrx7x367669g17vz2ilgi4cmamp1whdsxbk7")))) + (method url-fetch) + (uri (list (string-append home-page "files/doxygen-" + version ".src.tar.gz") + (string-append "mirror://sourceforge/doxygen/rel-" + version "/doxygen-" version + ".src.tar.gz"))) + (sha256 + (base32 + "1v1f9cp5lyymg7xmw0ldnzi7ql8agbaqam1xdyljk0lrbnrm9d2m")))) (build-system cmake-build-system) (native-inputs - (list bison flex libxml2 ;provides xmllint for the tests - python)) ;for creating the documentation + (list bison + flex + libxml2 ;provides xmllint for the tests + python)) ;for creating the documentation (inputs - `(("bash" ,bash-minimal))) + (list bash-minimal)) (arguments ;; Force cmake to use iconv header from cross-libc instead of the one ;; from native libc. - `(,@(if (%current-target-system) - '(#:configure-flags - (list (string-append "-DICONV_INCLUDE_DIR=" - (assoc-ref %build-inputs "cross-libc") - "/include"))) - '()) - #:test-target "tests" - #:phases (modify-phases %standard-phases - (add-after 'unpack 'disable-bibtex-test - (lambda _ - ;; Disable test that requires bibtex to avoid a - ;; circular dependency. - (for-each delete-file-recursively - '("testing/012" "testing/012_cite.dox")))) - (add-before 'configure 'patch-sh - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "src/portable.cpp" - (("/bin/sh") - (string-append - (assoc-ref inputs "bash") "/bin/sh"))) - #t))))) + (list + #:configure-flags + (if (%current-target-system) + #~(list (string-append "-DICONV_INCLUDE_DIR=" + (assoc-ref %build-inputs "cross-libc") + "/include")) + #~'()) + #:test-target "tests" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-bibtex-test + (lambda _ + ;; Disable test that requires bibtex to avoid a + ;; circular dependency. + (for-each delete-file-recursively + '("testing/012" "testing/012_cite.dox")))) + (add-before 'configure 'patch-sh + (lambda* (#:key inputs #:allow-other-keys) + (let ((/bin/sh (search-input-file inputs "/bin/sh"))) + (substitute* "src/portable.cpp" + (("/bin/sh") + /bin/sh)))))))) (synopsis "Generate documentation from annotated sources") (description "Doxygen is the de facto standard tool for generating documentation from annotated C++ sources, but it also supports other popular diff --git a/gnu/packages/ebook.scm b/gnu/packages/ebook.scm index 8e6f2bbc09..993ebb8fc1 100644 --- a/gnu/packages/ebook.scm +++ b/gnu/packages/ebook.scm @@ -125,7 +125,7 @@ with Microsoft Compiled HTML (CHM) files") (define-public calibre (package (name "calibre") - (version "5.36.0") + (version "5.44.0") (source (origin (method url-fetch) @@ -134,7 +134,7 @@ with Microsoft Compiled HTML (CHM) files") version ".tar.xz")) (sha256 (base32 - "1c036qmn7lxq0899c2xzzs6whz7z0557frnfqisbvfxa13b2sadk")) + "1v48mzmr9z9rs6s7r8fgaqs6vnxnin1hyzwmwmal78inzpma7ykg")) (modules '((guix build utils))) (snippet '(begin @@ -245,9 +245,8 @@ tags = [\"WS_X11\"]") (("\\[tool.sip.project\\]") (string-append "[tool.sip.project] sip-include-dirs = [\"" - #$(this-package-input - "python-pyqt") - "/share/sip\"]"))) + #$(this-package-input "python-pyqt") + "/lib/python3.10/site-packages/PyQt5/bindings\"]"))) (substitute* "src/calibre/ebooks/pdf/pdftohtml.py" (("PDFTOHTML = 'pdftohtml'") (string-append "PDFTOHTML = \"" diff --git a/gnu/packages/ed.scm b/gnu/packages/ed.scm index a42ba40102..31c41fa5ef 100644 --- a/gnu/packages/ed.scm +++ b/gnu/packages/ed.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org> ;;; Copyright © 2013, 2014 Ludovic Courtès <ludo@gnu.org> -;;; Copyright © 2016, 2019 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2019, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; ;;; This file is part of GNU Guix. ;;; @@ -22,31 +22,31 @@ #:use-module (guix licenses) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix utils) #:use-module (guix build-system gnu) #:use-module (gnu packages compression)) (define-public ed (package (name "ed") - (version "1.17") + (version "1.18") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/ed/ed-" version ".tar.lz")) (sha256 (base32 - "0m2yrkfjjraakxr98nsiakqrn351h99n706x9asgmdi57j43kpki")))) + "0krb8rsb0cd8mgz0c5pqgnjbbrj7zjl7mf9099r8gi80k2nyza5c")))) (build-system gnu-build-system) (native-inputs (list lzip)) (arguments - '(#:configure-flags '("CC=gcc") + `(#:configure-flags (list ,(string-append "CC=" (cc-for-target))) #:phases (modify-phases %standard-phases (add-before 'patch-source-shebangs 'patch-test-suite (lambda _ (substitute* "testsuite/check.sh" - (("/bin/sh") (which "sh"))) - #t))))) + (("/bin/sh") (which "sh")))))))) (home-page "https://www.gnu.org/software/ed/") (synopsis "Line-oriented text editor") (description diff --git a/gnu/packages/elf.scm b/gnu/packages/elf.scm index cb9393eab0..d188099812 100644 --- a/gnu/packages/elf.scm +++ b/gnu/packages/elf.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr> -;;; Copyright © 2017, 2018, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018, 2020 Marius Bakke <mbakke@fastmail.com> @@ -50,14 +50,14 @@ (define-public elfutils (package (name "elfutils") - (version "0.183") + (version "0.187") (source (origin (method url-fetch) (uri (string-append "https://sourceware.org/elfutils/ftp/" version "/elfutils-" version ".tar.bz2")) (sha256 (base32 - "1igjfia9x8h6fmh9nbl8mpz0i24my5iixrji99qmi79hilh7qqy3")) + "1j2lsicm3dkj5n6spszr9qy5rqm48bqimmz03x6hry8hwvxhs2z7")) (patches (search-patches "elfutils-tests-ptrace.patch")))) (build-system gnu-build-system) @@ -103,13 +103,19 @@ ,@(if (target-riscv64?) `((add-after 'unpack 'disable-failing-riscv64-test (lambda _ - ;; dwfl_thread_getframes: No DWARF information found (substitute* "tests/Makefile.in" - (("run-backtrace-dwarf.sh") ""))))) + ;; dwfl_thread_getframes: No DWARF information found + (("run-backtrace-dwarf.sh") "") + ;; These tests have several errors: + ;; unknown program header entry type 0x70000003 + ;; '.riscv.attributes' has unsupported type 1879048195 + (("run-reverse-sections-self.sh") "") + (("run-strip-strmerge.sh") "") + (("run-elflint-self.sh") ""))))) '())))) (native-inputs (list m4)) - (inputs (list zlib)) + (inputs (list xz zlib)) (home-page "https://sourceware.org/elfutils/") (synopsis "Collection of utilities and libraries to handle ELF files and DWARF data") diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index b9bece1365..96b72d8e4d 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014 Taylan Ulrich Bayirli/Kammer <taylanbayirli@gmail.com> -;;; Copyright © 2013-2022 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2013-2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Alex Kost <alezost@gmail.com> ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch> @@ -17850,7 +17850,9 @@ conflicts.") version ".tar")) (sha256 (base32 - "1fp5mzl63sh0h3ws4l5p4qgvi7ny8a3fj6k4dhqa98xgw2bx03v7")))) + "1fp5mzl63sh0h3ws4l5p4qgvi7ny8a3fj6k4dhqa98xgw2bx03v7")) + (patches + (search-patches "emacs-xelb-ignore-length-element.patch")))) (build-system emacs-build-system) ;; The following functions and variables needed by emacs-xelb are ;; not included in emacs-minimal: diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index c3be119ab5..8da7279147 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -346,7 +346,7 @@ libpng zlib (if (target-x86-64?) - librsvg-bootstrap + librsvg librsvg-2.40) libxpm libxml2 diff --git a/gnu/packages/embedded.scm b/gnu/packages/embedded.scm index 8d854c7e6d..f2d0def2f2 100644 --- a/gnu/packages/embedded.scm +++ b/gnu/packages/embedded.scm @@ -62,6 +62,7 @@ #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm index 13105ca8fa..44092e77c5 100644 --- a/gnu/packages/engineering.scm +++ b/gnu/packages/engineering.scm @@ -135,6 +135,7 @@ #:use-module (gnu packages protobuf) #:use-module (gnu packages pulseaudio) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-check) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-science) @@ -1288,7 +1289,7 @@ WiFi signal strength maps. It visualizes them using a Voronoi diagram.") (define-public volk (package (name "volk") - (version "2.4.1") + (version "3.0.0") (source (origin (method git-fetch) @@ -1298,19 +1299,26 @@ WiFi signal strength maps. It visualizes them using a Voronoi diagram.") (recursive? #t))) ; for cpu_features git submodule (file-name (git-file-name name version)) (sha256 - (base32 "1mkqiw0i2fbbsk46zvk8yv5swl7ifhq6y1dlfphq8dsmkvxckqby")))) + (base32 "0a59lnjh6hx2bmyn04f8r0ymwss1ss1iih2jwrl9jblkxsw0i3lh")))) (build-system cmake-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'disable-check-lgpl-test + ;; Disable the failing check-lgpl test that is supposed to be run + ;; only by upstream developers to check the authors and licenses + ;; of contributions in the git history. + (lambda _ + (substitute* "scripts/licensing/count_contrib.sh" + (("#!/bin/bash" all) + (string-append all "\nexit 0"))))) (add-after 'install 'remove-static-libraries ;; Remove libcpu_features.a (and any others that might appear). (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (lib (string-append out "/lib"))) (for-each delete-file (find-files lib "\\.a$" - #:fail-on-error? #t)) - #t))) + #:fail-on-error? #t))))) (add-after 'install 'wrap-pythonpath (lambda* (#:key inputs outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -1326,8 +1334,7 @@ WiFi signal strength maps. It visualizes them using a Voronoi diagram.") (wrap-program file `("GUIX_PYTHONPATH" ":" prefix (,path)) `("PATH" ":" prefix - (,(string-append python "/bin:"))))) - #t))))) + (,(string-append python "/bin:")))))))))) (inputs `(("boost" ,boost) ("python" ,python-wrapper) @@ -1339,7 +1346,8 @@ WiFi signal strength maps. It visualizes them using a Voronoi diagram.") with machine-specific optimizations for mathematical functions. It also provides a machine-independent interface to select the best such procedures to use on a given system.") - (license license:gpl3+))) + (license (list license:asl2.0 ; cpu_features + license:lgpl3+)))) (define-public libredwg (package @@ -2456,7 +2464,7 @@ specification can be downloaded at @url{http://3mf.io/specification/}.") (substitute* "pyvisa/shell.py" (("from .thirdparty import prettytable") "import prettytable"))))))) - (native-inputs (list python-pytest-7.1)) + (native-inputs (list python-pytest)) (propagated-inputs (list python-dataclasses python-prettytable python-typing-extensions)) (home-page "https://pyvisa.readthedocs.io/en/latest/") @@ -2493,7 +2501,7 @@ measurement devices and test equipment via GPIB, RS232, Ethernet or USB.") python-flake8 python-nbval python-networkx - python-pytest-7.1 + python-pytest python-pytest-cov python-pyvisa)) (home-page "https://scikit-rf.org/") @@ -3446,6 +3454,7 @@ perform various useful functions such as: ("gmp" ,gmp) ("mesa" ,mesa) ("mpfr" ,mpfr) + ("tbb" ,tbb) ("tinyxml2" ,tinyxml2) ;; When updating this package, update commit fields below according to ;; the hashes listed in "cmake/LibiglDownloadExternal.cmake". @@ -3499,7 +3508,7 @@ visualization, matrix manipulation.") (define-public prusa-slicer (package (name "prusa-slicer") - (version "2.5.0") + (version "2.5.2") (source (origin (method git-fetch) @@ -3508,7 +3517,10 @@ visualization, matrix manipulation.") (url "https://github.com/prusa3d/PrusaSlicer") (commit (string-append "version_" version)))) (file-name (git-file-name name version)) - (sha256 (base32 "17ic92ww2ny0frxyv7ajwdwa0fq70ygq562ik8sh94jx67jvxdy0")) + (sha256 (base32 "02qcrw3fa0d8ldbp73hp14l1qxbp3f4608j4csc07ny00ra42151")) + (patches (search-patches "prusa-slicer-boost-fixes.patch" + "prusa-slicer-fix-tests.patch" + "prusa-slicer-with-cereal-1.3.1.patch")) (modules '((guix build utils))) (snippet '(begin @@ -3544,7 +3556,7 @@ visualization, matrix manipulation.") (list pkg-config)) (inputs (list boost - cereal-1.3.0 + cereal cgal curl dbus diff --git a/gnu/packages/fabric-management.scm b/gnu/packages/fabric-management.scm index 3ab1a35d7c..b6b2e5176c 100644 --- a/gnu/packages/fabric-management.scm +++ b/gnu/packages/fabric-management.scm @@ -183,7 +183,7 @@ testing InfiniBand networks.") (define-public ucx (package (name "ucx") - (version "1.9.0") + (version "1.14.0") (source (origin (method git-fetch) (uri (git-reference @@ -193,7 +193,7 @@ testing InfiniBand networks.") (patches (search-patches "ucx-tcp-iface-ioctl.patch")) (sha256 (base32 - "0i0ji5ivzxjqh3ys1m517ghw3am7cw1hvf40ma7hsq3wznsyx5s1")))) + "0ki2r768wqm92qv06wxrh3kv2nl2yj4ds9fz0s0b5rr2ycjiw9ir")))) (build-system gnu-build-system) (arguments (list diff --git a/gnu/packages/file-systems.scm b/gnu/packages/file-systems.scm index d57d407d9c..f8959f208d 100644 --- a/gnu/packages/file-systems.scm +++ b/gnu/packages/file-systems.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2017 Gábor Boskovits <boskovits@gmail.com> ;;; Copyright © 2017, 2018, 2021 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2018 Leo Famulari <leo@famulari.name> -;;; Copyright © 2019-2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2019-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2020 Raghav Gururajan <raghavgururajan@disroot.org> ;;; Copyright © 2020 Morgan Smith <Morgan.J.Smith@outlook.com> ;;; Copyright © 2021 raid5atemyhomework <raid5atemyhomework@protonmail.com> @@ -1698,13 +1698,18 @@ compatible directories.") (define-public python-dropbox (package (name "python-dropbox") - (version "11.33.0") + (version "11.36.0") (source (origin (method url-fetch) (uri (pypi-uri "dropbox" version)) (sha256 - (base32 "1hd9gprvcr6h0p8fxhynf97qf6799whfpsmr73g619392598nqvw")))) + (base32 "0iwbi1qdw9qr7isa37yys582am59k80dqrwvm6s0afdwv0ifa343")) + (snippet + '(begin + (use-modules (guix build utils)) + (substitute* "setup.py" + (("pytest-runner == 5\\.2\\.0") "pytest-runner")))))) (build-system python-build-system) (arguments '(#:tests? #f)) ; Tests require a network connection. (native-inputs diff --git a/gnu/packages/file.scm b/gnu/packages/file.scm index 5e379d888b..3f870d84a1 100644 --- a/gnu/packages/file.scm +++ b/gnu/packages/file.scm @@ -1,9 +1,8 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016-2018, 2022, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2018 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de> ;;; Copyright © 2021 Marius Bakke <marius@gnu.org> ;;; @@ -32,14 +31,14 @@ (define-public file (package (name "file") - (version "5.39") + (version "5.44") (source (origin (method url-fetch) - (uri (string-append "ftp://ftp.astron.com/pub/file/file-" + (uri (string-append "http://ftp.astron.com/pub/file/file-" version ".tar.gz")) (sha256 (base32 - "1lgs2w2sgamzf27kz5h7pajz7v62554q21fbs11n4mfrfrm2hpgh")))) + "0fsz8wld09qai2qghphmwn69ni9m23razj3wip5k3j6vm3xwfl9p")))) (build-system gnu-build-system) ;; When cross-compiling, this package depends upon a native install of @@ -47,9 +46,6 @@ (native-inputs (if (%current-target-system) `(("self" ,this-package)) '())) - - (properties - `((release-monitoring-url . "http://ftp.astron.com/pub/file/"))) (synopsis "File type guesser") (description "The file command is a file type guesser, a command-line tool that tells @@ -58,15 +54,3 @@ extensions to tell you the type of a file, but looks at the actual contents of the file. This package provides the libmagic library.") (license bsd-2) (home-page "https://www.darwinsys.com/file/"))) - -(define-public file-next - (package - (inherit file) - (version "5.41") - (source (origin - (method url-fetch) - (uri (string-append "http://ftp.astron.com/pub/file/file-" - version ".tar.gz")) - (sha256 - (base32 - "0gv027jgdr0hdkw7m9ck0nwhq583f4aa7vnz4dzdbxv4ng3k5r8k")))))) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index e0f3fa8b21..31a139164b 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015, 2016 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2015, 2016, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com> ;;; Copyright © 2016, 2020 Hartmut Goebel <h.goebel@crazy-compilers.com> @@ -121,6 +121,7 @@ #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) #:use-module (gnu packages readline) + #:use-module (gnu packages security-token) #:use-module (gnu packages sphinx) #:use-module (gnu packages tex) #:use-module (gnu packages texinfo) @@ -1034,17 +1035,38 @@ settings.") of Bitcoin BIP-0039.") (license license:expat))) +(define-public python-u2flib-host + ;; The package is obsolete and superseded by python-fido2, but + ;; needed for python-ledgerblue@0.1.44. + (package + (name "python-u2flib-host") + (version "3.0.3") + (source (origin + (method url-fetch) + (uri (pypi-uri "python-u2flib-host" version)) + (sha256 + (base32 + "02pwafd5kyjpc310ys0pgnd0adff1laz18naxxwsfrllqafqnrxb")))) + (build-system python-build-system) + (propagated-inputs (list python-hidapi python-requests)) + (native-inputs (list python-cryptography)) + (home-page "https://github.com/Yubico/python-u2flib-host") + (synopsis "Python based U2F host library") + (description + "The package provides library functionality for communicating with a U2F device over USB.") + (license license:bsd-2))) + (define-public python-ledgerblue (package (name "python-ledgerblue") - (version "0.1.16") + (version "0.1.44") (source (origin (method url-fetch) (uri (pypi-uri "ledgerblue" version)) (sha256 (base32 - "010mghaqh1cmz3a0ifc3f40mmyplilwlw7kpha2mzyrrff46p9gb")))) + "0nbfa5i9ww7jsfc8cgy0r229pq2a1vj4xvn8mz0nxl7mx1wykqm4")))) (build-system python-build-system) (propagated-inputs (list python-ecpy @@ -1052,7 +1074,10 @@ of Bitcoin BIP-0039.") python-hidapi python-pillow python-protobuf - python-pycrypto)) + python-pycryptodomex + python-pyscard + python-u2flib-host + python-websocket-client)) (home-page "https://github.com/LedgerHQ/blue-loader-python") (synopsis "Python library to communicate with Ledger Blue/Nano S") (description "@code{ledgerblue} is a Python library to communicate with @@ -1339,13 +1364,13 @@ features: (define-public python-stdnum (package (name "python-stdnum") - (version "1.17") + (version "1.18") (source (origin (method url-fetch) (uri (pypi-uri "python-stdnum" version)) (sha256 - (base32 "0h4369b7gws5w5s2vhq590bk219y5k53zcmha2zwsb4i2dg2nkip")))) + (base32 "1h5y4qx75b6i2051ch8k0pcwkvhxzpaqd9mpsajkvqlsqkcn7ixw")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases diff --git a/gnu/packages/firmware.scm b/gnu/packages/firmware.scm index 956ece5d6d..0b7fff035a 100644 --- a/gnu/packages/firmware.scm +++ b/gnu/packages/firmware.scm @@ -486,7 +486,7 @@ provide OpenFirmware functionality on top of an already running system.") (native-inputs `(,@(if (and (not (string-prefix? "riscv64" (%current-system))) (string-prefix? "riscv64" arch)) - `(("cross-gcc" ,(cross-gcc "riscv64-linux-gnu" #:xgcc gcc-7)) + `(("cross-gcc" ,(cross-gcc "riscv64-linux-gnu")) ("cross-binutils" ,(cross-binutils "riscv64-linux-gnu"))) '()))) (arguments @@ -499,6 +499,11 @@ provide OpenFirmware functionality on top of an already running system.") `("CC=gcc")) "FW_PAYLOAD=n" "V=1") + ;; Direct __asm__ is used with fence.i instructions, which are not + ;; available in the generic riscv ISA. We need a micro-arch with + ;; support for it, and rv64g is the official ISA with support for + ;; fence.i. + #:configure-flags (list "-march=rv64g") #:phases (modify-phases %standard-phases (delete 'configure) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 6cd261f42e..3aad42493d 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -47,7 +47,7 @@ ;;; Copyright © 2022 Kitzman <kitzman@disroot.org> ;;; Copyright © 2021 Wamm K. D. <jaft.r@outlook.com> ;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com> -;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Liliana Marie Prikler <liliana.prikler@gmail.com> ;;; Copyright © 2022 Jose G Perez Taveras <josegpt27@gmail.com> ;;; Copyright © 2022 Hilton Chain <hako@ultrarare.space> @@ -840,7 +840,7 @@ OpenType variant of these fonts.") (replace 'install (assoc-ref font:%standard-phases 'install))))) (native-inputs - (list python-fonttools-next + (list python-fonttools python-glyphsets python-pcpp python-opentype-sanitizer @@ -2470,19 +2470,18 @@ It comes in seven weights and Roman, Italic and Oblique styles.") "1x5mhrpx24imh0r4l83mkaiszxgwi1q4ppyyvq63h3ddwk20cwdg")))) (build-system gnu-build-system) (native-inputs - `(("fontforge" ,fontforge) - ("harfbuzz" ,harfbuzz "bin") - ("python" ,python-minimal) - ("python-fonttools" ,python-fonttools) - ("python-brotli" ,python-brotli))) + (list fontforge + `(,harfbuzz "bin") + python-brotli + python-fonttools-minimal + python-minimal)) (arguments - `(#:make-flags (list "PY=python3" - (string-append "DESTDIR=" %output) - "fontpath=/share/fonts/truetype") - #:test-target "test" - #:phases - (modify-phases %standard-phases - (delete 'configure)))) + (list #:make-flags #~(list "PY=python3" + (string-append "DESTDIR=" #$output) + "fontpath=/share/fonts/truetype") + #:test-target "test" + #:phases #~(modify-phases %standard-phases + (delete 'configure)))) (home-page "https://gitlab.com/smc/meera-inimai") (synopsis "Meera Inimai Tamil font") (description "Meera Inimai is a Unicode font for the Tamil Script. Meera diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index fd1784a7e9..e7b5dc89a6 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -2,13 +2,13 @@ ;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2014, 2016 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2016 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2016, 2017, 2020, 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2017, 2020, 2022, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2017 Nikita <nikita@n0.is> ;;; Copyright © 2017, 2018, 2020–2022 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2018, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2018, 2019, 2020, 2021, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Roel Janssen <roel@gnu.org> ;;; Copyright © 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr> @@ -85,35 +85,43 @@ (define-public freetype (package - (name "freetype") - (version "2.10.4") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://savannah/freetype/freetype-" - version ".tar.xz")) - (sha256 - (base32 "112pyy215chg7f7fmp2l9374chhhpihbh8wgpj5nj6avj3c59a46")))) - (build-system gnu-build-system) - (arguments - ;; The use of "freetype-config" is deprecated, but other packages still - ;; depend on it. - `(#:configure-flags (list "--enable-freetype-config"))) - (native-inputs - (list pkg-config)) - (propagated-inputs - ;; These are all in the Requires.private field of freetype2.pc. - ;; XXX: add harfbuzz. - (list libpng zlib)) - (synopsis "Font rendering library") - (description - "Freetype is a library that can be used by applications to access the + (name "freetype") + (version "2.13.0") + (source + (origin + (method url-fetch) + (uri (string-append "mirror://savannah/freetype/freetype-" + version ".tar.xz")) + (sha256 + (base32 "0k32jaaz4pfhw34xwr6a38fncrpwr9fn5ij35m5w4dkn0jykmqjy")))) + (build-system gnu-build-system) + (arguments + ;; The use of "freetype-config" is deprecated, but other packages still + ;; depend on it. + (list + #:configure-flags #~(list "--enable-freetype-config") + #:disallowed-references (list pkg-config) + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'remove-reference-to-pkg-config + (lambda* (#:key outputs #:allow-other-keys) + (substitute* (search-input-file outputs "bin/freetype-config") + (("/([a-zA-Z0-9/\\._-]+)/bin/([a-zA-Z0-9_-]+)?pkg-config" + _ store target) + "pkg-config"))))))) + (native-inputs (list pkg-config)) + ;; XXX: Not adding harfbuzz here, as it would introduce a dependency + ;; cycle. + (propagated-inputs (list libpng zlib)) + (synopsis "Font rendering library") + (description + "Freetype is a library that can be used by applications to access the contents of font files. It provides a uniform interface to access font files. It supports both bitmap and scalable formats, including TrueType, OpenType, Type1, CID, CFF, Windows FON/FNT, X11 PCF, and others. It supports high-speed anti-aliased glyph bitmap generation with 256 gray levels.") - (license license:freetype) ; some files have other licenses - (home-page "https://www.freetype.org/"))) + (license license:freetype) ; some files have other licenses + (home-page "https://freetype.org/"))) (define-public opentype-sanitizer (package @@ -259,7 +267,7 @@ them as it goes.") python-booleanoperations python-defcon python-fontmath - python-fonttools-next + python-fonttools python-lxml python-tqdm python-ufonormalizer @@ -328,6 +336,42 @@ but also provides many useful font conversion and analysis facilities. @end table") (license license:asl2.0))) +(define-public python-afdko-3.6.1 + ;; This older version does not depend on Java and Antlr4. + (package + (inherit python-afdko) + (version "3.6.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "afdko" version)) + (sha256 + (base32 "0187xhgw6spzaji93fs1mnhqnq30pxhdj1p2m88673szvzpf10av")))) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (add-before 'build 'set-CC + (lambda _ + (setenv "CC" "gcc")))))) + (native-inputs + (list pkg-config + python-pytest + python-setuptools-scm + python-wheel)) + (inputs + (list bash-minimal + libxml2)) + (propagated-inputs + (list psautohint + python-booleanoperations + python-defcon + python-fontmath + python-fonttools + python-lxml + python-tqdm + python-ufonormalizer + python-ufoprocessor)))) + (define-public python-cffsubr (package (name "python-cffsubr") @@ -370,8 +414,12 @@ but also provides many useful font conversion and analysis facilities. (when tests? (invoke "pytest" "-vv"))))))) (native-inputs (list python-pytest python-setuptools-scm python-wheel)) - (inputs (list python-afdko)) - (propagated-inputs (list python-fonttools)) + + ;; Use version 3.6.1, which matches the bundled version and does not + ;; depend on Java. + (inputs (list python-afdko-3.6.1)) + + (propagated-inputs (list python-fonttools-minimal)) (home-page "https://github.com/adobe-type-tools/cffsubr") (synopsis "Compact Font Format (CFF) subroutinizer") (description "This package provides the @command{cffsubr} command, a @@ -401,7 +449,7 @@ Kit for OpenType (AFDKO) @command{tx} tool.") ((", \"setuptools_git_ls_files\"") ""))))))) (native-inputs (list python-pytest python-pytest-runner python-setuptools-scm)) - (propagated-inputs (list python-fonttools)) + (propagated-inputs (list python-fonttools-minimal)) (home-page "https://github.com/googlefonts/compreffor") (synopsis "Compact Font Format (CFF) subroutinizer for fontTools") (description "This package provides a Compact Font Format (CFF) @@ -419,7 +467,7 @@ subroutinizer for fontTools.") (sha256 (base32 "1x762r7bf39g6aivfvrmq00h6f07abvs9x1xm0fz8l81vq8jz64c")))) (build-system python-build-system) - (propagated-inputs (list python-fonttools-full)) + (propagated-inputs (list python-fonttools)) (native-inputs (list python-cython python-defcon @@ -453,7 +501,7 @@ converts any cubic curves to quadratic. The most useful function is probably python-compreffor python-cu2qu python-defcon - python-fonttools-next + python-fonttools python-skia-pathops python-ufolib2)) (home-page "https://github.com/googlefonts/ufo2ft") @@ -476,7 +524,7 @@ to generate OpenType font binaries from Unified Font Objects (UFOs).") (sha256 (base32 "070v1jz5f18g15if459ppwswq4w5hzffwp1gvdc5j47bgz5qflva")))) (build-system python-build-system) - (propagated-inputs (list python-fonttools)) + (propagated-inputs (list python-fonttools-minimal)) (native-inputs (list python-setuptools-scm python-pytest @@ -502,7 +550,7 @@ font, glyph, etc. mathematical operations on font data.") (base32 "1za15dzsnymq6d9x7xdfqwgw4a3003wj75fn2crhyidkfd2s3nd6")))) (build-system python-build-system) (arguments (list #:tests? #f)) - (propagated-inputs (list python-fonttools)) + (propagated-inputs (list python-fonttools-minimal)) (native-inputs (list unzip)) (home-page "https://github.com/robofab-developers/fontPens") (synopsis "Python classes implementing the pen protocol") @@ -553,7 +601,7 @@ implementing the pen protocol for manipulating glyphs.") (list python-booleanoperations python-defcon-bootstrap python-fontmath - python-fonttools)) + python-fonttools-minimal)) (native-inputs (list python-setuptools-scm unzip)) (home-page "https://github.com/robotools/fontParts") (synopsis "Library for interacting with font parts") @@ -599,7 +647,7 @@ process. FontParts is the successor of RoboFab.") python-xmldiff)) (propagated-inputs (list python-defcon - python-fonttools-next + python-fonttools python-openstep-plist python-ufolib2 python-ufo2ft @@ -637,7 +685,7 @@ to UFOs and DesignSpace files via @code{defcon} and @code{designspaceLib}.") (invoke "pytest" "-vv" "tests/testusage.py"))))))) (native-inputs (list python-pytest python-setuptools-scm)) (propagated-inputs - (list python-defcon python-fonttools python-glyphslib)) + (list python-defcon python-fonttools-minimal python-glyphslib)) (home-page "https://github.com/googlefonts/glyphsets/") (synopsis "Evaluate coverage of glyph sets") (description @@ -693,7 +741,8 @@ different scripts and languages.") (sha256 (base32 "0r1qq45np49x14zz1zwkaayqrn7m8dn2jlipjldg2ihnmpzw29w1")))) (build-system python-build-system) - (propagated-inputs (list python-defcon python-fontmath python-fonttools)) + (propagated-inputs (list python-defcon python-fontmath + python-fonttools-minimal)) (native-inputs (list unzip)) (home-page "https://github.com/LettError/MutatorMath") (synopsis "Piecewise linear interpolation Python library") @@ -756,7 +805,7 @@ suite of the @code{psautohint} package.") "tests/integration/data") (for-each make-file-writable (find-files "tests/integration/data"))))))) - (propagated-inputs (list python-fonttools-next)) + (inputs (list python-fonttools)) (native-inputs (list psautohint-font-data python-fs @@ -861,7 +910,7 @@ paths (intersection, union, difference, xor).") (list python-defcon python-fontmath python-fontparts - python-fonttools + python-fonttools-minimal python-mutatormath)) (native-inputs (list python-setuptools-scm unzip)) (home-page "https://github.com/LettError/ufoProcessor") @@ -1119,14 +1168,14 @@ Font Format (WOFF).") (hidden-package (package (name "fontconfig-minimal") - (version "2.13.94") + (version "2.14.0") (source (origin (method url-fetch) (uri (string-append "https://www.freedesktop.org/software/" "fontconfig/release/fontconfig-" version ".tar.xz")) (sha256 (base32 - "0g004r0bkkqz00mpm3svnnxn7d83158q0yb9ggxryizxfg5m5w55")) + "1b4v1r94ri44p4a3kbwd38ig5jgdgcfgwdfm6fqzvfvlki6bignw")) (patches (search-patches "fontconfig-cache-ignore-mtime.patch")))) (build-system gnu-build-system) ;; In Requires or Requires.private of fontconfig.pc. @@ -1323,7 +1372,7 @@ applications should be.") "01jzhwnj1c3d68dmw15jdxly0hwkmd8ja4kw755rbkykn1ly2qyx")))) (build-system cmake-build-system) (native-inputs - (list python python-fonttools)) + (list python python-fonttools-minimal)) (inputs (list freetype)) (synopsis "Reimplementation of the SIL Graphite text processing engine") @@ -1439,14 +1488,14 @@ definitions.") (define-public fontforge (package (name "fontforge") - (version "20201107") + (version "20220308") (source (origin (method url-fetch) (uri (string-append "https://github.com/fontforge/fontforge/releases/download/" version "/fontforge-" version ".tar.xz")) (sha256 - (base32 "0y3c8x1i6yf6ak9m5dhr1nldgfmg7zhnwdfd57ffs698c27vmg38")))) + (base32 "0ncfc4ajwy4ng6b6h79w52jh9z3lngvf3f3ldi1wzkhcg9zh3r01")))) (build-system cmake-build-system) (native-inputs (list pkg-config)) @@ -1464,7 +1513,6 @@ definitions.") ("libspiro" ,libspiro) ("libtiff" ,libtiff) ("libungif" ,libungif) - ("libuninameslist" ,libuninameslist) ("libxft" ,libxft) ("libxml2" ,libxml2) ("pango" ,pango) @@ -1533,8 +1581,9 @@ generate bitmaps.") `(modify-phases ,phases (delete 'do-not-override-RPATH))))) (inputs - `(("python" ,python-2) - ,@(alist-delete "python" (package-inputs fontforge)))))) + (modify-inputs (package-inputs fontforge) + (prepend libuninameslist) + (replace "python" python-2))))) (define-public python-statmake (package @@ -1578,7 +1627,7 @@ generate bitmaps.") (propagated-inputs (list python-attrs python-cattrs - python-fonttools-next)) + python-fonttools)) (home-page "https://github.com/daltonmaag/statmake") (synopsis "Apply OpenType STAT information to a variable font") (description @@ -1603,7 +1652,7 @@ with @samp{nameIDs}.") (build-system pyproject-build-system) (native-inputs (list python-pytest python-setuptools-scm)) - (propagated-inputs (list python-attrs python-fonttools-full)) + (propagated-inputs (list python-attrs python-fonttools)) (home-page "https://github.com/fonttools/ufoLib2") (synopsis "Unified Font Object (UFO) font processing library") (description "The ufoLib2 Python library is meant to be a thin @@ -1627,7 +1676,7 @@ API-compatible with defcon.") (sha256 (base32 "0i1a306b8c42dpbplwxj6ili2aac5lwq2ir6r1jswicysvk9dqxf")))) (build-system python-build-system) - (propagated-inputs (list python-fontpens-bootstrap python-fonttools-full)) + (propagated-inputs (list python-fontpens-bootstrap python-fonttools)) (native-inputs (list python-pytest python-pytest-runner diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm index 362c6b308b..78b459443a 100644 --- a/gnu/packages/freedesktop.scm +++ b/gnu/packages/freedesktop.scm @@ -25,12 +25,13 @@ ;;; Copyright © 2021 pineapples <guixuser6392@protonmail.com> ;;; Copyright © 2021 Sarah Morgensen <iskarian@mgsn.dev> ;;; Copyright © 2021 Robby Zambito <contact@robbyzambito.me> -;;; Copyright © 2021, 2022 Maxime Devos <maximedevos@telenet.be> +;;; Copyright © 2021, 2022, 2023 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2021, 2022 John Kehayias <john.kehayias@protonmail.com> ;;; Copyright © 2021, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Daniel Meißner <daniel.meissner-i4k@ruhr-uni-bochum.de> -;;; Copyright © 2022 muradm <mail@muradm.net> +;;; Copyright © 2022 Wamm K. D. <jaft.r@outlook.com> ;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com> +;;; Copyright © 2022 muradm <mail@muradm.net> ;;; ;;; This file is part of GNU Guix. ;;; @@ -148,7 +149,6 @@ (build-system meson-build-system) (arguments (list - #:meson meson-0.63 #:glib-or-gtk? #t #:phases #~(modify-phases %standard-phases @@ -263,15 +263,7 @@ application-centers for distributions.") ;; This test timeouts despite changing the value of ;; 'CK_DEFAULT_TIMEOUT' to 600 (see: ;; https://gitlab.freedesktop.org/farstream/farstream/-/issues/20). - (("^\ttransmitter/nice.*") "")))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* '("libs/farstream-libs-docs.sgml" - "plugins/farstream-plugins-docs.sgml") - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (search-input-directory (or native-inputs inputs) - "xml/dtd/docbook/"))))))))) + (("^\ttransmitter/nice.*") ""))))))) (native-inputs (list autoconf automake @@ -280,6 +272,7 @@ application-centers for distributions.") gobject-introspection gtk-doc/stable libtool + libxml2 ;for XML_CATALOG_FILES libxslt perl pkg-config @@ -563,14 +556,15 @@ freedesktop.org project.") ;; Updating this will rebuild over 700 packages through libinput-minimal. (package (name "libinput") - (version "1.19.4") + (version "1.22.1") (source (origin - (method url-fetch) - (uri (string-append "https://freedesktop.org/software/libinput/" - "libinput-" version ".tar.xz")) + (method git-fetch) + (uri (git-reference + (url "https://gitlab.freedesktop.org/libinput/libinput.git") + (commit version))) (sha256 (base32 - "0h5lz54rrl48bhi3vki6s08m6rn2h62rlf08dhgchdm9nmqaaczz")))) + "17a5qlym2d6lg2j8fdpxda9k7x5zr35flb4wlj1bz7h0mnkh8326")))) (build-system meson-build-system) (arguments `(#:configure-flags '("-Ddocumentation=false") @@ -704,6 +698,13 @@ the freedesktop.org XDG Base Directory specification.") (substitute* "meson.build" (("join_paths\\(bindir, 'pkttyagent'\\)") "'\"/run/current-system/profile/bin/pkttyagent\"'")))) + (add-after 'unpack 'use-global-hook-directory + ;; XXX There is no run-time setting to set this per-process, only a + ;; build-time, hard-coded list of global directories. + (lambda _ + (substitute* (list "src/login/elogind-dbus.c" + "src/sleep/sleep.c") + (("PKGSYSCONFDIR") "\"/etc/elogind\"")))) (add-after 'unpack 'adjust-tests (lambda _ ;; Skip the following test, which depends on users such as 'root' @@ -752,7 +753,7 @@ the freedesktop.org XDG Base Directory specification.") (substitute* "src/login/elogind.c" (("\"/run/elogind.pid\"") "\"/run/systemd/elogind.pid\""))))))) (native-inputs - `(("docbook-xml" ,docbook-xml) + `(("docbook-xml" ,docbook-xml-4.5) ("docbook-xml-4.2" ,docbook-xml-4.2) ("docbook-xsl" ,docbook-xsl) ("gettext" ,gettext-minimal) @@ -968,7 +969,14 @@ with localed. This package is extracted from the broader systemd package.") ".tar.xz")) (sha256 (base32 - "09md23m4fw87x264mls1f5isrswk6iw7y9g4hr1nib008wbbk370")))) + "09md23m4fw87x264mls1f5isrswk6iw7y9g4hr1nib008wbbk370")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "contrib/meson.build" + (("bash_.*_dep\\.get_.*\\('completionsdir', .*\\)") + "join_paths(get_option('prefix'), 'share', + 'bash-completion', 'completions')")))))) (build-system meson-build-system) (arguments (list #:tests? #f @@ -1149,58 +1157,44 @@ Python.") (define-public wayland (package (name "wayland") - (version "1.20.0") + (version "1.22.0") (source (origin (method url-fetch) - (uri (string-append "https://wayland.freedesktop.org/releases/" + (uri (string-append "https://gitlab.freedesktop.org/" name + "/" name "/-/releases/" version "/downloads/" name "-" version ".tar.xz")) (sha256 (base32 - "09c7rpbwavjg4y16mrfa57gk5ix6rnzpvlnv1wp7fnbh9hak985q")))) + "0hjq8b1cprxpxcv2klgir1hd63vy5hrqilp9v317394qlqgayh0m")))) (build-system meson-build-system) (outputs '("out" "doc")) (arguments - `(#:parallel-tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.5/") - (string-append (assoc-ref (or native-inputs inputs) - "docbook-xml") - "/xml/dtd/docbook/")) - (("http://www.oasis-open.org/docbook/xml/4\\.2/") - (string-append (assoc-ref (or native-inputs inputs) - "docbook-xml-4.2") - "/xml/dtd/docbook/")))))) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/doc") - (string-append doc "/share/doc")))))))) + (list #:parallel-tests? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/doc") + (string-append #$output:doc "/share/doc"))))))) (native-inputs - `(("docbook-xml-4.2" ,docbook-xml-4.2) - ("docbook-xml" ,docbook-xml) - ("docbook-xsl" ,docbook-xsl) - ("dot" ,graphviz) - ("doxygen" ,doxygen) - ("pkg-config" ,pkg-config) - ("python" ,python) - ("xmlto" ,xmlto) - ("xsltproc" ,libxslt) - ,@(if (%current-target-system) - `(("pkg-config-for-build" ,pkg-config-for-build) - ("wayland" ,this-package)) ; for wayland-scanner - '()))) - (inputs - (list expat libxml2)) ; for XML_CATALOG_FILES - (propagated-inputs - (list libffi)) + (append + (list docbook-xml-4.2 + docbook-xml-4.5 + docbook-xsl + graphviz + doxygen + pkg-config + python + xmlto + libxslt) + (if (%current-target-system) + (list pkg-config-for-build + this-package) ;for wayland-scanner + '()))) + (inputs (list expat libxml2)) ;for XML_CATALOG_FILES + (propagated-inputs (list libffi)) (home-page "https://wayland.freedesktop.org/") (synopsis "Core Wayland window system code and protocol") (description "Wayland is a project to define a protocol for a compositor to @@ -1214,15 +1208,15 @@ fullscreen) or other display servers.") (define-public wayland-protocols (package (name "wayland-protocols") - (version "1.23") + (version "1.29") (source (origin (method url-fetch) - (uri (string-append - "https://wayland.freedesktop.org/releases/" - "wayland-protocols-" version ".tar.xz")) + (uri (string-append "https://gitlab.freedesktop.org/wayland/" + name "/-/releases/" version "/downloads/" + name "-" version ".tar.xz")) (sha256 (base32 - "0xizccackgwszjhlq7jjiv2z2gwppljx0w32ga91bxlnby8z22kc")))) + "1n4yzyjbp5fng8pvckandymvwc47mkwyi4pyvr6p0dn7bavrlpp2")))) (build-system meson-build-system) (inputs (list wayland)) @@ -1242,20 +1236,6 @@ protocol either in Wayland core, or some other protocol in wayland-protocols.") . "https://wayland.freedesktop.org/releases.html"))) (license license:expat))) -(define-public wayland-protocols-next - (package - (inherit wayland-protocols) - (name "wayland-protocols") - (version "1.26") - (source (origin - (method url-fetch) - (uri (string-append - "https://wayland.freedesktop.org/releases/" - "wayland-protocols-" version ".tar.xz")) - (sha256 - (base32 - "04vgllmpmrv14x3x64ns01vgwx4hriljayjkz9idgbv83i63hly5")))))) - (define-public wayland-utils (package (name "wayland-utils") @@ -1271,7 +1251,7 @@ protocol either in Wayland core, or some other protocol in wayland-protocols.") "04k1yhyh7h4xawbhpz9pf6cpfmmp1l862fdgsvvnyp4hg9n3j9aj")))) (build-system meson-build-system) (native-inputs (list pkg-config)) - (inputs (list libdrm wayland wayland-protocols-next)) + (inputs (list libdrm wayland wayland-protocols)) (home-page "https://wayland.freedesktop.org/") (synopsis "Display information about the Wayland protocols") (description "This package provides @code{wayland-info} tool that can be @@ -1348,7 +1328,7 @@ compositor.") linux-pam pango pipewire - wayland-protocols-next + wayland-protocols xorg-server-xwayland)) (propagated-inputs (list libxkbcommon pixman wayland)) @@ -1644,15 +1624,6 @@ message bus.") "-Dsystemdsystemunitdir=/tmp/empty") #:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-references - ;; Having XML_CATALOG_FILES set is not enough; xmlto does not seem - ;; to honor it. - (lambda* (#:key inputs #:allow-other-keys) - (substitute* (find-files "." "\\.xml(\\.in)?$") - (("http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd") - (search-input-file inputs "share/xml/dbus-1/introspect.dtd")) - (("http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd") - (search-input-file inputs "xml/dtd/docbook/docbookx.dtd"))))) (add-after 'unpack 'patch-paths (lambda* (#:key inputs #:allow-other-keys) (substitute* "meson_post_install.py" @@ -2085,9 +2056,7 @@ iChat interoperability, and multi-user chats and Tubes using the pkg-config vala)) (inputs - ;; TODO: remove pango-next after it's the default. - (list gtk+ - pango-next)) + (list gtk+)) (propagated-inputs ;; colord-gtk.pc refers to all these. (list colord gtk)) @@ -2547,23 +2516,13 @@ Its features include: (add-after 'unpack 'make-reproducible (lambda _ (substitute* "src/main.c" - (("__DATE__") "\"guix\"")))) - (add-before 'configure 'fix-docbook - (lambda _ - (substitute* "docs/Makefile.in" - (("http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl") - (string-append #$(this-package-native-input "docbook-xsl") - "/xml/xsl/docbook-xsl-" - #$(package-version (this-package-native-input "docbook-xsl")) - "/manpages/docbook.xsl"))) - (setenv "XML_CATALOG_FILES" - (string-append #$(this-package-native-input "docbook-xml") - "/xml/dtd/docbook/catalog.xml"))))))) + (("__DATE__") "\"guix\""))))))) (inputs (list glib pango libdrm libpng eudev)) (native-inputs (list gettext-minimal pkg-config + libxml2 ;for XML_CATALOG_FILES libxslt docbook-xsl docbook-xml)) diff --git a/gnu/packages/fribidi.scm b/gnu/packages/fribidi.scm index d3a6169b0b..6b10787b87 100644 --- a/gnu/packages/fribidi.scm +++ b/gnu/packages/fribidi.scm @@ -28,7 +28,7 @@ (define-public fribidi (package (name "fribidi") - (version "1.0.9") + (version "1.0.12") (source (origin (method url-fetch) @@ -37,7 +37,7 @@ "/download/v" version "/fribidi-" version ".tar.xz")) (sha256 - (base32 "1iz06r6ha2nrgbzbn4141r58a60a9s5qiaadjjhhvdkg0alpxr65")))) + (base32 "159l56c48rfcqa8mnxhnynngzlzmvr089ki7mjrppin8gzwk7lhc")))) (build-system gnu-build-system) (synopsis "Implementation of the Unicode bidirectional algorithm") (description diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index a384572a9d..844ce935ae 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -280,47 +280,60 @@ DeuTex has functions such as merging wads, etc.") (license license:gpl2+))) (define-public grfcodec - (package - (name "grfcodec") - (version "6.0.6") - (source - (origin - (method url-fetch) - (uri (string-append "https://binaries.openttd.org/extra/" - name "/" version "/" name "-" version - "-source.tar.xz")) - (patches (search-patches "grfcodec-gcc-compat.patch")) - (sha256 - (base32 "08admgnpqcsifpicbm56apgv360fxapqpbbsp10qyk8i22w1ivsk")))) - (build-system gnu-build-system) - (arguments - '(#:tests? #f ;no check target - #:phases - (modify-phases %standard-phases - (delete 'configure) ;no configure script - (replace 'install ;no install target - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin")) - (doc (string-append out "/share/doc")) - (man (string-append out "/share/man/man1"))) - (for-each (lambda (file) - (install-file file bin)) - '("grfcodec" "grfid" "grfstrip" "nforenum")) - (install-file "COPYING" doc) - (with-directory-excursion "docs" - (for-each (lambda (file) - (install-file (string-append file ".txt") doc)) - '("auto_correct" "commands" "grf" "grfcodec" "grftut" - "readme" "readme.rpn")) + ;; Latest release 6.0.6 requires an older boost and does not build with our + ;; newer GCC. + (let ((commit "7ded8ebd1447bd2e7c0f4b587be0c0510397bdd0") + (revision "0")) + (package + (name "grfcodec") + (version (git-version "6.0.6" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/OpenTTD/grfcodec") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "12bf5y7d83plrlssdlcj83w4yxmg5jp1w2p8570l92hy9mkcfmb9")) + (modules '((guix build utils))) + (snippet + `(begin + ;; The sources are not a git repository + (substitute* "generate_version.cmake" + (("\\$\\{GIT.*describe.*") (string-append "echo \"" ,version "\"\n")) + (("\\$\\{GIT.*show.*") "echo \"Not shown for reproducibility.\"\n")) + (substitute* "CMakeLists.txt" + (("find_package\\(Git REQUIRED\\)") "")))))) + (build-system cmake-build-system) + (arguments + '(#:tests? #f ;no check target + #:phases + (modify-phases %standard-phases + (replace 'install ;no install target + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin")) + (doc (string-append out "/share/doc")) + (man (string-append out "/share/man/man1"))) (for-each (lambda (file) - (install-file file man)) - (find-files "." "\\.1"))))))))) - (inputs - (list boost libpng zlib)) - (synopsis "GRF development tools") - (description - "The @dfn{Graphics Resource File} (GRF) development tools are a set of + (install-file file bin)) + '("grfcodec" "grfid" "grfstrip" "nforenum")) + (with-directory-excursion "../source" + (install-file "COPYING" doc) + (with-directory-excursion "docs" + (for-each (lambda (file) + (install-file (string-append file ".txt") doc)) + '("auto_correct" "commands" "grf" "grfcodec" "grftut" + "readme" "readme.rpn")) + (for-each (lambda (file) + (install-file file man)) + (find-files "." "\\.1")))))))))) + (inputs + (list boost libpng zlib)) + (synopsis "GRF development tools") + (description + "The @dfn{Graphics Resource File} (GRF) development tools are a set of tools for developing (New)GRFs. It includes a number of smaller programs, each with a specific task: @enumerate @@ -330,11 +343,11 @@ with a specific task: @item @code{nforenum} checks NFO code for errors, making corrections when necessary. @end enumerate") - (home-page "https://dev.openttdcoop.org/projects/grfcodec") - ;; GRFCodec, GRFID, and GRFStrip are exclusively under the GPL2. - ;; NFORenum is under the GPL2+. - ;; The MD5 implementation contained in GRFID is under the zlib license. - (license (list license:gpl2 license:gpl2+ license:zlib)))) + (home-page "https://dev.openttdcoop.org/projects/grfcodec") + ;; GRFCodec, GRFID, and GRFStrip are exclusively under the GPL2. + ;; NFORenum is under the GPL2+. + ;; The MD5 implementation contained in GRFID is under the zlib license. + (license (list license:gpl2 license:gpl2+ license:zlib))))) (define-public catcodec (package @@ -404,13 +417,13 @@ provide connectivity for client applications written in any language.") (define-public nml (package (name "nml") - (version "0.5.3") + (version "0.7.2") (source (origin (method url-fetch) (uri (pypi-uri "nml" version)) (sha256 - (base32 "0l5pfs8q7jrl3xscqq7pnwh5h5d17fsyjy7xspkc73sa0ayjm9jx")))) + (base32 "1kgzkv8pc0blck8c6iqq1idx1nrxyjw2vbnrdisnxizi6zds5l73")))) (build-system python-build-system) ;; TODO: Fix test that fails with ;; "AttributeError: partially initialized module 'nml.nmlop' has no diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 727854afda..62ee0050fa 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -4520,6 +4520,11 @@ engine. When you start it you will be prompted to download a graphics set.") ;; Make sure HOME is writable for GIMP. (setenv "HOME" (getcwd)) + (mkdir-p ".local/share") + (symlink (string-append #$(this-package-native-input "shared-mime-info") + "/share/mime") + ".local/share/mime") + ;; Redirect stdout, not stderr, to /dev/null. This prevents ;; dos2unix from receiving its version information as a flag. (substitute* "Makefile" @@ -4534,6 +4539,7 @@ engine. When you start it you will be prompted to download a graphics set.") #:parallel-build? #f)) (native-inputs (list dos2unix + shared-mime-info gimp grfcodec nml diff --git a/gnu/packages/gawk.scm b/gnu/packages/gawk.scm index 9feaf059fb..16a4ca5b0a 100644 --- a/gnu/packages/gawk.scm +++ b/gnu/packages/gawk.scm @@ -1,8 +1,8 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012, 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2018 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2018, 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2021, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com> ;;; ;;; This file is part of GNU Guix. @@ -29,6 +29,7 @@ #:use-module (gnu packages libsigsegv) #:use-module (gnu packages multiprecision) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix utils) @@ -38,55 +39,45 @@ (define-public gawk (package (name "gawk") - (version "5.1.0") + (version "5.2.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gawk/gawk-" version ".tar.xz")) (sha256 - (base32 "1gc2cccqy1x1bf6rhwlmd8q7dz7gnam6nwgl38bxapv6qm5flpyg")))) + (base32 "0kvy78jdv6lww1s6y2jm1w2cj46mz1fhflgdj9bwq64y3ywm6db7")))) (build-system gnu-build-system) (arguments - `(#:phases (modify-phases %standard-phases - (add-before 'configure 'set-shell-file-name - (lambda* (#:key inputs #:allow-other-keys) - ;; Refer to the right shell. - (let ((bash (assoc-ref inputs "bash"))) - (substitute* "io.c" - (("/bin/sh") - (string-append bash "/bin/sh"))) + (list #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'set-shell-file-name + (lambda* (#:key inputs #:allow-other-keys) + ;; Refer to the right shell. + (let ((/bin/sh (search-input-file inputs "bin/sh"))) + (substitute* "io.c" + (("/bin/sh") /bin/sh)) - ;; When cross-compiling, remove dependencies on the - ;; `check-for-shared-lib-support' target, which tries - ;; to run the cross-built `gawk'. - ,@(if (%current-target-system) - '((substitute* "extension/Makefile.in" + ;; When cross-compiling, remove dependencies on the + ;; `check-for-shared-lib-support' target, which tries + ;; to run the cross-built `gawk'. + #$@(if (%current-target-system) + '((substitute* "extension/Makefile.in" (("^.*: check-for-shared-lib-support" match) (string-append "### " match)))) - '())))) + '())))) - (add-before 'check 'adjust-test-infrastructure - (lambda _ - ;; Remove dependency on 'more' (from util-linux), which - ;; would needlessly complicate bootstrapping. - (substitute* "test/Makefile" - (("\\| more") "")) + (add-before 'check 'adjust-test-infrastructure + (lambda _ + ;; Remove dependency on 'more' (from util-linux), which + ;; would needlessly complicate bootstrapping. + (substitute* "test/Makefile" + (("\\| more") "")) - ;; Silence a warning from bash about not being able - ;; to change to an ISO-8859-1 locale. The test itself - ;; works fine, but newer versions of bash give a - ;; locale warning which mangles the test output. - (substitute* "test/localenl.sh" - (("for LC_ALL in") - "for LC in") - (("export LC_ALL\n") - "export LC_ALL=$LC 2>/dev/null\n")) - - ;; Adjust the shebang in that file since it is then diff'd - ;; against the actual test output. - (substitute* "test/watchpoint1.ok" - (("#! /usr/bin/gawk") - (string-append "#!" (which "gawk"))))))))) + ;; Adjust the shebang in that file since it is then diff'd + ;; against the actual test output. + (substitute* "test/watchpoint1.ok" + (("#! /usr/bin/gawk") + (string-append "#!" (which "gawk"))))))))) (inputs (list libsigsegv ;; Use the full-fledged Bash package, otherwise the test suite diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm index bf3c753b2d..b7d15d0730 100644 --- a/gnu/packages/gcc.scm +++ b/gnu/packages/gcc.scm @@ -1,12 +1,12 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2022 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012-2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2019, 2021 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2015 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2015, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2015-2018, 2020-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Carlos Sánchez de La Lama <csanchezdll@gmail.com> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2018, 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2018, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Joseph LaFreniere <joseph@lafreniere.xyz> ;;; Copyright © 2020 Guy Fleury Iteriteka <gfleury@disroot.org> ;;; Copyright © 2020 Simon Tournier <zimon.toutoune@gmail.com> @@ -173,7 +173,7 @@ where the OS part is overloaded to denote a specific ABI---into GCC "lib" ;libgcc_s, libgomp, etc. (15+ MiB) "debug")) ;debug symbols of run-time libraries - (inputs (list gmp mpfr mpc libelf zlib)) + (inputs (list gmp mpfr mpc elfutils zlib)) ;; GCC < 5 is one of the few packages that doesn't ship .info files. ;; Newer texinfos fail to build the manual, so we use an older one. @@ -182,7 +182,16 @@ where the OS part is overloaded to denote a specific ABI---into GCC (arguments `(#:out-of-source? #t - #:configure-flags ,(configure-flags) + #:configure-flags ,(let ((flags (configure-flags)) + (version (package-version this-package))) + ;; GCC 4.9 and 5.0 requires C++11 but GCC + ;; 11.3.0 defaults to C++17, which is partly + ;; incompatible. Force C++11. + (if (or (version-prefix? "4.9" version) + (version-prefix? "5" version)) + `(cons "CXX=g++ -std=c++11" ,flags) + flags)) + #:make-flags ;; None of the flags below are needed when doing a Canadian cross. ;; TODO: Simplify this. @@ -295,15 +304,13 @@ where the OS part is overloaded to denote a specific ABI---into GCC (substitute* "gcc/config/aarch64/t-aarch64-linux" (("lib64") "lib"))) - ;; TODO: Make this unconditional in core-updates. ;; The STARTFILE_PREFIX_SPEC prevents gcc from finding the ;; gcc:lib output, which causes ld to not find -lgcc_s. - ,@(if (target-riscv64?) - `((when (file-exists? "gcc/config/riscv") - (substitute* "gcc/config/riscv/linux.h" - (("define STARTFILE_PREFIX_SPEC") - "define __STARTFILE_PREFIX_SPEC")))) - '()) + (when (file-exists? "gcc/config/riscv") + (substitute* '("gcc/config/riscv/linux.h" + "gcc/config/riscv/riscv.h") ; GCC < 10 + (("define STARTFILE_PREFIX_SPEC") + "define __STARTFILE_PREFIX_SPEC"))) (when (file-exists? "libbacktrace") ;; GCC 4.8+ comes with libbacktrace. By default it builds @@ -441,30 +448,36 @@ Go. It also includes runtime support libraries for these languages.") (native-inputs (list perl ;for manpages texinfo)) (arguments - (if (%current-target-system) - (package-arguments gcc-4.8) - ;; For native builds of GCC 4.9 and GCC 5, the C++ include path needs - ;; to be adjusted so it does not interfere with GCC's own build processes. - (substitute-keyword-arguments (package-arguments gcc-4.8) - ((#:modules modules %gnu-build-system-modules) - `((srfi srfi-1) - ,@modules)) - ((#:phases phases) - `(modify-phases ,phases - (add-after 'set-paths 'adjust-CPLUS_INCLUDE_PATH - (lambda* (#:key inputs #:allow-other-keys) - (let ((libc (assoc-ref inputs "libc")) - (gcc (assoc-ref inputs "gcc"))) - (setenv "CPLUS_INCLUDE_PATH" - (string-join (fold delete - (string-split (getenv "CPLUS_INCLUDE_PATH") - #\:) - (list (string-append libc "/include") - (string-append gcc "/include/c++"))) - ":")) - (format #t - "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%" - (getenv "CPLUS_INCLUDE_PATH")))))))))))) + ;; Since 'arguments' is a function of the package's version, define + ;; 'parent' such that the 'arguments' thunk gets to see the right + ;; version. + (let ((parent (package + (inherit gcc-4.8) + (version (package-version this-package))))) + (if (%current-target-system) + (package-arguments parent) + ;; For native builds of GCC 4.9 and GCC 5, the C++ include path needs + ;; to be adjusted so it does not interfere with GCC's own build processes. + (substitute-keyword-arguments (package-arguments parent) + ((#:modules modules %gnu-build-system-modules) + `((srfi srfi-1) + ,@modules)) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'set-paths 'adjust-CPLUS_INCLUDE_PATH + (lambda* (#:key inputs #:allow-other-keys) + (let ((libc (assoc-ref inputs "libc")) + (gcc (assoc-ref inputs "gcc"))) + (setenv "CPLUS_INCLUDE_PATH" + (string-join (fold delete + (string-split (getenv "CPLUS_INCLUDE_PATH") + #\:) + (list (string-append libc "/include") + (string-append gcc "/include/c++"))) + ":")) + (format #t + "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%" + (getenv "CPLUS_INCLUDE_PATH"))))))))))))) (define gcc-canadian-cross-objdump-snippet ;; Fix 'libcc1/configure' error when cross-compiling GCC. Without that, @@ -619,7 +632,8 @@ It also includes runtime support libraries for these languages.") `((compiler-cpu-architectures ("aarch64" ,@%gcc-7.5-aarch64-micro-architectures) ("armhf" ,@%gcc-7.5-armhf-micro-architectures) - ("x86_64" ,@%gcc-7.5-x86_64-micro-architectures)))))) + ("x86_64" ,@%gcc-7.5-x86_64-micro-architectures)) + ,@(package-properties gcc-6))))) (define-public gcc-8 (package @@ -658,23 +672,25 @@ It also includes runtime support libraries for these languages.") (define-public gcc-10 (package (inherit gcc-8) - (version "10.3.0") + (version "10.4.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gcc/gcc-" version "/gcc-" version ".tar.xz")) (sha256 (base32 - "0i6378ig6h397zkhd7m4ccwjx5alvzrf2hm27p1pzwjhlv0h9x34")) + "1wg4xdizkksmwi66mvv2v4pk3ja8x64m7v9gzhykzd3wrmdpsaf9")) (patches (search-patches "gcc-9-strmov-store-file-names.patch" - "gcc-5.0-libvtv-runpath.patch")) + "gcc-5.0-libvtv-runpath.patch" + "gcc-10-tree-sra-union-handling.patch")) (modules '((guix build utils))) (snippet gcc-canadian-cross-objdump-snippet))) (properties `((compiler-cpu-architectures ("aarch64" ,@%gcc-10-aarch64-micro-architectures) ("armhf" ,@%gcc-10-armhf-micro-architectures) - ("x86_64" ,@%gcc-10-x86_64-micro-architectures)))))) + ("x86_64" ,@%gcc-10-x86_64-micro-architectures)) + ,@(package-properties gcc-8))))) (define-public gcc-11 (package @@ -688,15 +704,28 @@ It also includes runtime support libraries for these languages.") (base32 "0fdclcwf728wbq52vphfcjywzhpsjp3kifzj3pib3xcihs0z4z5l")) (patches (search-patches "gcc-9-strmov-store-file-names.patch" - "gcc-5.0-libvtv-runpath.patch")) + "gcc-5.0-libvtv-runpath.patch" + "gcc-10-tree-sra-union-handling.patch")) (modules '((guix build utils))) (snippet gcc-canadian-cross-objdump-snippet))) - + (arguments + (substitute-keyword-arguments (package-arguments gcc-8) + ((#:phases phases #~%standard-phases) + (if (target-hurd?) + #~(modify-phases #$phases + (add-after 'unpack 'patch-hurd-libpthread + (lambda _ + (define patch + #$(local-file + (search-patch "gcc-11-libstdc++-hurd-libpthread.patch"))) + (invoke "patch" "--force" "-p1" "-i" patch)))) + phases)))) (properties `((compiler-cpu-architectures ("aarch64" ,@%gcc-11-aarch64-micro-architectures) ("armhf" ,@%gcc-11-armhf-micro-architectures) - ("x86_64" ,@%gcc-11-x86_64-micro-architectures)))))) + ("x86_64" ,@%gcc-11-x86_64-micro-architectures)) + ,@(package-properties gcc-8))))) (define-public gcc-12 (package @@ -718,7 +747,7 @@ It also includes runtime support libraries for these languages.") ;; Note: When changing the default gcc version, update ;; the gcc-toolchain-* definitions. -(define-public gcc gcc-10) +(define-public gcc gcc-11) ;;; @@ -828,8 +857,50 @@ using compilers other than GCC." (name "libstdc++") (arguments `(#:out-of-source? #t + #:modules ((srfi srfi-1) + (srfi srfi-26) + ,@%gnu-build-system-modules) #:phases (modify-phases %standard-phases + ,@(if (version>=? (package-version gcc) "11") + `((add-after 'unpack 'hide-gcc-headers + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (let ((gcc (assoc-ref (or native-inputs inputs) + ,(if (%current-target-system) + "cross-gcc" + "gcc")))) + ;; Fix a regression in GCC 11 where the GCC headers + ;; shadows glibc headers when building libstdc++. An + ;; upstream fix was added in GCC 11.3.0, but it only + ;; hides system include directories, not those on + ;; CPLUS_INCLUDE_PATH. See discussion at + ;; <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100017> + ;; and the similar adjustment in GCC-FINAL. + (substitute* "libstdc++-v3/src/c++17/Makefile.in" + (("AM_CXXFLAGS = ") + (string-append ,(if (%current-target-system) + "CROSS_CPLUS_INCLUDE_PATH = " + "CPLUS_INCLUDE_PATH = ") + (string-join + (remove (cut string-prefix? gcc <>) + (string-split + (getenv + ,(if (%current-target-system) + "CROSS_CPLUS_INCLUDE_PATH" + "CPLUS_INCLUDE_PATH")) + #\:)) + ":") + "\nAM_CXXFLAGS = "))))))) + '()) + ,@(let ((version (package-version gcc))) + (if (and (target-ppc64le?) + (version>=? version "11") + (not (version>=? version "12"))) + `((add-after 'unpack 'patch-powerpc + (lambda* (#:key inputs #:allow-other-keys) + (invoke "patch" "--force" "-p1" "-i" + (assoc-ref inputs "powerpc64le-patch"))))) + '())) ;; Force rs6000 (i.e., powerpc) libdir to be /lib and not /lib64. (add-before 'chdir 'fix-rs6000-libdir (lambda _ @@ -846,7 +917,14 @@ using compilers other than GCC." "/include")))) (outputs '("out" "debug")) (inputs '()) - (native-inputs '()) + (native-inputs + `(,@(if (and (target-ppc64le?) + (let ((version (package-version gcc))) + (and + (version>=? version "11") + (not (version>=? version "12"))))) + `(("powerpc64le-patch" ,(search-patch "gcc-11-libstdc++-powerpc.patch"))) + '()))) (propagated-inputs '()) (synopsis "GNU C++ standard library"))) @@ -1141,7 +1219,7 @@ provides the GNU compiler for the Go programming language.")) (custom-gcc gcc-12 "gcc-objc" '("objc") %objc-search-paths)) -(define-public gcc-objc gcc-objc-10) +(define-public gcc-objc gcc-objc-11) (define %objc++-search-paths (list (search-path-specification @@ -1191,7 +1269,7 @@ provides the GNU compiler for the Go programming language.")) (custom-gcc gcc-12 "gcc-objc++" '("obj-c++") %objc++-search-paths)) -(define-public gcc-objc++ gcc-objc++-10) +(define-public gcc-objc++ gcc-objc++-11) (define (make-libstdc++-doc gcc) "Return a package with the libstdc++ documentation for GCC." @@ -1252,16 +1330,16 @@ provides the GNU compiler for the Go programming language.")) (define-public isl (package (name "isl") - (version "0.23") + (version "0.24") (source (origin (method url-fetch) (uri (list (string-append "mirror://sourceforge/libisl/isl-" - version ".tar.bz2") + version ".tar.xz") (string-append %gcc-infrastructure - "isl-" version ".tar.bz2"))) + "isl-" version ".tar.xz"))) (sha256 (base32 - "0k91zck10zxs9sk3yrbb92y1j3w981w3fbwkfwd7kl779b0j52f5")))) + "1bgbk6n93qqn7w8v21kxf4x6dc3z0ypqrzvgfd46nhagak60ac84")))) (build-system gnu-build-system) (outputs '("out" "static")) (arguments diff --git a/gnu/packages/gd.scm b/gnu/packages/gd.scm index 90023ddc84..149b82468c 100644 --- a/gnu/packages/gd.scm +++ b/gnu/packages/gd.scm @@ -78,11 +78,11 @@ (native-inputs (list pkg-config)) (inputs - `(("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("zlib" ,zlib))) + (list fontconfig + freetype + libjpeg-turbo + libpng + zlib)) (home-page "https://www.libgd.org/") (synopsis "Library for the dynamic creation of images by programmers") (description @@ -94,7 +94,10 @@ most anything else, on the fly. While not restricted to use on the web, the most common applications of GD involve website development.") (license (non-copyleft "file://COPYING" "See COPYING file in the distribution.")) - (properties '((cpe-name . "libgd"))))) + (properties '((cpe-name . "libgd") + (upstream-name . "libgd") + (release-monitoring-url + . "https://github.com/libgd/libgd/releases"))))) (define-public perl-gd (package diff --git a/gnu/packages/gdb.scm b/gnu/packages/gdb.scm index fd0bc80e44..82050d9ac5 100644 --- a/gnu/packages/gdb.scm +++ b/gnu/packages/gdb.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015, 2019, 2020 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2013, 2014, 2015, 2019, 2020, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015, 2016, 2019, 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com> @@ -25,6 +25,7 @@ (define-module (gnu packages gdb) #:use-module (gnu packages) #:use-module (gnu packages bash) + #:use-module (gnu packages cross-base) #:use-module (gnu packages hurd) #:use-module (gnu packages ncurses) #:use-module (gnu packages readline) @@ -71,12 +72,6 @@ "gdbsupport/pathstuff.cc") (("\"/bin/sh\"") (format #f "~s" sh)))))) - ,@(if (hurd-target?) - '((add-after 'unpack 'patch-gdb/hurd - (lambda* (#:key inputs #:allow-other-keys) - (let ((patch (assoc-ref inputs "hurd-build.patch"))) - (invoke "patch" "-p1" "--force" "-i" patch))))) - '()) (add-after 'configure 'post-configure (lambda _ (for-each patch-makefile-SHELL @@ -118,9 +113,7 @@ ;; The Hurd needs -lshouldbeinlibc. ,@(if (hurd-target?) - `(("hurd" ,hurd) - ("hurd-build.patch" - ,(search-patch "gdb-fix-gnu-nat-build.patch"))) + `(("hurd" ,hurd)) '()))) (native-inputs `(("texinfo" ,texinfo) @@ -130,7 +123,7 @@ ;; When cross-compiling from x86_64-linux, make sure to use a ;; 32-bit MiG because we assume target i586-pc-gnu. `(("mig" ,(if (%current-target-system) - mig/32-bit + (cross-mig (%current-target-system)) mig))) '()))) ;; TODO: Add support for the GDB_DEBUG_FILE_DIRECTORY environment @@ -147,7 +140,11 @@ doing while it runs or what it was doing just before a crash. It allows you to specify the runtime conditions, to define breakpoints, and to change how the program is running to try to fix bugs. It can be used to debug programs written in C, C++, Ada, Objective-C, Pascal and more.") - (license gpl3+))) + (license gpl3+) + + ;; GDB 11 now fails to build on GNU/Hurd (undefined references to process + ;; RPC stubs). + (supported-systems (fold delete %supported-systems %hurd-systems)))) (define-public gdb-12 (package @@ -159,15 +156,22 @@ written in C, C++, Ada, Objective-C, Pascal and more.") version ".tar.xz")) (sha256 (base32 - "1vczsqcbh5y0gx7qrclpna0qzx26sk7lra6y8qzxam1biyzr65qf")))))) + "1vczsqcbh5y0gx7qrclpna0qzx26sk7lra6y8qzxam1biyzr65qf")))) -(define-public gdb + ;; GDB 12 builds fine on GNU/Hurd. + (supported-systems %supported-systems))) + +(define-public gdb/pinned ;; This is the fixed version that packages depend on. Update it rarely ;; enough to avoid massive rebuilds. gdb-11) +(define-public gdb + ;; The "default" version. + gdb-12) + (define-public gdb-minimal - (package/inherit gdb + (package/inherit gdb-12 (name "gdb-minimal") (inputs (fold alist-delete (package-inputs gdb) '("libxml2" "ncurses" "python-wrapper" "source-highlight"))))) diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm index 77f6f853b4..cd56f50bf0 100644 --- a/gnu/packages/geo.scm +++ b/gnu/packages/geo.scm @@ -19,7 +19,7 @@ ;;; Copyright © 2021 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2021, 2022 Nikolay Korotkiy <sikmir@disroot.org> ;;; Copyright © 2022 Roman Scherer <roman.scherer@burningswell.com> -;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> ;;; ;;; This file is part of GNU Guix. @@ -245,44 +245,31 @@ than 600 operators available.") (outputs '("out" "doc")) (arguments `(#:configure-flags - (list - "--disable-static" - "--enable-gtk-doc" - "--enable-vala" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) + (list "--disable-static" + "--enable-gtk-doc" + "--enable-vala" + (string-append "--with-html-dir=" #$output "/share/gtk-doc/html")) #:phases (modify-phases %standard-phases (add-after 'unpack 'patch-autogen (lambda _ (substitute* "autogen.sh" (("\\./configure \"\\$@\"") - "")) - #t)) - (add-after 'patch-autogen 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs/reference" - (substitute* "libmemphis-docs.sgml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t))))) + ""))))))) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("docbook-xml" ,docbook-xml-4.3) - ("gobject-introspection" ,gobject-introspection) - ("gtk-doc" ,gtk-doc/stable) - ("libtool" ,libtool) - ("pkg-config" ,pkg-config) - ("python" ,python-wrapper) - ("seed" ,seed) - ("vala" ,vala))) - (inputs - (list expat glib)) - (propagated-inputs - (list cairo)) + (list autoconf + automake + docbook-xml-4.3 + gobject-introspection + gtk-doc/stable + libtool + libxml2 ;for XML_CATALOG_FILES + pkg-config + python-wrapper + seed + vala)) + (inputs (list expat glib)) + (propagated-inputs (list cairo)) (synopsis "Map-rendering for OpenSteetMap") (description "Memphis is a map-rendering application and a library for OpenStreetMap written in C using eXpat, Cairo and GLib.") @@ -341,7 +328,6 @@ topology functions.") (arguments (list #:glib-or-gtk? #t - #:meson meson-0.63 #:phases #~(modify-phases %standard-phases (add-after 'unpack 'skip-cache-and-database-updates @@ -389,7 +375,6 @@ topology functions.") libshumate libsoup libxml2 - pango-next ;TODO: remove when it's the default rest-next webkitgtk)) (synopsis "Graphical map viewer and wayfinding program") @@ -2488,26 +2473,17 @@ growing set of geoscientific methods.") ;; Configure correct path to PyQt5 SIP directory (add-after 'unpack 'configure-pyqt5-sip-path (lambda* (#:key inputs #:allow-other-keys) - (substitute* "cmake/FindPyQt5.py" - (("sip_dir = cfg.default_sip_dir") - (string-append "sip_dir = \"" - (assoc-ref inputs "python-pyqt+qscintilla") - "/share/sip\""))) - ;; Fix building with python-sip@5. - ;; - ;; The reason for this is that python-sip@5 introduces some - ;; changes such as a new build system 'sip-build' as well as the - ;; use of the path "/lib/pythonX.X/site-packages/*/bindings/" - ;; instead of "/share/sip/" for .sip files. However, we do not - ;; actually use that those yet. QGIS detects SIP5 and assumes we - ;; are, messing up the build. The long term solution is to fully - ;; upgrade SIP, use sip-build and fix all failing packages, but - ;; for now I just want to get the build working. - (substitute* "cmake/FindPyQt5.cmake" - (("SET\\(PYQT5_SIP_DIR \"\\$\\{Python_SITEARCH\\}/PyQt5/bindings\"\\)") - (string-append "SET(PYQT5_SIP_DIR \"" - (assoc-ref inputs "python-pyqt+qscintilla") - "/share/sip\")"))) + (let ((sip-dir (string-append + (assoc-ref inputs "python-pyqt+qscintilla") + "/lib/python" + (python:python-version (assoc-ref inputs "python")) + "/site-packages/PyQt5/bindings"))) + (substitute* "cmake/FindPyQt5.py" + (("sip_dir = cfg.default_sip_dir") + (string-append "sip_dir = \"" sip-dir "\""))) + (substitute* "cmake/FindPyQt5.cmake" + (("SET\\(PYQT5_SIP_DIR \"\\$\\{Python_SITEARCH\\}/PyQt5/bindings\"\\)") + (string-append "SET(PYQT5_SIP_DIR \"" sip-dir "\")")))) (substitute* (list "tests/code_layout/test_qt_imports.sh" "tests/code_layout/test_qgsscrollarea.sh") (("\\$\\(git rev-parse --show-toplevel\\)") @@ -2575,24 +2551,29 @@ growing set of geoscientific methods.") "test_core_compositionconverter" "test_core_expression" "test_core_gdalutils" + "test_core_labelingengine" "test_core_layoutpicture" + "test_core_layouttable" "test_core_pointcloudlayerexporter" "test_core_projectstorage" "test_core_coordinatereferencesystem" "test_gui_queryresultwidget" "test_provider_copcprovider" + "test_provider_eptprovider" "test_analysis_processingalgspt1" "test_analysis_processingalgspt2" "test_analysis_processing" "test_app_gpsintegration" "PyQgsAnnotation" "PyQgsAuthenticationSystem" + "PyQgsConnectionRegistry" "PyQgsDatumTransform" "PyQgsFileUtils" "PyQgsGeometryTest" "PyQgsGoogleMapsGeocoder" "PyQgsGroupLayer" "PyQgsHashLineSymbolLayer" + "PyQgsLayerMetadataProviderPython" "PyQgsLayoutHtml" "PyQgsLineSymbolLayers" "PyQgsMapLayer" @@ -2602,6 +2583,8 @@ growing set of geoscientific methods.") "PyQgsProviderConnectionGpkg" "PyQgsProviderConnectionSpatialite" "PyQgsOGRProvider" + "PyQgsSettingsTreeNode" + "PyQgsTextRenderer" "PyQgsVectorFileWriter" "PyQgsVectorLayerEditBuffer" "PyQgsVirtualLayerProvider" diff --git a/gnu/packages/gettext.scm b/gnu/packages/gettext.scm index d1e51ab530..9387f4fb8a 100644 --- a/gnu/packages/gettext.scm +++ b/gnu/packages/gettext.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org> ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015, 2017 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2016, 2019 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2019, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Alex Kost <alezost@gmail.com> ;;; Copyright © 2017, 2019, 2020 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2020 EuAndreh <eu@euandre.org> ;;; Copyright © 2022 gemmaro <gemmaro.dev@gmail.com> +;;; Copyright © 2023 Maxim Cournoyer maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -62,7 +63,8 @@ version ".tar.gz")) (sha256 (base32 - "04kbg1sx0ncfrsbr85ggjslqkzzb243fcw9nyh3rrv1a22ihszf7")))) + "04kbg1sx0ncfrsbr85ggjslqkzzb243fcw9nyh3rrv1a22ihszf7")) + (patches (search-patches "gettext-libunicode-update.patch")))) (build-system gnu-build-system) (outputs '("out" "doc")) ;9 MiB of HTML @@ -168,9 +170,8 @@ translated messages from the catalogs. Nearly all GNU packages use Gettext.") (with-directory-excursion (string-append (assoc-ref outputs "out") "/share/emacs/site-lisp") - (symlink "start-po.el" "gettext-autoloads.el") - #t))))))) - (native-inputs `(("emacs" ,emacs-minimal))) ; for Emacs tools + (symlink "start-po.el" "gettext-autoloads.el")))))))) + (native-inputs (list emacs-minimal)) ;for Emacs tools (synopsis "Tools and documentation for translation"))) (define-public libtextstyle @@ -250,57 +251,49 @@ from Markdown files.") "045i8izp2dqmkdzvnxyy5sy27ffrwl85dk8n6cmg1804ikk28qdg")))) (build-system perl-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'install 'wrap-programs - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Make sure all executables in "bin" find the Perl modules - ;; required by this package at runtime. - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin/")) - (path (string-append out "/lib/perl5/site_perl:" - (string-join - (map (lambda (name) - (string-append (assoc-ref inputs name) - "/lib/perl5/site_perl")) - (list "perl-gettext" - "perl-pod-parser" - "perl-sgmls" - "perl-syntax-keyword-try" - "perl-xs-parse-keyword" - "perl-term-readkey" - "perl-text-wrapi18n" - "perl-unicode-linebreak" - "perl-yaml-tiny")) - ":")))) - (for-each (lambda (file) - (wrap-program file - `("PERL5LIB" ":" prefix (,path)))) - (find-files bin "\\.*$")) - #t))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (substitute* (find-files "." ".*\\.xml(-good)?") - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/"))) - #t)) - (add-before 'check 'disable-failing-tests - (lambda _ - ;; FIXME: fails despite of importing SGMLS - (delete-file "t/fmt-sgml.t") - #t))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'wrap-programs + (lambda* (#:key inputs outputs #:allow-other-keys) + ;; Make sure all executables in "bin" find the Perl modules + ;; required by this package at runtime. + (let* ((out #$output) + (bin (string-append out "/bin/")) + (path (string-append + out "/lib/perl5/site_perl:" + (string-join + (map (lambda (name) + (string-append (assoc-ref inputs name) + "/lib/perl5/site_perl")) + (list "perl-gettext" + "perl-pod-parser" + "perl-sgmls" + "perl-syntax-keyword-try" + "perl-xs-parse-keyword" + "perl-term-readkey" + "perl-text-wrapi18n" + "perl-unicode-linebreak" + "perl-yaml-tiny")) + ":")))) + (for-each (lambda (file) + (wrap-program file + `("PERL5LIB" ":" prefix (,path)))) + (find-files bin "\\.*$"))))) + (add-before 'check 'disable-failing-tests + (lambda _ + ;; FIXME: fails despite of importing SGMLS + (delete-file "t/fmt-sgml.t")))))) (native-inputs - `(("gettext" ,gettext-minimal) - ("perl-module-build" ,perl-module-build) - ("docbook-xsl" ,docbook-xsl) - ("libxml2" ,libxml2) - ("xsltproc" ,libxslt) - - ;; For tests. - ("docbook-xml" ,docbook-xml-4.1.2) - ("perl-test-pod" ,perl-test-pod) - ("texlive" ,texlive-tiny))) + (list gettext-minimal + perl-module-build + docbook-xsl + libxml2 + libxslt + ;; For tests. + docbook-xml-4.1.2 + perl-test-pod + texlive-tiny)) (inputs (list bash-minimal perl-gettext diff --git a/gnu/packages/ghostscript.scm b/gnu/packages/ghostscript.scm index dfd43d8ed0..1813cc367e 100644 --- a/gnu/packages/ghostscript.scm +++ b/gnu/packages/ghostscript.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2017, 2018, 2019, 2021, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2018, 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2018, 2020, 2022 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; @@ -33,6 +33,7 @@ #:use-module (gnu packages cups) #:use-module (gnu packages fontutils) #:use-module (gnu packages image) + #:use-module (gnu packages man) #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -41,249 +42,221 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix build-system gnu) #:use-module (srfi srfi-1)) (define-public lcms (package - (name "lcms") - (version "2.12") - (source (origin - (method url-fetch) - (uri (string-append "mirror://sourceforge/lcms/lcms/" version - "/lcms2-" version ".tar.gz")) - - (sha256 (base32 - "1x8hzq8kw16lgjxmqpnqah1p3hrqqhjpcl1ymiah8434x22kjrhq")))) - (build-system gnu-build-system) - (arguments - `(#:configure-flags '("--disable-static"))) - (inputs `(("libjpeg" ,libjpeg-turbo) - ("libtiff" ,libtiff) - ("zlib" ,zlib))) - (synopsis "Little CMS, a small-footprint colour management engine") - (description - "Little CMS is a small-footprint colour management engine, with special + (name "lcms") + (version "2.13.1") + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/lcms/lcms/" + (version-major+minor version) + "/lcms2-" version ".tar.gz")) + (sha256 + (base32 + "121v414bg2zk0fcwx0kigr2l6nxl88nmblfn3gq5lz5jwybffwyl")))) + (build-system gnu-build-system) + (arguments + '(#:configure-flags '("--disable-static"))) + (inputs + (list libjpeg-turbo libtiff zlib)) + (synopsis "Little CMS, a small-footprint colour management engine") + (description + "Little CMS is a small-footprint colour management engine, with special focus on accuracy and performance. It uses the International Color Consortium standard (ICC), approved as ISO 15076-1.") - (license license:x11) - (home-page "https://www.littlecms.com/") - (properties '((cpe-name . "little_cms_color_engine"))))) + (license license:x11) + (home-page "https://www.littlecms.com/") + (properties '((cpe-name . "little_cms_color_engine"))))) (define-public libpaper (package - (name "libpaper") - (version "1.1.24") - (source (origin - (method url-fetch) - (uri (string-append - ;; Debian moved their libpaper-1.1.24 to archive.debian.net - ;; but in the move the hash of their tarball changed. - "http://pkgs.fedoraproject.org/repo/pkgs/libpaper/libpaper_" - version ".tar.gz/5bc87d494ba470aba54f6d2d51471834/libpaper_" - version ".tar.gz")) - (sha256 (base32 - "0zhcx67afb6b5r936w5jmaydj3ks8zh83n9rm5sv3m3k8q8jib1q")))) - (build-system gnu-build-system) - (native-inputs - (list automake)) ; For up to date 'config.guess' and 'config.sub'. - (arguments - `(#:configure-flags '("--disable-static") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-configure - (lambda* (#:key inputs native-inputs #:allow-other-keys) - ;; Replace outdated config.sub and config.guess: - (for-each (lambda (file) - (install-file - (string-append (assoc-ref - (or native-inputs inputs) "automake") - "/share/automake-" - ,(version-major+minor - (package-version automake)) - "/" file) ".")) - '("config.sub" "config.guess")) - #t))))) - (synopsis "Library for handling paper sizes") - (description - "The paper library and accompanying files are intended to provide a simple + (name "libpaper") + (version "2.0.0") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/rrthomas/libpaper/releases" + "/download/v" version "/libpaper-" + version ".tar.gz")) + (sha256 + (base32 + "0aipyaqp30cn919j7w5wvlgkw0v4aqsax82i2zw4wmgck8g6ax77")))) + (build-system gnu-build-system) + (native-inputs + (list help2man)) + (arguments + '(#:configure-flags '("--disable-static" + ;; Tests require a relocatable build. + "--enable-relocatable"))) + (outputs '("out" "debug")) + (home-page "https://github.com/rrthomas/libpaper") + (synopsis "Library for handling paper sizes") + (description + "The paper library and accompanying files are intended to provide a simple way for applications to take actions based on a system- or user-specified paper size.") - (license license:gpl2) - (home-page "https://packages.qa.debian.org/libp/libpaper.html"))) + ;; The library is LGPL3+, everything else GPL3+. + (license (list license:lgpl3+ license:gpl3+)))) (define-public psutils (package - (name "psutils") - (version "17") - (source (origin - (method url-fetch) - (uri "ftp://ftp.knackered.org/pub/psutils/psutils.tar.gz") - (sha256 (base32 - "1r4ab1fvgganm02kmm70b2r1azwzbav2am41gbigpa2bb1wynlrq")))) - (build-system gnu-build-system) - (inputs (list perl)) - (arguments - `(#:tests? #f ; none provided - #:phases - (modify-phases %standard-phases - (replace 'configure - (lambda* (#:key inputs outputs #:allow-other-keys #:rest args) - (let ((perl (assoc-ref inputs "perl")) - (out (assoc-ref outputs "out"))) - (copy-file "Makefile.unix" "Makefile") - (substitute* "Makefile" - (("/usr/local/bin/perl") (string-append perl "/bin/perl"))) - (substitute* "Makefile" - (("/usr/local") out)) - ;; for the install phase - (substitute* "Makefile" - (("-mkdir") "mkdir -p")) - ;; drop installation of non-free files - (substitute* "Makefile" - ((" install.include") ""))) - #t))))) - (synopsis "Collection of utilities for manipulating PostScript documents") - (description - "PSUtils is a collection of utilities for manipulating PostScript + (name "psutils") + (version "2.09") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/rrthomas/psutils/releases" + "/download/v" version "/psutils-" + version ".tar.gz")) + (sha256 + (base32 + "1nmp0hb7c4a315vv1mqw2cbckvca8bzh1cv3gdvwwy24w9qba6p3")))) + (build-system gnu-build-system) + (inputs (list perl)) + (native-inputs + (list libpaper)) + (arguments + (list #:tests? #f ;FIXME: requires files not present in tarball + #:configure-flags + ;; Help the build system locate Perl when cross-compiling. + (if (%current-target-system) + #~(list (string-append "ac_cv_path_PERL=" + (search-input-file %build-inputs "bin/perl"))) + #~'()))) + (synopsis "Collection of utilities for manipulating PostScript documents") + (description + "PSUtils is a collection of utilities for manipulating PostScript documents. Programs included are psnup, for placing out several logical pages on a single sheet of paper, psselect, for selecting pages from a document, pstops, for general imposition, psbook, for signature generation for booklet printing, and psresize, for adjusting page sizes.") - (license (license:non-copyleft "file://LICENSE" - "See LICENSE in the distribution.")) - (home-page "http://knackered.org/angus/psutils/"))) + (home-page "https://github.com/rrthomas/psutils") + (license (list license:gpl3+ + ;; This file carries the "historical" psutils license (v1), + ;; which is "effectively BSD 3-clause" (a quote from the file). + (license:non-copyleft + "file://extractres.in.in" + "See extractres.in.in in the distribution."))))) (define-public ghostscript (package (name "ghostscript") - (version "9.54.0") + (version "9.56.1") (source - (origin - (method url-fetch) - (uri (string-append "https://github.com/ArtifexSoftware/" - "ghostpdl-downloads/releases/download/gs" - (string-delete #\. version) - "/ghostscript-" version ".tar.xz")) - (sha256 - (base32 - "0fvfvv6di5s6j4sy4gaw65klm23dby39bkdjxxq4w3v0vqyb9dy2")) - (patches (search-patches "ghostscript-no-header-creationdate.patch" - "ghostscript-no-header-id.patch" - "ghostscript-no-header-uuid.patch")) - (modules '((guix build utils))) - (snippet - ;; Remove bundled libraries. The bundled OpenJPEG is a patched fork so - ;; we leave it, at least for now. - ;; TODO Try unbundling ijs, which is developed alongside Ghostscript. - ;; Likewise for the thread-safe lcms2 fork called "lcms2art". - '(begin - (for-each delete-file-recursively '("freetype" "jbig2dec" "jpeg" - "libpng" "tiff" "zlib")) - #t)))) + (origin + (method url-fetch) + (uri (string-append "https://github.com/ArtifexSoftware/" + "ghostpdl-downloads/releases/download/gs" + (string-delete #\. version) + "/ghostscript-" version ".tar.xz")) + (sha256 + (base32 + "1r5qash65m6ignki6z72q4rlai9ka99xrxnmqd19n02has00cd6l")) + (patches (search-patches "ghostscript-no-header-creationdate.patch" + "ghostscript-no-header-id.patch" + "ghostscript-no-header-uuid.patch")) + (modules '((guix build utils))) + (snippet + ;; Remove bundled libraries. The bundled OpenJPEG is a patched fork so + ;; we leave it, at least for now. + ;; TODO Try unbundling ijs, which is developed alongside Ghostscript. + ;; Likewise for the thread-safe lcms2 fork called "lcms2art". + '(begin + (for-each delete-file-recursively '("freetype" "jbig2dec" "jpeg" + "libpng" "tiff" "zlib")))))) (build-system gnu-build-system) - (outputs '("out" "doc")) ;19 MiB of HTML/PS doc + examples + (outputs '("out" "doc")) ;19 MiB of HTML/PS doc + examples (arguments - `(#:disallowed-references ("doc") - ;; XXX: Starting with version 9.27, building the tests in parallel - ;; occasionally fails like this: - ;; In file included from ./base/memory_.h:23:0, - ;; from ./obj/gsmd5.h:1, - ;; from ./obj/gsmd5.c:56: - ;; ./base/std.h:25:10: fatal error: arch.h: No such file or directory - #:parallel-tests? #f - #:configure-flags - (list (string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - "--with-system-libtiff" - "LIBS=-lz" - (string-append "ZLIBDIR=" - (assoc-ref %build-inputs "zlib") "/include") - "--enable-dynamic" - "--disable-compile-inits" - (string-append "--with-fontpath=" - (assoc-ref %build-inputs "font-ghostscript") - "/share/fonts/type1/ghostscript") + (list + #:disallowed-references '("doc") + #:configure-flags + #~(list (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib") + "--with-system-libtiff" + "LIBS=-lz" + (string-append "ZLIBDIR=" + (dirname (search-input-file %build-inputs + "include/zlib.h"))) + "--enable-dynamic" + "--disable-compile-inits" + (string-append "--with-fontpath=" + (search-input-directory + %build-inputs + "share/fonts/type1/ghostscript")) - ,@(if (%current-target-system) - '(;; Specify the native compiler, which is used to build 'echogs' - ;; and other intermediary tools when cross-compiling; see - ;; <https://ghostscript.com/FAQ.html>. - "CCAUX=gcc" + #$@(if (%current-target-system) + '(;; Specify the native compiler, which is used to build 'echogs' + ;; and other intermediary tools when cross-compiling; see + ;; <https://ghostscript.com/FAQ.html>. + "CCAUX=gcc" - ;; Save 'config.log' etc. of the native build under - ;; auxtmp/, useful for debugging. - "--enable-save_confaux") - '())) - #:phases - (modify-phases %standard-phases - (add-before 'configure 'create-output-directory - (lambda* (#:key outputs #:allow-other-keys) - ;; The configure script refuses to function if the directory - ;; specified as -rpath does not already exist. - (mkdir-p (string-append (assoc-ref outputs "out") "/lib")) - #t)) - (add-after 'configure 'remove-doc-reference - (lambda _ - ;; Don't retain a reference to the 'doc' output in 'gs'. - ;; The only use of this definition is in the output of - ;; 'gs --help', so this change is fine. - (substitute* "base/gscdef.c" - (("GS_DOCDIR") - "\"~/.guix-profile/share/doc/ghostscript\"")) - #t)) - (add-after 'configure 'patch-config-files - (lambda _ - (substitute* "base/unixhead.mak" - (("/bin/sh") (which "sh"))) - #t)) - ,@(if (%current-target-system) - `((add-after 'configure 'add-native-lz - (lambda _ - ;; Add missing '-lz' for native tools such as 'mkromfs'. - (substitute* "Makefile" - (("^AUXEXTRALIBS=(.*)$" _ value) - (string-append "AUXEXTRALIBS = -lz " value "\n"))) - #t))) - '()) - (replace 'build - (lambda _ - ;; Build 'libgs.so', but don't build the statically-linked 'gs' - ;; binary (saves 22 MiB). - (invoke "make" "so" "-j" - (number->string (parallel-job-count))))) - (replace 'install - (lambda _ - (invoke "make" "soinstall"))) - (add-after 'install 'create-gs-symlink - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - ;; Some programs depend on having a 'gs' binary available. - (symlink "gsc" (string-append out "/bin/gs")) - #t)))))) + ;; Save 'config.log' etc. of the native build under + ;; auxtmp/, useful for debugging. + "--enable-save_confaux") + '())) + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'create-output-directory + (lambda _ + ;; The configure script refuses to function if the directory + ;; specified as -rpath does not already exist. + (mkdir-p (string-append #$output "/lib")))) + (add-after 'configure 'remove-doc-reference + (lambda _ + ;; Don't retain a reference to the 'doc' output in 'gs'. + ;; The only use of this definition is in the output of + ;; 'gs --help', so this change is fine. + (substitute* "base/gscdef.c" + (("GS_DOCDIR") + "\"~/.guix-profile/share/doc/ghostscript\"")))) + (add-after 'configure 'patch-config-files + (lambda _ + (substitute* "base/unixhead.mak" + (("/bin/sh") (which "sh"))))) + #$@(if (%current-target-system) + '((add-after 'configure 'add-native-lz + (lambda _ + ;; Add missing '-lz' for native tools such as 'mkromfs'. + (substitute* "Makefile" + (("^AUXEXTRALIBS=(.*)$" _ value) + (string-append "AUXEXTRALIBS = -lz " value "\n")))))) + '()) + (replace 'build + (lambda _ + ;; Build 'libgs.so', but don't build the statically-linked 'gs' + ;; binary (saves 22 MiB). + (invoke "make" "so" "-j" + (number->string (parallel-job-count))))) + (replace 'install + (lambda _ + (invoke "make" "soinstall"))) + (add-after 'install 'create-gs-symlink + (lambda _ + ;; Some programs depend on having a 'gs' binary available. + (symlink "gsc" (string-append #$output "/bin/gs"))))))) (native-inputs - `(("perl" ,perl) - ("pkg-config" ,pkg-config) ;needed for freetype - ("python" ,python-minimal-wrapper) - ("tcl" ,tcl) - - ;; When cross-compiling, some of the natively-built tools require all - ;; these libraries. - ,@(if (%current-target-system) - `(("zlib/native" ,zlib) - ("libjpeg/native" ,libjpeg-turbo)) - '()))) + (append + (list perl + pkg-config ;needed for freetype + python-minimal-wrapper + tcl) + ;; When cross-compiling, some of the natively-built tools require all + ;; these libraries. + (if (%current-target-system) + (list zlib libjpeg-turbo) + '()))) (inputs - `(("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("font-ghostscript" ,font-ghostscript) - ("jbig2dec" ,jbig2dec) - ("libjpeg" ,libjpeg-turbo) - ("libpaper" ,libpaper) - ("libpng" ,libpng) - ("libtiff" ,libtiff) - ("zlib" ,zlib))) + (list fontconfig + freetype + font-ghostscript + jbig2dec + libjpeg-turbo + libpaper + libpng + libtiff + zlib)) (synopsis "PostScript and PDF interpreter") (description "Ghostscript is an interpreter for the PostScript language and the PDF @@ -296,15 +269,14 @@ output file formats and printers.") (define-public ghostscript/x (package/inherit ghostscript (name (string-append (package-name ghostscript) "-with-x")) - (inputs `(("libxext" ,libxext) - ("libxt" ,libxt) - ,@(package-inputs ghostscript))))) + (inputs (modify-inputs (package-inputs ghostscript) + (prepend libxext libxt))))) (define-public ghostscript/cups (package/inherit ghostscript (name "ghostscript-with-cups") - (inputs `(("cups" ,cups-minimal) - ,@(package-inputs ghostscript))))) + (inputs (modify-inputs (package-inputs ghostscript) + (prepend cups-minimal))))) (define-public ijs (package @@ -400,14 +372,14 @@ Ghostscript. It currently includes the 35 standard PostScript fonts.") (define-public libspectre (package (name "libspectre") - (version "0.2.9") + (version "0.2.10") (source (origin (method url-fetch) (uri (string-append "https://libspectre.freedesktop.org/releases" "/libspectre-" version ".tar.gz")) (sha256 (base32 - "1vgvxp77d5d9chhx4i9cv9hifw4x10jgw6aw8l2v90dgnm99rbj9")))) + "01sdaakrv5js8r6gj2r1ankyl304161z060f25mrmz3b1ylb4q6g")))) (build-system gnu-build-system) (inputs (list ghostscript)) (native-inputs (list pkg-config)) diff --git a/gnu/packages/gimp.scm b/gnu/packages/gimp.scm index af5adb8bfd..73102e30cf 100644 --- a/gnu/packages/gimp.scm +++ b/gnu/packages/gimp.scm @@ -333,7 +333,7 @@ buffers.") ;; ./configure requests not to annoy upstream with packaging bugs. "--with-bug-report-url=https://bugs.gnu.org/guix"))) (inputs - (list atk + (list at-spi2-core babl gegl gexiv2 diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index fd69e6dbeb..3a63d70c7a 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2014, 2015, 2016, 2017 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2016 Nikita <nikita@n0.is> ;;; Copyright © 2016, 2017, 2018, 2020, 2021 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2017, 2018, 2019, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017-2019, 2021, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com> ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr> @@ -15,7 +15,7 @@ ;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2020 Kei Kebreau <kkebreau@posteo.net> ;;; Copyright © 2021 Ivan Gankevich <i.gankevich@spbu.ru> -;;; Copyright © 2021 John Kehayias <john.kehayias@protonmail.com> +;;; Copyright © 2021, 2022 John Kehayias <john.kehayias@protonmail.com> ;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com> ;;; ;;; This file is part of GNU Guix. @@ -266,7 +266,7 @@ also known as DXTn or DXTC) for Mesa.") (define-public mesa (package (name "mesa") - (version "21.3.8") + (version "22.2.4") (source (origin (method url-fetch) @@ -278,61 +278,61 @@ also known as DXTn or DXTC) for Mesa.") version "/mesa-" version ".tar.xz"))) (sha256 (base32 - "19wx5plk6z0hhi0zdzxjx8ynl3lhlc5mbd8vhwqyk92kvhxjf3g7")) + "1azpr68pdg63yq3igmzwsgn2ypg49m0mp3hfkq0lcyswr99npmv5")) (patches - (search-patches "mesa-skip-tests.patch")))) + (list (search-patch "mesa-fix-sporadic-test-failures.patch"))))) (build-system meson-build-system) (propagated-inputs - (list ;; The following are in the Requires.private field of gl.pc. - libdrm - libvdpau - libx11 - libxdamage - libxfixes - libxshmfence - libxxf86vm - xorgproto)) + ;; The following are in the Requires.private field of gl.pc. + (list libdrm + libvdpau + libx11 + libxdamage + libxfixes + libxshmfence + libxxf86vm + xorgproto)) (inputs - (append (list expat - elfutils ;libelf required for r600 when using llvm - (force libva-without-mesa) - libxml2 - libxrandr - libxvmc - wayland - wayland-protocols) - ;; TODO: Resort alphabetically. - ;; Note: update the 'clang' input of mesa-opencl when bumping this. - (list llvm-11))) + (list elfutils ;libelf required for r600 when using llvm + expat + (force libva-without-mesa) + libxml2 + libxrandr + libxvmc + llvm-for-mesa + wayland + wayland-protocols)) (native-inputs - (append (list bison - flex - gettext-minimal - pkg-config - python-wrapper - python-libxml2 ;for OpenGL ES 1.1 and 2.0 support - python-mako - (@ (gnu packages base) which)) - ;; TODO: Resort alphabetically. - (list glslang))) + (list bison + flex + gettext-minimal + glslang + pkg-config + python-libxml2 ;for OpenGL ES 1.1 and 2.0 support + python-mako + python-wrapper + (@ (gnu packages base) which))) (outputs '("out" "bin")) (arguments `(#:configure-flags '(,@(match (%current-system) ("aarch64-linux" ;; TODO: Fix svga driver for non-Intel architectures. - '("-Dgallium-drivers=etnaviv,freedreno,kmsro,lima,nouveau,panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl")) + '("-Dgallium-drivers=etnaviv,freedreno,kmsro,lima,nouveau,\ +panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl")) ("armhf-linux" ;; Freedreno FTBFS when built on a 64-bit machine. - '("-Dgallium-drivers=etnaviv,kmsro,lima,nouveau,panfrost,r300,r600,swrast,tegra,v3d,vc4,virgl")) + '("-Dgallium-drivers=etnaviv,kmsro,lima,nouveau,panfrost,\ +r300,r600,swrast,tegra,v3d,vc4,virgl")) ((or "powerpc64le-linux" "powerpc-linux" "riscv64-linux") '("-Dgallium-drivers=nouveau,r300,r600,radeonsi,swrast,virgl")) (_ - '("-Dgallium-drivers=iris,nouveau,r300,r600,radeonsi,svga,swrast,virgl"))) + '("-Dgallium-drivers=iris,nouveau,r300,r600,radeonsi,\ +svga,swrast,virgl"))) ;; Enable various optional features. TODO: opencl requires libclc, ;; omx requires libomxil-bellagio "-Dplatforms=x11,wayland" - "-Dglx=dri" ;Thread Local Storage, improves performance + "-Dglx=dri" ;Thread Local Storage, improves performance ;; "-Dopencl=true" ;; "-Domx=true" "-Dosmesa=true" @@ -362,15 +362,7 @@ also known as DXTn or DXTC) for Mesa.") ;; Also enable the tests. "-Dbuild-tests=true" - ;; on non-intel systems, drop i915 and i965 - ;; from the default dri drivers - ,@(match (%current-system) - ((or "x86_64-linux" "i686-linux") - '("-Ddri-drivers=i915,i965,nouveau,r200,r100")) - (_ - '("-Ddri-drivers=nouveau,r200,r100"))) - - "-Dllvm=enabled") ; default is x86/x86_64 only + "-Dllvm=enabled") ; default is x86/x86_64 only ;; XXX: 'debugoptimized' causes LTO link failures on some drivers. The ;; documentation recommends using 'release' for performance anyway. @@ -419,10 +411,10 @@ also known as DXTn or DXTC) for Mesa.") (substitute* "src/amd/common/meson.build" (("and not with_platform_windows") "and with_platform_windows")))) ("i686-linux" - ;; Disable new test from Mesa 19 that fails on i686. Upstream - ;; report: <https://bugs.freedesktop.org/show_bug.cgi?id=110612>. - `((substitute* "src/util/tests/format/meson.build" - (("'u_format_test',") "")))) + ;; This test is known to fail on i686 (see: + ;; https://gitlab.freedesktop.org/mesa/mesa/-/issues/4091). + `((substitute* "src/util/meson.build" + ((".*'tests/u_debug_stack_test.cpp',.*") "")))) ("aarch64-linux" ;; The ir3_disasm test segfaults. ;; The simplest way to skip it is to run a different test instead. @@ -521,7 +513,7 @@ from software emulation to complete hardware acceleration for modern GPUs.") (prepend libclc))) (native-inputs (modify-inputs (package-native-inputs mesa) - (prepend clang-11))))) + (prepend clang-15))))) (define-public mesa-opencl-icd (package/inherit mesa-opencl @@ -565,8 +557,7 @@ from software emulation to complete hardware acceleration for modern GPUs.") (lambda* (#:key outputs #:allow-other-keys) (copy-recursively "include" (string-append (assoc-ref outputs "out") - "/include")) - #t))))))) + "/include"))))))))) ;;; The mesa-demos distribution contains non-free files, many files with no ;;; clear license information, and many demos that aren't useful for most diff --git a/gnu/packages/glib.scm b/gnu/packages/glib.scm index f85d5e3225..6327d0c8b1 100644 --- a/gnu/packages/glib.scm +++ b/gnu/packages/glib.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2017 Petter <petter@mykolab.ch> ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com> -;;; Copyright © 2019, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2019, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org> ;;; Copyright © 2019, 2020, 2021 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz> @@ -103,15 +103,15 @@ (define dbus (package (name "dbus") - (version "1.12.20") + (version "1.14.0") (source (origin (method url-fetch) (uri (string-append "https://dbus.freedesktop.org/releases/dbus/dbus-" - version ".tar.gz")) + version ".tar.xz")) (sha256 (base32 - "1zp5gpx61v1cpqf2zwb1cidhp9xylvw49d3zydkxqk6b1qa20xpp")) + "1m7bibavml4gx9d67j403l0kzd1a4z8lhrpxb2as3q4nfpiwrmyc")) (patches (search-patches "dbus-helper-search-path.patch")))) (build-system gnu-build-system) (arguments @@ -215,7 +215,7 @@ information, refer to the @samp{dbus-daemon(1)} man page."))) (define glib (package (name "glib") - (version "2.70.2") + (version "2.72.3") (source (origin (method url-fetch) @@ -224,7 +224,7 @@ information, refer to the @samp{dbus-daemon(1)} man page."))) name "/" (string-take version 4) "/" name "-" version ".tar.xz")) (sha256 - (base32 "0vw08p4jllavp9qmlqg1yl1zanmy53yid46wipas6gfdhnf4al85")) + (base32 "1w25sf2wxkkah2p2w189q58mza3zv8z1fh2q1m82sldq4kva4faa")) (patches (search-patches "glib-appinfo-watch.patch" "glib-skip-failing-test.patch")) @@ -239,127 +239,122 @@ information, refer to the @samp{dbus-daemon(1)} man page."))) "bin" ;executables; depends on Python "debug")) (arguments - `(#:disallowed-references - (,tzdata-for-tests - ;; Verify glib-mkenums, gtester, ... use the cross-compiled - ;; python. - ,@(if (%current-target-system) - (map (cut gexp-input <> #:native? #t) - `(,(this-package-native-input "python") - ,(this-package-native-input "python-wrapper"))) - '())) - #:configure-flags ,#~(list "--default-library=both" - "-Dman=false" - "-Dselinux=disabled" - (string-append "--bindir=" - #$output:bin "/bin")) - #:phases - (modify-phases %standard-phases - ;; Needed to pass the test phase on slower ARM and i686 machines. - (add-after 'unpack 'increase-test-timeout - (lambda _ - (substitute* "meson.build" - (("(test_timeout.*) = ([[:digit:]]+)" all first second) - (string-append first " = " second "0"))))) - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "gio/tests/meson.build" - ((".*'testfilemonitor'.*") ;marked as flaky - "")) - (with-directory-excursion "glib/tests" - (substitute* '("unix.c" "utils.c") - (("[ \t]*g_test_add_func.*;") ""))) - (with-directory-excursion "gio/tests" - (substitute* '("contenttype.c" "gdbus-address-get-session.c" - "gdbus-peer.c" "appinfo.c" "desktop-app-info.c") - (("[ \t]*g_test_add_func.*;") ""))) + (list + #:disallowed-references + (cons tzdata-for-tests + ;; Verify glib-mkenums, gtester, ... use the cross-compiled + ;; python. + (if (%current-target-system) + (map (cut gexp-input <> #:native? #t) + `(,(this-package-native-input "python") + ,(this-package-native-input "python-wrapper"))) + '())) + #:configure-flags #~(list "--default-library=both" + "-Dman=false" + "-Dselinux=disabled" + (string-append "--bindir=" + #$output:bin "/bin")) + #:phases + #~(modify-phases %standard-phases + ;; Needed to pass the test phase on slower ARM and i686 machines. + (add-after 'unpack 'increase-test-timeout + (lambda _ + (substitute* "meson.build" + (("(test_timeout.*) = ([[:digit:]]+)" all first second) + (string-append first " = " second "0"))))) + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "gio/tests/meson.build" + ((".*'testfilemonitor'.*") ;marked as flaky + "")) + (with-directory-excursion "glib/tests" + (substitute* '("unix.c" "utils.c") + (("[ \t]*g_test_add_func.*;") ""))) + (with-directory-excursion "gio/tests" + (substitute* '("contenttype.c" "gdbus-address-get-session.c" + "gdbus-peer.c" "appinfo.c" "desktop-app-info.c") + (("[ \t]*g_test_add_func.*;") ""))) - ,@(if (target-x86-32?) - ;; Comment out parts of timer.c that fail on i686 due to - ;; excess precision when building with GCC 10: - ;; <https://gitlab.gnome.org/GNOME/glib/-/issues/820>. - '((substitute* "glib/tests/timer.c" - (("^ g_assert_cmpuint \\(micros.*" all) - (string-append "//" all "\n")) - (("^ g_assert_cmpfloat \\(elapsed, ==.*" all) - (string-append "//" all "\n")))) - '()))) - ;; Python references are not being patched in patch-phase of build, - ;; despite using python-wrapper as input. So we patch them manually. - ;; - ;; These python scripts are both used during build and installed, - ;; so at first, use a python from 'native-inputs', not 'inputs'. When - ;; cross-compiling, the 'patch-shebangs' phase will replace - ;; the native python with a python from 'inputs'. - (add-after 'unpack 'patch-python-references - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (substitute* '("gio/gdbus-2.0/codegen/gdbus-codegen.in" - "glib/gtester-report.in" - "gobject/glib-genmarshal.in" - "gobject/glib-mkenums.in") - (("@PYTHON@") - (search-input-file (or native-inputs inputs) - (string-append - "/bin/python" - ,(version-major+minor - (package-version python)))))))) - (add-before 'check 'pre-check - (lambda* (#:key native-inputs inputs outputs #:allow-other-keys) - ;; For tests/gdatetime.c. - (setenv "TZDIR" - (search-input-directory (or native-inputs inputs) - "share/zoneinfo")) - ;; Some tests want write access there. - (setenv "HOME" (getcwd)) - (setenv "XDG_CACHE_HOME" (getcwd)))) - (add-after 'install 'move-static-libraries - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (static (assoc-ref outputs "static"))) - (mkdir-p (string-append static "/lib")) - (for-each (lambda (a) - (rename-file a (string-append static "/lib/" - (basename a)))) - (find-files out "\\.a$"))))) - (add-after 'install 'patch-pkg-config-files - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - ;; Do not refer to "bindir", which points to "${prefix}/bin". - ;; We don't patch "bindir" to point to "$bin/bin", because that - ;; would create a reference cycle between the "out" and "bin" - ;; outputs. - (substitute* - (list - (string-append out "/lib/pkgconfig/gio-2.0.pc") - (string-append out "/lib/pkgconfig/glib-2.0.pc")) - (("^bindir=.*") - "") - (("=\\$\\{bindir\\}/") - "=")))))))) + #$@(if (target-x86-32?) + ;; Comment out parts of timer.c that fail on i686 due to + ;; excess precision when building with GCC 10: + ;; <https://gitlab.gnome.org/GNOME/glib/-/issues/820>. + '((substitute* "glib/tests/timer.c" + (("^ g_assert_cmpuint \\(micros.*" all) + (string-append "//" all "\n")) + (("^ g_assert_cmpfloat \\(elapsed, ==.*" all) + (string-append "//" all "\n")))) + '()))) + ;; Python references are not being patched in patch-phase of build, + ;; despite using python-wrapper as input. So we patch them manually. + ;; + ;; These python scripts are both used during build and installed, + ;; so at first, use a python from 'native-inputs', not 'inputs'. When + ;; cross-compiling, the 'patch-shebangs' phase will replace + ;; the native python with a python from 'inputs'. + (add-after 'unpack 'patch-python-references + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (substitute* '("gio/gdbus-2.0/codegen/gdbus-codegen.in" + "glib/gtester-report.in" + "gobject/glib-genmarshal.in" + "gobject/glib-mkenums.in") + (("@PYTHON@") + (search-input-file (or native-inputs inputs) + (string-append + "/bin/python" + #$(version-major+minor + (package-version python)))))))) + (add-before 'check 'pre-check + (lambda* (#:key native-inputs inputs outputs #:allow-other-keys) + ;; For tests/gdatetime.c. + (setenv "TZDIR" + (search-input-directory (or native-inputs inputs) + "share/zoneinfo")) + ;; Some tests want write access there. + (setenv "HOME" (getcwd)) + (setenv "XDG_CACHE_HOME" (getcwd)))) + (add-after 'install 'move-static-libraries + (lambda _ + (mkdir-p (string-append #$output:static "/lib")) + (for-each (lambda (a) + (rename-file a (string-append #$output:static "/lib/" + (basename a)))) + (find-files #$output "\\.a$")))) + (add-after 'install 'patch-pkg-config-files + (lambda* (#:key outputs #:allow-other-keys) + ;; Do not refer to "bindir", which points to "${prefix}/bin". + ;; We don't patch "bindir" to point to "$bin/bin", because that + ;; would create a reference cycle between the "out" and "bin" + ;; outputs. + (substitute* + (list (search-input-file outputs "lib/pkgconfig/gio-2.0.pc") + (search-input-file outputs "lib/pkgconfig/glib-2.0.pc")) + (("^bindir=.*") + "") + (("=\\$\\{bindir\\}/") + "="))))))) (native-inputs - `(("gettext" ,gettext-minimal) - ("m4" ,m4) ; for installing m4 macros - ("perl" ,perl) ; needed by GIO tests - ("pkg-config" ,pkg-config) - ("python" ,python) ; For 'patch-python-references - ("python-wrapper" ,python-wrapper) - ("tzdata" ,tzdata-for-tests))) ; for tests/gdatetime.c - (inputs - (list bash-completion - ;; "python", "python-wrapper" and "bash-minimal" - ;; are for the 'patch-shebangs' phase, to make - ;; sure the installed scripts end up with a correct shebang - ;; when cross-compiling. - python + (list dbus + gettext-minimal + m4 ;for installing m4 macros + perl ;needed by GIO tests + pkg-config + python ;for 'patch-python-references python-wrapper - bash-minimal - dbus - libelf)) + tzdata-for-tests)) ;for tests/gdatetime.c + (inputs + (list ;; "python", "python-wrapper" and "bash-minimal" + ;; are for the 'patch-shebangs' phase, to make + ;; sure the installed scripts end up with a correct shebang + ;; when cross-compiling. + bash-minimal + python + python-wrapper)) (propagated-inputs - (list libffi ; in the Requires.private field of gobject-2.0.pc - pcre ; in the Requires.private field of glib-2.0.pc - `(,util-linux "lib") ;for libmount - zlib)) ; in the Requires.private field of glib-2.0.pc + (list libffi ;in the Requires.private field of gobject-2.0.pc + pcre ;in the Requires.private field of glib-2.0.pc + `(,util-linux "lib") ;for libmount + zlib)) ;in the Requires.private field of glib-2.0.pc (native-search-paths ;; This variable is not really "owned" by GLib, but several related ;; packages refer to it: gobject-introspection's tools use it as a search @@ -405,35 +400,35 @@ functions for strings and common data structures.") ((#:test-options test-options ''()) ;; Skip flaky or slow tests. `(cons* "--no-suite=slow" "--no-suite=flaky" ,test-options)) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (replace 'disable-failing-tests - (lambda _ - (with-directory-excursion "glib/tests" - (substitute* '("unix.c" "utils.c") - (("[ \t]*g_test_add_func.*;") ""))) - ;; The "glib:gio / file" test fails with the error "No - ;; application is registered as handling this file" (see: - ;; https://gitlab.gnome.org/GNOME/glib/-/issues/2742). - (with-directory-excursion "gio/tests" - (substitute* '("appinfo.c" - "contenttype.c" - "desktop-app-info.c" - "file.c" - "gdbus-address-get-session.c" - "gdbus-peer.c") - (("[ \t]*g_test_add_func.*;") ""))) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'disable-failing-tests + (lambda _ + (with-directory-excursion "glib/tests" + (substitute* '("unix.c" "utils.c") + (("[ \t]*g_test_add_func.*;") ""))) + ;; The "glib:gio / file" test fails with the error "No + ;; application is registered as handling this file" (see: + ;; https://gitlab.gnome.org/GNOME/glib/-/issues/2742). + (with-directory-excursion "gio/tests" + (substitute* '("appinfo.c" + "contenttype.c" + "desktop-app-info.c" + "file.c" + "gdbus-address-get-session.c" + "gdbus-peer.c") + (("[ \t]*g_test_add_func.*;") ""))) - ,@(if (target-x86-32?) - ;; Comment out parts of timer.c that fail on i686 due to - ;; excess precision when building with GCC 10: - ;; <https://gitlab.gnome.org/GNOME/glib/-/issues/820>. - '((substitute* "glib/tests/timer.c" - (("^ g_assert_cmpuint \\(micros.*" all) - (string-append "//" all "\n")) - (("^ g_assert_cmpfloat \\(elapsed, ==.*" all) - (string-append "//" all "\n")))) - '()))))))) + #$@(if (target-x86-32?) + ;; Comment out parts of timer.c that fail on i686 due to + ;; excess precision when building with GCC 10: + ;; <https://gitlab.gnome.org/GNOME/glib/-/issues/820>. + '((substitute* "glib/tests/timer.c" + (("^ g_assert_cmpuint \\(micros.*" all) + (string-append "//" all "\n")) + (("^ g_assert_cmpfloat \\(elapsed, ==.*" all) + (string-append "//" all "\n")))) + '()))))))) (native-inputs (modify-inputs (package-native-inputs glib) (append desktop-file-utils))) @@ -444,44 +439,31 @@ functions for strings and common data structures.") (define-public glib-with-documentation ;; glib's doc must be built in a separate package since it requires gtk-doc, ;; which in turn depends on glib. - (let ((base glib-next)) - (package/inherit base - (properties (alist-delete 'hidden? (package-properties base))) - (outputs (cons "doc" (package-outputs base))) ; 20 MiB of GTK-Doc reference - (native-inputs - `(("docbook-xml-4.2" ,docbook-xml-4.2) - ("docbook-xml-4.5" ,docbook-xml) - ("docbook-xsl" ,docbook-xsl) - ("gtk-doc" ,gtk-doc) - ("libxml2" ,libxml2) - ("xsltproc" ,libxslt) - ,@(package-native-inputs base))) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:configure-flags flags ''()) - #~(cons "-Dgtk_doc=true" - (delete "-Dman=false" #$flags))) - ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.5/") - (string-append (assoc-ref inputs "docbook-xml-4.5") - "/xml/dtd/docbook/")) - (("http://www.oasis-open.org/docbook/xml/4\\.2/") - (string-append (assoc-ref inputs "docbook-xml-4.2") - "/xml/dtd/docbook/")))))) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc")) - (html (string-append "/share/gtk-doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out html) - (string-append doc html)))))))))))) + (package/inherit glib + (properties (alist-delete 'hidden? (package-properties glib))) + (outputs (cons "doc" (package-outputs glib))) ; 20 MiB of GTK-Doc reference + (native-inputs + (modify-inputs (package-native-inputs glib) + (prepend docbook-xml-4.2 + docbook-xml + docbook-xsl + gtk-doc + libxml2 + libxslt))) + (arguments + (substitute-keyword-arguments (package-arguments glib) + ((#:configure-flags flags ''()) + #~(cons "-Dgtk_doc=true" + (delete "-Dman=false" #$flags))) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'install 'move-doc + (lambda _ + (let ((html "/share/gtk-doc")) + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output html) + (string-append #$output:doc html))))))))))) (define (python-extension-suffix python triplet) "Determine the suffix for C extensions for PYTHON when compiled @@ -522,14 +504,14 @@ be used when cross-compiling." (define gobject-introspection (package (name "gobject-introspection") - (version "1.66.1") + (version "1.72.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" "gobject-introspection/" (version-major+minor version) "/gobject-introspection-" version ".tar.xz")) (sha256 - (base32 "078n0q7b6z682mf4irclrksm73cyixq295mqnqifl9plwmgaai6x")) + (base32 "1g5aps3b20ck96ahy7fjl4nhp9nabkd9rlqd0s1qzn3111cqxzh2")) (patches (search-patches "gobject-introspection-cc.patch" "gobject-introspection-girepository.patch" @@ -578,11 +560,7 @@ be used when cross-compiling." ("bison" ,bison) ("flex" ,flex))) (inputs - `(,@(if (%current-target-system) - `(("python" ,python)) - `(("bison" ,bison) - ("flex" ,flex) - ("python" ,python-wrapper))) + `(("python" ,python) ("zlib" ,zlib))) (propagated-inputs (list glib @@ -682,27 +660,25 @@ The intltool collection can be used to do these things: (define itstool (package (name "itstool") - (version "2.0.6") + (version "2.0.7") (source (origin (method url-fetch) (uri (string-append "http://files.itstool.org/itstool/itstool-" version ".tar.bz2")) (sha256 (base32 - "1acjgf8zlyk7qckdk19iqaca4jcmywd7vxjbcs1mm6kaf8icqcv2")))) + "1jl7gsr7aclb9nvqazr039m86y7f7ivfhl2pixcrbfqjkb97r6kb")))) (build-system gnu-build-system) (inputs (list libxml2 python-libxml2 python)) (arguments - '(#:phases - (modify-phases %standard-phases - (add-after 'install 'wrap-program - (lambda* (#:key outputs #:allow-other-keys) - (let ((prog (string-append (assoc-ref outputs "out") - "/bin/itstool"))) - (wrap-program prog - `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH")))) - #t)))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'wrap-program + (lambda _ + (wrap-program (string-append #$output "/bin/itstool") + `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH"))))))))) (home-page "https://itstool.org") (synopsis "Tool to translate XML documents with PO files") (description @@ -829,55 +805,39 @@ credentials and service-specific settings.") (build-system meson-build-system) (outputs '("out" "doc")) (arguments - `(#:configure-flags - (list - "-Dbuild-documentation=true") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.1\\.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t)) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/doc") - (string-append doc "/share/doc")) - #t)))))) + (list #:configure-flags #~(list "-Dbuild-documentation=true") + #:phases #~(modify-phases %standard-phases + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/doc") + (string-append #$output:doc "/share/doc"))))))) (native-inputs - `(("docbook-xml" ,docbook-xml-4.1.2) - ("docbook-xsl" ,docbook-xsl) - ("dot" ,graphviz) - ("doxygen" ,doxygen) - ("m4" ,m4) - ("mm-common" ,mm-common) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("xmllint" ,libxml2) - ("xsltproc" ,libxslt))) - (inputs - (list boost)) + (list docbook-xml-4.1.2 + docbook-xsl + graphviz + doxygen + m4 + mm-common + perl + pkg-config + libxml2 + libxslt)) + (inputs (list boost)) (home-page "https://libsigcplusplus.github.io/libsigcplusplus/") (synopsis "Type-safe callback system for standard C++") (description "Libsigc++ implements a type-safe callback system for standard C++. It - allows you to define signals and to connect those signals to any callback - function, either global or a member function, regardless of whether it is - static or virtual. - - It also contains adaptor classes for connection of dissimilar callbacks and - has an ease of use unmatched by other C++ callback libraries.") +allows you to define signals and to connect those signals to any callback +function, either global or a member function, regardless of whether it is +static or virtual. It also contains adaptor classes for connection of +dissimilar callbacks and has an ease of use unmatched by other C++ callback +libraries.") (license license:lgpl3+))) - (define-public libsigc++-2 - (package +(define-public libsigc++-2 + (package (inherit libsigc++) (name "libsigc++") (version "2.9.3") @@ -892,30 +852,19 @@ credentials and service-specific settings.") (base32 "0zq963d0sss82q62fdfjs7l9iwbdch51albck18cb631ml0v7y8b")))) (build-system gnu-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.1\\.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t)) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/doc") - (string-append doc "/share/doc")) - #t)))))))) + (list #:phases + #~(modify-phases %standard-phases + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/doc") + (string-append #$output:doc "/share/doc"))))))))) (define glibmm (package (name "glibmm") - (version "2.70.0") + (version "2.72.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/glibmm/" @@ -923,31 +872,29 @@ credentials and service-specific settings.") "/glibmm-" version ".tar.xz")) (sha256 (base32 - "085mzpphz71sh5wh71ppikwnxsgn4pk3s4bzz6ingj6wxn5gs240")))) + "1n2w2pcpbxjbsxynmar3i5ibr7src6gnrdxb9nn57p5miai4jxia")))) (build-system meson-build-system) (outputs '("out" "doc")) (arguments - `(#:configure-flags - (list "-Dbuild-documentation=true") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "tests/meson.build" - ;; This test uses /etc/fstab as an example file to read - ;; from; disable it. - (("[ \t]*.*giomm_simple.*$") "") - ;; This test does a DNS lookup, and then expects to be able - ;; to open a TLS session; just skip it. - (("[ \t]*.*giomm_tls_client.*$") "")))) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/doc") - (string-append doc "/share/doc")))))))) + (list + #:configure-flags #~(list "-Dbuild-documentation=true") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "tests/meson.build" + ;; This test uses /etc/fstab as an example file to read from; + ;; disable it. + (("[ \t]*.*giomm_simple.*$") "") + ;; This test does a DNS lookup, and then expects to be able to + ;; open a TLS session; just skip it. + (("[ \t]*.*giomm_tls_client.*$") "")))) + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/doc") + (string-append #$output:doc "/share/doc"))))))) (native-inputs (list graphviz doxygen @@ -987,7 +934,7 @@ useful for C++.") (define-public python-pygobject (package (name "python-pygobject") - (version "3.40.1") + (version "3.42.2") (source (origin (method url-fetch) @@ -996,7 +943,7 @@ useful for C++.") "/pygobject-" version ".tar.xz")) (sha256 (base32 - "0d80g5kgf2i9cginyhalvb7ibfk9g30yilqzmcsw6h6byj8xbih0")) + "0my95gjnps093inzznbipkhf25cffbc32v9is2fq8wvh59g6ks5d")) (modules '((guix build utils))) (snippet '(begin @@ -1032,6 +979,8 @@ useful for C++.") (synopsis "Python bindings for GObject") (description "Python bindings for GLib, GObject, and GIO.") + (properties + '((upstream-name . "pygobject"))) (license license:lgpl2.1+))) (define-public perl-glib diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 2cb087c987..3cc53f5923 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -73,6 +73,7 @@ ;;; Copyright © 2022 Rene Saavedra <nanuui@protonmail.com> ;;; Copyright © 2022 Alexandros Theodotou <alex@zrythm.org> ;;; Copyright © 2022 Arjan Adriaanse <arjan@adriaan.se> +;;; Copyright © 2023 Kaelyn Takata <kaelyn.alexi@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -259,14 +260,6 @@ #:configure-flags #~(list "-Dgtk_doc=true") #:phases #~(modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* "gupnp-igd-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append #$(this-package-native-input - "docbook-xml") - "/xml/dtd/docbook/")))))) (add-before 'check 'set-home (lambda _ ;; A test using GIO expects ~/.config/glib-2.0/settings to be @@ -285,6 +278,7 @@ gobject-introspection gsettings-desktop-schemas gtk-doc/stable + libxml2 ;for XML_CATALOG_FILES pkg-config)) (propagated-inputs ;; These libraries are required by the .pc file. @@ -373,9 +367,7 @@ features to enable users to create their discs easily and quickly.") "-Denable-gtk-doc=false" "-Dvapigen=false"))) (native-inputs - `(("glib:bin" ,glib "bin") - ("pkg-config" ,pkg-config) - ("vala" ,vala))) + (list `(,glib "bin") pkg-config vala)) (inputs (list glib glib-networking)) (synopsis "Cloudproviders Integration API") @@ -429,27 +421,13 @@ services.") (build-system glib-or-gtk-build-system) (outputs '("out" "doc")) (arguments - `(#:configure-flags - (list - "--enable-gtk-doc" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc/reference" - (substitute* "libgrss-docs.sgml" - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t))))) - (native-inputs - (list docbook-xml-4.1.2 gobject-introspection gtk-doc/stable - pkg-config)) - (propagated-inputs - (list glib libsoup-minimal-2 libxml2)) + (list #:configure-flags + #~(list "--enable-gtk-doc" (string-append "--with-html-dir=" + #$output + "/share/gtk-doc/html")))) + (native-inputs (list docbook-xml-4.1.2 gobject-introspection gtk-doc/stable + pkg-config)) + (propagated-inputs (list glib libsoup-minimal-2 libxml2)) (synopsis "Glib library for feeds") (description "LibGRSS is a Glib abstraction to handle feeds in RSS, Atom, and other formats.") @@ -502,65 +480,52 @@ bindings.") (build-system glib-or-gtk-build-system) (outputs '("out" "doc")) (arguments - `(#:configure-flags - (list - "--disable-static" - "--enable-xorg-module" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html") - "--with-webkit=4.0") - #:phases - (modify-phases %standard-phases - ;; The seed-webkit.patch patches configure.ac. - ;; So the source files need to be re-bootstrapped. - (add-after 'unpack 'trigger-bootstrap - (lambda _ - (for-each delete-file - (list - "configure" - "Makefile.in")) - #t)) - (add-after 'unpack 'patch-tests - (lambda* (#:key outputs #:allow-other-keys) - (substitute* (find-files "." "\\.js$") - (("#!/usr/bin/env seed") - (string-append "#!" (getcwd) "/src/seed"))) - #t)) - (add-before 'build 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* '("reference/seed-docs.sgml" "modules/book.xml") - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t))))) + (list #:configure-flags + #~(list "--disable-static" + "--enable-xorg-module" + (string-append "--with-html-dir=" #$output:doc + "/share/gtk-doc/html") + "--with-webkit=4.0") + #:phases + #~(modify-phases %standard-phases + ;; The seed-webkit.patch patches configure.ac. + ;; So the source files need to be re-bootstrapped. + (add-after 'unpack 'trigger-bootstrap + (lambda _ + (for-each delete-file + (list "configure" + "Makefile.in")))) + (add-after 'unpack 'patch-tests + (lambda* (#:key outputs #:allow-other-keys) + (substitute* (find-files "." "\\.js$") + (("#!/usr/bin/env seed") + (string-append "#!" (getcwd) "/src/seed")))))))) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("docbook-xml" ,docbook-xml-4.1.2) - ("gettext" ,gettext-minimal) - ("gobject-introspection" ,gobject-introspection) - ("gtk-doc" ,gtk-doc/stable) - ("intltool" ,intltool) - ("libtool" ,libtool) - ("pkg-config" ,pkg-config))) + (list autoconf + automake + docbook-xml-4.1.2 + gettext-minimal + gobject-introspection + gtk-doc/stable + intltool + libtool + pkg-config)) (inputs - `(("cairo" ,cairo) - ("dbus" ,dbus) - ("dbus-glib" ,dbus-glib) - ("gnome-js-common" ,gnome-js-common) - ("gtk+" ,gtk+) - ("gtk+-2" ,gtk+-2) - ("libffi" ,libffi) - ("libxml2" ,libxml2) - ("mpfr" ,mpfr) - ("readline" ,readline) - ("sqlite" ,sqlite) - ("xscrnsaver" ,libxscrnsaver))) + (list cairo + dbus + dbus-glib + gnome-js-common + gtk+ + gtk+-2 + libffi + libxml2 + mpfr + readline + sqlite + libxscrnsaver)) (propagated-inputs - `(("glib" ,glib) - ("webkit" ,webkitgtk-with-libsoup2))) + (list glib + webkitgtk-with-libsoup2)) (synopsis "GObject JavaScriptCore bridge") (description "Seed is a library and interpreter, dynamically bridging (through GObjectIntrospection) the WebKit JavaScriptCore engine, with the @@ -585,23 +550,11 @@ in JavaScript.") (build-system glib-or-gtk-build-system) (outputs '("out" "doc")) (arguments - `(#:tests? #f ; Tests require networking. - #:configure-flags - (list - "--disable-static" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* "libdmapsharing-4.0-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))) - #t))))) + (list #:tests? #f ; Tests require networking. + #:configure-flags + #~(list "--disable-static" + (string-append "--with-html-dir=" #$output:doc + "/share/gtk-doc/html")))) (native-inputs (list check docbook-xml-4.3 @@ -610,11 +563,11 @@ in JavaScript.") pkg-config vala)) (inputs - `(("avahi" ,avahi) - ("librsvg" ,librsvg) - ("gee" ,libgee) - ("gst-plugins-base" ,gst-plugins-base) - ("gtk+" ,gtk+))) + (list avahi + librsvg + libgee + gst-plugins-base + gtk+)) (propagated-inputs (list glib glib-networking gstreamer libsoup-minimal-2)) (synopsis "Media management library") @@ -674,56 +627,46 @@ of writing test cases for asynchronous interactions.") (build-system glib-or-gtk-build-system) (outputs '("out" "doc")) (arguments - `(#:configure-flags - (list - "--disable-maintainer-flags" - (string-append "--with-pygi-overrides-dir=" - (assoc-ref %outputs "out") - "/lib/python" - ,(version-major+minor - (package-version python)) - "/site-packages/gi/overrides") - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc/reference/dee-1.0" - (substitute* "dee-1.0-docs.sgml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))))) - (add-after 'patch-docbook-xml 'disable-failing-tests - (lambda _ - (substitute* "tests/test-icu.c" - (("g_test_add \\(DOMAIN\"/Default/AsciiFolder\", Fixture, 0,") - "") - (("setup, test_ascii_folder, teardown\\);") - "")))) - (add-before 'check 'pre-check - (lambda _ - ;; Tests require a running dbus-daemon. - (system "dbus-daemon &") - ;; For missing '/etc/machine-id'. - (setenv "DBUS_FATAL_WARNINGS" "0")))))) + (list #:configure-flags + #~(list "--disable-maintainer-flags" + (string-append "--with-pygi-overrides-dir=" + #$output "/lib/python" + #$(version-major+minor + (package-version python)) + "/site-packages/gi/overrides") + (string-append "--with-html-dir=" + #$output "/share/gtk-doc/html")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "tests/test-icu.c" + (("g_test_add \\(DOMAIN\"/Default/AsciiFolder\",\ + Fixture, 0,") + "") + (("setup, test_ascii_folder, teardown\\);") + "")))) + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running dbus-daemon. + (system "dbus-daemon &") + ;; For missing '/etc/machine-id'. + (setenv "DBUS_FATAL_WARNINGS" "0")))))) (native-inputs - `(("dbus" ,dbus) - ("dbus-test-runner" ,dbus-test-runner) - ("docbook-xml" ,docbook-xml-4.3) - ("gobject-introspection" ,gobject-introspection) - ("gtk-doc" ,gtk-doc/stable) - ;; Would only be required by configure flag "--enable-extended-tests". - ;("gtx" ,gtx) - ("pkg-config" ,pkg-config) - ("pygobject" ,python-pygobject) - ("python" ,python-wrapper) - ("vala" ,vala-0.52))) - (inputs - `(("icu" ,icu4c))) - (propagated-inputs - (list glib)) + (list dbus + dbus-test-runner + docbook-xml-4.3 + gobject-introspection + gtk-doc/stable + ;; Would only be required by configure flag "--enable-extended-tests". + ;;gtx + libxml2 ;for XML_CATALOG_FILES + pkg-config + python-pygobject + python-wrapper + vala-0.52)) + (inputs (list icu4c)) + (propagated-inputs (list glib)) (synopsis "Model to synchronize multiple instances over DBus") (description "Dee is a library that uses DBus to provide objects allowing you to create Model-View-Controller type programs across DBus. It also consists @@ -754,31 +697,23 @@ of known objects without needing a central registrar.") (base32 "07b1ahj3vd3m8srwkrh7dl3ymr7d55xiiszny44q13g06pq4svch")))) (build-system glib-or-gtk-build-system) (arguments - `(#:configure-flags - (list - "--enable-explain-queries" - "--enable-fts" - "--enable-docs") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc/libzeitgeist" - (substitute* "zeitgeist-gtkdoc-index.sgml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (search-input-directory inputs "/xml/dtd/docbook/")))))) - (add-after 'patch-docbook-xml 'disable-failing-tests - (lambda _ - (substitute* "test/direct/Makefile.am" - ((" log-test ") - "")) - (substitute* "test/c/Makefile.am" - ((" test-log ") - "")))) - (add-before 'bootstrap 'remove-autogen-script - (lambda _ - ;; To honor `autoreconf -vif` by build-system. - (delete-file "autogen.sh")))))) + (list #:configure-flags #~(list "--enable-explain-queries" + "--enable-fts" + "--enable-docs") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "test/direct/Makefile.am" + ((" log-test ") + "")) + (substitute* "test/c/Makefile.am" + ((" test-log ") + "")))) + (add-before 'bootstrap 'remove-autogen-script + (lambda _ + ;; To honor `autoreconf -vif` by build-system. + (delete-file "autogen.sh")))))) (native-inputs (list autoconf automake @@ -787,6 +722,7 @@ of known objects without needing a central registrar.") gobject-introspection gtk-doc/stable libtool + libxml2 ;for XML_CATALOG_FILES pkg-config vala xorg-server-for-tests)) @@ -799,8 +735,7 @@ of known objects without needing a central registrar.") python-wrapper python-rdflib xapian)) - (propagated-inputs - (list glib)) + (propagated-inputs (list glib)) (synopsis "Desktop Activity Logging") (description "Zeitgeist is a service which logs the users’s activities and events, anywhere from files opened to websites visited and conversations. It @@ -1205,7 +1140,10 @@ as a \"boring window manager for the adult in you.\"") "mm-common-" version ".tar.xz")) (sha256 (base32 - "1x8yvjy0yg17qyhmqws8xh2k8dvzrhpwqz7j1cfwzalrb1i9c5g8")))) + "1x8yvjy0yg17qyhmqws8xh2k8dvzrhpwqz7j1cfwzalrb1i9c5g8")) + (patches + (search-patches + "mm-common-reproducible-tarball.patch")))) (build-system meson-build-system) (arguments `(#:phases @@ -1647,44 +1585,35 @@ tour of all gnome components and allows the user to set them up.") (define-public gnome-user-share (package - (name "gnome-user-share") - (version "3.34.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "04r9ck9v4i0d31grbli1d4slw2d6dcsfkpaybkwbzi7wnj72l30x")))) - (build-system meson-build-system) - (arguments - `(#:glib-or-gtk? #t - #:meson ,meson-0.60 - #:configure-flags - `("-Dsystemduserunitdir=/tmp/empty" - ;; Enable nautilus extension for file sharing. - "-Dnautilus_extension=true"))) - (native-inputs - `(("gettext" ,gettext-minimal) - ("glib:bin" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("gtk+:bin" ,gtk+ "bin") - ("pkg-config" ,pkg-config) - ("yelp-tools" ,yelp-tools))) - (inputs - (list glib - gnome-bluetooth - gtk+ - libcanberra - libnotify - nautilus)) ; For nautilus extension. - (synopsis "File sharing for GNOME desktop") - (description "GNOME User Share is a small package that binds together + (name "gnome-user-share") + (version "43.0") + (source (origin + (method url-fetch) + (uri (string-append "mirror://gnome/sources/" name "/" + (version-major version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "1kiq2n39yz7szcf7wrs5vhd2hdn04zx1pxgp7qskycaq0nm0dwqd")))) + (build-system meson-build-system) + (arguments + (list #:glib-or-gtk? #t + #:configure-flags + #~(list "-Dsystemduserunitdir=/tmp/empty"))) + (native-inputs + (list gettext-minimal + `(,glib "bin") + gobject-introspection + `(,gtk "bin") + pkg-config + yelp-tools)) + (inputs (list glib gtk)) + (synopsis "File sharing for GNOME desktop") + (description "GNOME User Share is a small package that binds together various free software projects to bring easy to use user-level file sharing to the masses.") - (home-page "https://gitlab.gnome.org/GNOME/gnome-user-share") - (license license:gpl2+))) + (home-page "https://gitlab.gnome.org/GNOME/gnome-user-share") + (license license:gpl2+))) (define-public sushi (package @@ -1819,23 +1748,16 @@ client devices can handle.") (arguments ;; GTK 4.x depends on Rust (indirectly) so pull it only on platforms ;; where it is supported. - `(#:configure-flags ,(if (supported-package? gtk) - `(list "-Dlibnma_gtk4=true") - `(list "-Dlibnma_gtk4=false")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "libnma-docs.xml" - (("http://.*/docbookx\\.dtd") - (search-input-file - inputs "xml/dtd/docbook/docbookx.dtd")))))))) + (list #:configure-flags (if (supported-package? gtk) + #~(list "-Dlibnma_gtk4=true") + #~(list "-Dlibnma_gtk4=false")))) (native-inputs (list docbook-xml-4.3 gettext-minimal `(,glib "bin") gtk-doc/stable gobject-introspection + libxml2 ;for XML_CATALOG_FILES pkg-config vala)) (inputs @@ -2338,7 +2260,7 @@ The gnome-about program helps find which version of GNOME is installed.") (define-public gnome-disk-utility (package (name "gnome-disk-utility") - (version "42.0") + (version "44.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -2346,18 +2268,22 @@ The gnome-about program helps find which version of GNOME is installed.") name "-" version ".tar.xz")) (sha256 (base32 - "02q906gn420xbf1f0apazryzqfv5b1ammz1vrci66hk79m2n8r8v")))) + "1vx3wyvidjyzr4141p3zrvgx88rp7vwj6n3sf7c3gnvci6bi00q2")))) (build-system meson-build-system) (arguments `(#:configure-flags '("-Dlogind=libelogind") - #:meson ,meson-0.60 #:phases (modify-phases %standard-phases (add-after 'unpack 'skip-gtk-update-icon-cache ;; Don't create 'icon-theme.cache'. (lambda _ - (substitute* "meson_post_install.py" - (("gtk-update-icon-cache") "true"))))))) + (substitute* "meson.build" + (("gtk_update_icon_cache: true") + "gtk_update_icon_cache: false") + (("glib_compile_schemas: true") + "glib_compile_schemas: false") + (("update_desktop_database: true") + "update_desktop_database: false"))))))) (native-inputs (list docbook-xml docbook-xsl @@ -2379,7 +2305,7 @@ The gnome-about program helps find which version of GNOME is installed.") libpwquality libsecret udisks)) - (home-page "https://git.gnome.org/browse/gnome-disk-utility") + (home-page "https://gitlab.gnome.org/GNOME/gnome-disk-utility") (synopsis "Disk management utility for GNOME") (description "Disk management utility for GNOME.") (license license:gpl2+))) @@ -2508,7 +2434,7 @@ GNOME Desktop.") (define-public gdl (package (name "gdl") - (version "3.34.0") + (version "3.40.0") (source (origin (method git-fetch) (uri (git-reference @@ -2520,7 +2446,7 @@ GNOME Desktop.") (file-name (git-file-name name version)) (sha256 (base32 - "154qcr0x6f68f4q526y87imv0rscmp34n47nk1pp82rsq52h2zna")))) + "11hp93gqk7m64h84q5hndzlwj4w6hl0cbmzrk2pkdn04ikm2zj4v")))) (build-system gnu-build-system) (native-inputs (list autoconf @@ -2696,7 +2622,7 @@ update_desktop_database): true" _ tool) libspectre djvulibre ghostscript - poppler-next + poppler libtiff texlive-libkpathsea ; for DVI support gnome-desktop @@ -2705,7 +2631,7 @@ update_desktop_database): true" _ tool) libgnome-keyring adwaita-icon-theme gdk-pixbuf - atk + at-spi2-core pango gtk+ glib @@ -2737,7 +2663,7 @@ on the GNOME Desktop with a single simple application.") (define-public gsettings-desktop-schemas (package (name "gsettings-desktop-schemas") - (version "41.0") + (version "42.0") (source (origin (method url-fetch) @@ -2746,7 +2672,7 @@ on the GNOME Desktop with a single simple application.") name "-" version ".tar.xz")) (sha256 (base32 - "1v9jagk679m01nji0acirynxinziv036618c7xc49l4nwmr9ja3p")))) + "1li3fcqwnw20f4j0i21i88fygm0hli8gmzkn4apgf8ynkrd371k6")))) (build-system meson-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -3036,13 +2962,6 @@ database is translated at Transifex.") (substitute* "Makefile.am" (("/bin/bash") (which "bash"))) (delete-file "configure"))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - ;; Modify the man XML otherwise xmlto tries to access the network - (substitute* "man/system-config-printer.xml" - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/"))))) (add-after 'install 'add-install-to-pythonpath (@@ (guix build python-build-system) add-install-to-pythonpath)) (add-after 'add-install-to-pythonpath 'wrap-for-python @@ -3130,36 +3049,32 @@ configuring CUPS.") "0qa7cx6ra5hwqnxw95b9svgjg5q6ynm8y843iqjszxvds5z53h36")))) (build-system meson-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-docbook - (lambda* (#:key inputs #:allow-other-keys) - ;; Don't attempt to download XSL schema. - (substitute* "meson.build" - (("http://docbook.sourceforge.net/release/xsl-ns/current\ + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-docbook + (lambda* (#:key inputs #:allow-other-keys) + ;; Don't attempt to download XSL schema. + (substitute* "meson.build" + (("http://docbook.sourceforge.net/release/xsl-ns/current\ /manpages/docbook.xsl") - (string-append (assoc-ref inputs "docbook-xsl") - "/xml/xsl/docbook-xsl-" - ,(package-version docbook-xsl) - "/manpages/docbook.xsl"))) - #t))))) - (propagated-inputs - (list ;; In Requires of libnotify.pc. - gdk-pixbuf glib)) - (inputs - (list gtk+ libpng)) + (string-append #$(this-package-native-input "docbook-xsl") + "/xml/xsl/docbook-xsl-" + #$(package-version docbook-xsl) + "/manpages/docbook.xsl")))))))) + (propagated-inputs (list gdk-pixbuf glib)) ;in Requires of libnotify.pc. + (inputs (list gtk+ libpng)) (native-inputs - `(("pkg-config" ,pkg-config) - ("glib" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) + (list pkg-config + `(,glib "bin") + gobject-introspection - ;; For the documentation. - ("gtk-doc" ,gtk-doc/stable) - ("xsltproc" ,libxslt) - ("docbook-xsl" ,docbook-xsl))) + ;; For the documentation. + gtk-doc/stable + libxslt + docbook-xsl)) (home-page "https://developer-next.gnome.org/libnotify/") - (synopsis - "GNOME desktop notification library") + (synopsis "GNOME desktop notification library") (description "Libnotify is a library that sends desktop notifications to a notification daemon, as defined in the Desktop Notifications spec. These @@ -3300,7 +3215,8 @@ API add-ons to make GTK+ widgets OpenGL-capable.") '()) (list gtk+ libxml2))) (native-inputs - (list docbook-xml-4.2 + (list at-spi2-core ;for tests + docbook-xml-4.2 docbook-xsl gettext-minimal `(,glib "bin") @@ -3505,34 +3421,24 @@ XML/CSS rendering engine.") (build-system glib-or-gtk-build-system) (outputs '("out" "bin" "doc")) (arguments - (list - #:configure-flags - #~(list - "--disable-static" - "--enable-introspection" - (string-append "--with-gir-dir=" #$output - "/share/gir-" - #$(version-major - (package-version gobject-introspection)) - ".0") - (string-append "--with-typelib-dir=" #$output - "/lib/girepository-" - #$(version-major - (package-version gobject-introspection)) - ".0") - (string-append "--with-html-dir=" #$output - "/share/gtk-doc/html") - "--with-zlib" - "--with-bz2") - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* "gsf-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.5/") - (search-input-directory (or native-inputs inputs) - "xml/dtd/docbook"))))))))) + (list #:configure-flags + #~(list + "--disable-static" + "--enable-introspection" + (string-append "--with-gir-dir=" #$output + "/share/gir-" + #$(version-major + (package-version gobject-introspection)) + ".0") + (string-append "--with-typelib-dir=" #$output + "/lib/girepository-" + #$(version-major + (package-version gobject-introspection)) + ".0") + (string-append "--with-html-dir=" #$output + "/share/gtk-doc/html") + "--with-zlib" + "--with-bz2"))) (native-inputs (list docbook-xml gettext-minimal @@ -3559,7 +3465,7 @@ for dealing with different structured file formats.") (define-public librsvg (package (name "librsvg") - (version "2.50.7") + (version "2.54.4") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/librsvg/" @@ -3567,154 +3473,127 @@ for dealing with different structured file formats.") "librsvg-" version ".tar.xz")) (sha256 (base32 - "1g3f8byg5w08fx1bka12mmpl59v6a4q2p827w6m2la6mijq63yzz")) + "0cs8qbn2khibb5w1r0f6cibfmkfb7zg713526vhc0hva7wj2l5ga")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "vendor"))))) (build-system cargo-build-system) (outputs '("out" "doc" "debug")) (arguments - `(#:install-source? #f - #:modules - ((guix build cargo-build-system) + (list + #:install-source? #f + #:modules + '((guix build cargo-build-system) (guix build utils) ((guix build gnu-build-system) #:prefix gnu:)) - #:cargo-inputs - (("rust-bitflags" ,rust-bitflags-1) - ("rust-cairo-rs" ,rust-cairo-rs-0.8) - ("rust-cairo-sys-rs" ,rust-cairo-sys-rs-0.9) - ("rust-cast" ,rust-cast-0.2) - ("rust-cssparser" ,rust-cssparser-0.27) + #:cargo-inputs + `(("rust-byteorder" ,rust-byteorder-1) + ("rust-cairo-rs" ,rust-cairo-rs-0.15) + ("rust-cast" ,rust-cast-0.3) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-clap" ,rust-clap-2) + ("rust-cssparser" ,rust-cssparser-0.28) ("rust-data-url" ,rust-data-url-0.1) ("rust-encoding" ,rust-encoding-0.2) - ("rust-float-cmp" ,rust-float-cmp-0.8) - ("rust-gdk-pixbuf" ,rust-gdk-pixbuf-0.8) - ("rust-gdk-pixbuf-sys" ,rust-gdk-pixbuf-sys-0.9) - ("rust-gio" ,rust-gio-0.8) - ("rust-gio-sys" ,rust-gio-sys-0.9) - ("rust-glib" ,rust-glib-0.9) - ("rust-glib-sys" ,rust-glib-sys-0.9) - ("rust-gobject-sys" ,rust-gobject-sys-0.9) - ("rust-itertools" ,rust-itertools-0.9) - ("rust-language-tags" ,rust-language-tags-0.2) + ("rust-float-cmp" ,rust-float-cmp-0.9) + ("rust-gdk-pixbuf" ,rust-gdk-pixbuf-0.15) + ("rust-gio" ,rust-gio-0.15) + ("rust-glib" ,rust-glib-0.15) + ("rust-itertools" ,rust-itertools-0.10) + ("rust-language-tags" ,rust-language-tags-0.3) ("rust-libc" ,rust-libc-0.2) ("rust-locale-config" ,rust-locale-config-0.3) ("rust-markup5ever" ,rust-markup5ever-0.10) - ("rust-nalgebra" ,rust-nalgebra-0.21) + ("rust-nalgebra" ,rust-nalgebra-0.29) ("rust-num-traits" ,rust-num-traits-0.2) ("rust-once-cell" ,rust-once-cell-1) - ("rust-pkg-config" ,rust-pkg-config-0.3) - ("rust-pango" ,rust-pango-0.8) - ("rust-pango-sys" ,rust-pango-sys-0.9) - ("rust-pangocairo" ,rust-pangocairo-0.9) + ("rust-pango" ,rust-pango-0.15) + ("rust-pangocairo" ,rust-pangocairo-0.15) ("rust-rayon" ,rust-rayon-1) - ("rust-rctree" ,rust-rctree-0.3) + ("rust-rctree" ,rust-rctree-0.4) ("rust-rgb" ,rust-rgb-0.8) ("rust-regex" ,rust-regex-1) - ("rust-selectors" ,rust-selectors-0.22) + ("rust-selectors" ,rust-selectors-0.23) ("rust-string-cache" ,rust-string-cache-0.8) - ("rust-tinyvec" ,rust-tinyvec-0.3) + ("rust-tinyvec" ,rust-tinyvec-1) ("rust-url" ,rust-url-2) ("rust-xml5ever" ,rust-xml5ever-0.16)) - #:cargo-development-inputs - (("rust-assert-cmd" ,rust-assert-cmd-1) - ("rust-cairo-rs" ,rust-cairo-rs-0.8) + #:cargo-development-inputs + `(("rust-anyhow" ,rust-anyhow-1) + ("rust-assert-cmd" ,rust-assert-cmd-2) + ("rust-cairo-rs" ,rust-cairo-rs-0.15) ("rust-chrono" ,rust-chrono-0.4) ("rust-criterion" ,rust-criterion-0.3) - ("rust-float-cmp" ,rust-float-cmp-0.8) + ("rust-glib" ,rust-glib-0.15) + ("rust-libc" ,rust-libc-0.2) ("rust-lopdf" ,rust-lopdf-0.26) - ("rust-png" ,rust-png-0.16) - ("rust-predicates" ,rust-predicates-1) - ("rust-tempfile" ,rust-tempfile-3)) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* "rsvg-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))))) - (add-after 'unpack 'prepare-for-build - (lambda _ - ;; In lieu of #:make-flags - (setenv "CC" ,(cc-for-target)) - ;; Something about the build environment resists building - ;; successfully with the '--locked' flag. - (substitute* '("Makefile.am" "Makefile.in") - (("--locked") "")))) - (add-before 'configure 'pre-configure - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "gdk-pixbuf-loader/Makefile.in" - ;; By default the gdk-pixbuf loader is installed under - ;; gdk-pixbuf's prefix. Work around that. - (("gdk_pixbuf_moduledir = .*$") - (string-append "gdk_pixbuf_moduledir = " - "$(prefix)/" - ,(dirname %gdk-pixbuf-loaders-cache-file) "/" - "loaders\n"))) - (substitute* "configure" - (("gdk_pixbuf_cache_file=.*") - (string-append "gdk_pixbuf_cache_file=" - (assoc-ref outputs "out") "/" - ,%gdk-pixbuf-loaders-cache-file "\n"))))) - (add-after 'configure 'gnu-configure - (lambda* (#:key outputs #:allow-other-keys #:rest args) - (apply (assoc-ref gnu:%standard-phases 'configure) - #:configure-flags - (list "--disable-static" - "--enable-vala" - (string-append "--with-html-dir=" - (assoc-ref outputs "doc") - "/share/gtk-doc/html")) - args))) - (add-after 'configure 'dont-vendor-self - (lambda* (#:key vendor-dir #:allow-other-keys) - ;; Don't keep the whole tarball in the vendor directory - (delete-file-recursively - (string-append vendor-dir "/" ,name "-" ,version ".tar.xz")))) - (replace 'build - (assoc-ref gnu:%standard-phases 'build)) - (add-before 'check 'ignore-failing-tests - ;; stderr=```/tmp/guix-build-.../librsvg-2.50.1/rsvg-convert: line 150: ls: command not found - (lambda _ - (substitute* "tests/src/cmdline/rsvg_convert.rs" - (("fn background_color_option_invalid_color_yields_error" all) - (string-append "#[ignore] " all)) - (("fn empty_input_yields_error" all) - (string-append "#[ignore] " all)) - (("fn empty_svg_yields_error" all) - (string-append "#[ignore] " all)) - (("fn env_source_data_epoch_empty" all) - (string-append "#[ignore] " all)) - (("fn env_source_data_epoch_no_digits" all) - (string-append "#[ignore] " all)) - (("fn env_source_data_epoch_trailing_garbage" all) - (string-append "#[ignore] " all)) - (("fn export_id_option_error" all) - (string-append "#[ignore] " all)) - (("fn huge_zoom_factor_yields_error" all) - (string-append "#[ignore] " all)) - (("fn multiple_input_files_not_allowed_for_png_output" all) - (string-append "#[ignore] " all)) - (("fn stylesheet_option_error" all) - (string-append "#[ignore] " all))))) - (replace 'check - (lambda* args - ((assoc-ref gnu:%standard-phases 'check) - #:test-target "check"))) - (replace 'install - (assoc-ref gnu:%standard-phases 'install))))) - (native-inputs - (list docbook-xml-4.3 - `(,glib "bin") - gobject-introspection - pkg-config - vala)) - (inputs - (list freetype harfbuzz libxml2 pango)) - (propagated-inputs - (list cairo gdk-pixbuf glib)) + ("rust-matches" ,rust-matches-0.1) + ("rust-png" ,rust-png-0.17) + ("rust-predicates" ,rust-predicates-2) + ("rust-proptest" ,rust-proptest-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-test-generator" ,rust-test-generator-0.3) + ("rust-yeslogic-fontconfig-sys" ,rust-yeslogic-fontconfig-sys-2)) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-gdk-pixbuf-thumbnailer + (lambda* (#:key inputs #:allow-other-keys) + ;; The gdk-pixbuf-thumbnailer location is assumed to be relative + ;; to librsvg's own installation prefix (see: + ;; https://gitlab.gnome.org/GNOME/librsvg/-/issues/955). + (substitute* "gdk-pixbuf-loader/librsvg.thumbnailer.in" + (("@bindir@/gdk-pixbuf-thumbnailer") + (search-input-file inputs "bin/gdk-pixbuf-thumbnailer"))))) + (add-after 'unpack 'prepare-for-build + (lambda _ + ;; In lieu of #:make-flags + (setenv "CC" #$(cc-for-target)) + ;; Something about the build environment resists building + ;; successfully with the '--locked' flag. + (substitute* '("Makefile.am" "Makefile.in") + (("--locked") "")))) + (add-before 'configure 'pre-configure + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "gdk-pixbuf-loader/Makefile.in" + ;; By default the gdk-pixbuf loader is installed under + ;; gdk-pixbuf's prefix. Work around that. + (("gdk_pixbuf_moduledir = .*$") + (string-append "gdk_pixbuf_moduledir = " + "$(prefix)/" + #$(dirname %gdk-pixbuf-loaders-cache-file) "/" + "loaders\n"))) + (substitute* "configure" + (("gdk_pixbuf_cache_file=.*") + (string-append "gdk_pixbuf_cache_file=" + #$output "/" + #$%gdk-pixbuf-loaders-cache-file "\n"))))) + (add-after 'configure 'gnu-configure + (lambda* (#:key outputs #:allow-other-keys #:rest args) + (apply (assoc-ref gnu:%standard-phases 'configure) + #:configure-flags + (list "--disable-static" + "--enable-vala" + (string-append "--with-html-dir=" #$output + "/share/gtk-doc/html")) + args))) + (add-after 'configure 'dont-vendor-self + (lambda* (#:key vendor-dir #:allow-other-keys) + ;; Don't keep the whole tarball in the vendor directory + (delete-file-recursively + (string-append vendor-dir "/" #$name "-" #$version ".tar.xz")))) + (replace 'build + (assoc-ref gnu:%standard-phases 'build)) + (replace 'check + (lambda* args + ((assoc-ref gnu:%standard-phases 'check) + #:test-target "check"))) + (replace 'install + (assoc-ref gnu:%standard-phases 'install))))) + (native-inputs (list `(,glib "bin") gobject-introspection pkg-config vala)) + (inputs (list freetype harfbuzz libxml2 pango)) + (propagated-inputs (list cairo gdk-pixbuf glib)) (synopsis "SVG rendering library") (description "Librsvg is a library to render SVG images to Cairo surfaces. GNOME uses this to render SVG icons. Outside of GNOME, other desktop @@ -3723,34 +3602,6 @@ diagrams.") (home-page "https://wiki.gnome.org/LibRsvg") (license license:lgpl2.1+))) -;; This copy of librsvg uses the bundled rust libraries. It is useful for -;; packages which have too many dependencies to be rebuilt as frequently -;; as the rust inputs are updated. -;; TODO: Remove this package and use packaged rust libraries! -(define-public librsvg-bootstrap - (package - (inherit librsvg) - (name "librsvg") - (version "2.50.7") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/librsvg/" - (version-major+minor version) "/" - "librsvg-" version ".tar.xz")) - (sha256 - (base32 - "1g3f8byg5w08fx1bka12mmpl59v6a4q2p827w6m2la6mijq63yzz")) - (modules '((guix build utils))) - (snippet - '(begin - (for-each delete-file (find-files "vendor" "\\.a$")))))) - (arguments - (substitute-keyword-arguments (package-arguments librsvg) - ((#:vendor-dir _ "vendor") "vendor") - ((#:cargo-inputs _) '()) - ((#:cargo-development-inputs _) '()))) - (properties '((hidden? . #t))))) - (define-public librsvg-2.40 ;; This is the last version implemented in C. (package @@ -3782,6 +3633,12 @@ diagrams.") (("gdk_pixbuf_cache_file = .*$") "gdk_pixbuf_cache_file = $(TMPDIR)/loaders.cache\n")) #t)) + (add-before 'check 'fix-test-with-pango-1.50 + (lambda _ + ;; Changes between pango 1.48 and 1.50 caused the text to be one + ;; pixel lower in the output image compared to the reference. + (substitute* "tests/fixtures/reftests/bugs/587721-text-transform.svg" + (("660\\.9") "659.9")))) (add-before 'check 'remove-failing-tests (lambda _ (with-directory-excursion "tests/fixtures/reftests" @@ -4549,60 +4406,6 @@ passwords in the GNOME keyring.") (define-public vala (package (name "vala") - (version "0.54.2") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/vala/" - (version-major+minor version) "/" - "vala-" version ".tar.xz")) - (sha256 - (base32 - "048k5c6c6y7jyb961krnrb7m0kghr0yrkpnfx3j5ckbx652yfkc8")))) - (build-system glib-or-gtk-build-system) - (arguments - '(#:configure-flags '("--enable-coverage") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc/manual" - (substitute* '("manual.xml" "version.xml.in") - (("http://www.oasis-open.org/docbook/xml/4.4/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))))) - (add-before 'check 'pre-check - (lambda _ - (setenv "CC" "gcc") - (substitute* "valadoc/tests/libvaladoc\ -/tests-extra-environment.sh" - (("export PKG_CONFIG_PATH=" m) - (string-append m "$PKG_CONFIG_PATH:")))))))) - (native-inputs - `(("bison" ,bison) - ("dbus" ,dbus) ; for dbus tests - ("docbook-xml" ,docbook-xml-4.4) - ("docbook-xsl" ,docbook-xsl) - ("flex" ,flex) - ("gobject-introspection" ,gobject-introspection) ; for gir tests - ("help2man" ,help2man) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("xsltproc" ,libxslt))) - (propagated-inputs - `(("glib" ,glib) ; required by libvala-0.40.pc - ("libgvc" ,graphviz))) - (home-page "https://wiki.gnome.org/Projects/Vala/") - (synopsis "Compiler using the GObject type system") - (description "Vala is a programming language using modern high level -abstractions without imposing additional runtime requirements and without using -a different ABI compared to applications and libraries written in C. Vala uses -the GObject type system and has additional code generation routines that make -targeting the GNOME stack simple.") - (license license:lgpl2.1+))) - -(define-public vala-next - (package - (inherit vala) (version "0.56.3") (source (origin (method url-fetch) @@ -4612,6 +4415,7 @@ targeting the GNOME stack simple.") (sha256 (base32 "1gwrnr0d0bqkh6m4bgz39mh3pcswcj43hyijlwgwp2bvpwhn41p1")))) + (build-system glib-or-gtk-build-system) (arguments (list #:configure-flags #~(list "CC=gcc" "--enable-coverage") @@ -4622,12 +4426,6 @@ targeting the GNOME stack simple.") (substitute* "codegen/valaccodecompiler.c" (("cc_command = \"cc\"") "cc_command = \"gcc\"")))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc/manual" - (substitute* '("manual.xml" "version.xml.in") - (("http://www.oasis-open.org/docbook/xml/4.4/") - (search-input-directory inputs "xml/dtd/docbook")))))) (add-before 'check 'pre-check (lambda _ (substitute* "valadoc/tests/libvaladoc/tests-extra-environment.sh" @@ -4636,7 +4434,29 @@ targeting the GNOME stack simple.") ;; Wrapping the binaries breaks vala's behavior adaptations based on ;; the file name of the program executed (vala: compile and execute, ;; valac: compile into a binary). - (delete 'glib-or-gtk-wrap)))))) + (delete 'glib-or-gtk-wrap)))) + (native-inputs + (list bison + dbus ; for dbus tests + docbook-xml-4.4 + docbook-xsl + flex + gobject-introspection ; for gir tests + help2man + perl + pkg-config + libxslt)) + (propagated-inputs + (list glib ; required by libvala-0.40.pc + graphviz)) + (home-page "https://wiki.gnome.org/Projects/Vala/") + (synopsis "Compiler using the GObject type system") + (description "Vala is a programming language using modern high level +abstractions without imposing additional runtime requirements and without using +a different ABI compared to applications and libraries written in C. Vala uses +the GObject type system and has additional code generation routines that make +targeting the GNOME stack simple.") + (license license:lgpl2.1+))) ;;; An older variant kept to build libsoup-minimal-2. (define-public vala-0.52 @@ -4891,53 +4711,38 @@ GLib and GObject, and integrates JSON with GLib data types.") (arguments (substitute-keyword-arguments (package-arguments json-glib-minimal) ((#:configure-flags _) - `(list "-Ddocs=true" - "-Dman=true" - ,@(if (%current-target-system) - ;; If enabled, gtkdoc-scangobj will try to execute a - ;; cross-compiled binary. - '("-Dgtk_doc=disabled" - ;; Trying to build introspection data when cross-compiling - ;; causes errors during linking. - "-Dintrospection=disabled") - '()))) + #~(list "-Ddocs=true" + "-Dman=true" + #$@(if (%current-target-system) + ;; If enabled, gtkdoc-scangobj will try to execute a + ;; cross-compiled binary. + #~("-Dgtk_doc=disabled" + ;; Trying to build introspection data when cross-compiling + ;; causes errors during linking. + "-Dintrospection=disabled") + #~()))) ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-after 'unpack 'patch-docbook - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.3/") - (string-append (assoc-ref (or native-inputs inputs) - "docbook-xml") - "/xml/dtd/docbook/"))) - (substitute* "meson.build" - (("http://docbook.sourceforge.net/release/xsl/current/") - (string-append (assoc-ref (or native-inputs inputs) - "docbook-xsl") - "/xml/xsl/docbook-xsl-1.79.2/")))))) - ;; When cross-compiling, there are no docs to move. - ,(if (%current-target-system) - '(add-after 'install 'stub-docs - (lambda* (#:key outputs #:allow-other-keys) - ;; The daemon doesn't like empty output paths. - (mkdir (assoc-ref outputs "doc")))) - '(add-after 'install 'move-docs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/gtk-doc") - (string-append doc "/share/gtk-doc")))))))))) - (native-inputs - (append - `(("docbook-xml" ,docbook-xml-4.3) - ("docbook-xsl" ,docbook-xsl) - ("gobject-introspection" ,gobject-introspection) - ("gtk-doc" ,gtk-doc) - ("xsltproc" ,libxslt)) - (package-native-inputs json-glib-minimal))))) + #~(modify-phases #$phases + ;; When cross-compiling, there are no docs to move. + #$@(if (%current-target-system) + #~((add-after 'install 'stub-docs + (lambda _ + ;; The daemon doesn't like empty output paths. + (mkdir #$output:doc)))) + #~((add-after 'install 'move-docs + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/gtk-doc") + (string-append #$output:doc + "/share/gtk-doc")))))))))) + (native-inputs + (modify-inputs (package-native-inputs json-glib-minimal) + (prepend docbook-xml-4.3 + docbook-xsl + gobject-introspection + gtk-doc + libxslt))))) (define-public libxklavier (package @@ -4987,7 +4792,7 @@ indicators etc).") (define-public glib-networking (package (name "glib-networking") - (version "2.70.0") + (version "2.72.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/glib-networking/" @@ -4995,24 +4800,12 @@ indicators etc).") "glib-networking-" version ".tar.xz")) (sha256 (base32 - "0dbg1na239mbavn4hknkax5sns9q2dbdnqw9wcpmhv58mzkhid36")) + "0s42l6dkajciqc99zp6dc9l8yv9g8w7d8mgv97l7h7drgd60hand")) (patches (search-patches "glib-networking-gnutls-binding.patch")))) (build-system meson-build-system) - (arguments - (if (target-64bit?) - '() - (list #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'work-around-32-bit-time-t - (lambda _ - (invoke "patch" "--force" "-p1" "-i" - #$(local-file - (search-patch - "glib-networking-32-bit-time.patch"))))))))) (native-inputs - `(("pkg-config" ,pkg-config) - ("gettext" ,gettext-minimal))) + (list pkg-config gettext-minimal)) (inputs (list glib gnutls gsettings-desktop-schemas libproxy)) (home-page "https://wiki.gnome.org/Projects/GLib") @@ -5041,8 +4834,7 @@ from the GSettings schemas in gsettings-desktop-schemas.") "0ll9220d6qf9m7wdi5xhq69p8h8whs7l5h5nzdhlbn99qh5388bz")))) (build-system meson-build-system) (arguments - (list #:meson meson-0.63 - #:phases + (list #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch-paths (lambda* (#:key inputs #:allow-other-keys) @@ -5095,14 +4887,10 @@ files.") #:configure-flags '("--with-ca-certificates=/etc/ssl/certs/ca-certificates.crt"))) (native-inputs - `(("glib-mkenums" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("pkg-config" ,pkg-config))) + (list `(,glib "bin") gobject-introspection pkg-config)) (propagated-inputs ;; rest-0.7.pc refers to all these. - `(("glib" ,glib) - ("libsoup" ,libsoup-minimal-2) - ("libxml2" ,libxml2))) + (list glib libsoup-minimal-2 libxml2)) (home-page "https://www.gtk.org/") (synopsis "RESTful web api query library") (description @@ -5151,7 +4939,7 @@ libxml to ease remote use of the RESTful API.") (inputs (list json-glib)) (propagated-inputs (modify-inputs (package-propagated-inputs rest) - (replace "libsoup" libsoup) + (replace "libsoup-minimal" libsoup) (append json-glib))))) (define-public libshumate @@ -5202,7 +4990,7 @@ as OpenStreetMap, OpenCycleMap, OpenAerialMap and Maps.") (define-public libsoup-minimal (package (name "libsoup-minimal") - (version "3.0.4") + (version "3.0.7") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/libsoup/" @@ -5210,7 +4998,7 @@ as OpenStreetMap, OpenCycleMap, OpenAerialMap and Maps.") "libsoup-" version ".tar.xz")) (sha256 (base32 - "0ysnvvfd2f6w2z6g31spqqb8wgyamixc7mryzbbpyw0z15g8plsv")))) + "1j7p3cz6hwi9js9rp0pbas7cdln97yg9v2l1nv5imhcr6p7r1pzb")))) (build-system meson-build-system) (arguments `(#:configure-flags '("-Dgtk_doc=false") @@ -5235,7 +5023,6 @@ as OpenStreetMap, OpenCycleMap, OpenAerialMap and Maps.") (native-inputs (list `(,glib "bin") ;for glib-mkenums gobject-introspection - intltool pkg-config python-wrapper vala @@ -5264,8 +5051,9 @@ and the GLib main loop, to integrate well with GNOME applications.") ;;; An older variant kept to build the 'rest' package. (define-public libsoup-minimal-2 - (package/inherit libsoup-minimal - (version "2.72.0") + (package + (inherit libsoup-minimal) + (version "2.74.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/libsoup/" @@ -5273,7 +5061,7 @@ and the GLib main loop, to integrate well with GNOME applications.") "libsoup-" version ".tar.xz")) (sha256 (base32 - "11skbyw2pw32178q3h8pi7xqa41b2x4k6q4k9f75zxmh8s23y30p")))) + "0n8is108n0dn4dw7nm2wq9rydcm1vy47w40wywfrxqazdrjjg97h")))) (arguments (substitute-keyword-arguments (package-arguments libsoup-minimal) ((#:phases phases) @@ -5725,65 +5513,66 @@ file.") (define-public colord-minimal (package (name "colord-minimal") - (version "1.4.5") + (version "1.4.6") (source (origin (method url-fetch) (uri (string-append "https://www.freedesktop.org/software/colord/releases/" "colord-" version ".tar.xz")) (sha256 - (base32 "05sydi6qqqx1rrqwnga1vbg9srkf89wdcfw5w4p4m7r37m2flx5p")))) + (base32 "0vwfx06k1in8hci3kdxpc3c0bh81f1vl5bp7favd3rdz4wd661vl")))) (build-system meson-build-system) (arguments - '( ;; FIXME: One test fails: - ;; /colord/icc-store (in lib/colord/colord-self-test-private): - ;; Incorrect content type for /tmp/colord-vkve/already-exists.icc, got - ;; application/x-zerosize - #:tests? #f - #:glib-or-gtk? #t - #:configure-flags (list "-Dargyllcms_sensor=false" ;requires spotread - "-Dbash_completion=false" - "-Ddaemon_user=colord" - "-Ddocs=false" - "-Dlocalstatedir=/var" - "-Dman=false" - "-Dsane=true" - "-Dsystemd=false") ;no systemd - #:phases - (modify-phases %standard-phases - (add-before 'configure 'patch-build-system - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "rules/meson.build" - (("udev.get_pkgconfig_variable\\('udevdir'\\)") - (string-append "'" (assoc-ref outputs "out") "/lib/udev'"))))) - (add-before 'configure 'set-sqlite3-file-name - (lambda* (#:key inputs #:allow-other-keys) - ;; "colormgr dump" works by invoking the "sqlite3" command. - ;; Record its absolute file name. - (let ((sqlite (assoc-ref inputs "sqlite"))) - (substitute* "client/cd-util.c" - (("\"sqlite3\"") - (string-append "\"" sqlite "/bin/sqlite3\""))))))))) - (native-inputs - `(("glib:bin" ,glib "bin") ; for glib-compile-resources, etc. - ("gettext" ,gettext-minimal) - ("pkg-config" ,pkg-config) - ("vala" ,vala))) + (list + #:glib-or-gtk? #t + #:configure-flags #~(list "-Dargyllcms_sensor=false" ;requires spotread + "-Dbash_completion=false" + "-Ddaemon_user=colord" + "-Ddocs=false" + "-Dlocalstatedir=/var" + "-Dman=false" + "-Dsystemd=false") ;no systemd + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-problematic-tests + (lambda _ + ;; Skip the colord-test-private, which requires a *system* D-Bus + ;; session, which wants to run as root, among other requirements + ;; (see: https://github.com/hughsie/colord/issues/97). + (substitute* "lib/colord/meson.build" + ((".*test\\('colord-test-private'.*") "")))) + (add-before 'configure 'patch-build-system + (lambda _ + (substitute* "rules/meson.build" + (("udev.get_pkgconfig_variable\\('udevdir'\\)") + (string-append "'" #$output "/lib/udev'"))))) + (add-before 'configure 'set-sqlite3-file-name + (lambda* (#:key inputs #:allow-other-keys) + ;; "colormgr dump" works by invoking the "sqlite3" command. + ;; Record its absolute file name. + (substitute* "client/cd-util.c" + (("\"sqlite3\"") + (format #f "~s" (search-input-file inputs + "bin/sqlite3"))))))))) + (native-inputs + (list `(,glib "bin") ; for glib-compile-resources, etc. + gettext-minimal + pkg-config + vala)) (propagated-inputs ;; colord.pc refers to all these. - `(("glib" ,glib) - ("lcms" ,lcms) - ("udev" ,eudev))) + (list glib + lcms + eudev)) (inputs - `(("dbus-glib" ,dbus-glib) - ("gobject-introspection" ,gobject-introspection) - ("gusb" ,gusb-minimal) - ("libgudev" ,libgudev) - ("libusb" ,libusb) - ("polkit" ,polkit) - ("python" ,python-wrapper) - ("sqlite" ,sqlite) - ("sane-backends" ,sane-backends))) + (list dbus-glib + gobject-introspection + gusb-minimal + libgudev + libusb + polkit + python-wrapper + sqlite)) (home-page "https://www.freedesktop.org/software/colord/") (synopsis "Color management service") (description "Colord is a system service that makes it easy to manage, @@ -5810,6 +5599,7 @@ output devices.") (append '("-Dbash_completion=true" "-Ddocs=true" "-Dman=true" + "-Dsane=true" "-Dvapi=true") (fold delete #$flags '("-Dbash_completion=false" "-Ddocs=false" @@ -5830,6 +5620,7 @@ output devices.") gtk-doc/stable libxml2 ;for XML_CATALOG_FILES libxslt + sane-backends vala))))) ;for VAPI, needed by simple-scan (define-public geoclue @@ -6458,7 +6249,7 @@ without stepping on each others toes.") libxslt pkg-config)) (propagated-inputs - (list atk + (list at-spi2-core cairo cogl glib @@ -6845,7 +6636,7 @@ discovery protocols.") (inputs (list gtk+ gdk-pixbuf - atk + at-spi2-core cairo dbus-glib xorgproto @@ -6967,7 +6758,7 @@ which can read a large number of file formats.") ;;clutter-gtk ;;clutter-gst (list adwaita-icon-theme - atk + at-spi2-core bash-minimal brasero json-glib @@ -7296,76 +7087,6 @@ supports any scanner for which a suitable SANE driver is available, which is almost all of them.") (license license:gpl3+))) -(define-public eolie - (package - (name "eolie") - (version "0.9.101") - (source (origin - (method url-fetch) - (uri (string-append "https://adishatz.org/eolie/eolie-" - version ".tar.xz")) - (sha256 - (base32 - "1v8n21y75abdzsnx5idyd0q6yfb6cd0sqbknlbkwh5fdgvjzyvwn")))) - (build-system meson-build-system) - (arguments - `(#:glib-or-gtk? #t - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'skip-gtk-update-icon-cache - ;; Don't create 'icon-theme.cache'. - (lambda _ - (substitute* "meson_post_install.py" - (("gtk-update-icon-cache") "true")) - #t)) - (add-after 'wrap 'wrap-more - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - ;; These libraries must be on LD_LIBRARY_PATH. - (libs '("gtkspell3" "webkitgtk" "libsoup" "libsecret" - "atk" "gtk+" "gsettings-desktop-schemas" - "gobject-introspection")) - (path (string-join - (map (lambda (lib) - (string-append (assoc-ref inputs lib) "/lib")) - libs) - ":"))) - (wrap-program (string-append out "/bin/eolie") - `("LD_LIBRARY_PATH" ":" prefix (,path)) - `("GUIX_PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH"))) - `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH"))))) - #t))))) - (native-inputs - `(("intltool" ,intltool) - ("itstool" ,itstool) - ("pkg-config" ,pkg-config) - ("python" ,python) - ("glib:bin" ,glib "bin"))) - (inputs - `(("gobject-introspection" ,gobject-introspection) - ("glib-networking" ,glib-networking) - ("cairo" ,cairo) - ("gtk+" ,gtk+) - ("atk" ,atk) ; propagated by gtk+, but we need it in LD_LIBRARY_PATH - ("python" ,python-wrapper) - ("python-dateutil" ,python-dateutil) - ("python-pyfxa" ,python-pyfxa) - ("python-pygobject" ,python-pygobject) - ("python-pycairo" ,python-pycairo) - ("python-pycrypto" ,python-pycrypto) - ("libhandy" ,libhandy) - ("libsecret" ,libsecret) - ("gtkspell3" ,gtkspell3) - ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) - ("gnome-settings-daemon" ,gnome-settings-daemon) ; desktop-schemas are not enough - ("webkitgtk" ,webkitgtk-with-libsoup2))) - (home-page "https://wiki.gnome.org/Apps/Eolie") - (synopsis "Web browser for GNOME") - (description - "Eolie is a new web browser for GNOME. It features Firefox sync support, -a secret password store, an adblocker, and a modern UI.") - (license license:gpl3+))) - (define-public epiphany (package (name "epiphany") @@ -7550,16 +7271,13 @@ environments.") (base32 "19d46rkajvr0f04560vlrzwvac88x5j8ilvzwkawbn5vjg069kf8")))) (build-system gnu-build-system) (arguments - `(#:configure-flags - (list - "--enable-doc"))) + '(#:configure-flags '("--enable-doc"))) (native-inputs - `(("ducktype" ,mallard-ducktype) - ("gettext" ,gettext-minimal) - ("intltool" ,intltool) - ("itstool" ,itstool) - ("xmllint" ,libxml2) - ("xsltproc" ,libxslt))) + (list mallard-ducktype + gettext-minimal + itstool + libxml2 + libxslt)) (synopsis "XSL stylesheets for Yelp") (description "Yelp-XSL is a collection of programs and data files to help you build, maintain, and distribute documentation. It provides XSLT stylesheets @@ -7753,8 +7471,7 @@ metadata in photo and video files of various formats.") `(,glib "bin") itstool pkg-config - python - vala-next)) + python)) (inputs (list gcr gexiv2 @@ -7885,7 +7602,8 @@ configuration program to choose applications starting on login.") (define-public gjs (package (name "gjs") - (version "1.72.2") + ;; Note: We use a pre-release for compatibility with recent LibFFI. + (version "1.73.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -7893,7 +7611,7 @@ configuration program to choose applications starting on login.") name "-" version ".tar.xz")) (sha256 (base32 - "0xrrv9lsi087yb9yf146a1aarf5yh6rf4jw9blx30zasvjdkgvnx")) + "0xfspsc1q4xm7p500lmy17b9csyaqps1kilylq8wjjd0fjqq8ayg")) (modules '((guix build utils))) (snippet '(begin @@ -7924,7 +7642,7 @@ configuration program to choose applications starting on login.") xorg-server-for-tests)) (propagated-inputs ;; These are all in the Requires.private field of gjs-1.0.pc. - (list cairo gobject-introspection mozjs-91)) + (list cairo gobject-introspection mozjs)) (inputs (list gtk+ readline)) (synopsis "Javascript bindings for GNOME") @@ -8067,10 +7785,12 @@ to display dialog boxes from the commandline and shell scripts.") #~(list ;; Otherwise, the RUNPATH will lack the final path component. (string-append "-Dc_link_args=-Wl,-rpath=" - #$output "/lib:" - #$output "/lib/mutter-9") + #$output "/lib,-rpath=" + #$output "/lib/mutter-10") ;; Disable systemd support. "-Dsystemd=false" + ;; Don't install tests. + "-Dinstalled_tests=false" ;; The following flags are needed for the bundled clutter (string-append "-Dxwayland_path=" (search-input-file %build-inputs "bin/Xwayland")) @@ -8084,15 +7804,13 @@ to display dialog boxes from the commandline and shell scripts.") #:test-options '(list "--verbose") #:phases #~(modify-phases %standard-phases - (add-after 'unpack 'adjust-runpath-linker-directives + (add-after 'unpack 'use-RUNPATH-instead-of-RPATH (lambda _ - ;; By default Mutter uses RPATH instead of RUNPATH, which our - ;; customized linker script makes use of. Some libraries are - ;; also installed under lib/mutter-10 and need to be added to - ;; the RUNPATH. + ;; The build system disables RUNPATH in favor of RPATH to work + ;; around a peculiarity of their CI system. Ignore that. (substitute* "meson.build" - (("'-Wl,--disable-new-dtags'") - (string-append "'-Wl,-rpath=" #$output "/lib/mutter-10'"))))) + (("disable-new-dtags") + "enable-new-dtags")))) (add-after 'unpack 'patch-dlopen-calls (lambda* (#:key inputs #:allow-other-keys) (substitute* "src/wayland/meta-wayland-egl-stream.c" @@ -8180,7 +7898,7 @@ to display dialog boxes from the commandline and shell scripts.") autoconf automake libtool - wayland-protocols-next + wayland-protocols ;; For tests. ;; Warnings are configured to be fatal during the tests; add an icon ;; theme to please libxcursor. @@ -8195,7 +7913,7 @@ to display dialog boxes from the commandline and shell scripts.") (list gsettings-desktop-schemas-next ;required by libmutter.pc gtk+ ;required by libmutter.pc ;; mutter-clutter-1.0.pc and mutter-cogl-1.0.pc refer to these: - atk + at-spi2-core cairo eudev gdk-pixbuf @@ -8401,7 +8119,6 @@ Microsoft Exchange, Last.fm, IMAP/SMTP, Jabber, SIP and Kerberos.") libphonenumber mit-krb5 openldap - pango-next ;remove after it's the default webkitgtk)) (synopsis "Store address books and calendars") (home-page "https://wiki.gnome.org/Apps/Evolution") @@ -8580,11 +8297,6 @@ users.") ((".*test-lldp.*") "") ((".*test-route-linux.*") "") ((".*test-tc-linux.*") "")))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (substitute* (find-files "." ".*\\.(xsl|xml)") - (("http://.*/docbookx\\.dtd") - (search-input-file inputs "xml/dtd/docbook/docbookx.dtd"))))) (add-before 'check 'pre-check (lambda _ ;; For the missing /etc/machine-id. @@ -8709,8 +8421,7 @@ services.") libnma libsecret network-manager - openvpn - pango-next)) ;remove after it's the default + openvpn)) (home-page "https://wiki.gnome.org/Projects/NetworkManager/VPN") (synopsis "OpenVPN plug-in for NetworkManager") (description @@ -8760,8 +8471,7 @@ to virtual private networks (VPNs) via OpenVPN.") vpnc network-manager libnma - libsecret - pango-next)) ;TODO: remove after it's the default + libsecret)) ;TODO: remove after it's the default (home-page "https://wiki.gnome.org/Projects/NetworkManager/VPN") (synopsis "VPNC plug-in for NetworkManager") (description @@ -8813,8 +8523,7 @@ Compatible with Cisco VPN concentrators configured to use IPsec.") libxml2 lz4 network-manager - openconnect - pango-next)) ;TODO: remove after it's the default + openconnect)) (home-page "https://wiki.gnome.org/Projects/NetworkManager/VPN") (synopsis "OpenConnect plug-in for NetworkManager") (description @@ -8877,7 +8586,6 @@ Cisco's AnyConnect SSL VPN.") libsecret network-manager openfortivpn - pango-next ;TODO: remove after it's the default ppp)) (home-page "https://wiki.gnome.org/Projects/NetworkManager/VPN") (synopsis "Fortinet SSLVPN plug-in for NetworkManager") @@ -8966,30 +8674,6 @@ the available networks and allows users to easily switch between them.") (sha256 (base32 "13jlhz57yjxapplflm8aarczxv6ll3d336y1446mr5n4ylkcc1xz")))) (build-system gnu-build-system) - (arguments - (list - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'fix-documentation - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (let* ((xsl-version #$(package-version docbook-xsl)) - (xsldoc (string-append "xml/xsl/docbook-xsl-" - xsl-version))) - (substitute* '("examples/dom_xpath/example.xml" - "docs/manual/libxml++_without_code.xml") - (("http://.*/docbookx\\.dtd") - (search-input-file (or native-inputs inputs) - "xml/dtd/docbook/docbookx.dtd"))) - (setenv "SGML_CATALOG_FILES" - (search-input-file (or native-inputs inputs) - (string-append - xsldoc "/catalog.xml"))) - (substitute* "docs/manual/docbook-customisation.xsl" - (("http://docbook.sourceforge.net/release/xsl\ -/current/html/chunk.xsl") - (search-input-file (or native-inputs inputs) - (string-append xsldoc - "/html/chunk.xsl")))))))))) (propagated-inputs (list libxml2)) ;required by .pc file (native-inputs @@ -9304,8 +8988,6 @@ usage and information about running processes.") (list eudev gsound libnotify - ;; TODO: Delete pango-next after it's the default. - pango-next python-dbus upower)) (synopsis "GNOME Bluetooth subsystem") @@ -10018,10 +9700,9 @@ files.") python vala)) (inputs - (list gtk libadwaita libhandy - ;; XXX: Ensure pango-next is used instead of the equally propagated - ;; 'pango'. - pango-next)) + (list gtk + libadwaita + libhandy)) (synopsis "Disk usage analyzer for GNOME") (description "Baobab (Disk Usage Analyzer) is a graphical application to analyse disk @@ -10034,7 +9715,7 @@ is complete it provides a graphical representation of each selected folder.") (define-public gnome-backgrounds (package (name "gnome-backgrounds") - (version "41.0") + (version "42.0") (source (origin (method url-fetch) @@ -10043,7 +9724,7 @@ is complete it provides a graphical representation of each selected folder.") name "-" version ".tar.xz")) (sha256 (base32 - "0i9id5z72dqddh94648zylyf41amqq5lhny8sbyg1v8v4q6sr88x")))) + "0p99q434c8qgj5wxcma9jj4dh1ff9x984ncs31vmz725kyhf2zsc")))) (build-system meson-build-system) (native-inputs (list gettext-minimal)) (home-page "https://gitlab.gnome.org/GNOME/gnome-backgrounds") @@ -10059,73 +9740,81 @@ can add your own files to the collection.") license:cc-by-sa3.0)))) (define-public gnome-screenshot - (package - (name "gnome-screenshot") - (version "41.0") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "15wmikwk62cdi93gas77nqh4fbhlrxrncyfmcd1gfa34jbn7vnsa")))) - (build-system meson-build-system) - (arguments - `(#:meson ,meson-0.60 - #:glib-or-gtk? #t - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'skip-gtk-update-icon-cache - ;; Don't create 'icon-theme.cache'. - (lambda _ - (substitute* "build-aux/postinstall.py" - (("gtk-update-icon-cache") "true"))))))) - (native-inputs - (list appstream-glib - desktop-file-utils ; for update-desktop-database - gettext-minimal - `(,glib "bin") ; for glib-compile-schemas, etc. - pkg-config - python)) - (inputs - (list gtk+ - libhandy - libx11 - libxext)) - (home-page "https://gitlab.gnome.org/GNOME/gnome-screenshot") - (synopsis "Take pictures of your screen") - (description - "GNOME Screenshot is a utility used for taking screenshots of the entire + ;; GNOME Screenshot hasn't had a release in a long time, and the last one + ;; (41) doesn't build with a recent Meson. + (let ((commit "9f067cf428b6bac78ffac31c1a17a20fb2c24843") + (revision "0")) + (package + (name "gnome-screenshot") + (version (git-version "41.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.gnome.org/GNOME/gnome-screenshot") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10a3yd9qmfhxiw984a9fyvgrfq6i3w2yxayac0n7qqjl9ysxwb31")))) + (build-system meson-build-system) + (arguments + `(#:glib-or-gtk? #t + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'skip-gtk-update-icon-cache + ;; Don't create 'icon-theme.cache'. + (lambda _ + (substitute* "build-aux/postinstall.py" + (("gtk-update-icon-cache") "true"))))))) + (native-inputs + (list appstream-glib + desktop-file-utils ; for update-desktop-database + gettext-minimal + `(,glib "bin") ; for glib-compile-schemas, etc. + pkg-config + python)) + (inputs + (list gtk+ + libhandy + libx11 + libxext)) + (home-page "https://gitlab.gnome.org/GNOME/gnome-screenshot") + (synopsis "Take pictures of your screen") + (description + "GNOME Screenshot is a utility used for taking screenshots of the entire screen, a window or a user defined area of the screen, with optional beautifying border effects.") - (license license:gpl2+))) + (license license:gpl2+)))) (define-public dconf-editor (package (name "dconf-editor") - (version "3.38.3") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "1qvrxrk1h8bd75xwasxbvlkqrw6xkavjimvc7sslkw6lvb3z86jp")))) + (version "43.0") + (source (origin + (method url-fetch) + (uri (string-append "mirror://gnome/sources/" name "/" + (version-major version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "0dli166qzfphqlyvdx4nncg13ys7756sbsdfslyakhkcswnkqnlk")))) (build-system meson-build-system) (arguments - (list #:meson meson-0.60)) + (list #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'disable-gtk-update-icon-cache + (lambda _ + (setenv "DESTDIR" "/")))))) (native-inputs - `(("glib:bin" ,glib "bin") ; for glib-compile-schemas, gio-2.0. - ("gtk+-bin" ,gtk+ "bin") ; for gtk-update-icon-cache - ("intltool" ,intltool) - ("pkg-config" ,pkg-config) - ("vala" ,vala))) + (list `(,glib "bin") ;for glib-compile-schemas, gio-2.0 + `(,gtk "bin") ;for gtk-update-icon-cache + intltool + pkg-config + vala)) (inputs - (list dconf gtk+ libxml2)) + (list dconf + gtk+ + libhandy + libxml2)) (home-page "https://gitlab.gnome.org/GNOME/dconf-editor") (synopsis "Graphical editor for GNOME's dconf configuration system") (description @@ -10344,7 +10033,7 @@ world.") ;; Packages not part of GNOME proper but that are needed for a good ;; experience. See <https://bugs.gnu.org/39646>. ;; XXX: Find out exactly which ones are needed and why. - at-spi2-core-minimal + at-spi2-core dbus dconf desktop-file-utils @@ -10431,23 +10120,26 @@ specified duration and save it as a GIF encoded animated image file.") (base32 "1c4r9rnrz5gazrfg0z2rcwax4nscs7z391bcjcl74k6ln3blwzpr")))) (build-system meson-build-system) (arguments - `(#:meson ,meson-0.59 - #:glib-or-gtk? #t - #:phases - (modify-phases %standard-phases - (add-after 'glib-or-gtk-wrap 'python-and-gi-wrap - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((prog (string-append (assoc-ref outputs "out") - "/bin/authenticator")) - (pylib (string-append (assoc-ref outputs "out") - "/lib/python" - ,(version-major+minor - (package-version - (this-package-input "python"))) - "/site-packages"))) - (wrap-program prog - `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH") ,pylib)) - `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))))))))) + (list + #:glib-or-gtk? #t + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-meson.build + (lambda _ + (substitute* "data/meson.build" + (("^ 'desktop',.*") "") + (("^ 'appdata',.*") "")))) + (add-after 'glib-or-gtk-wrap 'python-and-gi-wrap + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((prog (search-input-file outputs "bin/authenticator")) + (pylib (string-append #$output "/lib/python" + #$(version-major+minor + (package-version + (this-package-input "python"))) + "/site-packages"))) + (wrap-program prog + `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH") ,pylib)) + `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))))))))) (native-inputs (list desktop-file-utils gettext-minimal @@ -10565,7 +10257,7 @@ Microsoft SkyDrive and Hotmail, using their REST protocols.") `(,glib "bin") ; for glib-compile-resources itstool pkg-config - vala-next)) + vala)) (inputs (list geoclue geocode-glib-with-libsoup2 @@ -10619,9 +10311,7 @@ desktop. It supports world clock, stop watch, alarms, and count down timer.") gsettings-desktop-schemas libadwaita libdazzle - libgweather4-with-libsoup2 - ;; Remove pango-next when it's the default. - pango-next)) + libgweather4-with-libsoup2)) (home-page "https://wiki.gnome.org/Apps/Calendar") (synopsis "GNOME's calendar application") (description @@ -11839,7 +11529,7 @@ micro-pauses and rest breaks, and restricts you to your daily limit.") pkg-config yelp-tools)) (inputs - (list atk + (list at-spi2-core gtk)) (synopsis "GNOME hexadecimal editor") (description "The GHex program can view and edit files in two ways: @@ -12101,30 +11791,20 @@ tabs, and it supports drag and drop re-ordering of terminals.") (base32 "1z8sbx7g19c1p8dy0sn0l25qfvrd2j28h269lsqm1y98r818h2k1")))) (build-system meson-build-system) (arguments - `(#:configure-flags - '("-Dglade_catalog=enabled" - ;; XXX: Generating the documentation fails because the - ;; libhandy.devhelp2 document cannot be created. This seems to be - ;; caused by a problem during the XSL transformation. - "-Dgtk_doc=false") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (for-each - (lambda (file) - (substitute* file - (("http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd") - (search-input-file inputs - "/xml/dtd/docbook/docbookx.dtd")))) - (find-files "doc" "\\.xml")))) - (add-before 'check 'pre-check - (lambda _ - ;; Tests require a running X server. - (system "Xvfb :1 &") - (setenv "DISPLAY" ":1")))))) - (inputs - (list gtk+ glade3)) + (list #:configure-flags + #~(list "-Dglade_catalog=enabled" + ;; XXX: Generating the documentation fails because the + ;; libhandy.devhelp2 document cannot be created. This seems + ;; to be caused by a problem during the XSL transformation. + "-Dgtk_doc=false") + #:phases + #~(modify-phases %standard-phases + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running X server. + (system "Xvfb :1 &") + (setenv "DISPLAY" ":1")))))) + (inputs (list gtk+ glade3)) (native-inputs (list gobject-introspection ; for g-ir-scanner `(,glib "bin") @@ -12331,39 +12011,44 @@ library which detects when a file or a directory has been modified.") (license license:gpl2+))) (define-public gnome-mahjongg - (package - (name "gnome-mahjongg") - (version "3.38.3") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" name "-" - version ".tar.xz")) - (sha256 - (base32 - "144ia3zn9rhwa1xbdkvsz6m0dsysl6mxvqw9bnrlh845hmyy9cfj")))) - (build-system meson-build-system) - (arguments - `(#:meson ,meson-0.59 - #:glib-or-gtk? #t)) - (native-inputs - `(("appstream-glib" ,appstream-glib) - ("gettext" ,gettext-minimal) - ("glib:bin" ,glib "bin") ;; For glib-compile-resources - ("gtk+" ,gtk+ "bin") ;; For gtk-update-icon-cache - ("itstool" ,itstool) - ("pkg-config" ,pkg-config) - ("vala" ,vala))) - (propagated-inputs - (list dconf)) - (inputs - (list glib gtk+)) - (synopsis "Mahjongg tile-matching game") - (description "GNOME Mahjongg is a game based on the classic Chinese + ;; There hasn't been a GNOME Mahjongg release in a long time, and the last + ;; release doesn't build with a recent Meson, so use the latest commit. + (let ((commit "e9e73e5165e5968ff897e568f8eba10fc1eb207b") + (revision "0")) + (package + (name "gnome-mahjongg") + (version (git-version "3.38.3" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.gnome.org/GNOME/gnome-mahjongg") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1cj0c076h7qfz77wpz8ypli60inj37fgw0cl9cc39b1kjfqcy3mb")))) + (build-system meson-build-system) + (arguments (list #:glib-or-gtk? #t)) + (native-inputs + (list appstream-glib + gettext-minimal + `(,glib "bin") ;for glib-compile-resources + `(,gtk "bin") ;for gtk-update-icon-cache + itstool + pkg-config + vala)) + (propagated-inputs + (list dconf)) + (inputs + (list glib + gtk + libadwaita)) + (synopsis "Mahjongg tile-matching game") + (description "GNOME Mahjongg is a game based on the classic Chinese tile-matching game Mahjongg. It features multiple board layouts, tile themes, and a high score table.") - (home-page "https://wiki.gnome.org/Apps/Mahjongg") - (license license:gpl2+))) + (home-page "https://wiki.gnome.org/Apps/Mahjongg") + (license license:gpl2+)))) (define-public gnome-themes-extra (package @@ -12549,13 +12234,13 @@ integrate seamlessly with the GNOME desktop.") itstool pkg-config python - vala-next)) + vala)) (inputs (list glib-networking ;for TLS support gsettings-desktop-schemas gtk gtk-vnc - gtksourceview + gtksourceview-4 json-glib libarchive libgudev @@ -13314,7 +12999,6 @@ profiler via Sysprof, debugging support, and more.") (arguments (list #:glib-or-gtk? #t - #:meson meson-0.63 #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch-sources @@ -13461,7 +13145,7 @@ your data.") libgda libhandy libsoup - pango-next)) + pango)) (propagated-inputs (list gtksourceview-4)) ; required for source view (home-page "https://wiki.gnome.org/Apps/Gtranslator") diff --git a/gnu/packages/gnupg.scm b/gnu/packages/gnupg.scm index ffd5d62a71..49d29ed9bd 100644 --- a/gnu/packages/gnupg.scm +++ b/gnu/packages/gnupg.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2017, 2020 Leo Famulari <leo@famulari.name> ;;; Copyright © 2017 Petter <petter@mykolab.ch> ;;; Copyright © 2018–2022 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2018, 2019 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2018, 2019, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling@bjoernhoefling.de> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Fredrik Salomonsson <plattfot@posteo.net> @@ -91,7 +91,7 @@ (define-public libgpg-error (package (name "libgpg-error") - (version "1.42") + (version "1.45") (source (origin (method url-fetch) @@ -99,7 +99,7 @@ version ".tar.bz2")) (sha256 (base32 - "08syj8mlarww8mh8x3s0x6hjqbnxp2lkg3hab57qqpv1dh7yf1zw")))) + "09haz1kk48b8q0hd58g98whylah0fp121yfgjms7pzsbzgj8w3sp")))) (build-system gnu-build-system) (arguments (if (%current-target-system) @@ -142,7 +142,7 @@ (_ #t))) (#t #t))))))) '())) - (native-inputs `(("gettext" ,gettext-minimal))) + (native-inputs (list gettext-minimal)) (home-page "https://gnupg.org") (synopsis "Library of error values for GnuPG components") (description @@ -157,14 +157,14 @@ Daemon and possibly more in the future.") (define-public libgcrypt (package (name "libgcrypt") - (version "1.8.8") + (version "1.10.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnupg/libgcrypt/libgcrypt-" version ".tar.bz2")) (sha256 (base32 - "1xasrh9zxhgj2n5n8dvpzbwn1mzpmlzy270xhbq2gl8xk2xy4pc9")))) + "1pp9zyx02bzgzjzldxf0mx9kp3530xgaaqcz4n2cv100ddaaw57g")))) (build-system gnu-build-system) (propagated-inputs `(("libgpg-error-host" ,libgpg-error))) @@ -176,10 +176,20 @@ Daemon and possibly more in the future.") ;; 'configure' uses 'gpg-error-config' to determine the '-L' flag, and ;; the 'gpg-error-config' it runs is the native one---i.e., the wrong one. `(#:configure-flags - (list (string-append "--with-gpg-error-prefix=" + (list (string-append "--with-libgpg-error-prefix=" (assoc-ref %build-inputs "libgpg-error-host")) - ;; When cross-compiling, _gcry_mpih_lshift etc are undefined - ,@(if (%current-target-system) '("--disable-asm") + ;; libgcrypt is transitioning from gpg-error-config to + ;; gpgrt-config, and in the process the + ;; --with-libgpg-error-config prefix defined above is + ;; not respected. See <https://dev.gnupg.org/T5365>. + ;; TODO: transition to pkg-config instead of these scripts. + (string-append "ac_cv_path_GPGRT_CONFIG=" + (assoc-ref %build-inputs + "libgpg-error-host") + "/bin/gpgrt-config") + ,@(if (%current-target-system) + ;; When cross-compiling, _gcry_mpih_lshift etc are undefined. + `("--disable-asm") '())))) (outputs '("out" "debug")) (home-page "https://gnupg.org/") @@ -223,8 +233,7 @@ provided.") (define-public libksba (package (name "libksba") - (version "1.6.0") - (replacement libksba/fixed) + (version "1.6.3") (source (origin (method url-fetch) @@ -233,7 +242,7 @@ provided.") version ".tar.bz2")) (sha256 (base32 - "12x40y9ihs8nw2xs2y2vjfw90mhikbm5rvabma0dh5frybk87mns")))) + "0p6y82j9y6n0l7scjgqhz3as9w13jiqjfx9n2jzynw89nf6wcwiz")))) (build-system gnu-build-system) (propagated-inputs (list libgpg-error)) @@ -254,18 +263,6 @@ specifications are building blocks of S/MIME and TLS.") (properties '((ftp-server . "ftp.gnupg.org") (ftp-directory . "/gcrypt/libksba"))))) -(define libksba/fixed - (package - (inherit libksba) - (version "1.6.3") - (source - (origin - (method url-fetch) - (uri (string-append - "mirror://gnupg/libksba/libksba-" version ".tar.bz2")) - (sha256 - (base32 "0p6y82j9y6n0l7scjgqhz3as9w13jiqjfx9n2jzynw89nf6wcwiz")))))) - (define-public npth (package (name "npth") @@ -295,10 +292,7 @@ compatible to GNU Pth.") (name "gnupg") ;; Note: The 2.2.X releases are Long Term Support (LTS), so stick to it ;; for our stable 'gnupg'. - ;; Note2: 2.2.33 currently suffers from regressions, so do not update to it - ;; (see: https://dev.gnupg.org/T5742). - (version "2.2.32") - (replacement gnupg/fixed) + (version "2.2.39") (source (origin (method url-fetch) (uri (string-append "mirror://gnupg/gnupg/gnupg-" version @@ -306,7 +300,7 @@ compatible to GNU Pth.") (patches (search-patches "gnupg-default-pinentry.patch")) (sha256 (base32 - "0506gv54z10c96z5821z9p0ksibk1pfilsmag39ffqrcz0sinmxj")))) + "0bscgv9gg9yhlpyia7b9l438cq6dvv6pwlhbl70df9phhmkdnx5b")))) (build-system gnu-build-system) (native-inputs (list pkg-config)) @@ -322,37 +316,39 @@ compatible to GNU Pth.") readline sqlite zlib)) - (arguments - `(#:configure-flags '(;; Otherwise, the test suite looks for the `gpg` - ;; executable in its installation directory in - ;; /gnu/store before it has been installed. - "--enable-gnupg-builddir-envvar" - "--enable-all-tests") + (arguments + (list + #:configure-flags #~'(;; Otherwise, the test suite looks for the `gpg` + ;; executable in its installation directory in + ;; /gnu/store before it has been installed. + "--enable-gnupg-builddir-envvar" + "--enable-all-tests") #:phases - (modify-phases %standard-phases - (add-before 'configure 'patch-paths - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "scd/scdaemon.c" - (("\"(libpcsclite\\.so[^\"]*)\"" _ name) - (string-append "\"" (assoc-ref inputs "pcsc-lite") - "/lib/" name "\""))))) - (add-after 'build 'patch-scheme-tests - (lambda _ - (substitute* (find-files "tests" ".\\.scm$") - (("/usr/bin/env gpgscm") - (string-append (getcwd) "/tests/gpgscm/gpgscm"))))) - (add-before 'build 'patch-test-paths - (lambda _ - (substitute* '("tests/inittests" - "tests/pkits/inittests" - "tests/Makefile" - "tests/pkits/common.sh" - "tests/pkits/Makefile") - (("/bin/pwd") (which "pwd"))) - (substitute* "common/t-exectool.c" - (("/bin/cat") (which "cat")) - (("/bin/true") (which "true")) - (("/bin/false") (which "false")))))))) + #~(modify-phases %standard-phases + (add-before 'configure 'patch-paths + (lambda* (#:key inputs #:allow-other-keys) + (let ((libpcsclite.so (search-input-file inputs + "lib/libpcsclite.so"))) + (substitute* "scd/scdaemon.c" + (("libpcsclite\\.so") + libpcsclite.so))))) + (add-after 'build 'patch-scheme-tests + (lambda _ + (substitute* (find-files "tests" ".\\.scm$") + (("/usr/bin/env gpgscm") + (string-append (getcwd) "/tests/gpgscm/gpgscm"))))) + (add-before 'build 'patch-test-paths + (lambda _ + (substitute* '("tests/inittests" + "tests/pkits/inittests" + "tests/Makefile" + "tests/pkits/common.sh" + "tests/pkits/Makefile") + (("/bin/pwd") (which "pwd"))) + (substitute* "common/t-exectool.c" + (("/bin/cat") (which "cat")) + (("/bin/true") (which "true")) + (("/bin/false") (which "false")))))))) (home-page "https://gnupg.org/") (synopsis "GNU Privacy Guard") (description @@ -366,15 +362,6 @@ libskba (working with X.509 certificates and CMS data).") (properties '((ftp-server . "ftp.gnupg.org") (ftp-directory . "/gcrypt/gnupg"))))) -(define gnupg/fixed - (package - (inherit gnupg) - (source (origin - (inherit (package-source gnupg)) - (patches - (append (origin-patches (package-source gnupg)) - (search-patches "gnupg-CVE-2022-34903.patch"))))))) - (define-public gnupg-1 (package (inherit gnupg) (version "1.4.23") @@ -400,21 +387,19 @@ libskba (working with X.509 certificates and CMS data).") (define-public gpgme (package (name "gpgme") - (version "1.15.1") + (version "1.18.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnupg/gpgme/gpgme-" version ".tar.bz2")) (sha256 - (base32 "1bg13l5s8x9p1v0jyv29n84bay27pflindpzjsc9gj7i4wdkrg7f")))) + (base32 "17hfigfnq6xz45b5xrp299f68b5mwx0aysd51sx5v4nf8yp4w79n")))) (build-system gnu-build-system) (native-inputs (list gnupg)) (propagated-inputs - ;; Needs to be propagated because gpgme.h includes gpg-error.h. - (list libgpg-error)) - (inputs - (list libassuan)) + ;; As required by the pkg-config's Requires.private. + (list libgpg-error libassuan)) (home-page "https://www.gnupg.org/related_software/gpgme/") (synopsis "Library providing simplified access to GnuPG functionality") (description @@ -431,19 +416,6 @@ and every application benefits from this.") (properties '((ftp-server . "ftp.gnupg.org") (ftp-directory . "/gcrypt/gpgme"))))) -;; TODO: Merge with gpgme in the next rebuild cycle. -(define-public gpgme-1.18 - (package - (inherit gpgme) - (version "1.18.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnupg/gpgme/gpgme-" - version ".tar.bz2")) - (sha256 - (base32 - "17hfigfnq6xz45b5xrp299f68b5mwx0aysd51sx5v4nf8yp4w79n")))))) - (define-public qgpgme (package (inherit gpgme) @@ -472,16 +444,6 @@ QGpgME was originally developed as part of libkleo and incorporated into gpgpme starting with version 1.7.") (license license:gpl2+))) ;; Note: this differs from gpgme -;; TODO: Merge with qgpgme in the next rebuild cycle. -(define-public qgpgme-1.18 - (package - (inherit qgpgme) - (version (package-version gpgme-1.18)) - (source (package-source gpgme-1.18)) - (inputs - (modify-inputs (package-inputs qgpgme) - (replace "gpgme" gpgme-1.18))))) - (define-public guile-gcrypt (package (name "guile-gcrypt") diff --git a/gnu/packages/gnuzilla.scm b/gnu/packages/gnuzilla.scm index ace6662d48..fa90c38951 100644 --- a/gnu/packages/gnuzilla.scm +++ b/gnu/packages/gnuzilla.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr> -;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2013-2022 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> ;;; Copyright © 2016, 2017, 2018, 2019, 2021 Efraim Flashner <efraim@flashner.co.il> @@ -55,6 +55,7 @@ #:use-module (guix build-system copy) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) + #:use-module (guix build-system mozilla) #:use-module (gnu packages admin) #:use-module (gnu packages audio) #:use-module (gnu packages autotools) @@ -210,7 +211,7 @@ fractional-second-digits-append-item.js") rust `(,rust "cargo"))) (inputs - (list icu4c-71 readline zlib)) + (list icu4c readline zlib)) (propagated-inputs (list nspr)) ; in the Requires.private field of mozjs-*.pc (home-page @@ -249,7 +250,7 @@ in C/C++.") (delete-file "non262/Intl/DateTimeFormat/tz-environment-variable.js")))))))) (inputs (modify-inputs (package-inputs mozjs) - (replace "icu4c" icu4c))))) + (replace "icu4c" icu4c-69))))) (define-public mozjs-78 (package @@ -269,6 +270,25 @@ in C/C++.") (substitute-keyword-arguments (package-arguments mozjs) ((#:phases phases) #~(modify-phases #$phases + (add-after 'unpack 'patch-for-python-3.10 + (lambda _ + ;; Some classes were moved from collections to collections.abc + ;; in Python 3.10. + (substitute* "python/mozbuild/mozbuild/util.py" + (("collections\\.Sequence") + "collections.abc.Sequence")) + (substitute* "python/mozbuild/mozbuild/makeutil.py" + (("from collections import Iterable") + "from collections.abc import Iterable")) + (substitute* "python/mozbuild/mozbuild/backend/configenvironment.py" + (("from collections import Iterable, OrderedDict") + "from collections import OrderedDict\n\ +from collections.abc import Iterable")) + (substitute* + "testing/mozbase/manifestparser/manifestparser/filters.py" + (("from collections import defaultdict, MutableSequence") + "from collections import defaultdict\n\ +from collections.abc import MutableSequence")))) (replace 'configure (lambda* (#:key configure-flags #:allow-other-keys) ;; The configure script does not accept environment variables as @@ -351,7 +371,7 @@ in C/C++.") rust `(,rust "cargo"))) (inputs - (list icu4c readline zlib)))) + (list icu4c-69 readline zlib)))) ;;; @@ -675,7 +695,7 @@ variable defined below. It requires guile-json to be installed." (name "icecat-minimal") (version %icecat-version) (source icecat-source) - (build-system gnu-build-system) + (build-system mozilla-build-system) (inputs (list alsa-lib bzip2 @@ -708,7 +728,7 @@ variable defined below. It requires guile-json to be installed." ;; https://bugzilla.mozilla.org/show_bug.cgi?id=1819374). ffmpeg-5 libvpx - icu4c-71 ;TODO: Change to 'icu4c' when its version is >= 71. + icu4c pixman pulseaudio mesa @@ -716,8 +736,8 @@ variable defined below. It requires guile-json to be installed." mit-krb5 hunspell libnotify - nspr-next - nss-next + nspr + nss shared-mime-info sqlite eudev @@ -1504,7 +1524,7 @@ ca495991b7852b855")) gtk+ gtk+-2 hunspell - icu4c-71 + icu4c libcanberra libevent libffi @@ -1520,7 +1540,7 @@ ca495991b7852b855")) libxt mesa mit-krb5 - nss-next + nss pango pixman pulseaudio diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 27f62ea867..98b0223110 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -361,65 +361,59 @@ objects!") (license license:lgpl2.1+))) (define-public autotrace - (let ((commit "travis-20190624.59") - (version-base "0.40.0")) - (package - (name "autotrace") - (version (string-append version-base "-" - (if (string-prefix? "travis-" commit) - (string-drop commit 7) - commit))) - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/autotrace/autotrace") - (commit commit))) - (file-name (git-file-name name version)) - (patches (search-patches "autotrace-glib-compat.patch")) - (sha256 - (base32 - "0mk4yavy42dj0pszr1ggnggpvmzs4ds46caa9wr55cqsypn7bq6s")))) - (build-system gnu-build-system) - (arguments - `(#:phases (modify-phases %standard-phases - ;; See: https://github.com/autotrace/autotrace/issues/27. - (add-after 'unpack 'include-spline.h-header - (lambda _ - (substitute* "Makefile.am" - ((".*src/types.h.*" all) - (string-append all "\t\tsrc/spline.h \\\n"))) - #t)) - ;; See: https://github.com/autotrace/autotrace/issues/26. - (replace 'check - (lambda _ - (invoke "sh" "tests/runtests.sh")))))) - (native-inputs - `(("which" ,which) - ("pkg-config" ,pkg-config) - ("autoconf" ,autoconf) - ("automake" ,automake) - ("intltool" ,intltool) - ("libtool" ,libtool) - ("gettext" ,gettext-minimal))) - (inputs - `(("glib" ,glib) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("imagemagick" ,imagemagick) - ("pstoedit" ,pstoedit))) - (home-page "https://github.com/autotrace/autotrace") - (synopsis "Bitmap to vector graphics converter") - (description "AutoTrace is a utility for converting bitmap into vector + (package + (name "autotrace") + (version "0.31.9") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/autotrace/autotrace") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0fsg13pg72ac51l3fkzvyf7h9mzbvfxp9vfjfiwkyvx6hbm83apj")))) + (build-system gnu-build-system) + (arguments + (list #:configure-flags #~'("--disable-static") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-pkg-config-file + (lambda _ + ;; autotrace can be built against either GraphicsMagick or + ;; ImageMagick. However the pkg-config file refers to + ;; non-existent MAGICK_ variables instead of GRAPHICSMAGICK_ + ;; or IMAGEMAGICK_; fix that. + (substitute* "autotrace.pc.in" + (("@MAGICK_(LIBS|CFLAGS)@" _ var) + (string-append "@IMAGEMAGICK_" var "@")))))))) + (native-inputs + (list which + autoconf + automake + libtool + intltool + pkg-config + procps)) ;for tests + (inputs + (list glib + imagemagick + libjpeg-turbo + libpng + pstoedit)) + (home-page "https://github.com/autotrace/autotrace") + (synopsis "Bitmap to vector graphics converter") + (description "AutoTrace is a utility for converting bitmap into vector graphics. It can trace outlines and midlines, effect color reduction or despeckling and has support for many input and output formats. It can be used with the @command{autotrace} utility or as a C library, @code{libautotrace}.") - (license (list license:gpl2+ ;for the utility itself - license:lgpl2.1+))))) ;for use as a library + (license (list license:gpl2+ ;for the utility itself + license:lgpl2.1+)))) ;for use as a library (define-public embree (package (name "embree") - (version "3.12.1") + (version "3.13.5") (source (origin (method git-fetch) (uri (git-reference @@ -428,7 +422,7 @@ with the @command{autotrace} utility or as a C library, @code{libautotrace}.") (file-name (git-file-name name version)) (sha256 (base32 - "0aznd16n7h8g3f6jcahzfp1dq4r7wayqvn03wsaskiq2dvsi4srd")))) + "1kcvz7g6j56anv9zjyd3gidxl46vipw0gg82lns12m45cd43iwxm")))) (build-system cmake-build-system) (arguments `(#:tests? #f ; no tests (apparently) @@ -867,7 +861,7 @@ exception-handling library.") (define-public lib2geom (package (name "lib2geom") - (version "1.1") + (version "1.2") (source (origin (method git-fetch) (uri (git-reference @@ -876,7 +870,7 @@ exception-handling library.") (file-name (git-file-name name version)) (sha256 (base32 - "03bx9k1m4bfhmx0ldsg0bks6i8h7fmvl5vbg6gmpq0bk0nkmpnmv")))) + "0dq981g894hmvhd6rmfl1w32mksg9hpvpjs1qvfxrnz87rhkknj8")))) (build-system cmake-build-system) (arguments `(#:imported-modules ((guix build python-build-system) @@ -933,20 +927,6 @@ basic geometries.") ;; https://gitlab.com/inkscape/inkscape/issues/784). (license license:gpl3+))) -(define-public lib2geom-1.2 - (package - (inherit lib2geom) - (version "1.2") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://gitlab.com/inkscape/lib2geom") - (commit version))) - (file-name (git-file-name "lib2geom" version)) - (sha256 - (base32 - "0dq981g894hmvhd6rmfl1w32mksg9hpvpjs1qvfxrnz87rhkknj8")))))) - (define-public python-booleanoperations (package (name "python-booleanoperations") @@ -958,7 +938,7 @@ basic geometries.") (sha256 (base32 "1f41lb19m8azchl1aqz6j5ycbspb8jsf1cnn42hlydxd68f85ylc")))) (build-system python-build-system) - (propagated-inputs (list python-fonttools python-pyclipper)) + (propagated-inputs (list python-fonttools-minimal python-pyclipper)) (native-inputs (list python-defcon-bootstrap python-fontpens-bootstrap diff --git a/gnu/packages/graphviz.scm b/gnu/packages/graphviz.scm index f1038a83eb..73d07e913f 100644 --- a/gnu/packages/graphviz.scm +++ b/gnu/packages/graphviz.scm @@ -68,7 +68,7 @@ (define-public graphviz (package (name "graphviz") - (version "2.49.0") + (version "7.0.1") (source (origin (method url-fetch) (uri (string-append "https://gitlab.com/api/v4/projects/4207231" @@ -76,24 +76,16 @@ version "/graphviz-" version ".tar.xz")) (sha256 (base32 - "042s6mbi681pwgffqww2ap780230nrsrfpfiz9a41dcjb5a0m524")))) + "1b6x3g03j7q77lzyvdp34hkzld5sg1l1ippc6sh1qxnmm59xs3ly")))) (build-system gnu-build-system) (arguments ;; FIXME: rtest/rtest.sh is a ksh script (!). Add ksh as an input. (list #:tests? #f #:phases #~(modify-phases %standard-phases - (add-after 'install 'move-docs + (add-after 'install 'move-guile-bindings (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share/graphviz")) - (rename-file (string-append out "/share/graphviz/doc") - (string-append doc "/share/graphviz/doc"))))) - (add-after 'move-docs 'move-guile-bindings - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lib (string-append out "/lib")) + (let* ((lib (string-append #$output "/lib")) (extdir (string-append lib "/guile/" #$(version-major+minor (package-version @@ -105,22 +97,24 @@ (string-append extdir "/libgv_guile.so")))))))) (inputs - `(("libXrender" ,libxrender) - ("libX11" ,libx11) - ("gts" ,gts) - ("gd" ,gd) - ("guile" ,guile-3.0) ;Guile bindings - ("pango" ,pango) - ("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("libltdl" ,libltdl) - ("libXaw" ,libxaw) - ("expat" ,expat) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng))) + (list libxrender + libx11 + gts + gd + guile-3.0 ;Guile bindings + pango + fontconfig + freetype + libltdl + libxaw + expat + libjpeg-turbo + libpng)) (native-inputs - (list bison swig pkg-config)) - (outputs '("out" "doc")) ; 5 MiB of html + pdfs + (list bison + pkg-config + swig)) + (outputs '("out" "doc")) ;5 MiB of html + pdfs (home-page "https://www.graphviz.org/") (synopsis "Graph visualization software") (description @@ -200,6 +194,7 @@ interfaces for other technical domains.") (list unzip ;; For tests. graphviz + python-mock python-pytest python-pytest-cov python-pytest-mock)) @@ -346,12 +341,12 @@ Graphviz and LaTeX.") (assoc-ref inputs "gtk+") "/lib/girepository-1.0" ":" (assoc-ref inputs "pango") "/lib/girepository-1.0" ":" (assoc-ref inputs "gdk-pixbuf") "/lib/girepository-1.0" - ":" (assoc-ref inputs "atk") "/lib/girepository-1.0" + ":" (assoc-ref inputs "at-spi2-core") "/lib/girepository-1.0" ":" (assoc-ref inputs "harfbuzz") "/lib/girepository-1.0"))) `("PATH" ":" prefix (,(dirname (search-input-file inputs "bin/dot")))))))))) (inputs - (list atk + (list at-spi2-core (librsvg-for-system) harfbuzz graphviz @@ -433,8 +428,8 @@ graphs in Graphviz's DOT language, written in pure Python.") ;; the resulting generated TeX files, which \usepackage them. texlive-bin texlive-amsmath + texlive-graphics texlive-latex-geometry - texlive-latex-graphics texlive-latex-base texlive-latex-preview texlive-latex-xkeyval diff --git a/gnu/packages/gsasl.scm b/gnu/packages/gsasl.scm index 70624f9c59..2923bd6465 100644 --- a/gnu/packages/gsasl.scm +++ b/gnu/packages/gsasl.scm @@ -77,14 +77,14 @@ the underlying security implementation.") (define-public gsasl (package (name "gsasl") - (version "2.0.1") + (version "2.2.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gsasl/gsasl-" version ".tar.gz")) (sha256 (base32 - "0yhvq3n6smgnc7fp0smmly8d248248xr7q2apbcbqhc80117ab1j")))) + "0nbp62isfdfrsnp34vfkwinfjyw9x05clacvsn2c8vcpp7inif3r")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--with-gssapi-impl=mit" diff --git a/gnu/packages/gstreamer.scm b/gnu/packages/gstreamer.scm index 0d051438e3..8971c11479 100644 --- a/gnu/packages/gstreamer.scm +++ b/gnu/packages/gstreamer.scm @@ -245,10 +245,7 @@ and very fast.") (chdir "libvisual") #t))))) (native-inputs - `(("gettext" ,gettext-minimal) - ("libintl" ,intltool) - ("libtool" ,libtool) - ("pkg-config" ,pkg-config))) + (list gettext-minimal intltool libtool pkg-config)) (inputs (list sdl)) (native-search-paths @@ -300,20 +297,20 @@ applications that want audio visualisation and audio visualisation plugins.") (chdir "libvisual-plugins") #t))))) (native-inputs - `(("bison" ,bison) - ("flex" ,flex) - ("gettext" ,gettext-minimal) - ("libintl" ,intltool) - ("libtool" ,libtool) - ("pkg-config" ,pkg-config))) + (list bison + flex + gettext-minimal + intltool + libtool + pkg-config)) (inputs - `(("alsa-lib" ,alsa-lib) - ("esound" ,esound) - ("librsvg" ,librsvg) - ("gtk+" ,gtk+-2) - ("jack" ,jack-2) - ("libx11" ,libx11) - ("libxext" ,libxext))) + (list alsa-lib + esound + librsvg + gtk+-2 + jack-2 + libx11 + libxext)) (propagated-inputs (list libvisual)) (synopsis "Audio visualisation library") @@ -477,7 +474,6 @@ the GStreamer multimedia framework.") (build-system meson-build-system) (arguments (list #:disallowed-references (list python) - #:meson meson-0.63 #:phases #~(modify-phases %standard-phases #$@%common-gstreamer-phases @@ -593,7 +589,6 @@ This package provides the core library and elements.") xorg-server-for-tests)) (arguments (list - #:meson meson-0.63 #:phases #~(modify-phases %standard-phases #$@%common-gstreamer-phases @@ -659,7 +654,6 @@ for the GStreamer multimedia library.") (build-system meson-build-system) (arguments (list - #:meson meson-0.63 #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas #:phases #~(modify-phases %standard-phases @@ -782,7 +776,6 @@ model to base your own plug-in on, here it is.") (build-system meson-build-system) (arguments (list - #:meson meson-0.63 #:configure-flags #~(list "-Dsctp-internal-usrsctp=disabled") #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas #:phases @@ -961,8 +954,7 @@ par compared to the rest.") (base32 "1486x08bwasq6l7kc75nph5az61siq9mbgkgpw4kf1mxn16z8c4g")))) (build-system meson-build-system) (arguments - (list #:meson meson-0.63 - #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas + (list #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas #:phases #~(modify-phases %standard-phases #$@%common-gstreamer-phases @@ -1019,13 +1011,9 @@ think twice about shipping them.") (sha256 (base32 "1zfg7giwampmjxkqr5pqy66vck42b0akmwby661brwz8iy3zkapw")))) (build-system meson-build-system) - (arguments (list #:meson meson-0.63)) - (native-inputs - (list perl pkg-config python-wrapper ruby)) - (inputs - (list ffmpeg)) - (propagated-inputs - (list gstreamer gst-plugins-base)) + (native-inputs (list perl pkg-config python-wrapper ruby)) + (inputs (list ffmpeg)) + (propagated-inputs (list gstreamer gst-plugins-base)) (synopsis "GStreamer plugins and helper libraries") (description "Gst-Libav contains a GStreamer plugin for using the encoders, decoders, muxers, and demuxers provided by FFmpeg.") @@ -1047,7 +1035,6 @@ decoders, muxers, and demuxers provided by FFmpeg.") (build-system meson-build-system) (arguments (list - #:meson meson-0.63 #:tests? #f ; FIXME: 16/23 failing tests. #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas #:phases #~(modify-phases %standard-phases @@ -1116,7 +1103,6 @@ binary, but none of the actual plugins."))) (build-system meson-build-system) (arguments (list - #:meson meson-0.63 #:modules `((guix build meson-build-system) (guix build utils) ((guix build python-build-system) #:prefix python:)) diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index e4026c601f..1d547d6ac7 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -24,7 +24,7 @@ ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org> ;;; Copyright © 2020 Brendan Tildesley <mail@brendan.scot> ;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net> -;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Leo Famulari <leo@famulari.name> ;;; Copyright © 2021 Simon Streit <simon@netpanic.org> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> @@ -158,41 +158,6 @@ such as mate-panel and xfce4-panel.") (home-page "https://gitlab.com/vala-panel-project/vala-panel-appmenu") (license (list license:lgpl3)))) -(define-public atk - (package - (name "atk") - (version "2.36.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "1217cmmykjgkkim0zr1lv5j13733m4w5vipmy4ivw0ll6rz28xpv")))) - (build-system meson-build-system) - (arguments - `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - ,@(if (%current-target-system) - `(#:configure-flags - ;; introspection requires running binaries for the host system - ;; on the build system. - '("-Dintrospection=false")) - '()))) - (propagated-inputs (list glib)) ; required by atk.pc - (native-inputs - `(("gettext" ,gettext-minimal) - ("glib" ,glib "bin") ; glib-mkenums, etc. - ("gobject-introspection" ,gobject-introspection) ; g-ir-compiler, etc. - ("pkg-config" ,pkg-config))) - (synopsis "GNOME accessibility toolkit") - (description - "ATK provides the set of accessibility interfaces that are implemented -by other toolkits and applications. Using the ATK interfaces, accessibility -tools have full access to view and control running applications.") - (license license:lgpl2.1+) - (home-page "https://wiki.gnome.org/Accessibility"))) - (define-public cairo (package (name "cairo") @@ -233,7 +198,7 @@ tools have full access to view and control running applications.") ("pkg-config" ,pkg-config) ("python" ,python-wrapper))) (inputs - `(("bash-minimal" ,bash-minimal) + `(("bash-minimal" ,bash-minimal) ;for glib-or-gtk-wrap ("drm" ,libdrm) ("ghostscript" ,ghostscript) ("libspectre" ,libspectre) @@ -285,67 +250,41 @@ output. Experimental backends include OpenGL, BeOS, OS/2, and DirectFB.") (define-public harfbuzz (package - (name "harfbuzz") - (version "2.8.2") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/harfbuzz/harfbuzz" - "/releases/download/" version "/harfbuzz-" - version ".tar.xz")) - (sha256 - (base32 - "1rvv86wpm3y04fqns1655268rhvhvms469837709v2z2bhwn316m")))) - (build-system gnu-build-system) - (outputs '("out" - "bin")) ; 160K, only hb-view depend on cairo - (inputs - (list cairo)) - (propagated-inputs - ;; There are all in the Requires or Requires.private field of '.pc'. - (list glib graphite2 icu4c)) - (native-inputs - `(("glib:bin" ,glib "bin") ;for glib-mkenums - ("gobject-introspection" ,gobject-introspection) - ("pkg-config" ,pkg-config) - ("python" ,python-wrapper) - ("which" ,which))) - (arguments - `(#:configure-flags `("--with-graphite2" - "--with-gobject" - ,(string-append - "--bindir=" (assoc-ref %outputs "bin") "/bin")))) - (synopsis "OpenType text shaping engine") - (description - "HarfBuzz is an OpenType text shaping engine.") - (license (license:x11-style "file://COPYING" - "See 'COPYING' in the distribution.")) - (home-page "https://www.freedesktop.org/wiki/Software/HarfBuzz/"))) - -(define-public harfbuzz-3 - (package - (inherit harfbuzz) - (version "3.4.0") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/harfbuzz/harfbuzz" - "/releases/download/" version - "/harfbuzz-" version ".tar.xz")) - (sha256 - (base32 - "0lprrl8iih8ji1n17xwm5llz05a1hv4g04b7a3y229dq9myahn3i")))))) - -(define-public harfbuzz-4 - (package - (inherit harfbuzz) - (version "4.3.0") + (name "harfbuzz") + (version "5.3.1") (source (origin (method url-fetch) (uri (string-append "https://github.com/harfbuzz/harfbuzz" - "/releases/download/" version - "/harfbuzz-" version ".tar.xz")) + "/releases/download/" version "/harfbuzz-" + version ".tar.xz")) (sha256 (base32 - "0c5mzwgz43d37h75p4b6cgjg4v24jdd96i7gjpgxirn8qks2i5m4")))))) + "0ka3nkk2lks2lgakq02vyibwdziv11dkpa2brkx230asnyby0v2a")))) + (build-system gnu-build-system) + (outputs '("out" + "bin")) ;160K, only hb-view depend on cairo + (inputs + (list cairo)) + (propagated-inputs + ;; There are all in the Requires or Requires.private field of '.pc'. + (list glib graphite2 icu4c)) + (native-inputs + (list `(,glib "bin") ;for glib-mkenums + gobject-introspection + pkg-config + python-wrapper + which)) + (arguments + (list #:configure-flags + #~(list "--with-graphite2" + "--with-gobject" + (string-append "--bindir=" #$output:bin "/bin")))) + (synopsis "OpenType text shaping engine") + (description + "HarfBuzz is an OpenType text shaping engine.") + (license (license:x11-style "file://COPYING" + "See 'COPYING' in the distribution.")) + (home-page "https://www.freedesktop.org/wiki/Software/HarfBuzz/"))) (define-public harfbuzz-5 @@ -394,7 +333,7 @@ representing trie. Trie is a kind of digital search tree.") (define-public libthai (package (name "libthai") - (version "0.1.28") + (version "0.1.29") (source (origin (method url-fetch) @@ -402,7 +341,7 @@ representing trie. Trie is a kind of digital search tree.") (string-append "https://linux.thai.net/pub/thailinux/software/" "libthai/libthai-" version ".tar.xz")) (sha256 - (base32 "04g93bgxrcnay9fglpq2lj9nr7x1xh06i60m7haip8as9dxs3q7z")))) + (base32 "1kab1w6i1fb76807xrwjfac8n2nky8jbvkhpnh117qahrdywr07w")))) (build-system gnu-build-system) (outputs '("out" "doc")) (arguments @@ -427,7 +366,7 @@ applications.") (define-public pango (package (name "pango") - (version "1.48.10") + (version "1.50.10") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/pango/" @@ -436,7 +375,7 @@ applications.") (patches (search-patches "pango-skip-libthai-test.patch")) (sha256 (base32 - "166wxhsjb6hb0dk7wkkdcmpvasl9n0a0aa64mdgagzfdidwzbq91")))) + "0rj9sszflckk8gj47ppirpndpp3mzsx97l64lalj8kc580g2ypby")))) (build-system meson-build-system) (arguments '(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas @@ -452,26 +391,27 @@ applications.") (("\\[ 'test-harfbuzz'.*") ""))))))) (propagated-inputs ;; These are all in Requires or Requires.private of the '.pc' files. - `(("cairo" ,cairo) - ("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("fribidi" ,fribidi) - ("glib" ,glib) - ("harfbuzz" ,harfbuzz) - ("libthai" ,libthai) - ;; Some packages, such as Openbox, expect Pango to be built with the - ;; optional libxft support. - ("libxft" ,libxft) - ("libxrender" ,libxrender))) + (list cairo + fontconfig + freetype + fribidi + glib + harfbuzz + libthai + ;; Some packages, such as Openbox, expect Pango to be built with the + ;; optional libxft support. + libxft + libxrender)) (inputs - (list bash-minimal zlib)) + (list bash-minimal + zlib)) (native-inputs - `(("glib" ,glib "bin") ; glib-mkenums, etc. - ("gobject-introspection" ,gobject-introspection) ; g-ir-compiler, etc. - ("help2man" ,help2man) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("python" ,python-wrapper))) + (list `(,glib "bin") ;glib-mkenums, etc. + gobject-introspection ;g-ir-compiler, etc. + help2man + perl + pkg-config + python-wrapper)) (synopsis "Text and font handling library") (description "Pango is a library for laying out and rendering of text, with an emphasis on internationalization. Pango can be used anywhere that text @@ -481,22 +421,6 @@ handling for GTK+-2.x.") (home-page "https://pango.gnome.org/") (license license:lgpl2.0+))) -;; TODO: Make this the default package in next release cycle. -(define-public pango-next - (package - (inherit pango) - (name "pango-next") ;to avoid profile conflicts - (version "1.50.4") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/pango/" - (version-major+minor version) - "/pango-" version ".tar.xz")) - (patches (search-patches "pango-skip-libthai-test.patch")) - (sha256 - (base32 - "0qn1a7ccs3p5vc6swbqm6hdzka879l0gp9220lq4bcf2gpl67bgl")))))) - (define-public pango-1.42 (package (inherit pango) @@ -543,9 +467,7 @@ handling for GTK+-2.x.") #~(begin (substitute* "pango/pangocairo-font.c" (("cairo_user_font_face_set_render_color_glyph_func") - "cairo_user_font_face_set_render_glyph_func")))))) - (inputs (modify-inputs (package-inputs pango) - (prepend harfbuzz-4))))) + "cairo_user_font_face_set_render_glyph_func")))))))) (define-public pangox-compat (package @@ -713,8 +635,8 @@ printing and other features typical of a source code editor.") glib-next gtk libxml2 - pcre2 - pango-next)) + pango + pcre2)) (home-page "https://wiki.gnome.org/Projects/GtkSourceView") (synopsis "GNOME source code widget") (description "GtkSourceView is a text widget that extends the standard @@ -741,7 +663,6 @@ highlighting and other features typical of a source code editor.") (propagated-inputs (modify-inputs (package-propagated-inputs gtksourceview) (replace "gtk" gtk+) - (replace "pango-next" pango) (replace "glib" glib))))) (define-public gtksourceview-3 @@ -766,7 +687,7 @@ highlighting and other features typical of a source code editor.") (define-public gdk-pixbuf (package (name "gdk-pixbuf") - (version "2.42.4") + (version "2.42.8") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -774,7 +695,7 @@ highlighting and other features typical of a source code editor.") name "-" version ".tar.xz")) (sha256 (base32 - "0k9f9177qxaryaxprwrhqnv5p2gdq4a8i6y05gm98qa8izc5v77y")))) + "1iplb43nn74pp3w1wjwwn522i9man6jia85k6j8v4494rcxfmb44")))) (build-system meson-build-system) (outputs '("out" "debug")) (arguments @@ -782,57 +703,42 @@ highlighting and other features typical of a source code editor.") #:configure-flags '("-Dinstalled_tests=false") #:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* "meson.build" - (("http://docbook.sourceforge.net/release/xsl/current/") - (string-append (assoc-ref ,(if (%current-target-system) - '(or native-inputs inputs) - 'inputs) "docbook-xsl") - "/xml/xsl/docbook-xsl-1.79.2/"))) - (substitute* (find-files "." "\\.xml$") - (("http://www.oasis-open.org/docbook/xml/4\\.3/") - (string-append (assoc-ref ,(if (%current-target-system) - '(or native-inputs inputs) - 'inputs) "docbook-xml") - "/xml/dtd/docbook/")))))) (add-before 'configure 'disable-failing-tests (lambda _ (substitute* "tests/meson.build" (("\\[ 'pixbuf-fail', \\['conform', 'slow'\\], \\],") "")))) ;; The slow tests take longer than the specified timeout. - ,@(if (any (cute string=? <> (%current-system)) - '("armhf-linux" "aarch64-linux")) + ,@(if (target-arm? (%current-system)) '((replace 'check - (lambda _ - (invoke "meson" "test" "--timeout-multiplier" "5")))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "meson" "test" "--timeout-multiplier" "5"))))) '())))) (propagated-inputs - (list ;; Required by gdk-pixbuf-2.0.pc - glib - ;; Required by gdk-pixbuf-xlib-2.0.pc - ;; TODO: Remove on core-updates. - libx11 - ;; Used for testing and required at runtime. - shared-mime-info)) + (list glib ;in Requires of gdk-pixbuf-2.0.pc + + ;; These are in Requires.private of gdk-pixbuf-2.0.pc + libjpeg-turbo + libpng + libtiff + shared-mime-info)) ;required at runtime, too (inputs - `(,@(if (%current-target-system) - `(("bash-minimal" ,bash-minimal)) ; for glib-or-gtk-wrap - '()) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("libtiff" ,libtiff))) + (if (%current-target-system) + (list bash-minimal) ;for glib-or-gtk-wrap + '())) (native-inputs - `(("docbook-xml" ,docbook-xml-4.3) - ("docbook-xsl" ,docbook-xsl) - ("gettext" ,gettext-minimal) - ("glib" ,glib "bin") ; glib-mkenums, etc. - ("gobject-introspection" ,gobject-introspection) ; g-ir-compiler, etc. - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("xsltproc" ,libxslt))) + (list gettext-minimal + `(,glib "bin") ;glib-mkenums, etc. + gobject-introspection ;g-ir-compiler, etc. + perl + pkg-config + + ;; For the documentation. + docbook-xml-4.3 + docbook-xsl + libxml2 ;for XML_CATALOG_FILES + libxslt)) ;for xsltproc (native-search-paths ;; This file is produced by the gdk-pixbuf-loaders-cache-file ;; profile hook. @@ -877,11 +783,11 @@ ever use this library.") (license license:lgpl2.1+))) ;;; A minimal variant used to prevent a cycle with Inkscape. -(define-public at-spi2-core-minimal +(define-public at-spi2-core (hidden-package (package (name "at-spi2-core") - (version "2.40.0") + (version "2.45.90") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -889,33 +795,44 @@ ever use this library.") name "-" version ".tar.xz")) (sha256 (base32 - "0a9l6cfxynjn6jcp29d72i75xbkrzs1l5kmqcwmfal801b9sg5j1")))) + "03dba3c6m3sfapkkbbgzvbi1qcmrrlppydxjjs1m8ds9qb9hl1g9")))) (build-system meson-build-system) (arguments - '(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - #:phases - (modify-phases %standard-phases - (add-after 'install 'check - (lambda _ - (setenv "HOME" (getenv "TMPDIR")) ; xfconfd requires a writable HOME - ;; Run test-suite under a dbus session. - (setenv "XDG_DATA_DIRS" ; for finding org.xfce.Xfconf.service - (string-append %output "/share")) - ;; Don't fail on missing '/etc/machine-id'. - (setenv "DBUS_FATAL_WARNINGS" "0") ; - (invoke "dbus-launch" "ninja" "test"))) - (delete 'check)))) + (list + #:glib-or-gtk? #t ;to wrap binaries and/or compile schemas + #:phases + #~(modify-phases %standard-phases + (delete 'check) + (add-after 'install 'check + (lambda _ + (setenv "HOME" (getenv "TMPDIR")) ;xfconfd requires a writable HOME + ;; Run test-suite under a dbus session. + (setenv "XDG_DATA_DIRS" ;for finding org.xfce.Xfconf.service + (string-append #$output "/share:" (getenv "XDG_DATA_DIRS"))) + ;; Don't fail on missing '/etc/machine-id'. + (setenv "DBUS_FATAL_WARNINGS" "0") + (with-directory-excursion (string-append "../at-spi2-core-" + #$version "") + (invoke "dbus-run-session" "--" "ci/run-registryd-tests.sh") + (substitute* "ci/run-tests.sh" + (("ps auxwww") "") ;avoid a dependency on procps + (("meson test -C _build") + "meson test -C ../build")) ;adjust build directory + (invoke "dbus-run-session" "--" "ci/run-tests.sh"))))))) (inputs - (list bash-minimal)) + (list bash-minimal libxml2)) (propagated-inputs ;; atspi-2.pc refers to all these. (list dbus glib libx11 libxi libxtst)) (native-inputs - `(("gettext" ,gettext-minimal) - ("glib" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("pkg-config" ,pkg-config) - ("python" ,python-wrapper))) + (list gettext-minimal + `(,glib "bin") + gobject-introspection + gsettings-desktop-schemas + pkg-config + python-dbusmock + python-pytest + python-wrapper)) (synopsis "Assistive Technology Service Provider Interface, core components") (description "The Assistive Technology Service Provider Interface, core components, @@ -923,86 +840,48 @@ is part of the GNOME accessibility project.") (license license:lgpl2.1+) (home-page "https://wiki.gnome.org/Accessibility/")))) -(define-public at-spi2-core - (package/inherit at-spi2-core-minimal - (outputs (cons "doc" (package-outputs at-spi2-core-minimal))) +(define-public at-spi2-core-with-documentation + (package/inherit at-spi2-core + (outputs (cons "doc" (package-outputs at-spi2-core))) (arguments - (substitute-keyword-arguments (package-arguments at-spi2-core-minimal) + (substitute-keyword-arguments (package-arguments at-spi2-core) ((#:configure-flags flags ''()) - `(cons ,(if (%current-target-system) - "-Ddocs=false" - "-Ddocs=true") - ,flags)) + #~(cons #$(if (%current-target-system) + "-Ddocs=false" + "-Ddocs=true") + #$flags)) ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'set-documentation-path - (lambda* (#:key outputs #:allow-other-keys) - ;; Ensure that the cross-references point to the "doc" output. - (substitute* "doc/libatspi/meson.build" - (("docpath =.*") - (string-append "docpath = '" (assoc-ref outputs "doc") - "/share/gtk-doc/html'\n"))))) - (add-before 'install 'prepare-doc-directory - (lambda* (#:key outputs #:allow-other-keys) - (mkdir-p (string-append (assoc-ref outputs "doc") "/share")))) - ,@(if (%current-target-system) - '() - '((add-after 'install 'move-documentation - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (copy-recursively - (string-append out "/share/gtk-doc") - (string-append doc "/share/gtk-doc")) - (delete-file-recursively - (string-append out "/share/gtk-doc"))))))))))) + #~(modify-phases #$phases + (add-after 'unpack 'set-documentation-path + (lambda _ + ;; Ensure that the cross-references point to the "doc" output. + (substitute* "doc/libatspi/meson.build" + (("docpath =.*") + (string-append "docpath = '" #$output:doc + "/share/gtk-doc/html'\n"))))) + (add-before 'install 'prepare-doc-directory + (lambda _ + (mkdir-p (string-append #$output:doc "/share")))) + #$@(if (%current-target-system) + #~() + #~((add-after 'install 'move-documentation + (lambda _ + (copy-recursively + (string-append #$output "/share/gtk-doc") + (string-append #$output:doc "/share/gtk-doc")) + (delete-file-recursively + (string-append #$output "/share/gtk-doc")))))))))) (native-inputs - (append `(("docbook-xml" ,docbook-xml-4.3) - ("gtk-doc" ,gtk-doc/stable) - ("libxml2" ,libxml2)) ;for XML_CATALOG_FILES - (package-native-inputs at-spi2-core-minimal))) + (modify-inputs (package-native-inputs at-spi2-core) + (append docbook-xml-4.3 gtk-doc/stable))) (properties (alist-delete 'hidden? - (package-properties at-spi2-core-minimal))))) + (package-properties at-spi2-core))))) (define-public at-spi2-atk - (package - (name "at-spi2-atk") - (version "2.38.0") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "0ks6r9sx27l80n3a7yjmkilxv48cqj183wc7cap3caw2myjhi86g")))) - (build-system meson-build-system) - (arguments - `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - ;; Compiling tests requires "libxml2" to be in 'inputs'. - ,@(if (%current-target-system) - `(#:configure-flags '("-Dtests=false")) - '()) - #:phases - (modify-phases %standard-phases - (replace 'check - ;; Run test-suite under a dbus session. - (lambda _ - (setenv "DBUS_FATAL_WARNINGS" "0") - (invoke "dbus-launch" "meson" "test")))))) - (propagated-inputs - (list at-spi2-core-minimal)) ; required by atk-bridge-2.0.pc - (inputs - (list atk glib)) - (native-inputs - (list dbus ; For tests - gobject-introspection libxml2 pkg-config)) - (synopsis "Assistive Technology Service Provider Interface, ATK bindings") - (description - "The Assistive Technology Service Provider Interface -is part of the GNOME accessibility project.") - (license license:lgpl2.1+) - (home-page "https://wiki.gnome.org/Accessibility/"))) + (deprecated-package "at-spi2-atk" at-spi2-core)) + +(define-public atk + (deprecated-package "atk" at-spi2-core)) (define-public gtk+-2 (package @@ -1023,11 +902,11 @@ is part of the GNOME accessibility project.") (build-system gnu-build-system) (outputs '("out" "bin" "doc" "debug")) (propagated-inputs - (list atk cairo - (if (target-x86-64?) - librsvg-bootstrap - librsvg-2.40) - glib pango)) + (list at-spi2-core + cairo + glib + (librsvg-for-system) + pango)) (inputs (list cups libx11 @@ -1051,41 +930,43 @@ is part of the GNOME accessibility project.") python-wrapper xorg-server-for-tests)) (arguments - `(#:parallel-tests? #f - #:configure-flags - (list "--with-xinput=yes" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "gtk/Makefile.in" - (("aliasfilescheck\\.sh") "")) - (substitute* "gtk/tests/recentmanager.c" - (("g_test_add_func \\(\"/recent-manager.*;") "")) - (substitute* "gtk/tests/defaultvalue.c" - (("return g_test_run\\(\\);") "")) - #t)) - (add-before 'check 'pre-check - (lambda _ - ;; Tests require a running X server. - (system "Xvfb :1 +extension GLX &") - (setenv "DISPLAY" ":1") - ;; Tests write to $HOME. - (setenv "HOME" (getcwd)) - ;; Tests look for $XDG_RUNTIME_DIR. - (setenv "XDG_RUNTIME_DIR" (getcwd)) - ;; For missing '/etc/machine-id'. - (setenv "DBUS_FATAL_WARNINGS" "0") - #t)) - (add-after 'install 'remove-cache - (lambda* (#:key outputs #:allow-other-keys) - (for-each - delete-file - (find-files (assoc-ref outputs "out") "immodules.cache")) - #t))))) + (list + #:parallel-tests? #f + #:configure-flags + #~(list "--with-xinput=yes" + (string-append "--with-html-dir=" #$output + "/share/gtk-doc/html")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "gtk/Makefile.in" + (("aliasfilescheck\\.sh") "")) + (substitute* "gtk/tests/recentmanager.c" + (("g_test_add_func \\(\"/recent-manager.*;") "")) + (substitute* "gtk/tests/defaultvalue.c" + (("return g_test_run\\(\\);") "")) + ;; These require XPM support in Gdk-Pixbuf which is obsolete. + (substitute* "gtk/tests/textbuffer.c" + (("g_test_add_func.*test_fill_empty\\);") + "") + (("g_test_add_func.*test_tag\\);") + "")))) + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running X server. + (system "Xvfb :1 +extension GLX &") + (setenv "DISPLAY" ":1") + ;; Tests write to $HOME. + (setenv "HOME" (getcwd)) + ;; Tests look for $XDG_RUNTIME_DIR. + (setenv "XDG_RUNTIME_DIR" (getcwd)) + ;; For missing '/etc/machine-id'. + (setenv "DBUS_FATAL_WARNINGS" "0"))) + (add-after 'install 'remove-cache + (lambda _ + (for-each delete-file + (find-files #$output "immodules.cache"))))))) (native-search-paths (list (search-path-specification (variable "GUIX_GTK2_PATH") @@ -1104,7 +985,7 @@ application suites.") (package (inherit gtk+-2) (name "gtk+") - (version "3.24.30") + (version "3.24.37") (source (origin (method url-fetch) @@ -1113,19 +994,20 @@ application suites.") name "-" version ".tar.xz")) (sha256 (base32 - "1a9vg840fjq1mmm403b67k624qrkxh9shaz9pv7z9l8a6bzvyxds")) + "0mvzzgjrzzir7nzx379yz3swzk3pn1s283hgzm8l2yakq2sg0ib7")) (patches (search-patches "gtk3-respect-GUIX_GTK3_PATH.patch" "gtk3-respect-GUIX_GTK3_IM_MODULE_FILE.patch")))) + ;; There is no "doc" output, because adding gtk-doc here would introduce a + ;; dependency cycle with itself. + (outputs '("out" "bin")) + (build-system meson-build-system) (propagated-inputs - (list atk - at-spi2-atk + (list at-spi2-core cairo fribidi fontconfig freetype - (if (target-x86-64?) - librsvg-bootstrap - librsvg-2.40) + (librsvg-for-system) glib libcloudproviders-minimal libepoxy @@ -1145,21 +1027,21 @@ application suites.") wayland wayland-protocols)) (inputs - (list colord-minimal ;to prevent a cycle with inkscape + (list colord-minimal ;to prevent a cycle with inkscape cups graphene harfbuzz - iso-codes/official ;XXX TODO core-updates: use iso-codes + iso-codes json-glib-minimal libxml2 rest)) (native-inputs - (list docbook-xml-4.1.2 + (list docbook-xml-4.3 + docbook-xsl gettext-minimal `(,glib "bin") gobject-introspection hicolor-icon-theme - perl pkg-config python-wrapper sassc @@ -1168,67 +1050,54 @@ application suites.") xorg-server-for-tests libxslt)) (arguments - `(#:imported-modules ((guix build glib-or-gtk-build-system) - ,@%gnu-build-system-modules) - #:modules ((guix build utils) - (guix build gnu-build-system) + (list + #:imported-modules `((guix build glib-or-gtk-build-system) + ,@%meson-build-system-modules) + #:modules '((guix build utils) + (guix build meson-build-system) ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)) - #:disallowed-references (,xorg-server-for-tests) - ;; 47 MiB goes to "out" (24 of which is locale data!), and 26 MiB goes - ;; to "doc". - #:configure-flags (list (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html") - "--enable-cloudproviders" - ;; The header file <gdk/gdkwayland.h> is required - ;; by gnome-control-center - "--enable-wayland-backend" - ;; This is necessary to build both backends. - "--enable-x11-backend" - ;; This enables the HTML5 websocket backend. - "--enable-broadway-backend") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'generate-gdk-pixbuf-loaders-cache-file - (assoc-ref glib-or-gtk:%standard-phases - 'generate-gdk-pixbuf-loaders-cache-file)) - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "testsuite/gtk/Makefile.in" - (("builderparser cellarea check-icon-names check-cursor-names") - "builderparser cellarea check-cursor-names") - (("notify no-gtk-init object objects-finalize papersize rbtree") - "no-gtk-init papersize rbtree") - (("stylecontext templates textbuffer textiter treemodel treepath") - "stylecontext textbuffer textiter treemodel treepath")) - (substitute* "testsuite/a11y/Makefile.in" - (("accessibility-dump tree-performance text children derive") - "tree-performance text children derive")) - (substitute* "testsuite/reftests/Makefile.in" - (("TEST_PROGS = gtk-reftest") - "TEST_PROGS = ")) - #t)) - (add-before 'check 'pre-check - (lambda _ - ;; Tests require a running X server. - (system "Xvfb :1 +extension GLX &") - (setenv "DISPLAY" ":1") - ;; Tests write to $HOME. - (setenv "HOME" (getcwd)) - ;; Tests look for $XDG_RUNTIME_DIR. - (setenv "XDG_RUNTIME_DIR" (getcwd)) - ;; For missing '/etc/machine-id'. - (setenv "DBUS_FATAL_WARNINGS" "0") - #t)) - (add-after 'install 'move-desktop-files - ;; Move desktop files into 'bin' to avoid cycle references. - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (bin (assoc-ref outputs "bin"))) - (mkdir-p (string-append bin "/share")) - (rename-file (string-append out "/share/applications") - (string-append bin "/share/applications")) - #t)))))) + #:disallowed-references (list xorg-server-for-tests) + #:configure-flags + #~(list "-Dcloudproviders=true" ;for cloud-providers support + "-Dcolord=yes" ;for color printing support + "-Dbroadway_backend=true" + "-Dman=true") + ;; Use the same test options as upstream uses for their CI (see the + ;; .gitlab-ci/run-tests.sh file). + #:test-options '(list "--suite=gtk" + "--no-suite=failing" + "--no-suite=flaky" + "--no-suite=gsk-compare-broadway") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + ;; These tests fail only in the containerized environment, for + ;; unknown reasons. + (substitute* "testsuite/gtk/meson.build" + ((".*\\['defaultvalue'],.*") "") + ((".*\\['objects-finalize',.*") "")))) + (add-after 'unpack 'generate-gdk-pixbuf-loaders-cache-file + (assoc-ref glib-or-gtk:%standard-phases + 'generate-gdk-pixbuf-loaders-cache-file)) + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running X server. + (system "Xvfb :1 +extension GLX &") + (setenv "DISPLAY" ":1") + ;; Tests write to $HOME. + (setenv "HOME" (getcwd)) + ;; Tests look for $XDG_RUNTIME_DIR. + (setenv "XDG_RUNTIME_DIR" (getcwd)) + ;; For missing '/etc/machine-id'. + (setenv "DBUS_FATAL_WARNINGS" "0"))) + (add-after 'install 'move-desktop-files + ;; Move desktop files into 'bin' to avoid cycle references. + (lambda* (#:key outputs #:allow-other-keys) + (mkdir-p (string-append #$output:bin "/share")) + (rename-file (string-append #$output "/share/applications") + (string-append #$output:bin + "/share/applications"))))))) (native-search-paths (list (search-path-specification (variable "GUIX_GTK3_PATH") @@ -1329,7 +1198,6 @@ application suites.") (lambda _ (for-each mkdir-p (list - (string-append #$output:bin "/bin") (string-append #$output:bin "/share/applications") (string-append #$output:bin "/share/icons") (string-append #$output:bin "/share/man") @@ -1341,7 +1209,6 @@ application suites.") (string-append #$output dir) (string-append #$output:bin dir))) (list - "/bin" "/share/applications" "/share/icons" "/share/man" @@ -1386,6 +1253,7 @@ application suites.") iso-codes json-glib libcloudproviders ;for cloud-providers support + libgudev ;for gstreamer-gl libjpeg-turbo libpng libtiff @@ -1396,9 +1264,7 @@ application suites.") ;; Following dependencies are referenced in .pc files. (list cairo fontconfig - (if (target-x86-64?) - librsvg-bootstrap - librsvg-2.40) + (librsvg-for-system) glib graphene libepoxy @@ -1413,7 +1279,7 @@ application suites.") libxkbcommon libxrandr libxrender - pango-next + pango vulkan-headers vulkan-loader ;for vulkan graphics API support wayland ;for wayland display-backend @@ -1681,7 +1547,7 @@ documents.") (build-system gnu-build-system) (native-inputs (list pkg-config - atk + at-spi2-core ;;("corba" ,corba) ; not packaged yet gconf gobject-introspection @@ -1793,7 +1659,7 @@ library.") (define-public pangomm (package (name "pangomm") - (version "2.50.0") + (version "2.50.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -1801,48 +1667,45 @@ library.") name "-" version ".tar.xz")) (sha256 (base32 - "0nrvvf1fyzlimh7rvxcblnrvn2l9rz8mpn2iwzlzr6kv05zafym2")))) + "054jglmnbig14fs99qqi5y174z9j90r6dprpyszw42742cs95jfc")))) (build-system meson-build-system) (outputs '("out" "doc")) (arguments - `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - #:configure-flags - (list - "-Dbuild-documentation=true") - #:phases - (modify-phases %standard-phases - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/doc") - (string-append doc "/share/doc")) - #t)))))) + (list + #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas + #:configure-flags #~(list "-Dbuild-documentation=true") + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file (string-append #$output "/share/doc") + (string-append #$output:doc "/share/doc"))))))) (native-inputs - `(("dot" ,graphviz) - ("doxygen" ,doxygen) - ("m4" ,m4) - ("mm-common" ,mm-common) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("python" ,python) - ("xsltproc" ,libxslt))) + (list graphviz + doxygen + m4 + mm-common + perl + pkg-config + python + libxslt)) (propagated-inputs - (list cairo cairomm glibmm pango-next)) + (list cairo + cairomm + glibmm + pango)) (home-page "https://pango.gnome.org//") (synopsis "C++ interface to the Pango text rendering library") - (description - "Pangomm provides a C++ programming interface to the Pango text rendering -library.") + (description "Pangomm provides a C++ programming interface to the Pango +text rendering library.") (license license:lgpl2.1+))) (define-public pangomm-2.46 (package (inherit pangomm) (name "pangomm") - (version "2.46.0") + (version "2.46.2") (source (origin (method url-fetch) @@ -1851,14 +1714,14 @@ library.") (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 - (base32 "06zczkaxf5p5kjgnzrfylzi40w9a8lxpndgs7rpn12qrsq27sy6k")))) + (base32 "1x56xb4k1d9g88a1d9rlcvy97mmj39rib6c3wfzpff04vjs2li2p")))) (propagated-inputs (list cairomm-1.14 glibmm-2.64 pango)))) (define-public atkmm (package (name "atkmm") - (version "2.36.0") + (version "2.36.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -1866,7 +1729,7 @@ library.") name "-" version ".tar.xz")) (sha256 (base32 - "0wwr0663jrqx2klsasffd9wpk3kqnwisj1y3ahdkjdk5hzrsjgy9")))) + "0yg0v8f0xms2cfj1r9q6yrl4757wrivpb4q56rbmx626yycxsqkg")))) (build-system meson-build-system) (outputs '("out" "doc")) (arguments @@ -1894,7 +1757,7 @@ library.") ("python" ,python) ("xsltproc" ,libxslt))) (propagated-inputs - (list glibmm atk)) + (list glibmm at-spi2-core)) (synopsis "C++ bindings for ATK") (description "ATKmm is the C++ binding for the ATK library.") (home-page "https://wiki.gnome.org/Accessibility") @@ -1995,7 +1858,7 @@ tutorial.") (package (inherit gtkmm) (name "gtkmm") - (version "3.24.5") + (version "3.24.6") (source (origin (method url-fetch) @@ -2004,7 +1867,7 @@ tutorial.") (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 - (base32 "1ri2msp3cmzi6r65ghwb8gfavfaxv0axpwi3q60nm7v8hvg36qw5")))) + (base32 "1mhi3ws43l051fha4zssfpykraa1qc2hd408l2xk65jfjhp18gjb")))) (propagated-inputs `(("atkmm-2.28" ,atkmm-2.28) ("cairomm-1.14" ,cairomm-1.14) @@ -2066,7 +1929,7 @@ printing and other features typical of a source code editor.") (define-public python-pycairo (package (name "python-pycairo") - (version "1.20.0") + (version "1.21.0") (source (origin (method url-fetch) @@ -2074,7 +1937,7 @@ printing and other features typical of a source code editor.") version "/pycairo-" version ".tar.gz")) (sha256 (base32 - "1326aa2ybhhhrvz3n4p22z5sic25m016ddb5yq0hvbprnw6a35an")))) + "0jxpyibpjadw8ah1mqbhvryr795myiznb1ikm8wgjbamibqhf695")))) (build-system python-build-system) (native-inputs (list pkg-config python-pytest)) @@ -2084,6 +1947,8 @@ printing and other features typical of a source code editor.") (synopsis "Python bindings for cairo") (description "Pycairo is a set of Python bindings for the Cairo graphics library.") + (properties + '((upstream-name . "pycairo"))) (license license:lgpl3+))) ;; Pycairo no longer supports Python 2 since version 1.19.0, so we stick diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index ea67deff86..1fb0bbcd26 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -850,8 +850,8 @@ is not available for Guile 2.0.") (license license:lgpl3+))) (define-public guile-fibers-next - (let ((commit "0fa712ecd85c65d7d11ce0c897f068fba4e6ef3f") - (revision "0")) + (let ((commit "36a6cc707921f4ab503965fefd096d80afee72f0") + (revision "1")) (package (inherit guile-fibers-1.1) (name "guile-fibers-next") @@ -866,7 +866,7 @@ is not available for Guile 2.0.") (file-name (git-file-name "guile-fibers" version)) (sha256 (base32 - "0vfq4dkdq2szi5f99ywm856vll397c1x42a55rpxya61rrws8s9r"))))))) + "0vcb1xck7wv1z9d7i9gzs1k2vav73yf6as5cbjgjjfz8dzm0rq7q"))))))) (define-public guile-fibers (package diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm index dc2c42cdc9..322eda1fc8 100644 --- a/gnu/packages/guile.scm +++ b/gnu/packages/guile.scm @@ -8,14 +8,14 @@ ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016, 2019, 2020 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017 Andy Wingo <wingo@igalia.com> -;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2017, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017, 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2017, 2022 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2017, 2018 Amirouche <amirouche@hypermove.net> ;;; Copyright © 2018 Danny Milosavljevic <dannym@scratchpost.org> ;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2019 Taylan Kammer <taylan.kammer@gmail.com> -;;; Copyright © 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2020-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2021 Timothy Sample <samplet@ngyro.com> ;;; @@ -58,6 +58,7 @@ #:use-module (gnu packages sqlite) #:use-module (gnu packages texinfo) #:use-module (gnu packages version-control) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -157,32 +158,35 @@ without requiring the source code to be rewritten.") (build-system gnu-build-system) ;; When cross-compiling, a native version of Guile itself is needed. - (native-inputs `(,@(if (%current-target-system) - `(("self" ,this-package)) - '()) - ("pkgconfig" ,pkg-config))) - (inputs `(("libffi" ,libffi) - ,@(libiconv-if-needed) - - ;; We need Bash when cross-compiling because some of the scripts - ;; in bin/ refer to it. Use 'bash-minimal' because we don't need - ;; an interactive Bash with Readline and all. - ,@(if (target-mingw?) '() `(("bash" ,bash-minimal))))) + (native-inputs + (append (list pkg-config) + (if (%current-target-system) + (list this-package) + '()))) + (inputs + (append (list libffi) + (libiconv-if-needed) + + ;; We need Bash when cross-compiling because some of the scripts + ;; in bin/ refer to it. Use 'bash-minimal' because we don't need + ;; an interactive Bash with Readline and all. + (if (target-mingw?) '() (list bash-minimal)))) (propagated-inputs - `( ;; These ones aren't normally needed here, but since `libguile-2.0.la' - ;; reads `-lltdl -lunistring', adding them here will add the needed - ;; `-L' flags. As for why the `.la' file lacks the `-L' flags, see - ;; <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/18903>. - ("libunistring" ,libunistring) - - ;; Depend on LIBLTDL, not LIBTOOL. That way, we avoid some the extra - ;; dependencies that LIBTOOL has, which is helpful during bootstrap. - ("libltdl" ,libltdl) - - ;; The headers and/or `guile-2.0.pc' refer to these packages, so they - ;; must be propagated. - ("bdw-gc" ,libgc) - ("gmp" ,gmp))) + (list + ;; These ones aren't normally needed here, but since `libguile-2.0.la' + ;; reads `-lltdl -lunistring', adding them here will add the needed + ;; `-L' flags. As for why the `.la' file lacks the `-L' flags, see + ;; <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/18903>. + libunistring + + ;; Depend on LIBLTDL, not LIBTOOL. That way, we avoid some the extra + ;; dependencies that LIBTOOL has, which is helpful during bootstrap. + libltdl + + ;; The headers and/or `guile-2.0.pc' refer to these packages, so they + ;; must be propagated. + libgc + gmp)) (outputs '("out" "debug")) @@ -215,17 +219,21 @@ without requiring the source code to be rewritten.") (add-before 'configure 'pre-configure (lambda* (#:key inputs #:allow-other-keys) ;; Tell (ice-9 popen) the file name of Bash. + + ;; TODO: On the next rebuild cycle, unconditionally use + ;; 'search-input-file' instead of 'assoc-ref'. (let ((bash (assoc-ref inputs "bash"))) (substitute* "module/ice-9/popen.scm" ;; If bash is #f allow fallback for user to provide ;; "bash" in PATH. This happens when cross-building to ;; MinGW for which we do not have Bash yet. (("/bin/sh") - ,@(if (target-mingw?) - '((if bash - (string-append bash "/bin/bash") - "bash")) - '((string-append bash "/bin/bash"))))) + ,(cond ((target-mingw?) + "bash") + ((%current-target-system) + '(search-input-file inputs "/bin/bash")) + (else + '(string-append bash "/bin/bash"))))) #t)))))) (native-search-paths @@ -247,7 +255,8 @@ without requiring the source code to be rewritten.") (license license:lgpl3+))) (define-public guile-2.2 - (package (inherit guile-2.0) + (package + (inherit guile-2.0) (name "guile") (version "2.2.7") (source (origin @@ -308,22 +317,19 @@ without requiring the source code to be rewritten.") (package (inherit guile-2.2) (name "guile") - (version "3.0.7") + (version "3.0.9") (source (origin (inherit (package-source guile-2.2)) - (patches '()) ; We no longer need the patches. (uri (string-append "mirror://gnu/guile/guile-" version ".tar.xz")) (sha256 (base32 - "1dwiwsrpm4f96alfnz6wibq378242z4f16vsxgy1n9r00v3qczgm")) + "03bm1mnfc9kkg2ls942a0js7bxrdzmcffgrgg6anwdmjfan2a9hs")) + (patches '()) ;; Replace the snippet because the oom-test still ;; fails on some 32-bit architectures. - (snippet '(begin - (substitute* "test-suite/standalone/Makefile.in" - (("test-out-of-memory") "")) - (for-each delete-file - (find-files "prebuilt" "\\.go$")))))) + (snippet '(for-each delete-file + (find-files "prebuilt" "\\.go$"))))) ;; Build with the bundled mini-GMP to avoid interference with GnuTLS' own ;; use of GMP via Nettle: <https://issues.guix.gnu.org/46330>. @@ -332,50 +338,74 @@ without requiring the source code to be rewritten.") (delete "gmp" "libltdl"))) (arguments (substitute-keyword-arguments (package-arguments guile-2.0) - ((#:configure-flags flags ''()) + ;; Guile 3.0.9 is bit-reproducible when built in parallel, thanks to + ;; its multi-stage build process for cross-module inlining, except when + ;; cross-compiling. + ((#:parallel-build? _ #f) + (not (%current-target-system))) + ((#:configure-flags flags #~'()) ;; XXX: JIT-enabled Guile crashes in obscure ways on GNU/Hurd. - `(cons* ,@(if (hurd-target?) - '("--disable-jit") - '()) - ;; -fexcess-precision=standard is required when compiling for - ;; i686-linux, otherwise "numbers.test" will fail - ;; (see <https://issues.guix.gnu.org/49368> and - ;; <https://issues.guix.gnu.org/49659>). - ;; TODO: Keep this in GUILE-2.2 and remove from here on next - ;; rebuild cycle. - ,@(if (target-x86-32?) - '("CFLAGS=-g -O2 -fexcess-precision=standard") - '()) - "--enable-mini-gmp" - '("--disable-static"))) + #~(cons* #$@(if (hurd-target?) + #~("--disable-jit") + #~()) + ;; -fexcess-precision=standard is required when compiling for + ;; i686-linux, otherwise "numbers.test" will fail + ;; (see <https://issues.guix.gnu.org/49368> and + ;; <https://issues.guix.gnu.org/49659>). + ;; TODO: Keep this in GUILE-2.2 and remove from here on next + ;; rebuild cycle. + #$@(if (target-x86-32?) + #~("CFLAGS=-g -O2 -fexcess-precision=standard") + #~()) + "--enable-mini-gmp" + '("--disable-static"))) ((#:phases phases) - `(modify-phases ,phases - (add-before 'check 'disable-stack-overflow-test - (lambda _ - ;; This test can invoke the "OOM killer", especially when - ;; running on emulated hardware (QEMU). Skip it. - (substitute* "test-suite/standalone/test-stack-overflow" - (("!#") - "!#\n(exit 77)\n")))) - - ,@(if (string-prefix? "powerpc-" (%current-system)) - `((add-after 'unpack 'adjust-bootstrap-flags - (lambda _ - ;; Upstream knows about suggested solution. - ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=45214 - (substitute* "bootstrap/Makefile.in" - (("^GUILE_OPTIMIZATIONS.*") - "GUILE_OPTIMIZATIONS = -O1 -Oresolve-primitives -Ocps\n"))))) - '()) - ,@(if (or (target-ppc32?) - (target-riscv64?)) - `((add-after 'unpack 'skip-failing-fdes-test - (lambda _ - ;; ERROR: ((system-error "seek" "~A" ("Bad file descriptor") (9))) - (substitute* "test-suite/tests/ports.test" - (("fdes not closed\"" all) (string-append all "(exit 77)"))) - #t))) - '()))))) + #~(modify-phases #$phases + (add-before 'check 'disable-stack-overflow-test + (lambda _ + ;; This test can invoke the "OOM killer", especially when + ;; running on emulated hardware (QEMU). Skip it. + (substitute* "test-suite/standalone/test-stack-overflow" + (("!#") + "!#\n(exit 77)\n")))) + + #$@(if (target-hurd?) + #~((add-before 'build 'patch-posix-spawn-usage + (lambda _ + ;; TODO: Move patch to 'source' on next rebuild + ;; cycle. + (define patch + #$(local-file + (search-patch "guile-hurd-posix-spawn.patch"))) + (invoke "patch" "--force" "-p1" "-i" patch)))) + #~()) + #$@(if (target-ppc32?) + #~((add-after 'unpack 'adjust-bootstrap-flags + (lambda _ + ;; Upstream knows about suggested solution. + ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=45214 + ;; https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=977223#46 + (substitute* "stage0/Makefile.in" + (("^GUILE_OPTIMIZATIONS.*") + "GUILE_OPTIMIZATIONS = -O1 -Oresolve-primitives -Ocps\n"))))) + #~()) + #$@(if (target-powerpc?) + #~((add-after 'unpack 'skip-oom-test + (lambda _ + ;; This test hangs with guile-3.0.9 and libgc-8.2.2 and + ;; fails completely on powerpc-linux. + (substitute* "test-suite/standalone/test-out-of-memory" + (("!#") "!#\n\n(exit 77)\n"))))) + #~()) + #$@(if (or (target-ppc32?) + (target-riscv64?)) + #~((add-after 'unpack 'skip-failing-fdes-test + (lambda _ + ;; ERROR: ((system-error "seek" "~A" ("Bad file descriptor") (9))) + (substitute* "test-suite/tests/ports.test" + (("fdes not closed\"" all) (string-append all "(exit 77)"))) + #t))) + #~()))))) (native-search-paths (list (search-path-specification @@ -386,38 +416,7 @@ without requiring the source code to be rewritten.") (files '("lib/guile/3.0/site-ccache" "share/guile/site/3.0"))))))) -(define-public guile-3.0-latest - (package - (inherit guile-3.0) - (version "3.0.9") - (source (origin - (inherit (package-source guile-3.0)) - (uri (string-append "mirror://gnu/guile/guile-" - version ".tar.xz")) - (sha256 - (base32 - "03bm1mnfc9kkg2ls942a0js7bxrdzmcffgrgg6anwdmjfan2a9hs")) - (patches (search-patches - "guile-fix-invalid-unicode-handling.patch")))) - (arguments - (substitute-keyword-arguments (package-arguments guile-3.0) - ;; Guile 3.0.9 is bit-reproducible when built in parallel, thanks to - ;; its multi-stage build process for cross-module inlining, except when - ;; cross-compiling. - ((#:parallel-build? _ #f) - (not (%current-target-system))) - ((#:phases phases) - `(modify-phases ,phases - ,@(if (target-ppc32?) - `((replace 'adjust-bootstrap-flags - (lambda _ - ;; Upstream knows about suggested solution. - ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=45214 - ;; https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=977223#46 - (substitute* "stage0/Makefile.in" - (("^GUILE_OPTIMIZATIONS.*") - "GUILE_OPTIMIZATIONS = -O1 -Oresolve-primitives -Ocps\n"))))) - '()))))))) +(define-public guile-3.0-latest guile-3.0) ;;; The symbol guile-3.0/fixed should be used when guile-3.0 needs fixes ;;; (security or else) and this deprecation could be removed. @@ -454,23 +453,20 @@ without requiring the source code to be rewritten.") (arguments (substitute-keyword-arguments (package-arguments guile-3.0) ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-before 'bootstrap 'set-version - (lambda _ - ;; Tell 'git-version-gen' what version this is, or it will - ;; just pick "UNKNOWN", making it unusable as a replacement - ;; for 'guile-3.0'. XXX: This is inaccurate when using - ;; '--with-branch' but using (package-version this-package) - ;; wouldn't give us a valid version string. - (call-with-output-file ".tarball-version" - (lambda (port) - (display ,version port))))) - (add-before 'check 'skip-failing-tests - (lambda _ - (substitute* "test-suite/standalone/test-out-of-memory" - (("!#") "!#\n\n(exit 77)\n")) - (delete-file "test-suite/tests/version.test") - #t)))))) + #~(modify-phases #$phases + (add-before 'bootstrap 'set-version + (lambda _ + ;; Tell 'git-version-gen' what version this is, or it will + ;; just pick "UNKNOWN", making it unusable as a replacement + ;; for 'guile-3.0'. XXX: This is inaccurate when using + ;; '--with-branch' but using (package-version this-package) + ;; wouldn't give us a valid version string. + (call-with-output-file ".tarball-version" + (lambda (port) + (display #$version port))))) + (add-before 'check 'skip-failing-tests + (lambda _ + (delete-file "test-suite/tests/version.test"))))))) (native-inputs (modify-inputs (package-native-inputs guile-3.0) (prepend autoconf @@ -480,7 +476,7 @@ without requiring the source code to be rewritten.") gnu-gettext texinfo gperf) - (replace "self" this-package))) + (replace "guile" this-package))) (synopsis "Development version of GNU Guile")))) (define* (make-guile-readline guile #:optional (name "guile-readline")) @@ -490,49 +486,50 @@ without requiring the source code to be rewritten.") (source (package-source guile)) (build-system gnu-build-system) (arguments - '(#:configure-flags '("--disable-silent-rules" - "--enable-mini-gmp") ;for Guile >= 3.0.6 - #:phases (modify-phases %standard-phases - (add-before 'build 'chdir - (lambda* (#:key outputs #:allow-other-keys) - (invoke "make" "-C" "libguile" "scmconfig.h") - (invoke "make" "-C" "lib") - (chdir "guile-readline") - - (substitute* "Makefile" - (("../libguile/libguile-[[:graph:]]+\\.la") - ;; Remove dependency on libguile-X.Y.la. - "") - (("^READLINE_LIBS = (.*)$" _ libs) - ;; Link against the provided libguile. - (string-append "READLINE_LIBS = " - "-lguile-$(GUILE_EFFECTIVE_VERSION) " - libs "\n")) - (("\\$\\(top_builddir\\)/meta/build-env") - ;; Use the provided Guile, not the one from - ;; $(builddir). - "") - - ;; Install modules to the 'site' directories. - (("^moddir = .*$") - "moddir = $(pkgdatadir)/site/$(GUILE_EFFECTIVE_VERSION)\n") - (("^ccachedir = .*$") - "ccachedir = $(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/site-ccache\n")) - - ;; Load 'guile-readline.so' from the right place. - (substitute* "ice-9/readline.scm" - (("load-extension \"guile-readline\"") - (format #f "load-extension \ + (list #:configure-flags + #~'("--disable-silent-rules" + "--enable-mini-gmp") ;for Guile >= 3.0.6 + + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'chdir + (lambda* (#:key outputs #:allow-other-keys) + (invoke "make" "-C" "libguile" "scmconfig.h") + (invoke "make" "-C" "lib") + (chdir "guile-readline") + + (substitute* "Makefile" + (("../libguile/libguile-[[:graph:]]+\\.la") + ;; Remove dependency on libguile-X.Y.la. + "") + (("^READLINE_LIBS = (.*)$" _ libs) + ;; Link against the provided libguile. + (string-append "READLINE_LIBS = " + "-lguile-$(GUILE_EFFECTIVE_VERSION) " + libs "\n")) + (("\\$\\(top_builddir\\)/meta/build-env") + ;; Use the provided Guile, not the one from + ;; $(builddir). + "") + + ;; Install modules to the 'site' directories. + (("^moddir = .*$") + "moddir = $(pkgdatadir)/site/$(GUILE_EFFECTIVE_VERSION)\n") + (("^ccachedir = .*$") + "ccachedir = $(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/site-ccache\n")) + + ;; Load 'guile-readline.so' from the right place. + (substitute* "ice-9/readline.scm" + (("load-extension \"guile-readline\"") + (format #f "load-extension \ (string-append ~s \"/lib/guile/\" (effective-version) \"/extensions/guile-readline\")" - (assoc-ref outputs "out")))) - #t))))) + (assoc-ref outputs "out")))) + #t))))) (home-page (package-home-page guile)) (native-inputs (package-native-inputs guile)) - (inputs - `(,@(package-inputs guile) ;to placate 'configure' - ,@(package-propagated-inputs guile) - ("guile" ,guile) - ("readline" ,readline))) + (propagated-inputs (package-propagated-inputs guile)) + (inputs (modify-inputs (package-inputs guile) + (prepend guile readline))) (synopsis "Line editing support for GNU Guile") (description "This module provides line editing support via the Readline library for @@ -596,10 +593,6 @@ GNU@tie{}Guile. Use the @code{(ice-9 readline)} module and call its (substitute* "test-suite/tests/version.test" (("\\(pass-if \"version reporting works\"" m) (string-append "#;" m))) - ;; Warning: Unwind-only `out-of-memory' exception; skipping pre-unwind handler. - ;; FAIL: test-out-of-memory - (substitute* "test-suite/standalone/Makefile.am" - (("(check_SCRIPTS|TESTS) \\+= test-out-of-memory") "")) (patch-shebang "build-aux/git-version-gen") (invoke "sh" "autogen.sh") diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index f2cc60267b..a411bfc40a 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -6144,14 +6144,14 @@ forms of the Yoneda lemma, and (co)density (co)monads for Haskell.") (define-public ghc-language-c (package (name "ghc-language-c") - (version "0.8.3") + (version "0.9.1") (source (origin (method url-fetch) (uri (hackage-uri "language-c" version)) (sha256 (base32 - "0bi02jdirkys8v7flf39vrpla2a74z1z0sdhy9lb9v7cmcc6rmpk")))) + "0g5djsnzzmi1d1ndcmmrmwz4xnv1m3w009d6kx9jz9jxxdk9adcl")))) (build-system haskell-build-system) (properties '((upstream-name . "language-c"))) (inputs (list ghc-syb)) diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm index dddc85459a..5f2e36b9ba 100644 --- a/gnu/packages/haskell.scm +++ b/gnu/packages/haskell.scm @@ -23,6 +23,7 @@ ;;; Copyright © 2021 Matthew James Kraai <kraai@ftbfs.org> ;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz> ;;; Copyright © 2021 Simon Tournier <zimon.toutoune@gmail.com> +;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -730,7 +731,11 @@ interactive environment for the functional language Haskell.") (inputs `(("gmp" ,gmp) ("ncurses" ,ncurses) - ("libffi" ,libffi) + + ;; Use a LibFFI variant without static trampolines to work around + ;; <https://gitlab.haskell.org/ghc/ghc/-/issues/20051>. + ("libffi" ,libffi-sans-static-trampolines) + ("ghc-testsuite" ,(origin (method url-fetch) @@ -894,7 +899,9 @@ interactive environment for the functional language Haskell.") (supported-systems '("i686-linux" "x86_64-linux")) (outputs '("out" "doc")) (inputs - (list gmp ncurses libffi)) + ;; Use a LibFFI variant without static trampolines to work around + ;; <https://gitlab.haskell.org/ghc/ghc/-/issues/20051>. + (list gmp ncurses libffi-sans-static-trampolines)) (native-inputs `(("perl" ,perl) ("python" ,python-2) ; for tests @@ -1002,7 +1009,13 @@ interactive environment for the functional language Haskell.") version "/" name "-" version "-testsuite.tar.xz")) (sha256 (base32 - "0s8lf9sxj7n89pjagi58b3fahnp34qvmwhnn0j1fbg6955vbrfj6")))))) + "0s8lf9sxj7n89pjagi58b3fahnp34qvmwhnn0j1fbg6955vbrfj6")) + (modules '((guix build utils))) + (snippet + ;; collections.Iterable was moved to collections.abc in Python 3.10. + '(substitute* "testsuite/driver/testlib.py" + (("collections\\.Iterable") + "collections.abc.Iterable"))))))) (arguments (substitute-keyword-arguments (package-arguments ghc-8.0) ((#:phases phases) @@ -1064,10 +1077,17 @@ interactive environment for the functional language Haskell.") (uri (string-append "https://www.haskell.org/ghc/dist/" version "/" name "-" version "-testsuite.tar.xz")) - (patches (search-patches "ghc-testsuite-dlopen-pie.patch")) + (patches (search-patches "ghc-testsuite-dlopen-pie.patch" + "ghc-testsuite-grep-compat.patch")) (sha256 (base32 - "0pw9r91g2np3i806g2f4f8z4jfdd7mx226cmdizk4swa7av1qf91")))) + "0pw9r91g2np3i806g2f4f8z4jfdd7mx226cmdizk4swa7av1qf91")) + (modules '((guix build utils))) + (snippet + ;; collections.Iterable was moved to collections.abc in Python 3.10. + '(substitute* "testsuite/driver/testlib.py" + (("collections\\.Iterable") + "collections.abc.Iterable"))))) ,@(filter (match-lambda (("ghc-bootstrap" . _) #f) (("ghc-testsuite" . _) #f) @@ -1139,10 +1159,17 @@ interactive environment for the functional language Haskell.") (uri (string-append "https://www.haskell.org/ghc/dist/" version "/ghc-" version "-testsuite.tar.xz")) - (patches (search-patches "ghc-testsuite-dlopen-pie.patch")) + (patches (search-patches "ghc-testsuite-dlopen-pie.patch" + "ghc-testsuite-grep-compat.patch")) (sha256 (base32 - "0c55pj2820q26rikhpf636sn4mjgqsxjrl94vsywrh79dxp3k14z")))) + "0c55pj2820q26rikhpf636sn4mjgqsxjrl94vsywrh79dxp3k14z")) + (modules '((guix build utils))) + (snippet + ;; collections.Iterable was moved to collections.abc in Python 3.10. + '(substitute* "testsuite/driver/testlib.py" + (("collections\\.Iterable") + "collections.abc.Iterable"))))) ("git" ,git-minimal/pinned) ; invoked during tests ,@(filter (match-lambda (("ghc-bootstrap" . _) #f) @@ -1191,10 +1218,17 @@ interactive environment for the functional language Haskell.") (uri (string-append "https://www.haskell.org/ghc/dist/" version "/ghc-" version "-testsuite.tar.xz")) - (patches (search-patches "ghc-testsuite-dlopen-pie.patch")) + (patches (search-patches "ghc-testsuite-dlopen-pie.patch" + "ghc-testsuite-grep-compat.patch")) (sha256 (base32 - "1zl25gg6bpx5601k8h3cqnns1xfc0nqgwnh8jvn2s65ra3f2g1nz")))) + "1zl25gg6bpx5601k8h3cqnns1xfc0nqgwnh8jvn2s65ra3f2g1nz")) + (modules '((guix build utils))) + (snippet + ;; collections.Iterable was moved to collections.abc in Python 3.10. + '(substitute* "testsuite/driver/testlib.py" + (("collections\\.Iterable") + "collections.abc.Iterable"))))) ("git" ,git-minimal/pinned) ; invoked during tests ,@(filter (match-lambda (("ghc-bootstrap" . _) #f) @@ -1260,7 +1294,14 @@ interactive environment for the functional language Haskell.") version "/ghc-" version "-testsuite.tar.xz")) (sha256 (base32 - "1m5fzhr4gjn9ni8gxx7ag3fkbw1rspjzgv39mnfb0nkm5mw70v3s")))) + "1m5fzhr4gjn9ni8gxx7ag3fkbw1rspjzgv39mnfb0nkm5mw70v3s")) + (patches (search-patches "ghc-9.2-grep-warnings.patch")) + (modules '((guix build utils))) + (snippet + ;; collections.Iterable was moved to collections.abc in Python 3.10. + '(substitute* "testsuite/driver/testlib.py" + (("collections\\.Iterable") + "collections.abc.Iterable"))))) ,@(filter (match-lambda (("ghc-bootstrap" . _) #f) (("ghc-testsuite" . _) #f) @@ -1292,20 +1333,16 @@ interactive environment for the functional language Haskell.") (substitute-keyword-arguments (package-arguments base) ((#:phases phases '%standard-phases) #~(modify-phases #$phases - ;; File Common.hs has been moved to src/ in this release. - (replace 'fix-cc-reference - (lambda _ - (substitute* "utils/hsc2hs/src/Common.hs" - (("\"cc\"") "\"gcc\"")))) - ;; FIXME: Remove i686-specific match on the next rebuild cycle. - #$@(match (%current-system) - ("i686-linux" - #~((add-after 'skip-more-tests 'skip-T21694-i686 - (lambda _ - (substitute* '("testsuite/tests/simplCore/should_compile/all.T") - (("^test\\('T21694', \\[ " all) - (string-append all "when(arch('i386'), skip), "))))))) - (_ #~())))) + ;; File Common.hs has been moved to src/ in this release. + (replace 'fix-cc-reference + (lambda _ + (substitute* "utils/hsc2hs/src/Common.hs" + (("\"cc\"") "\"gcc\"")))) + (add-after 'skip-more-tests 'skip-T21694-i686 + (lambda _ + (substitute* '("testsuite/tests/simplCore/should_compile/all.T") + (("^test\\('T21694', \\[ " all) + (string-append all "when(arch('i386'), skip), "))))))) ;; Increase verbosity, so running the test suite does not time out on CI. ((#:make-flags make-flags ''()) #~(cons "VERBOSE=4" #$make-flags)))) @@ -1317,11 +1354,12 @@ interactive environment for the functional language Haskell.") ,(origin (method url-fetch) (uri (string-append - "https://www.haskell.org/ghc/dist/" - version "/ghc-" version "-testsuite.tar.xz")) + "https://www.haskell.org/ghc/dist/" + version "/ghc-" version "-testsuite.tar.xz")) (sha256 (base32 - "19ha0hidrijawy53vm2r0sgml5zkl8126mqy7p0pyacmw3k7913l")))) + "19ha0hidrijawy53vm2r0sgml5zkl8126mqy7p0pyacmw3k7913l")) + (patches (search-patches "ghc-9.2-grep-warnings.patch")))) ,@(filter (match-lambda (("ghc-bootstrap" . _) #f) (("ghc-testsuite" . _) #f) diff --git a/gnu/packages/hurd.scm b/gnu/packages/hurd.scm index 7f02e6141d..34c7c00f2d 100644 --- a/gnu/packages/hurd.scm +++ b/gnu/packages/hurd.scm @@ -66,60 +66,64 @@ GNU/Hurd." version ".tar.gz")) (define-public gnumach-headers - (let ((commit "097f9cf735ffa1212b828682ad92f0f6c5f1c552") - (revision "1")) - (package - (name "gnumach-headers") - (version (git-version "1.8" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://git.savannah.gnu.org/git/hurd/gnumach.git") - (commit commit))) - (file-name (git-file-name "gnumach" version)) - (sha256 - (base32 - "0q36z7k02bykrld90zaxbhyzxlmwlqqs4divgir6ix38zsp6icqk")))) - (build-system gnu-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'install - (lambda _ - (invoke "make" "install-data"))) - (delete 'build)) + (package + (name "gnumach-headers") + (version "1.8+git20220827") ;; This is an upstream tag + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://git.savannah.gnu.org/git/hurd/gnumach.git") + (commit (string-append "v" version)))) + (file-name (git-file-name "gnumach" version)) + (sha256 + (base32 + "07qlaf8vw029y7xdnhjyiiyn788zjzwmyzj79inz7idpswqsnyhf")) + (patches (search-patches "gnumach-add-missing-const_mach_port_name_array_t-type.patch")))) + (build-system gnu-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (replace 'install + (lambda _ + (invoke "make" "install-data"))) + (delete 'build)) - ;; GNU Mach supports only IA32 currently, so cheat so that we can at - ;; least install its headers. - ,@(if (%current-target-system) - '() - ;; See <http://lists.gnu.org/archive/html/bug-hurd/2015-06/msg00042.html> - ;; <http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00716.html> - '(#:configure-flags '("--build=i586-pc-gnu" - "--host=i686-linux-gnu"))) + ;; GNU Mach supports only IA32 currently, so cheat so that we can at + ;; least install its headers. + ,@(if (%current-target-system) + '() + ;; See <http://lists.gnu.org/archive/html/bug-hurd/2015-06/msg00042.html> + ;; <http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00716.html> + '(#:configure-flags '("--build=i586-pc-gnu" + "--host=i686-linux-gnu"))) - #:tests? #f)) - (native-inputs - (list autoconf automake texinfo-4)) - (home-page "https://www.gnu.org/software/hurd/microkernel/mach/gnumach.html") - (synopsis "GNU Mach kernel headers") - (description - "Headers of the GNU Mach kernel.") - (license gpl2+)))) + #:tests? #f)) + (native-inputs + (list autoconf automake texinfo-4)) + (home-page "https://www.gnu.org/software/hurd/microkernel/mach/gnumach.html") + (synopsis "GNU Mach kernel headers") + (description + "Headers of the GNU Mach kernel.") + (license gpl2+))) (define-public mig (package (name "mig") - (version "1.8") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://gnu/mig/mig-" - version ".tar.gz")) - (sha256 - (base32 - "1gyda8sq6b379nx01hkpbd85lz39irdvz2b9wbr63gicicx8i706")))) + (version "1.8+git20220827") + (source (origin + (method url-fetch) + ;; XXX: Version 2.35 of glibc can only be built with an + ;; unreleased version of MiG: + ;; <https://lists.gnu.org/archive/html/bug-hurd/2023-03/msg00025.html>. + ;; It cannot be fetched from Git though, as the extra dependency + ;; on Autoconf/Automake would complicate bootstrapping. + (uri (string-append "mirror://gnu/guix/mirror/mig-" + version ".tar.gz")) + (sha256 + (base32 + "163d37s9lscd6zxyfng421m9nl857464mgjj90xsrcl5ykbng5p2")) + (patches (search-patches "mig-cpu.h-generation.patch")))) (build-system gnu-build-system) ;; Flex is needed both at build and run time. (inputs (list gnumach-headers flex)) @@ -148,77 +152,71 @@ for other software in the GNU system that uses Mach-based inter-process communication.") (license gpl2+))) -(define-public mig/32-bit - ;; When cross-compiling from x86_64-linux to i586-gnu, we need this 32-bit - ;; native MIG. - (package - (inherit mig) - (arguments - (substitute-keyword-arguments (package-arguments mig) - ((#:system _ #f) - "i686-linux"))) - (properties `((hidden? . #t))))) - (define-public hurd-headers - ;; Resort to a post-0.9 snapshot that provides the 'file_utimens' and - ;; 'file_exec_paths' RPCs that glibc 2.28 expects. - (let ((revision "1") - (commit "91a51672ff4cfe1f1a0712b4c542ded3081c825b")) - (package - (name "hurd-headers") - (version (git-version "0.9" revision commit)) - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://git.savannah.gnu.org/git/hurd/hurd.git") - (commit commit))) - (sha256 - (base32 - "16k9wkahz9wasviijz53n6i13nmiwa9fs64ikf1jqh8rl60hw7cz")) - (file-name (git-file-name name version)))) - (build-system gnu-build-system) - (native-inputs - (list mig autoconf automake)) - (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'install - (lambda _ - (invoke "make" "install-headers" "no_deps=t"))) - (delete 'build)) - - #:configure-flags '( ;; Pretend we're on GNU/Hurd; 'configure' wants - ;; that. - ,@(if (%current-target-system) - '() - '("--host=i586-pc-gnu")) + ;; This commit is now slightly behind 0.9.git20220818 as this one needs a + ;; newer glibc + (let ((revision "2") + (commit "3ff70531ee672f431dbb0c11f286bfe85dce98fc")) + (package + (name "hurd-headers") + (version (git-version "0.9" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://git.savannah.gnu.org/git/hurd/hurd.git") + (commit commit))) + (sha256 + (base32 + "1jb9f2h2v4lf6acsji1c12aqg3pixkvjdyb4q6axkd8jp22fdgc0")) + (file-name (git-file-name name version)) + (patches (search-patches "hurd-add-without-rump-configure-option.patch" + "hurd-fix-types-of-read-write-and-readables-methods.patch" + "hurd-fix-types-of-read-write-and-readables-methods-2.patch")))) + (build-system gnu-build-system) + (native-inputs + (list autoconf + automake + (if (%current-target-system) + (let* ((cross-base (resolve-interface '(gnu packages cross-base))) + (cross-mig (module-ref cross-base 'cross-mig))) + (cross-mig (%current-target-system))) + mig))) + (arguments + `(#:phases + (modify-phases %standard-phases + (replace 'install + (lambda _ + (invoke "make" "install-headers" "no_deps=t"))) + (delete 'build)) - ;; Reduce set of dependencies. - "--without-parted" - "--disable-ncursesw" - "--disable-test" - "--without-libbz2" - "--without-libcrypt" - "--without-libz" - ;; Skip the clnt_create check because it expects - ;; a working glibc causing a circular dependency. - "ac_cv_search_clnt_create=no" + #:configure-flags '( ;; Reduce set of dependencies. + "--without-parted" + "--disable-ncursesw" + "--disable-test" + "--without-libbz2" + "--without-libcrypt" + "--without-libz" + "--without-rump" + ;; Skip the clnt_create check because it expects + ;; a working glibc causing a circular dependency. + "ac_cv_search_clnt_create=no" - ;; Annihilate the checks for the 'file_exec_paths' - ;; & co. libc functions to avoid "link tests are - ;; not allowed after AC_NO_EXECUTABLES" error. - "ac_cv_func_file_exec_paths=no" - "ac_cv_func_exec_exec_paths=no" - "ac_cv_func__hurd_exec_paths=no" - "ac_cv_func_file_futimens=no") + ;; Annihilate the checks for the 'file_exec_paths' + ;; & co. libc functions to avoid "link tests are + ;; not allowed after AC_NO_EXECUTABLES" error. + "ac_cv_func_file_exec_paths=no" + "ac_cv_func_exec_exec_paths=no" + "ac_cv_func__hurd_exec_paths=no" + "ac_cv_func__hurd_libc_proc_init=no" + "ac_cv_func_file_futimens=no") - #:tests? #f)) - (home-page "https://www.gnu.org/software/hurd/hurd.html") - (synopsis "GNU Hurd headers") - (description - "This package provides C headers of the GNU Hurd, used to build the GNU C + #:tests? #f)) + (home-page "https://www.gnu.org/software/hurd/hurd.html") + (synopsis "GNU Hurd headers") + (description + "This package provides C headers of the GNU Hurd, used to build the GNU C Library and other user programs.") - (license gpl2+)))) + (license gpl2+)))) (define-public hurd-minimal (package (inherit hurd-headers) @@ -306,7 +304,15 @@ Hurd-minimal package which are needed for both glibc and GCC.") (invoke "make" "gnumach.gz") (install-file "gnumach.gz" boot)))))))) (native-inputs - (list mig perl autoconf automake texinfo-4)) + (list autoconf + automake + (if (%current-target-system) + (let* ((cross-base (resolve-interface '(gnu packages cross-base))) + (cross-mig (module-ref cross-base 'cross-mig))) + (cross-mig (%current-target-system))) + mig) + perl + texinfo-4)) (supported-systems (cons "i686-linux" %hurd-systems)) (synopsis "Microkernel of the GNU system") (description @@ -325,7 +331,7 @@ Hurd-minimal package which are needed for both glibc and GCC.") (define dde-sources ;; This is the current tip of the dde branch - (let ((commit "ac1c7eb7a8b24b7469bed5365be38a968d59a136")) + (let ((commit "ce8810277fa3584eb36ecb23da58394153fabe6f")) (origin (method git-fetch) (uri (git-reference @@ -333,32 +339,38 @@ Hurd-minimal package which are needed for both glibc and GCC.") (commit commit))) (sha256 (base32 - "1vryinbg75xpydfrv9dbgfnds6knlh8l8bk2rxp32y9dc58z0692")) + "0ygk7jm4jmhpvh0zzi5bk638242z7sbcab2i57fkb4y2mmdkjjbw")) (file-name (git-file-name "dde" commit))))) +(define %import-from-dde + (list "libmachdevdde" "libddekit" "libdde_linux26")) + +(define %add-to-hurd-subdirs + (list "libmachdevdde" "libddekit")) + (define-public hurd (package (name "hurd") + (source (package-source hurd-headers)) (version (package-version hurd-headers)) - (source (origin (inherit (package-source hurd-headers)) - (patches (search-patches "hurd-cross.patch" - "hurd-xattr.patch")))) (arguments `(#:phases (modify-phases %standard-phases (add-after 'unpack 'prepare-dde (lambda* (#:key native-inputs inputs #:allow-other-keys) - (substitute* "Makefile" - (("libbpf ") - "libbpf libmachdev libmachdevdde libddekit")) + ;; First we import the things we want from dde. (for-each make-file-writable (find-files ".")) (let ((dde (or (assoc-ref inputs "dde-sources") (assoc-ref native-inputs "dde-sources")))) (for-each (lambda (dir) (copy-recursively (string-append dde "/" dir ) dir)) - '("libmachdev" "libmachdevdde" "libddekit"))) - #t)) + '("libmachdevdde" "libddekit" "libdde_linux26"))) + ;; And we add some as subdirs so that they're built by the main + ;; Makefile. libdde_linux26 is built later in its own phase. + (substitute* "Makefile" + (("libbpf ") + "libbpf libmachdevdde libddekit")))) (add-after 'unpack 'find-tirpc (lambda* (#:key inputs #:allow-other-keys) (for-each (lambda (var) @@ -477,12 +489,34 @@ exec ${system}/rc \"$@\" (patch-shebang file path)) (find-files (string-append out "/libexec"))) #t))) + (add-after 'build 'build-libdde-linux + (lambda* (#:key inputs native-inputs #:allow-other-keys) + (invoke (string-append (assoc-ref native-inputs "make") + "/bin/make") + ;; XXX There can be a race condition because subdirs + ;; aren't interdependent targets in the Makefile. + "-j1" "-C" "libdde_linux26" + (string-append "SHELL=" + (assoc-ref native-inputs "bash") + "/bin/bash") + (string-append "CC=" + ,(cc-for-target))))) (add-after 'install 'install-goodies - (lambda* (#:key inputs outputs #:allow-other-keys) + (lambda* (#:key inputs native-inputs outputs #:allow-other-keys) ;; Install additional goodies. ;; TODO: Build & install *.msgids for rpctrace. (let* ((out (assoc-ref outputs "out")) (datadir (string-append out "/share/hurd"))) + ;; Install libdde_linux26. + (invoke (string-append (assoc-ref native-inputs "make") + "/bin/make") + "-C" "libdde_linux26" "install" + (string-append "SHELL=" + (assoc-ref native-inputs "bash") + "/bin/bash") + (string-append "INSTALLDIR=" + out + "/share/libdde_linux26/build/include")) ;; Install the fancy UTF-8 motd. (mkdir-p (string-append out "/etc")) (copy-file "console/motd.UTF8" @@ -510,9 +544,7 @@ exec ${system}/rc \"$@\" "CFLAGS=-fcommon"))) (build-system gnu-build-system) (inputs - `(("glibc-hurd-headers" ,glibc/hurd-headers) - - ("libgcrypt" ,libgcrypt) ;for /hurd/random + `(("libgcrypt" ,libgcrypt) ;for /hurd/random ("libdaemon" ,libdaemon) ;for /bin/console --daemonize ("unifont" ,unifont) ("libpciaccess" ,libpciaccess) @@ -530,12 +562,12 @@ exec ${system}/rc \"$@\" `(("autoconf" ,autoconf) ("automake" ,automake) ("libgcrypt" ,libgcrypt) ;for 'libgcrypt-config' - ("pkg-config" ,pkg-config) ("mig" ,(if (%current-target-system) - ;; XXX: When targeting i586-pc-gnu, we need a 32-bit MiG, - ;; hence this hack. - mig/32-bit + (let* ((cross-base (resolve-interface '(gnu packages cross-base))) + (cross-mig (module-ref cross-base 'cross-mig))) + (cross-mig (%current-target-system))) mig)) + ("pkg-config" ,pkg-config) ("perl" ,perl) ("texinfo" ,texinfo-4) ("dde-sources" ,dde-sources))) diff --git a/gnu/packages/ibus.scm b/gnu/packages/ibus.scm index dd15d65105..54f91ba848 100644 --- a/gnu/packages/ibus.scm +++ b/gnu/packages/ibus.scm @@ -125,13 +125,6 @@ (substitute* '("ibus-share.c" "ibus-compose.c" "ibus-keypress.c") (("[ \t]*return g_test_run \\(\\);") ""))))) - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs/reference/ibus" - (substitute* "ibus-docs.sgml.in" - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append #$(this-package-native-input "docbook-xml") - "/xml/dtd/docbook/")))))) (add-after 'unpack 'patch-python-target-directories (lambda _ (let ((root (string-append #$output @@ -257,7 +250,7 @@ may also simplify input method development.") ,(string-append #$output "/lib/girepository-1.0")))))))))) (inputs (modify-inputs (package-inputs ibus-minimal) (prepend gtk - pango-next + pango python python-dbus python-pygobject))) diff --git a/gnu/packages/icu4c.scm b/gnu/packages/icu4c.scm index 1e4f66d956..87986952f0 100644 --- a/gnu/packages/icu4c.scm +++ b/gnu/packages/icu4c.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2016, 2017, 2020, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2019, 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Björn Höfling <bjoern.hoefling@bjoernhoefling.de> ;;; Copyright © 2020 Julien Lepiller <julien@lepiller.eu> @@ -40,75 +40,7 @@ (define-public icu4c (package - (name "icu4c") - (version "69.1") - (source (origin - (method url-fetch) - (uri (string-append - "https://github.com/unicode-org/icu/releases/download/release-" - (string-map (lambda (x) (if (char=? x #\.) #\- x)) version) - "/icu4c-" - (string-map (lambda (x) (if (char=? x #\.) #\_ x)) version) - "-src.tgz")) - (sha256 - (base32 "0icps0avkwy5df3wwc5kybxcg63hcgk4phdh9g244g0xrmx7pfjc")))) - (build-system gnu-build-system) - ;; When cross-compiling, this package needs a source directory of a - ;; native-build of itself. - (native-inputs - `(("python" ,python-minimal) - ,@(if (%current-target-system) - `(("icu4c-build-root" ,icu4c-build-root)) - '()))) - (inputs - (list perl)) - (arguments - `(#:configure-flags - (list - "--enable-rpath" - ,@(if (%current-target-system) - '((string-append "--with-cross-build=" - (assoc-ref %build-inputs "icu4c-build-root"))) - '())) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'chdir-to-source - (lambda _ (chdir "source") #t)) - (add-after 'chdir-to-source 'update-LDFLAGS - (lambda _ - ;; Do not create a "data-only" libicudata.so because it causes - ;; problems on some architectures (notably armhf and MIPS). - (substitute* "config/mh-linux" - (("LDFLAGSICUDT=-nodefaultlibs -nostdlib") - "LDFLAGSICUDT=")) - #t)) - ,@(if (target-riscv64?) - `((add-after 'unpack 'disable-failing-test - ;; It is unknown why this test is failing. - (lambda _ - (substitute* "source/test/intltest/numbertest_api.cpp" - (("(TESTCASE_AUTO\\(unitUsage\\));" all) - (string-append "//" all)))))) - '()) - (add-after 'install 'avoid-coreutils-reference - ;; Don't keep a reference to the build tools. - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (substitute* (find-files (string-append out "/lib/icu") - "\\.inc$") - (("INSTALL_CMD=.*/bin/install") "INSTALL_CMD=install")) - #t)))))) - (synopsis "International Components for Unicode") - (description - "ICU is a set of C/C++ and Java libraries providing Unicode and -globalisation support for software applications. This package contains the -C/C++ part.") - (license x11) - (home-page "http://site.icu-project.org/"))) - -(define-public icu4c-71 - (package - (inherit icu4c) + (name "icu4c") (version "71.1") (source (origin (method url-fetch) @@ -119,8 +51,59 @@ C/C++ part.") (string-map (lambda (x) (if (char=? x #\.) #\_ x)) version) "-src.tgz")) (sha256 - (base32 - "1gqywaqj9jmdwrng9lm6inyqmi5j2cz36db9dcqg3yk13zjyd9v7")))))) + (base32 "1gqywaqj9jmdwrng9lm6inyqmi5j2cz36db9dcqg3yk13zjyd9v7")))) + (build-system gnu-build-system) + (native-inputs + (append (list python-minimal) + (if (%current-target-system) + ;; When cross-compiling, this package needs a source directory + ;; of a native-build of itself. + (list icu4c-build-root) + '()))) + (inputs + (list perl)) + (arguments + (list + #:configure-flags + #~(list + "--enable-rpath" + #$@(if (%current-target-system) + #~((string-append "--with-cross-build=" + #+(this-package-native-input + "icu4c-build-root"))) + #~())) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'chdir-to-source + (lambda _ (chdir "source"))) + (add-after 'chdir-to-source 'update-LDFLAGS + (lambda _ + ;; Do not create a "data-only" libicudata.so because it causes + ;; problems on some architectures (notably armhf and MIPS). + (substitute* "config/mh-linux" + (("LDFLAGSICUDT=-nodefaultlibs -nostdlib") + "LDFLAGSICUDT=")))) + #$@(if (target-riscv64?) + #~((add-after 'unpack 'disable-failing-test + ;; It is unknown why this test is failing. + (lambda _ + (substitute* "source/test/intltest/numbertest_api.cpp" + (("(TESTCASE_AUTO\\(unitUsage\\));" all) + (string-append "//" all)))))) + #~()) + (add-after 'install 'avoid-coreutils-reference + ;; Don't keep a reference to the build tools. + (lambda _ + (substitute* (find-files (string-append #$output "/lib/icu") + "\\.inc$") + (("INSTALL_CMD=.*/bin/install") "INSTALL_CMD=install"))))))) + (synopsis "International Components for Unicode") + (description + "ICU is a set of C/C++ and Java libraries providing Unicode and +globalisation support for software applications. This package contains the +C/C++ part.") + (license x11) + (home-page "http://site.icu-project.org/"))) (define-public icu4c-70 (package @@ -152,6 +135,22 @@ C/C++ part.") (string-append "//" all)))))))) (package-arguments icu4c))))) +(define-public icu4c-69 + (package + (inherit icu4c) + (version "69.1") + (source (origin + (method url-fetch) + (uri (string-append + "https://github.com/unicode-org/icu/releases/download/release-" + (string-map (lambda (x) (if (char=? x #\.) #\- x)) version) + "/icu4c-" + (string-map (lambda (x) (if (char=? x #\.) #\_ x)) version) + "-src.tgz")) + (sha256 + (base32 + "0icps0avkwy5df3wwc5kybxcg63hcgk4phdh9g244g0xrmx7pfjc")))))) + (define-public icu4c-68 (package (inherit icu4c) @@ -174,17 +173,15 @@ C/C++ part.") (name "icu4c-build-root") (arguments (substitute-keyword-arguments (package-arguments icu4c) - ((#:tests? _ '()) - #f) - ((#:out-of-source? _ '()) - #t) - ((#:phases phases) - `(modify-phases ,phases - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (copy-recursively "../build" out) - #t))))))) + ((#:tests? _ #f) + #f) + ((#:out-of-source? _ #t) + #t) + ((#:phases phases) + #~(modify-phases #$phases + (replace 'install + (lambda _ + (copy-recursively "../build" #$output))))))) (native-inputs '()))) (define-public java-icu4j diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index a0227c920c..42bd34bd63 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -427,7 +427,7 @@ many popular formats.") libpng libtiff openmpi - proj-7 + proj python ;("pugixml" ,pugixml) sqlite diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm index 765db31cca..7858c24c3e 100644 --- a/gnu/packages/image.scm +++ b/gnu/packages/image.scm @@ -613,28 +613,27 @@ extracting icontainer icon files.") (define-public libtiff (package (name "libtiff") - (version "4.3.0") + (version "4.4.0") (source (origin (method url-fetch) (uri (string-append "https://download.osgeo.org/libtiff/tiff-" - version ".tar.gz")) + version ".tar.xz")) + (patches (search-patches "libtiff-CVE-2022-34526.patch")) (sha256 (base32 - "1j3snghqjbhwmnm5vz3dr1zm68dj15mgbx1wqld7vkl7n2nfaihf")))) + "1h8xrcpbyf9id2hw2ms0cmpgx0li8gladjzj82ycgk28018pnc29")))) (build-system gnu-build-system) (outputs '("out" "doc")) ;1.8 MiB of HTML documentation (arguments - ;; Instead of using --docdir, this package has its own --with-docdir. - `(#:configure-flags - (list (string-append "--with-docdir=" - (assoc-ref %outputs "doc") - "/share/doc/" - ,name "-" ,(package-version this-package)) - "--disable-static"))) - (inputs `(("zlib" ,zlib) - ("libjpeg" ,libjpeg-turbo))) + (list #:configure-flags + ;; Instead of using --docdir, this package has its own --with-docdir. + #~(list (string-append "--with-docdir=" #$output:doc "/share/doc/" + #$name "-" #$(package-version this-package)) + "--disable-static"))) + (inputs + (list libjpeg-turbo xz zlib)) (synopsis "Library for handling TIFF files") (description "Libtiff provides support for the Tag Image File Format (TIFF), a format @@ -643,6 +642,8 @@ Included are a library, libtiff, for reading and writing TIFF and a small collection of tools for doing simple manipulations of TIFF images.") (license (license:non-copyleft "file://COPYRIGHT" "See COPYRIGHT in the distribution.")) + (properties + '((upstream-name . "tiff"))) (home-page "http://www.simplesystems.org/libtiff/"))) (define-public leptonica @@ -748,26 +749,12 @@ arithmetic ops.") (base32 "0dwa24kjqyg9hmm40fh048sdxfpnasz43l2rm8wlkw1qbdlpd517")))) (build-system gnu-build-system) - (arguments '(#:configure-flags '("--disable-static") - #:phases (modify-phases %standard-phases - (add-before 'bootstrap 'force-bootstrap - (lambda _ - ;; XXX: jbig2dec 0.18 was released with - ;; a broken configure script, so we - ;; recreate the build system here. - ;; Remove the autoconf inputs below - ;; when deleting this code. - (delete-file "configure") - (delete-file "autogen.sh") - #t))))) + (arguments '(#:configure-flags '("--disable-static"))) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("libtool" ,libtool) - ("python" ,python-minimal-wrapper))) ;for tests + (list python-minimal-wrapper)) ;for tests (synopsis "Decoder of the JBIG2 image compression format") (description - "JBIG2 is designed for lossy or lossless encoding of @code{bilevel} (1-bit + "JBIG2 is designed for lossy or lossless encoding of @code{bilevel} (1-bit monochrome) images at moderately high resolution, and in particular scanned paper documents. In this domain it is very efficient, offering compression ratios on the order of 100:1. @@ -857,17 +844,17 @@ images of initially unknown height.") (define-public openjpeg-data (package (name "openjpeg-data") - (version "2020.11.30") + (version "2021.09.26") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/uclouvain/openjpeg-data") - (commit "cd724fb1f93e6af41ebc68c4904f4bf2a4cd1e60"))) + (commit "1f3d093030f9a0b43353ec6b48500f65786ff57a"))) (file-name (git-file-name name version)) (sha256 - (base32 "1q2swh4g9r9haqs075fyk42aclqcs9q51lqqzfb57lisszminpwm")))) + (base32 "13jpdaqk7mngk0xw6xbh9zgipip6n25spvqd97hwpfna1zyh8lzh")))) (build-system copy-build-system) (synopsis "Test files for OpenJPEG") (description "OpenJPEG-Data contains all files required to run the openjpeg @@ -879,7 +866,7 @@ test suite, including conformance tests (following Rec. ITU-T T.803 | ISO/IEC (define-public openjpeg (package (name "openjpeg") - (version "2.4.0") + (version "2.5.0") (source (origin (method git-fetch) @@ -888,7 +875,7 @@ test suite, including conformance tests (following Rec. ITU-T T.803 | ISO/IEC (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "143dvy5g6v6129lzvl0r8mrgva2fppkn0zl099qmi9yi9l9h7yyf")))) + (base32 "0xvcxlzqlylnjsyl1j64d7rgzv68ihm4qy6fpdrix3xzbqb3fjpz")))) (build-system cmake-build-system) (arguments `(#:configure-flags @@ -1054,7 +1041,7 @@ Metafile}, and @acronym{EMF+, Enhanced Metafile Plus} files.") (define-public imlib2 (package (name "imlib2") - (version "1.9.1") + (version "1.10.0") (source (origin (method url-fetch) (uri (string-append @@ -1062,7 +1049,7 @@ Metafile}, and @acronym{EMF+, Enhanced Metafile Plus} files.") "/imlib2-" version ".tar.xz")) (sha256 (base32 - "0hsdfs7wa5f7fwb5nfgqzvf29bp59rgy0i0c4m6mvgpzpww408ja")))) + "1fnbh6vj0d9l1c2bzw9psxh3wnlbr1nlfzi16w60hp48gj9ilz3j")))) (build-system gnu-build-system) (arguments '(#:configure-flags (list "--disable-static"))) @@ -1171,7 +1158,8 @@ supplies a generic doubly-linked list and some string functions.") "LibJXR" "LibWebP" "OpenEXR" "ZLib")))) (patches (append - (search-patches "freeimage-unbundle.patch") + (search-patches "freeimage-unbundle.patch" + "freeimage-libtiff-compat.patch") ;; Take one patch from Arch Linux that adds LibRaw 0.20 compatibility. (list (origin (method url-fetch) @@ -1731,49 +1719,45 @@ is hereby granted.")))) (define-public libjpeg-turbo (package (name "libjpeg-turbo") - (version "2.0.5") + (version "2.1.4") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/libjpeg-turbo/" version "/libjpeg-turbo-" version ".tar.gz")) (sha256 (base32 - "0pbv6pc97kbj7ib31qcwi7lnmm9xg5y3b11aasmkhfjvf7rgdy0n")))) + "0arl61ici38ann5xjidwdzkhmjdp1r95x4x4zinnh4qs2fhjdvfk")))) (build-system cmake-build-system) (native-inputs (list nasm)) (arguments - `(#:configure-flags '("-DCMAKE_INSTALL_LIBDIR:PATH=lib" - "-DENABLE_STATIC=0" - ;; djpeg-shared-3x2-float-prog-cmp fails on 32-bit PPC. - ,@(if (string=? "powerpc-linux" (%current-system)) - `("-DFLOATTEST=NO") - '()) - ;; The build system probes for the current CPU, but - ;; that fails when cross-compiling. - ,@(let ((target (%current-target-system))) - (if target - (cond - ((string-prefix? "arm" target) - `("-DCMAKE_SYSTEM_PROCESSOR=arm")) - ((string-prefix? "aarch64" target) - `("-DCMAKE_SYSTEM_PROCESSOR=aarch64")) - ((string-prefix? "i686" target) - `("-DCMAKE_SYSTEM_PROCESSOR=x86")) - ((string-prefix? "x86_64" target) - `("-DCMAKE_SYSTEM_PROCESSOR=x86_64")) - ;; 32-bit and 64-bit - ((string-prefix? "powerpc" target) - `("-DCMAKE_SYSTEM_PROCESSOR=powerpc")) - ((string-prefix? "riscv64" target) - `("-DCMAKE_SYSTEM_PROCESSOR=riscv64")) - (else '())) - '()))) - ,@(if (%current-target-system) - '() - ;; Use a special "bootstrap" CMake for the native build to work - ;; around a circular dependency between CMake and this package. - `(#:cmake ,cmake-bootstrap)))) + (list #:configure-flags + #~'("-DCMAKE_INSTALL_LIBDIR:PATH=lib" + "-DENABLE_STATIC=0" + ;; djpeg-shared-3x2-float-prog-cmp fails on some systems. + #$@(if (or (target-ppc32?) + (target-riscv64?)) + '("-DFLOATTEST=NO") + '()) + ;; The build system probes for the current CPU, but + ;; that fails when cross-compiling. + #$@(let ((target (%current-target-system))) + (if target + (cond ((string-prefix? "arm" target) + '("-DCMAKE_SYSTEM_PROCESSOR=arm")) + ((string-prefix? "aarch64" target) + '("-DCMAKE_SYSTEM_PROCESSOR=aarch64")) + ((string-prefix? "i686" target) + '("-DCMAKE_SYSTEM_PROCESSOR=x86")) + ((string-prefix? "x86_64" target) + '("-DCMAKE_SYSTEM_PROCESSOR=x86_64")) + ;; 32-bit and 64-bit + ((string-prefix? "powerpc" target) + '("-DCMAKE_SYSTEM_PROCESSOR=powerpc")) + ((string-prefix? "riscv64" target) + '("-DCMAKE_SYSTEM_PROCESSOR=riscv64")) + (else '())) + '()))))) (home-page "https://libjpeg-turbo.org/") (synopsis "SIMD-accelerated JPEG image handling library") (description "libjpeg-turbo is a JPEG image codec that accelerates baseline @@ -2260,7 +2244,8 @@ This package can be used to create @code{favicon.ico} files for web sites.") (string-append #$gdk-pixbuf "/bin/gdk-pixbuf-thumbnailer"))))) (add-after 'install 'install-readme (lambda _ - (let ((doc (string-append #$output "/share/doc/libavif-" #$version))) + (let ((doc (string-append #$output "/share/doc/libavif-" + #$(package-version this-package)))) (install-file "../source/README.md" doc)))) (add-after 'install 'split (lambda _ diff --git a/gnu/packages/inkscape.scm b/gnu/packages/inkscape.scm index d1ac5e7312..b4b35dc251 100644 --- a/gnu/packages/inkscape.scm +++ b/gnu/packages/inkscape.scm @@ -35,6 +35,7 @@ #:use-module (gnu packages bdw-gc) #:use-module (gnu packages boost) #:use-module (gnu packages check) + #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages graphics) @@ -61,15 +62,16 @@ (hidden-package (package (name "inkscape") - (version "1.1.1") + (version "1.2.1") (source (origin (method url-fetch) (uri (string-append "https://media.inkscape.org/dl/" "resources/file/" "inkscape-" version ".tar.xz")) + (patches (search-patches "inkscape-poppler-compat.patch")) (sha256 - (base32 "1bvqg5xfs3m6r7qfdhmgzwhd1hx8wvg3nhvhmalwzcdm6ffhpjmf")) + (base32 "06scilds4p4bw337ss22nfdxy2kynv5yjw6vq6nlpjm7xfh7vkj6")) (modules '((guix build utils) (ice-9 format))) (snippet @@ -176,6 +178,20 @@ endif()~%~%" (substitute* "testfiles/cli_tests/CMakeLists.txt" (("add_cli_test\\(export-latex") "message(TEST_DISABLED: export-latex")))) + (add-after 'unpack 'disable-vertical-glyph-tests + (lambda _ + ;; FIXME: These tests fail with newer Pango and Harfbuzz: + ;; https://gitlab.com/inkscape/inkscape/-/issues/2917 + ;; https://gitlab.com/inkscape/inkscape/-/issues/3554 + ;; Simply providing older versions don't work, as we need + ;; the full GTK stack; we could use package-input-rewriting + ;; but then have to also downgrade pangomm and disable tests + ;; in librsvg and GTK+. Just ignore for now. + (substitute* "testfiles/rendering_tests/CMakeLists.txt" + (("test-glyph-y-pos") "") + (("text-glyphs-combining") "") + (("text-glyphs-vertical") "") + (("test-rtl-vertical") "")))) (add-after 'unpack 'set-home ;; Mute Inkscape warnings during tests. (lambda _ @@ -191,45 +207,51 @@ endif()~%~%" (add-after 'glib-or-gtk-compile-schemas 'glib-or-gtk-wrap (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)) (add-after 'install 'wrap-program - ;; Ensure Python is available at runtime. - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (wrap-program (string-append out "/bin/inkscape") - `("GUIX_PYTHONPATH" ":" prefix - (,(getenv "GUIX_PYTHONPATH")))))))))) + ;; Ensure Python is available at runtime. + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (wrap-program (string-append out "/bin/inkscape") + `("GUIX_PYTHONPATH" prefix + (,(getenv "GUIX_PYTHONPATH"))) + ;; Wrapping GDK_PIXBUF_MODULE_FILE allows Inkscape to load + ;; its own icons in pure environments. + `("GDK_PIXBUF_MODULE_FILE" = + (,(getenv "GDK_PIXBUF_MODULE_FILE")))))))))) (inputs - `(("aspell" ,aspell) - ("autotrace" ,autotrace) - ("gdl" ,gdl-minimal) - ("gtkmm" ,gtkmm-3) - ("gtk" ,gtk+) - ("gtkspell3" ,gtkspell3) - ("gsl" ,gsl) - ("poppler" ,poppler) - ("lib2geom" ,lib2geom) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("libxml2" ,libxml2) - ("libxslt" ,libxslt) - ("libgc" ,libgc) - ("libsoup" ,libsoup-minimal-2) - ("libcdr" ,libcdr) - ("libvisio" ,libvisio) - ("libwpd" ,libwpd) - ("libwpg" ,libwpg) - ("freetype" ,freetype) - ("popt" ,popt) - ("potrace" ,potrace) - ("lcms" ,lcms) - ("boost" ,boost) - ("python" ,python-wrapper) - ("python-scour" ,python-scour) - ("python-pyserial" ,python-pyserial) - ("python-numpy" ,python-numpy) - ("python-lxml" ,python-lxml))) + (list aspell + autotrace + bash-minimal + gdl-minimal + gtkmm-3 + gtk+ + gtkspell3 + gsl + poppler + lib2geom + libjpeg-turbo + libpng + libxml2 + libxslt + libgc + (librsvg-for-system) ;for the pixbuf loader + libsoup-minimal-2 + libcdr + libvisio + libwpd + libwpg + freetype + popt + potrace + lcms + boost + python-wrapper + python-scour + python-pyserial + python-numpy + python-lxml)) (native-inputs - (list imagemagick ;for tests - intltool + (list gettext-minimal + imagemagick ;for tests `(,glib "bin") googletest perl @@ -272,8 +294,5 @@ as the native format.") `("GDK_PIXBUF_MODULE_FILE" = (,(getenv "GDK_PIXBUF_MODULE_FILE"))))))))))) (inputs (modify-inputs (package-inputs inkscape/stable) - (replace "lib2geom" lib2geom-1.2) - (append bash-minimal - librsvg ;for the pixbuf loader - python-cssselect))) ;to render qrcode + (append python-cssselect))) ;to render qrcode (properties (alist-delete 'hidden? (package-properties inkscape/stable))))) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index de3a0003e5..8254330d55 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -233,15 +233,23 @@ "openjdk.src/jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c") (("#include <sys/sysctl.h>") "#include <linux/sysctl.h>")) + + ;; XXX 'ldd' in glibc 2.35 segfaults upon reading + ;; openjdk.build-boot/lib/amd64/libnio.so (!). + ;; It is only used as a verification step, so ignore it; + ;; try removing this substitution for newer versions of glibc. + (substitute* "openjdk.src/jdk/make/common/shared/Defs-linux.gmk" + (("\\$\\(LDD\\) \\$1 &&") + "")) + ;; It looks like the "h = 31 * h + c" line of the jsum() ;; function gets miscompiled. After a few iterations of the loop ;; the result of "31 * h" is always 0x8000000000000000. - ;; Bad optimization maybe... - ;; Transform "31 * h + c" into a convoluted "32 * h + c - h" - ;; as a workaround. - (substitute* "openjdk.src/hotspot/src/share/vm/memory/dump.cpp" - (("h = 31 \\* h \\+ c;") - "jlong h0 = h;\nfor(int i = 0; i < 5; i++) h += h;\nh += c - h0;")))) + ;; Disable optimizations of dump.cpp as a workaround. + (substitute* "openjdk.src/hotspot/make/linux/makefiles/gcc.make" + (("OPT_CFLAGS/NOOPT.*" all) + (string-append all "\n" + "OPT_CFLAGS/dump.o += -O0"))))) (add-after 'unpack 'fix-x11-extension-include-path (lambda* (#:key inputs #:allow-other-keys) (substitute* "openjdk.src/jdk/make/sun/awt/mawt.gmk" @@ -617,7 +625,8 @@ (base32 "17bdv39n4lh8l5737c96f3xgamx4y305m067p01cywgp7zaddqws")) (patches (search-patches - "icedtea-7-hotspot-aarch64-use-c++98.patch")))) + "icedtea-7-hotspot-aarch64-use-c++98.patch" + "icedtea-7-hotspot-pointer-comparison.patch")))) ("ant" ,ant-bootstrap) ("attr" ,attr) ("classpath" ,classpath-devel) @@ -862,7 +871,9 @@ new Date();")) (find-files "." ".*.(bin|exe|jar)$")))) (sha256 (base32 - "1v92nzdqx07c35x945awzir4yk0fk22vky6fpp8mq9js930sxsz0")))) + "1v92nzdqx07c35x945awzir4yk0fk22vky6fpp8mq9js930sxsz0")) + (patches (search-patches "openjdk-9-pointer-comparison.patch" + "openjdk-9-setsignalhandler.patch")))) (build-system gnu-build-system) (outputs '("out" "jdk" "doc")) (arguments @@ -1047,7 +1058,9 @@ new Date();")) (base32 "0i47ar8lxzjrkkiwbzybfxs473390h4jq9ahm3xqdvy5zpchxy3y")) (patches (search-patches - "openjdk-10-idlj-reproducibility.patch")))) + "openjdk-10-idlj-reproducibility.patch" + "openjdk-10-pointer-comparison.patch" + "openjdk-10-setsignalhandler.patch")))) (arguments (substitute-keyword-arguments (package-arguments openjdk9) ((#:phases phases) @@ -1419,7 +1432,8 @@ new Date();")) "0mbhdrk12b6878kby0flnbak7444dlpm0ihlmf92vk59y1c02bc2")) (modules '((guix build utils))) (snippet - '(for-each delete-file (find-files "." "\\.(bin|exe|jar)$"))))) + '(for-each delete-file (find-files "." "\\.(bin|exe|jar)$"))) + (patches (search-patches "openjdk-10-setsignalhandler.patch")))) (arguments (substitute-keyword-arguments (package-arguments openjdk11) ((#:phases phases) @@ -1435,7 +1449,10 @@ blacklisted.certs.pem" (define-public openjdk13 (make-openjdk openjdk12 "13.0.13" - "0pxf4dlig61k0pg7amg4mi919hzam7nzwckry01avgq1wj8ambji")) + "0pxf4dlig61k0pg7amg4mi919hzam7nzwckry01avgq1wj8ambji" + (source (origin + (inherit (package-source base)) + (patches '()))))) (define-public openjdk14 (make-openjdk @@ -1449,7 +1466,8 @@ blacklisted.certs.pem" ;; not available in bash-minimal (substitute* "make/autoconf/basics.m4" (("if help") "if command -v")) - (for-each delete-file (find-files "." "\\.(bin|exe|jar)$")))))))) + (for-each delete-file (find-files "." "\\.(bin|exe|jar)$")))) + (patches (search-patches "openjdk-10-setsignalhandler.patch")))))) (define-public openjdk15 (make-openjdk @@ -1472,12 +1490,18 @@ blacklisted.certs.pem" (define-public openjdk16 (make-openjdk openjdk15 "16.0.2" - "0587px2qbz07g3xi4a3ya6m630p72dvkxcn0bj1813pxnwvcgigz")) + "0587px2qbz07g3xi4a3ya6m630p72dvkxcn0bj1813pxnwvcgigz" + (source (origin + (inherit (package-source base)) + (patches (search-patches "openjdk-10-setsignalhandler.patch")))))) (define-public openjdk17 (make-openjdk openjdk16 "17.0.5" "1asnysg6kxdkrmb88y6qihdr12ljsyxv0mg6hlcs7cwxgsdlqkfs" + (source (origin + (inherit (package-source base)) + (patches '()))) (arguments (substitute-keyword-arguments (package-arguments openjdk16) ((#:phases phases) diff --git a/gnu/packages/jemalloc.scm b/gnu/packages/jemalloc.scm index 1abf8a69a6..5e7facfd5e 100644 --- a/gnu/packages/jemalloc.scm +++ b/gnu/packages/jemalloc.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2017, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2021 Ryan Sundberg <ryan@arctype.co> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -25,16 +26,17 @@ #:use-module (ice-9 match) #:use-module ((guix licenses) #:select (bsd-2)) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages perl) #:use-module (guix build-system gnu)) -(define-public jemalloc-4.5.0 +(define-public jemalloc (package (name "jemalloc") - (version "4.5.0") + (version "5.3.0") (source (origin (method url-fetch) (uri (string-append @@ -42,26 +44,29 @@ version "/jemalloc-" version ".tar.bz2")) (sha256 (base32 - "10373xhpc10pgmai9fkc1z0rs029qlcb3c0qfnvkbwdlcibdh2cl")))) + "1apyxjd1ixy4g8xkr61p0ny8jiz8vyv1j0k4nxqkxpqrf4g2vf1d")))) (build-system gnu-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'delete-thp-test - ;; This test does not check if transparent huge pages are supported - ;; on the system before running the test. - (lambda _ - (substitute* "Makefile.in" - (("\\$\\(srcroot\\)test/unit/pages.c \\\\") "\\")) - #t))) - #:configure-flags - '(,@(match (%current-system) - ((or "i686-linux" "x86_64-linux") - '()) - ("powerpc-linux" - (list "--disable-thp" "CPPFLAGS=-maltivec")) - (_ - (list "--disable-thp")))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'delete-thp-test + ;; This test does not check if transparent huge pages are supported + ;; on the system before running the test. + (lambda _ + (substitute* "Makefile.in" + (("\\$\\(srcroot\\)test/unit/pages.c \\\\") "\\"))))) + #:configure-flags + ;; Disable the thread local storage model in jemalloc 5 to prevent + ;; shared libraries linked to libjemalloc from crashing on dlopen() + ;; https://github.com/jemalloc/jemalloc/issues/937 + #~'("--disable-initial-exec-tls" + #$@(match (%current-system) + ("powerpc-linux" + (list "CPPFLAGS=-maltivec")) + (_ + '()))))) + (inputs (list perl)) ;; Install the scripts to a separate output to avoid referencing Perl and ;; Bash in the default output, saving ~75 MiB on the closure. (outputs '("out" "bin")) @@ -71,24 +76,3 @@ "This library providing a malloc(3) implementation that emphasizes fragmentation avoidance and scalable concurrency support.") (license bsd-2))) - -(define-public jemalloc - (package - (inherit jemalloc-4.5.0) - (version "5.2.1") - (source (origin - (method url-fetch) - (uri (string-append - "https://github.com/jemalloc/jemalloc/releases/download/" - version "/jemalloc-" version ".tar.bz2")) - (sha256 - (base32 - "1xl7z0vwbn5iycg7amka9jd6hxd8nmfk7nahi4p9w2bnw9f0wcrl")))) - (arguments - (substitute-keyword-arguments (package-arguments jemalloc-4.5.0) - ;; Disable the thread local storage model in jemalloc 5 to prevent - ;; shared libraries linked to libjemalloc from crashing on dlopen() - ;; https://github.com/jemalloc/jemalloc/issues/937 - ((#:configure-flags base-configure-flags '()) - `(cons "--disable-initial-exec-tls" ,base-configure-flags)))) - (inputs (list perl)))) diff --git a/gnu/packages/jrnl.scm b/gnu/packages/jrnl.scm deleted file mode 100644 index 45f9dab148..0000000000 --- a/gnu/packages/jrnl.scm +++ /dev/null @@ -1,64 +0,0 @@ -;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2014 Eric Bavier <address@hidden> -;;; Copyright © 2015 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2019 Tobias Geerinckx-Rice <me@tobias.gr> -;;; -;;; This file is part of GNU Guix. -;;; -;;; GNU Guix is free software; you can redistribute it and/or modify it -;;; under the terms of the GNU General Public License as published by -;;; the Free Software Foundation; either version 3 of the License, or (at -;;; your option) any later version. -;;; -;;; GNU Guix is distributed in the hope that it will be useful, but -;;; WITHOUT ANY WARRANTY; without even the implied warranty of -;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;;; GNU General Public License for more details. -;;; -;;; You should have received a copy of the GNU General Public License -;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. - -(define-module (gnu packages jrnl) - #:use-module (guix packages) - #:use-module (guix licenses) - #:use-module (guix git-download) - #:use-module (guix build-system python) - #:use-module (gnu packages check) - #:use-module (gnu packages python) - #:use-module (gnu packages python-crypto) - #:use-module (gnu packages python-xyz) - #:use-module (gnu packages time)) - -(define-public jrnl - (package - (name "jrnl") - (version "1.9.7") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/maebert/jrnl") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 "1bjjyfc3fnsy0h299s3jj42wnigj43xdyp5ppi1cvkqbwl369935")))) - (build-system python-build-system) - (native-inputs - (list behave)) - (inputs - (list python - python-keyring - python-pycrypto - python-pytz - python-tzlocal - python-six - python-dateutil - python-parsedatetime)) - (home-page "https://maebert.github.io/jrnl/") - (synopsis "Personal journal application") - (description - "Jrnl is a command line journal application that stores your journal in a -plain text file. Optionally, your journal can be encrypted using 256-bit AES -encryption.") - (license x11))) diff --git a/gnu/packages/julia.scm b/gnu/packages/julia.scm index 906cb4b94c..ba54175822 100644 --- a/gnu/packages/julia.scm +++ b/gnu/packages/julia.scm @@ -150,7 +150,8 @@ libraries. It is also a bit like @code{ldd} and @code{otool -L}.") (sha256 (base32 "0jf8dr5j7y8cjnr65kn38xps5h9m2qvi8g1yd8qgiip5r87ld3ad")) - (patches (search-patches "julia-SOURCE_DATE_EPOCH-mtime.patch")))) + (patches (search-patches "julia-SOURCE_DATE_EPOCH-mtime.patch" + "julia-Use-MPFR-4.2.patch")))) (build-system gnu-build-system) (arguments `(#:test-target "test" diff --git a/gnu/packages/kde-frameworks.scm b/gnu/packages/kde-frameworks.scm index 3dbce00d36..058f64187d 100644 --- a/gnu/packages/kde-frameworks.scm +++ b/gnu/packages/kde-frameworks.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2015, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2016, 2019, 2020, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016-2019 Hartmut Goebel <h.goebel@crazy-compilers.com> ;;; Copyright © 2016 David Craven <david@craven.ch> @@ -1692,7 +1692,7 @@ application crashes.") (native-inputs (list extra-cmake-modules)) (inputs - (list docbook-xml + (list docbook-xml-4.5 docbook-xsl karchive ki18n diff --git a/gnu/packages/kde-pim.scm b/gnu/packages/kde-pim.scm index 19066fd289..6f3cbf2999 100644 --- a/gnu/packages/kde-pim.scm +++ b/gnu/packages/kde-pim.scm @@ -1139,7 +1139,7 @@ protocol for querying and modifying directory services running over TCP/IP.") kdoctools)) (inputs (list boost - gpgme-1.18 + gpgme kcmutils kcodecs kconfig @@ -1159,7 +1159,7 @@ protocol for querying and modifying directory services running over TCP/IP.") libassuan libkleo breeze-icons ;; default icon set - qgpgme-1.18 + qgpgme qtbase-5)) (arguments `(#:phases @@ -1196,7 +1196,7 @@ and retrieving certificates from LDAP servers.") akonadi-mime akonadi-search boost - gpgme-1.18 + gpgme grantlee grantleetheme kbookmarks @@ -1243,7 +1243,7 @@ and retrieving certificates from LDAP servers.") libkleo libksieve breeze-icons ; default icon set, required for tests - qgpgme-1.18 + qgpgme qtbase-5 qtdeclarative-5 qtkeychain diff --git a/gnu/packages/kde-plasma.scm b/gnu/packages/kde-plasma.scm index 563ed04826..2000ec3114 100644 --- a/gnu/packages/kde-plasma.scm +++ b/gnu/packages/kde-plasma.scm @@ -1053,7 +1053,7 @@ you login.") qtwayland-5 kwayland wayland - wayland-protocols-next)) + wayland-protocols)) (arguments '(#:phases (modify-phases %standard-phases @@ -1213,7 +1213,7 @@ KDE Frameworks components.") mesa-utils pkg-config qttools-5 - wayland-protocols-next + wayland-protocols xorg-server-for-tests)) (inputs (list breeze eudev @@ -2342,7 +2342,7 @@ sensors, process information and other system resources.") qtgraphicaleffects qtx11extras wayland - wayland-protocols-next + wayland-protocols xcb-util xcb-util-image xcb-util-keysyms diff --git a/gnu/packages/kerberos.scm b/gnu/packages/kerberos.scm index 9e2f6acd56..c553f8180a 100644 --- a/gnu/packages/kerberos.scm +++ b/gnu/packages/kerberos.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -61,7 +62,7 @@ (define-public mit-krb5 (package (name "mit-krb5") - (version "1.19.2") + (version "1.20") (source (origin (method url-fetch) (uri (list @@ -74,7 +75,7 @@ (patches (search-patches "mit-krb5-hurd.patch")) (sha256 (base32 - "0snz1jm2w4dkk65zcz953jmmv9mqa30fanch2bk8r3rs9vp3yi8h")))) + "0bz16sh0vgzlpy2kx5acmpyy181hl83a1alz7wbk06457kfjn0ky")))) (build-system gnu-build-system) (native-inputs (list bison perl tcl)) ;required for some tests @@ -106,11 +107,13 @@ (chdir "src"))) (add-before 'check 'pre-check (lambda* (#:key inputs native-inputs #:allow-other-keys) - (let ((perl (assoc-ref (or native-inputs inputs) "perl"))) + (let ((perl (search-input-file (or native-inputs inputs) + "bin/perl"))) (substitute* "plugins/kdb/db2/libdb2/test/run.test" - (("/bin/cat") (string-append perl "/bin/perl")) + (("/bin/cat") perl) (("D/bin/sh") (string-append "D" (which "sh"))) - (("bindir=/bin/.") (string-append "bindir=" perl "/bin"))))))))) + (("bindir=/bin/.") (string-append "bindir=" + (dirname perl)))))))))) (synopsis "MIT Kerberos 5") (description "Massachusetts Institute of Technology implementation of Kerberos. diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm index 208fab4f5b..36968ad11c 100644 --- a/gnu/packages/language.scm +++ b/gnu/packages/language.scm @@ -6,6 +6,7 @@ ;;; Copyright © 2020 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2020, 2022 Julien Lepiller <julien@lepiller.eu> ;;; Copyright © 2022 Milran <milranmike@protonmail.com> +;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -66,6 +67,7 @@ #:use-module (guix build-system qt) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix utils)) @@ -88,115 +90,100 @@ (build-system glib-or-gtk-build-system) (outputs '("out" "gtk" "qt" "doc")) (arguments - `(#:imported-modules - (,@%glib-or-gtk-build-system-modules - (guix build cmake-build-system) - (guix build qt-build-system) - (guix build qt-utils)) - #:modules - ((guix build glib-or-gtk-build-system) - ((guix build qt-build-system) - #:prefix qt:) - (guix build utils)) - #:configure-flags - (list - "--with-im-config-data" - "--with-imsettings-data" - (string-append "--with-html-dir=" - (assoc-ref %outputs "doc") - "/share/gtk-doc/html")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-qt4 - (lambda _ - (substitute* '("configure.ac" "modules/clients/Makefile.am") - (("\\[QtGui\\]") - "[Qt5Gui]") - ((" qt4") - "")) - #t)) - (add-after 'disable-qt4 'patch-flags - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "configure.ac" - (("-Werror") - "-Wno-error")) - #t)) - (add-after 'patch-flags 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "docs" - (substitute* "nimf-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.3/") - (string-append (assoc-ref inputs "docbook-xml-4.3") - "/xml/dtd/docbook/")))) - #t)) - (add-after 'patch-docbook-xml 'patch-paths - (lambda* (#:key inputs outputs #:allow-other-keys) - (substitute* "configure.ac" - (("/usr/share/anthy/anthy.dic") - (search-input-file inputs "/share/anthy/anthy.dic"))) - (substitute* "configure.ac" - (("/usr/bin:\\$GTK3_LIBDIR/libgtk-3-0") - (string-append (assoc-ref inputs "gtk+:bin") - "/bin:$GTK3_LIBDIR/libgtk-3-0")) - (("/usr/bin:\\$GTK2_LIBDIR/libgtk2.0-0") - (string-append (assoc-ref inputs "gtk+-2:bin") - "/bin:$GTK2_LIBDIR/libgtk2.0-0"))) - (substitute* "modules/clients/gtk/Makefile.am" - (("\\$\\(GTK3_LIBDIR\\)") - (string-append (assoc-ref outputs "gtk") - "/lib")) - (("\\$\\(GTK2_LIBDIR\\)") - (string-append (assoc-ref outputs "gtk") - "/lib"))) - (substitute* "modules/clients/qt5/Makefile.am" - (("\\$\\(QT5_IM_MODULE_DIR\\)") - (string-append (assoc-ref outputs "qt") - "/lib/qt5/plugins/inputmethods"))) - (substitute* '("bin/nimf-settings/Makefile.am" - "data/apparmor-abstractions/Makefile.am" - "data/Makefile.am" "data/im-config/Makefile.am" - "data/imsettings/Makefile.am") - (("/etc") - (string-append (assoc-ref outputs "out") - "/etc")) - (("/usr/share") - (string-append (assoc-ref outputs "out") - "/share"))) - #t)) - (add-after 'install 'qt-wrap - (assoc-ref qt:%standard-phases 'qt-wrap))))) + (list + #:imported-modules `(,@%glib-or-gtk-build-system-modules + (guix build cmake-build-system) + (guix build qt-build-system) + (guix build qt-utils)) + #:modules '((guix build glib-or-gtk-build-system) + ((guix build qt-build-system) + #:prefix qt:) + (guix build utils)) + #:configure-flags + #~(list "--with-im-config-data" + "--with-imsettings-data" + (string-append "--with-html-dir=" #$output:doc + "/share/gtk-doc/html")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-qt4 + (lambda _ + (substitute* '("configure.ac" "modules/clients/Makefile.am") + (("\\[QtGui\\]") + "[Qt5Gui]") + ((" qt4") + "")))) + (add-after 'disable-qt4 'patch-flags + (lambda _ + (substitute* "configure.ac" + (("-Werror") + "-Wno-error")))) + (add-after 'patch-flags 'patch-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "configure.ac" + (("/usr/share/anthy/anthy.dic") + (search-input-file inputs "/share/anthy/anthy.dic"))) + (substitute* "configure.ac" + ;; Do not provide the PATH argument to AC_PATH_PROG; so that + ;; the needed binaries are looked from PATH (the default + ;; behavior). + (("\\[/usr/bin:\\$GTK3_LIBDIR/libgtk-3-0]") + "") + (("\\[/usr/bin:\\$GTK2_LIBDIR/libgtk2.0-0]") + "") + (("\\[/usr/bin:\\$GTK3_LIBDIR/libgtk-3-0:\ +\\$GTK2_LIBDIR/libgtk2.0-0]") + "")) + (substitute* "modules/clients/gtk/Makefile.am" + (("\\$\\(GTK3_LIBDIR\\)") + (string-append #$output:gtk "/lib")) + (("\\$\\(GTK2_LIBDIR\\)") + (string-append #$output:gtk "/lib"))) + (substitute* "modules/clients/qt5/Makefile.am" + (("\\$\\(QT5_IM_MODULE_DIR\\)") + (string-append #$output:qt + "/lib/qt5/plugins/inputmethods"))) + (substitute* '("bin/nimf-settings/Makefile.am" + "data/apparmor-abstractions/Makefile.am" + "data/Makefile.am" "data/im-config/Makefile.am" + "data/imsettings/Makefile.am") + (("/etc") + (string-append #$output "/etc")) + (("/usr/share") + (string-append #$output "/share"))))) + (add-after 'install 'qt-wrap + (assoc-ref qt:%standard-phases 'qt-wrap))))) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("docbook-xml-4.3" ,docbook-xml-4.3) - ("gettext" ,gettext-minimal) - ("gobject-introspection" ,gobject-introspection) - ("gtk+-2:bin" ,gtk+-2 "bin") - ("gtk+:bin" ,gtk+ "bin") - ("gtk-doc" ,gtk-doc/stable) - ("intltool" ,intltool) - ("libtool" ,libtool) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("which" ,which))) + (list autoconf + automake + docbook-xml-4.3 + gettext-minimal + gobject-introspection + `(,gtk+-2 "bin") + `(,gtk+ "bin") + gtk-doc/stable + intltool + libtool + perl + pkg-config + which)) (inputs - `(("anthy" ,anthy) - ("appindicator" ,libappindicator) - ("gtk+-2" ,gtk+-2) - ("gtk+" ,gtk+) - ("hangul" ,libhangul) - ("m17n-db" ,m17n-db) - ("m17n-lib" ,m17n-lib) - ("qtbase" ,qtbase-5) - ("rime" ,librime) - ("rsvg" ,librsvg) - ("wayland" ,wayland) - ("wayland-protocols" ,wayland-protocols) - ("x11" ,libx11) - ("xkbcommon" ,libxkbcommon) - ("xklavier" ,libxklavier))) - (propagated-inputs - (list glib)) + (list anthy + libappindicator + gtk+-2 + gtk+ + libhangul + m17n-db + m17n-lib + qtbase-5 + librime + librsvg + wayland + wayland-protocols + libx11 + libxkbcommon + libxklavier)) + (propagated-inputs (list glib)) (synopsis "Lightweight input method framework") (description "Nimf is a lightweight, fast and extensible input method framework. This package provides a fork of the original nimf project, that diff --git a/gnu/packages/libbsd.scm b/gnu/packages/libbsd.scm index 16a7e8fd89..79f1389081 100644 --- a/gnu/packages/libbsd.scm +++ b/gnu/packages/libbsd.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -20,22 +21,52 @@ #:use-module (guix build-system gnu) #:use-module (guix download) #:use-module (guix licenses) - #:use-module (guix packages)) + #:use-module (guix packages) + #:use-module (guix gexp) + #:use-module (gnu packages crypto)) (define-public libbsd (package (name "libbsd") - (version "0.10.0") + (version "0.11.6") (source (origin (method url-fetch) (uri (string-append "https://libbsd.freedesktop.org/releases/" "libbsd-" version ".tar.xz")) (sha256 (base32 - "11x8q45jvjvf2dvgclds64mscyg10lva33qinf2hwgc84v3svf1l")))) + "1pxmk42brddk43bj8lp4a64f9iwhc5ii91y6w7k97xpaf8qqzcqr")))) (build-system gnu-build-system) (arguments - '(#:configure-flags '("--disable-static"))) + (list #:configure-flags #~'("--disable-static") + #:phases #~(modify-phases %standard-phases + (add-after 'install 'embed-absolute-libmd-references + (lambda* (#:key inputs #:allow-other-keys) + (let ((libmd (search-input-file inputs + "lib/libmd.so"))) + ;; Add absolute references to libmd so it + ;; does not need to be propagated. + (with-directory-excursion #$output + (substitute* "lib/libbsd.so" + (("^GROUP") + (string-append "SEARCH_DIR(" + (dirname libmd) + ")\nGROUP"))) + (substitute* (find-files "lib/pkgconfig" + "\\.pc$") + (("-lmd") + (string-append "-L" (dirname libmd) + " -lmd"))))))) + (add-before 'check 'disable-pwcache-test + (lambda _ + ;; This test expects the presence of a root + ;; user and group, which do not exist in the + ;; build container. + (substitute* "test/Makefile" + (("pwcache\\$\\(EXEEXT\\) ") + ""))))))) + (inputs + (list libmd)) (synopsis "Utility functions from BSD systems") (description "This library provides useful functions commonly found on BSD systems, and lacking on others like GNU systems, thus making it easier to port diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm index 02b2795194..20f967757d 100644 --- a/gnu/packages/libevent.scm +++ b/gnu/packages/libevent.scm @@ -60,7 +60,7 @@ '(#:configure-flags '("--disable-libevent-regress" "--disable-openssl"))) (inputs - `(("python" ,python-wrapper))) ;for 'event_rpcgen.py' + (list python-wrapper)) ;for 'event_rpcgen.py' (native-inputs (list which)) (home-page "https://libevent.org/") @@ -114,14 +114,14 @@ limited support for fork events.") (define-public libuv (package (name "libuv") - (version "1.41.1") + (version "1.44.2") (source (origin (method url-fetch) (uri (string-append "https://dist.libuv.org/dist/v" version "/libuv-v" version ".tar.gz")) (sha256 (base32 - "0zb818sjwnxn5yv3qvkxaprjf037yqmjipk5i3a8rg1q4izhrnv5")))) + "1d1wy1061cf2mfygr2j6jbm0da2mhsf0l9yq4rjkqrsmijbdrz6c")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-static") diff --git a/gnu/packages/libffi.scm b/gnu/packages/libffi.scm index 60e8bb23ea..ba3fc6bc79 100644 --- a/gnu/packages/libffi.scm +++ b/gnu/packages/libffi.scm @@ -28,8 +28,10 @@ #:use-module (gnu packages) #:use-module (guix licenses) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) + #:use-module (guix utils) #:use-module (gnu packages check) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -43,17 +45,16 @@ (define-public libffi (package (name "libffi") - (version "3.3") + (version "3.4.4") (source (origin (method url-fetch) (uri - (string-append "ftp://sourceware.org/pub/libffi/" + (string-append "https://github.com/libffi/libffi/releases" + "/download/v" version "/" name "-" version ".tar.gz")) (sha256 (base32 - "0mi0cpf8aa40ljjmzxb7im6dbj45bb0kllcd09xgmp834y9agyvj")) - (patches (search-patches "libffi-3.3-powerpc-fixes.patch" - "libffi-float128-powerpc64le.patch")))) + "0xpn5mqlbdmqgxgp910ba1qj79axpwr8nh7wklmcz0ls4nnmcv6n")))) (build-system gnu-build-system) (arguments `(;; Prevent the build system from passing -march and -mtune to the @@ -79,6 +80,17 @@ conversions for values passed between the two languages.") ;; See <https://github.com/atgreen/libffi/blob/master/LICENSE>. (license expat))) +;; Provide a variant without static trampolines as some packages +;; (particularly GHC < 9) cannot handle them. See +;; <https://github.com/libffi/libffi/pull/647> for a discussion. +(define-public libffi-sans-static-trampolines + (hidden-package + (package/inherit libffi + (arguments + (substitute-keyword-arguments (package-arguments libffi) + ((#:configure-flags flags #~'()) + #~(append #$flags '("--disable-exec-static-tramp")))))))) + (define-public python-cffi (package (name "python-cffi") @@ -111,7 +123,12 @@ conversions for values passed between the two languages.") "linker_so='gcc -shared')"))) (substitute* "testing/cffi0/test_ownlib.py" (("\"cc testownlib") "\"gcc testownlib")) - (invoke "py.test" "-v" "c/" "testing/"))) + (invoke "pytest" "-v" "c/" "testing/" + ;; Disable tests that fail (harmlessly) with glibc + ;; 2.34 and later: + ;; https://foss.heptapod.net/pypy/cffi/-/issues/528 + "-k" (string-append "not TestFFI.test_dlopen_handle " + "and not test_dlopen_handle")))) (add-before 'check 'patch-paths-of-dynamically-loaded-libraries (lambda* (#:key inputs #:allow-other-keys) ;; Shared libraries should be referred by their absolute path as diff --git a/gnu/packages/libidn.scm b/gnu/packages/libidn.scm index 7c8b77f6fb..80350db495 100644 --- a/gnu/packages/libidn.scm +++ b/gnu/packages/libidn.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012 Andreas Enge <andreas@enge.fr> -;;; Copyright © 2016, 2017, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2017, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2017 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2017 Eric Bavier <bavier@member.fsf.org> @@ -34,14 +34,14 @@ (define-public libidn (package (name "libidn") - (version "1.37") + (version "1.41") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/libidn/libidn-" version ".tar.gz")) (sha256 (base32 - "1hljls9rkilh04dwiwg388wk8djkac8idijrdysqq2nqbh6rg3iw")))) + "0ic9zlqqppwaqr3i0r8lb8f47rrazzc8d5pfgg8vs6mqciip0kc8")))) (build-system gnu-build-system) ;; FIXME: No Java and C# libraries are currently built. (arguments @@ -60,14 +60,14 @@ Java libraries.") (define-public libidn2 (package (name "libidn2") - (version "2.3.1") + (version "2.3.4") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/libidn/" name "-" version ".tar.gz")) (sha256 (base32 - "0b8gsksj2g9f4iywwdma3v4jcg7i9rqvdxfmclwvbf1n72a89xla")))) + "0pxlvf37j9ivg2wp56q1xvx7g6y9cfmpd87mskwd2lg0nirbmjlk")))) (inputs (list libunistring)) (build-system gnu-build-system) diff --git a/gnu/packages/libreoffice.scm b/gnu/packages/libreoffice.scm index 3d3e6d18dc..667e93db26 100644 --- a/gnu/packages/libreoffice.scm +++ b/gnu/packages/libreoffice.scm @@ -242,6 +242,7 @@ spreadsheets and presentations.") (method url-fetch) (uri (string-append "mirror://sourceforge/libwpd/libwpd/" "libwpd-" version "/libwpd-" version ".tar.xz")) + (patches (search-patches "libwpd-gcc-compat.patch")) (sha256 (base32 "02fx8bngslcj7i5g1gx2kiign4vp09wrmp5wpvix9igxcavb0r94")))) (build-system gnu-build-system) diff --git a/gnu/packages/libsigsegv.scm b/gnu/packages/libsigsegv.scm index 627447e876..ebbdd2ad90 100644 --- a/gnu/packages/libsigsegv.scm +++ b/gnu/packages/libsigsegv.scm @@ -26,14 +26,14 @@ (define-public libsigsegv (package (name "libsigsegv") - (version "2.13") + (version "2.14") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/libsigsegv/libsigsegv-" version ".tar.gz")) (sha256 - (base32 "06c1qjiv69hjvbq06mcxdi5hzfadhy28sa83zxspqpxhfr0ywy5y")))) + (base32 "15d2r831xz94s7540nvb1gbfl062g7mrnj88m60wyr1kh10kkb6d")))) (build-system gnu-build-system) (home-page "https://www.gnu.org/software/libsigsegv/") (synopsis "Library for handling page faults") diff --git a/gnu/packages/libunistring.scm b/gnu/packages/libunistring.scm index fda839be54..eccd053a35 100644 --- a/gnu/packages/libunistring.scm +++ b/gnu/packages/libunistring.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012, 2013, 2014 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2016, 2018 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016, 2018, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2017 Eric Bavier <bavier@member.fsf.org> @@ -27,6 +27,7 @@ #:use-module (guix licenses) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix build-system gnu) #:use-module (gnu packages) #:use-module (gnu packages base)) @@ -34,7 +35,7 @@ (define-public libunistring (package (name "libunistring") - (version "0.9.10") + (version "1.0") (source (origin (method url-fetch) (uri (string-append @@ -42,7 +43,7 @@ version ".tar.xz")) (sha256 (base32 - "1mq57h06622m6qc5cv347fc3qk5mj840axw3c0vd7qmnwk1v53zb")))) + "0h97qx3c4970wvh25g51sjgz54xn37lrfy95dg97xmvmkys5basv")))) (propagated-inputs (libiconv-if-needed)) (outputs '("out" "static")) (build-system gnu-build-system) @@ -50,21 +51,20 @@ ;; Work around parallel build issue whereby C files may be compiled before ;; config.h is built: see <http://hydra.gnu.org/build/59381/nixlog/2/raw> and ;; <http://lists.openembedded.org/pipermail/openembedded-core/2012-April/059850.html>. - '(#:parallel-build? #f - #:phases (modify-phases %standard-phases - (add-after 'install 'move-static-library - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (static (assoc-ref outputs "static"))) - (with-directory-excursion (string-append out "/lib") - (install-file "libunistring.a" - (string-append static "/lib")) - (delete-file "libunistring.a") - #t))))))) + (list + #:parallel-build? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'move-static-library + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion (string-append #$output "/lib") + (install-file "libunistring.a" + (string-append #$output:static "/lib")) + (delete-file "libunistring.a"))))))) (synopsis "C library for manipulating Unicode strings") (description "GNU libunistring is a library providing functions to manipulate Unicode strings and for manipulating C strings according to the Unicode standard.") (home-page "https://www.gnu.org/software/libunistring/") - (license (list lgpl3+ gpl2)))) + (license (list lgpl3+ gpl2+)))) diff --git a/gnu/packages/libusb.scm b/gnu/packages/libusb.scm index c009c78e88..612af8b30e 100644 --- a/gnu/packages/libusb.scm +++ b/gnu/packages/libusb.scm @@ -62,7 +62,7 @@ (define-public libusb (package (name "libusb") - (version "1.0.24") + (version "1.0.25") (source (origin (method url-fetch) @@ -70,7 +70,7 @@ "releases/download/v" version "/libusb-" version ".tar.bz2")) (sha256 - (base32 "0amilbi5qncdnrds3ji21vbiz1wvdm1fwp5qrxnk49xkyy2jdzby")))) + (base32 "0j88ym7afy4wj3x789zzxsr04asyjy0mw29gf31blzkrg8cyya4a")))) (build-system gnu-build-system) ;; XXX: Enabling udev is now recommended, but eudev indirectly depends on diff --git a/gnu/packages/linphone.scm b/gnu/packages/linphone.scm index d41d368e67..bd7dffdf4a 100644 --- a/gnu/packages/linphone.scm +++ b/gnu/packages/linphone.scm @@ -3,6 +3,8 @@ ;;; Copyright © 2020, 2021 Raghav Gururajan <raghavgururajan@disroot.org> ;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2020 Tobias Geerinckx-Rice <me@tobias.gr> +;;; Copyright © 2023 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2023 Andreas Enge <andreas@enge.fr> ;;; ;;; This file is part of GNU Guix. ;;; @@ -22,6 +24,7 @@ (define-module (gnu packages linphone) #:use-module (gnu packages) #:use-module (gnu packages admin) + #:use-module (gnu packages aidc) #:use-module (gnu packages audio) #:use-module (gnu packages avahi) #:use-module (gnu packages cpp) @@ -57,6 +60,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix build-system cmake) #:use-module (guix build-system qt)) @@ -130,7 +134,7 @@ writing, administering, and running unit tests in C.") (define-public bctoolbox (package (name "bctoolbox") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -139,18 +143,21 @@ writing, administering, and running unit tests in C.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0bfswwvvdshaahg4jd2j10f0sci8809s4khajd0m6b059zwc7y25")))) + (base32 "0b51308jy5z32gp594r78jvbyrha16sanxdnbcmxgrwnb4myqx5j")))) (build-system cmake-build-system) (outputs '("out" "debug")) (arguments - `(#:configure-flags '("-DENABLE_STATIC=OFF") + `(#:configure-flags (list "-DENABLE_STATIC=OFF" + ;; Do not use -Werror, because due to skipping + ;; a test there are unused procedures. + "-DENABLE_STRICT=OFF") #:phases (modify-phases %standard-phases (add-after 'unpack 'patch-cmake (lambda* (#:key inputs #:allow-other-keys) ;; Fix decaf dependency (see: ;; https://gitlab.linphone.org/BC/public/bctoolbox/-/issues/3). - (let* ((decaf (assoc-ref inputs "decaf"))) + (let* ((decaf (assoc-ref inputs "libdecaf"))) (substitute* (find-files "." "CMakeLists.txt") (("find_package\\(Decaf CONFIG\\)") "set(DECAF_FOUND 1)") @@ -162,7 +169,7 @@ writing, administering, and running unit tests in C.") (lambda _ ;; The following test relies on networking; disable it. (substitute* "tester/port.c" - (("[ \t]*TEST_NO_TAG.*bctbx_addrinfo_sort_test\\)") + (("[ \t]*TEST_NO_TAG.*bctbx_addrinfo_sort_test\\),") "")))) (add-after 'unpack 'fix-installed-resource-directory-detection (lambda _ @@ -176,13 +183,12 @@ writing, administering, and running unit tests in C.") (("if \\(file_exists\\(\"..\"\\)\\)") "if (NULL)")))) (replace 'check - (lambda _ - (with-directory-excursion "tester" - (invoke "./bctoolbox_tester"))))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (with-directory-excursion "tester" + (invoke "./bctoolbox_tester")))))))) (inputs - `(("bcunit" ,bcunit) - ("decaf" ,libdecaf) - ("mbedtls" ,mbedtls-apache))) + (list bcunit libdecaf mbedtls-apache)) (synopsis "Belledonne Communications Tool Box") (description "BcToolBox is an utilities library used by Belledonne Communications software like belle-sip, mediastreamer2 and linphone.") @@ -192,7 +198,7 @@ Communications software like belle-sip, mediastreamer2 and linphone.") (define-public belr (package (name "belr") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -201,36 +207,33 @@ Communications software like belle-sip, mediastreamer2 and linphone.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0w2canwwm0qb99whnangvaybvjzq8xg6vksqxykgr8fbx7clw03h")))) + (base32 "1bj8qd4ahbff476z0ccwsxy7qznqi6n5l1pdd7zbvk0h53zyj74c")))) (build-system cmake-build-system) (outputs '("out" "debug" "tester")) (arguments - `(#:configure-flags '("-DENABLE_STATIC=OFF") + (list + #:configure-flags '(list "-DENABLE_STATIC=OFF") #:phases - (modify-phases %standard-phases - (delete 'check) ;moved after the install phase - (add-after 'install 'check - (lambda* (#:key outputs #:allow-other-keys) - (let* ((tester (assoc-ref outputs "tester")) - (belr_tester (string-append tester "/bin/belr_tester")) - (tester-share (string-append tester "/share/belr_tester"))) - (invoke belr_tester)))) - (add-after 'install 'move-tester - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (tester (assoc-ref outputs "tester"))) + #~(modify-phases %standard-phases + (delete 'check) ;moved after the install phase + (add-after 'install 'check + (lambda* (#:key tests? outputs #:allow-other-keys) + (when tests? + (invoke (string-append #$output:tester "/bin/belr_tester"))))) + (add-after 'install 'move-tester + (lambda _ (for-each mkdir-p - (list (string-append tester "/bin") - (string-append tester "/share"))) + (list (string-append #$output:tester "/bin") + (string-append #$output:tester "/share"))) (rename-file - (string-append out "/bin/belr_tester") - (string-append tester "/bin/belr_tester")) + (string-append #$output "/bin/belr_tester") + (string-append #$output:tester "/bin/belr_tester")) (rename-file - (string-append out "/share/belr-tester") + (string-append #$output "/share/belr-tester/res") ;; The detect_res_prefix procedure in bctoolbox's tester.c ;; resolves the resource path based on the executable path and ;; name, so have it match. - (string-append tester "/share/belr_tester")))))))) + (string-append #$output:tester "/share/belr_tester"))))))) (inputs (list bctoolbox)) (synopsis "Belledonne Communications Language Recognition Library") @@ -244,7 +247,7 @@ IETF.") (define-public belcard (package (name "belcard") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -253,41 +256,38 @@ IETF.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "16x2xp8d0a115132zhy1kpxkyj86ia7vrsnpjdg78fnbvmvysc8m")))) + (base32 "1rl1x7rnlnncb45sjp8r2xbcwr9l8qv5bhfybhr0mmvsv3a4k4a3")))) (build-system cmake-build-system) (outputs '("out" "debug" "tester")) (arguments - `(#:configure-flags '("-DENABLE_STATIC=OFF") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-vcard-grammar-location - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (vcard-grammar - (string-append out "/share/belr/grammars/vcard_grammar"))) - (substitute* "include/belcard/vcard_grammar.hpp" - (("define VCARD_GRAMMAR \"vcard_grammar\"") - (format #f "define VCARD_GRAMMAR ~s" vcard-grammar)))))) - (add-after 'install 'install-tester - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (tester (assoc-ref outputs "tester")) - (test-name (string-append ,name "_tester"))) - (for-each mkdir-p - (list (string-append tester "/bin") - (string-append tester "/share"))) - (rename-file (string-append out "/bin/" test-name) - (string-append tester "/bin/" test-name)) - (rename-file (string-append out "/share/" test-name) - (string-append tester "/share/" test-name))))) - (delete 'check) - (add-after 'install-tester 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (when tests? - (let* ((tester (assoc-ref outputs "tester")) - (belcard_tester (string-append tester - "/bin/belcard_tester"))) - (invoke belcard_tester)))))))) + (list + #:configure-flags '(list "-DENABLE_STATIC=OFF") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-vcard-grammar-location + (lambda _ + (let ((vcard-grammar + (string-append #$output + "/share/belr/grammars/vcard_grammar"))) + (substitute* "include/belcard/vcard_grammar.hpp" + (("define VCARD_GRAMMAR \"vcard_grammar\"") + (format #f "define VCARD_GRAMMAR ~s" vcard-grammar)))))) + (add-after 'install 'install-tester + (lambda _ + (let ((test-name (string-append #$name "_tester"))) + (for-each mkdir-p + (list (string-append #$output:tester "/bin") + (string-append #$output:tester "/share"))) + (rename-file (string-append #$output "/bin/" test-name) + (string-append #$output:tester "/bin/" test-name)) + (rename-file (string-append #$output "/share/" test-name) + (string-append #$output:tester "/share/" test-name))))) + (delete 'check) + (add-after 'install-tester 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke (string-append #$output:tester + "/bin/belcard_tester")))))))) (inputs (list bctoolbox belr)) (synopsis "Belledonne Communications VCard Library") @@ -299,7 +299,7 @@ format.") (define-public bcmatroska2 (package (name "bcmatroska2") - (version "0.23") + (version "5.2.1") (source (origin (method git-fetch) @@ -308,11 +308,22 @@ format.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1avl9w18kh4dxm3g8j0bkw39bksd7bz3nfxvyibqqnz63ds8vfi2")))) + (base32 "14c79znw37q3yc7llbv2wmxmm4a3ws6iq3cvgkbmcnf7hmhm7zdi")))) (build-system cmake-build-system) (arguments - `(#:tests? #f ; No test target - #:configure-flags (list "-DENABLE_STATIC=NO"))) ; Not required + (list + #:tests? #f ;No test target + #:phases + '(modify-phases %standard-phases + ;; See + ;; https://gitlab.linphone.org/BC/public/bcmatroska2/-/merge_requests/18 + (add-after 'unpack 'fix-build-system + (lambda _ + (substitute* "corec/corec/CMakeLists.txt" + (("helpers/file/file_libc.c") ""))))) + #:configure-flags + '(list "-DENABLE_STATIC=NO"))) ;Not required + (inputs (list bctoolbox)) (synopsis "Belledonne Communications Media Container") (description "BcMatroska is a free and open standard multi-media container format. It can hold an unlimited number of video, audio, picture, or subtitle @@ -397,7 +408,7 @@ such as conferencing.") (define-public ortp (package (name "ortp") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -406,39 +417,39 @@ such as conferencing.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1r1kvjzyfvkf66in4p51wi87balzg3sw3aq6r4xr609mz86spi5m")))) + (base32 "1hzbrj1ny3lr9sql0lrxggc48sqv5j2yvbpnrdnph88pwzrdnbn5")))) (build-system cmake-build-system) (outputs '("out""tester" "doc")) ;1.5 MiB of HTML doc (arguments - `(#:tests? #f ;requires networking - #:configure-flags (list "-DENABLE_STATIC=NO" + (list + #:tests? #f ;requires networking + #:configure-flags '(list "-DENABLE_STATIC=NO" + "-DENABLE_DOC=NO" ;XXX: missing link for b64 "-DENABLE_TESTS=YES") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-version-strings - ;; See: https://gitlab.linphone.org/BC/public/ortp/-/issues/5. - (lambda _ - (substitute* "CMakeLists.txt" - (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+") - (string-append "VERSION " ,version)) - (("\\$\\{ORTP_DOC_VERSION\\}") - ,version)))) - (add-after 'install 'separate-outputs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc")) - (doc-src (string-append out "/share/doc/ortp-" ,version)) - (doc-dest (string-append doc "/share/doc/ortp-" ,version)) - (tester (assoc-ref outputs "tester"))) - (for-each mkdir-p (list (string-append doc "/share/doc") - (string-append tester "/bin"))) - (rename-file doc-src doc-dest) - (rename-file (string-append out "/bin") - (string-append tester "/bin")))))))) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-version-strings + ;; See: https://gitlab.linphone.org/BC/public/ortp/-/issues/5. + (lambda _ + (substitute* "CMakeLists.txt" + (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+") + (string-append "VERSION " #$version)) + (("\\$\\{ORTP_DOC_VERSION\\}") + #$version)))) + (add-after 'install 'separate-outputs + (lambda _ + (let* ((doc-src + (string-append #$output "/share/doc/ortp-" #$version)) + (doc-dest + (string-append #$output:doc "/share/doc/ortp-" #$version))) + (for-each mkdir-p (list (string-append #$output:doc "/share/doc") + (string-append #$output:tester "/bin"))) + (rename-file doc-src doc-dest) + (rename-file (string-append #$output "/bin") + (string-append #$output:tester "/bin")))))))) (native-inputs - `(("dot" ,graphviz) - ("doxygen" ,doxygen))) + (list graphviz doxygen)) (inputs (list bctoolbox)) (synopsis "Belledonne Communications RTP Library") @@ -450,7 +461,7 @@ implements the RFC 3550 standard.") (define-public bzrtp (package (name "bzrtp") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -459,7 +470,7 @@ implements the RFC 3550 standard.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1yjmsbqmymzl4r7sba6w4a2yld8m6hzafr6jf7sj0syhwpnc3zv6")))) + (base32 "0dvn1w0g9c07llz9n82l6qdzz8lzz74jcdm1yyfks0jy7i63cr8w")))) (build-system cmake-build-system) (arguments `(#:configure-flags @@ -467,9 +478,7 @@ implements the RFC 3550 standard.") "-DENABLE_STATIC=NO" "-DENABLE_TESTS=YES"))) (inputs - `(("bctoolbox" ,bctoolbox) - ("sqlite3" ,sqlite) - ("xml2" ,libxml2))) + (list bctoolbox libxml2 sqlite)) (synopsis "Belledonne Communications ZRTP Library") (description "BZRTP is an implementation of ZRTP keys exchange protocol, written in C. It is fully portable and can be executed on many platforms @@ -480,7 +489,7 @@ including both ARM and x86.") (define-public belle-sip (package (name "belle-sip") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -489,65 +498,78 @@ including both ARM and x86.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1kknnlczq7dpqaj1dwxvy092dzrqjy11ndkv90rqwmdryigkjk6z")))) + (base32 "0yx1qvzp11ysh24hxrvz7dm69j8zswa0xcx9m42vcv95z72166cq")))) (build-system cmake-build-system) (outputs '("out" "tester")) (arguments - `(#:configure-flags (list "-DENABLE_STATIC=NO" - "-DENABLE_MDNS=ON") + (list + #:configure-flags '(list "-DENABLE_STATIC=NO" + "-DENABLE_MDNS=ON" + ;; We skip a test and thus have an unused + ;; procedure, so we need to disable -Werror. + "-DENABLE_STRICT=OFF") #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch - (lambda* (#:key inputs #:allow-other-keys) - ;; Fix mDNS dependency. - (let* ((avahi (assoc-ref inputs "avahi"))) - (substitute* (find-files "." "CMakeLists.txt") - (("find_package\\(DNSSD REQUIRED\\)") - "set(DNSSD_FOUND 1)") - (("\\$\\{DNSSD_INCLUDE_DIRS\\}") - (string-append avahi "/include/avahi-compat-libdns_sd")) - (("\\$\\{DNSSD_LIBRARIES\\}") - "dns_sd"))) - (substitute* "src/CMakeLists.txt" - ;; ANTLR would use multithreaded DFA generation otherwise, - ;; which would not be reproducible. - (("-Xmultithreaded ") "")))) - (delete 'check) ;move after install - (add-after 'install 'separate-outputs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (tester (assoc-ref outputs "tester")) - (tester-name "belle_sip_tester")) - (for-each mkdir-p (list (string-append tester "/bin") - (string-append tester "/share"))) - (rename-file (string-append out "/bin") - (string-append tester "/bin")) - (rename-file (string-append out "/share/" tester-name) - (string-append tester "/share/" tester-name))))) - (add-after 'separate-outputs 'check - (lambda* (#:key outputs #:allow-other-keys) - (let ((tester (string-append (assoc-ref outputs "tester") - "/bin/belle_sip_tester"))) - (for-each (lambda (suite-name) - (invoke tester "--suite" suite-name)) - (list "Object inheritance" - "SIP URI" - "FAST SIP URI" - "FAST SIP URI 2" - "Generic uri" - "Headers" - "Core" - "SDP" - ;;"Resolver" - "Message" - "Authentication helper" - ;;"Register" - ;;"Dialog" - "Refresher" - ;;"HTTP stack" - "Object")))))))) + #~(modify-phases %standard-phases + (add-after 'unpack 'patch + (lambda* (#:key inputs #:allow-other-keys) + ;; Fix mDNS dependency. + (let* ((avahi (assoc-ref inputs "avahi"))) + (substitute* (find-files "." "CMakeLists.txt") + (("find_package\\(DNSSD REQUIRED\\)") + "set(DNSSD_FOUND 1)") + (("\\$\\{DNSSD_INCLUDE_DIRS\\}") + (string-append avahi "/include/avahi-compat-libdns_sd")) + (("\\$\\{DNSSD_LIBRARIES\\}") + "dns_sd"))) + ;; Disable broken test. This test uses + ;; bctbx_unescaped_string_only_chars_in_rules from bctoolbox, + ;; which unescapes too much. + (substitute* "tester/belle_sip_base_uri_tester.c" + (("[ \t]*TEST_NO_TAG.*test_unescaping_good_chars\\),") + "")) + (substitute* "src/sdp/parser.cc" + (("load\\(\"sdp_grammar\"\\)") + (string-append "load(\"" #$output + "/share/belr/grammars/sdp_grammar\")"))) + (substitute* "src/CMakeLists.txt" + ;; ANTLR would use multithreaded DFA generation otherwise, + ;; which would not be reproducible. + (("-Xmultithreaded ") "")))) + (delete 'check) ;move after install + (add-after 'install 'separate-outputs + (lambda _ + (let ((tester-name "belle_sip_tester")) + (for-each mkdir-p (list (string-append #$output:tester "/bin") + (string-append #$output:tester "/share"))) + (rename-file (string-append #$output "/bin") + (string-append #$output:tester "/bin")) + (rename-file (string-append #$output "/share/" tester-name) + (string-append #$output:tester "/share/" tester-name))))) + (add-after 'separate-outputs 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (let ((tester (string-append #$output:tester + "/bin/belle_sip_tester"))) + (for-each (lambda (suite-name) + (invoke tester "--suite" suite-name)) + (list "Object inheritance" + "SIP URI" + "FAST SIP URI" + "FAST SIP URI 2" + "Generic uri" + "Headers" + "Core" + "SDP" + ;;"Resolver" + "Message" + "Authentication helper" + ;;"Register" + ;;"Dialog" + "Refresher" + ;;"HTTP stack" + "Object"))))))))) (inputs - (list avahi bctoolbox zlib)) + (list avahi bctoolbox belr zlib)) (synopsis "Belledonne Communications SIP Library") (description "Belle-sip is a modern library implementing SIP transport, transaction and dialog layers. It is written in C, with an object-oriented @@ -558,7 +580,7 @@ API. It also comprises a simple HTTP/HTTPS client implementation.") (define-public mediastreamer2 (package (name "mediastreamer2") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -567,104 +589,99 @@ API. It also comprises a simple HTTP/HTTPS client implementation.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0989h3d0h7qrx4kjx8gg09j8c5hvvi3h8qi1iq1dqbppwbaxbz8c")))) + (base32 "0mj0q2xaac22p2wf5gvgaiga03fbydilxfxzwyc6nwp5fyjnzawd")))) (outputs '("out" "doc" "tester")) (build-system cmake-build-system) (arguments - `(#:configure-flags (list "-DENABLE_STATIC=NO" + (list + #:configure-flags '(list "-DENABLE_STATIC=NO" "-DENABLE_PCAP=YES" ;; Do not fail on compile warnings. "-DENABLE_STRICT=NO" "-DENABLE_PORTAUDIO=YES" "-DENABLE_G729B_CNG=YES") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-version - (lambda _ - (substitute* "CMakeLists.txt" - (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+") - (string-append "VERSION " ,version))))) - (add-after 'unpack 'patch-source - (lambda _ - (substitute* "src/otherfilters/mspcapfileplayer.c" - (("O_BINARY") "L_INCR")))) - (add-before 'check 'pre-check - (lambda _ - ;; Tests require a running X server. - (system "Xvfb :1 +extension GLX &") - (setenv "DISPLAY" ":1") - ;; Tests write to $HOME. - (setenv "HOME" (getenv "TEMP")))) - (delete 'check) ;move after install - (add-after 'install 'separate-outputs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (tester (assoc-ref outputs "tester")) - (tester-name (string-append ,name "_tester")) - (doc (assoc-ref outputs "doc")) - (doc-name (string-append ,name "-" ,version))) - (for-each mkdir-p - (list (string-append tester "/bin") - (string-append tester "/share") - (string-append doc "/share/doc"))) - ;; Move the tester executable. - (rename-file (string-append out "/bin/" tester-name) - (string-append tester "/bin/" tester-name)) - ;; Move the tester data files. - (rename-file (string-append out "/share/" tester-name) - (string-append tester "/share/" tester-name)) - ;; Move the HTML documentation. - (rename-file (string-append out "/share/doc/" doc-name) - (string-append doc "/share/doc/" doc-name))))) - (add-after 'separate-outputs 'check - (lambda* (#:key outputs #:allow-other-keys) - (let ((tester (string-append (assoc-ref outputs "tester") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-version + (lambda _ + (substitute* "CMakeLists.txt" + (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+") + (string-append "VERSION " #$version))))) + (add-after 'unpack 'patch-source + (lambda _ + (substitute* "src/otherfilters/mspcapfileplayer.c" + (("O_BINARY") "L_INCR")))) + (add-before 'check 'pre-check + (lambda _ + ;; Tests require a running X server. + (system "Xvfb :1 +extension GLX &") + (setenv "DISPLAY" ":1") + ;; Tests write to $HOME. + (setenv "HOME" (getenv "TEMP")))) + (delete 'check) ;move after install + (add-after 'install 'separate-outputs + (lambda _ + (let ((tester-name (string-append #$name "_tester")) + (doc-name (string-append #$name "-" #$version))) + (for-each mkdir-p + (list (string-append #$output:tester "/bin") + (string-append #$output:tester "/share") + (string-append #$output:doc "/share/doc"))) + ;; Move the tester executable. + (rename-file (string-append #$output "/bin/" tester-name) + (string-append #$output:tester "/bin/" tester-name)) + ;; Move the tester data files. + (rename-file (string-append #$output "/share/" tester-name) + (string-append #$output:tester "/share/" tester-name)) + ;; Move the HTML documentation. + (rename-file (string-append #$output "/share/doc/" doc-name) + (string-append #$output:doc "/share/doc/" doc-name))))) + (add-after 'separate-outputs 'check + (lambda _ + (let ((tester (string-append #$output:tester "/bin/mediastreamer2_tester"))) - (for-each (lambda (suite-name) - (invoke tester "--suite" suite-name)) - ;; Some tests fail, due to requiring access to the - ;; sound card or the network. - (list "Basic Audio" - ;; "Sound Card" - ;; "AdaptiveAlgorithm" - ;; "AudioStream" - ;; "VideoStream" - "H26x Tools" - "Framework" - ;; "Player" - "TextStream")))))))) + (for-each (lambda (suite-name) + (invoke tester "--suite" suite-name)) + ;; Some tests fail, due to requiring access to the + ;; sound card or the network. + (list "Basic Audio" + ;; "Sound Card" + ;; "AdaptiveAlgorithm" + ;; "AudioStream" + ;; "VideoStream" + "H26x Tools" + "Framework" + ;; "Player" + "TextStream")))))))) (native-inputs - `(("dot" ,graphviz) - ("doxygen" ,doxygen) - ("python" ,python-wrapper) - ("xorg-server" ,xorg-server-for-tests))) + (list graphviz doxygen python-wrapper xorg-server-for-tests)) (inputs - `(("alsa" ,alsa-lib) - ("bcg729" ,bcg729) - ("bcmatroska2" ,bcmatroska2) - ("bctoolbox" ,bctoolbox) - ("ffmpeg" ,ffmpeg-4) - ("glew" ,glew) - ("glu" ,glu) - ("glx" ,mesa-utils) - ("gsm" ,gsm) - ("opengl" ,mesa) - ("opus" ,opus) - ("ortp" ,ortp) - ("pcap" ,libpcap) - ("portaudio" ,portaudio) - ("pulseaudio" ,pulseaudio) - ("spandsp" ,spandsp) - ("speex" ,speex) - ("speexdsp" ,speexdsp) - ("srtp" ,libsrtp) - ("theora" ,libtheora) - ("turbojpeg" ,libjpeg-turbo) - ("v4l" ,v4l-utils) - ("vpx" ,libvpx) - ("x11" ,libx11) - ("xv" ,libxv) - ("zrtp" ,bzrtp))) + (list alsa-lib + bcg729 + bcmatroska2 + bctoolbox + ffmpeg-4 + glew + glu + mesa-utils + gsm + mesa + opus + ortp + libpcap + portaudio + pulseaudio + spandsp + speex + speexdsp + libsrtp + libtheora + libjpeg-turbo + v4l-utils + libvpx + libx11 + libxv + bzrtp)) (synopsis "Belledonne Communications Streaming Engine") (description "Mediastreamer2 is a powerful and lightweight streaming engine for telephony applications. This media processing and streaming toolkit is @@ -676,7 +693,7 @@ including media capture, encoding and decoding, and rendering.") (define-public lime (package (name "lime") - (version "4.4.34") + (version "5.2.49") (source (origin (method git-fetch) @@ -685,12 +702,13 @@ including media capture, encoding and decoding, and rendering.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "14jg1zisjbzflw3scfqdbwy48wq3cp93l867vigb8l40lkc6n26z")))) + (base32 "1mglnypxl3glwvwf2h5q4ikbm6wbcd9pb7kdws8zajjhk9q803jr")))) (build-system cmake-build-system) (outputs '("out" "doc")) (arguments `(#:configure-flags (list "-DENABLE_STATIC=NO" - "-DENABLE_C_INTERFACE=YES") + "-DENABLE_C_INTERFACE=YES" + "-DENABLE_DOC=YES") #:phases (modify-phases %standard-phases (add-after 'unpack 'patch-source @@ -699,7 +717,9 @@ including media capture, encoding and decoding, and rendering.") (substitute* "tester/CMakeLists.txt" (("add_test\\(?.*\"Hello World\"\\)") "") (("add_test\\(?.*\"lime\"\\)") "") - (("add_test\\(?.*\"FFI\"\\)") "")))) + (("add_test\\(?.*\"FFI\"\\)") "") + (("add_test\\(?.*\"Multidomains\"\\)") "") + (("add_test\\(?.*\"Lime server\"\\)") "")))) (add-after 'build 'build-doc (lambda _ (invoke "make" "doc"))) @@ -726,7 +746,7 @@ device.") (define-public liblinphone (package (name "liblinphone") - (version "4.4.34") + (version "5.2.50") (source (origin (method git-fetch) @@ -735,30 +755,32 @@ device.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1lwabr93jw24y04pdqnw9dgg8jb3lzfplyx19f83jgp9dj8kmfq9")))) + (base32 "1lvbva234rmck57cxgswgqqvnq8r58i0ls4qgpymrxdfj74rinxj")))) (outputs '("out" "tester")) (build-system cmake-build-system) (arguments - `(#:tests? #f ; Tests require networking - #:configure-flags (list "-DENABLE_STATIC=NO" - "-DENABLE_DOC=NO" ;requires unpackaged javasphinx - "-DENABLE_LDAP=YES") - #:phases - (modify-phases %standard-phases - (add-after 'install 'separate-outputs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (tester (assoc-ref outputs "tester")) - (tester-name (string-append ,name "_tester"))) - (for-each mkdir-p - (list (string-append tester "/bin") - (string-append tester "/share"))) - (rename-file (string-append out "/bin/" tester-name) - (string-append tester "/bin/" tester-name)) - (rename-file (string-append out "/bin/groupchat_benchmark") - (string-append tester "/bin/groupchat_benchmark")) - (rename-file (string-append out "/share/" tester-name) - (string-append tester "/share/" tester-name)))))))) + (list + #:tests? #f ; Tests require networking + #:configure-flags + '(list "-DENABLE_FLEXIAPI=NO" ;requires jsoncpp, but it cannot be found + "-DENABLE_STATIC=NO" + "-DENABLE_DOC=NO" ;requires unpackaged javasphinx + "-DENABLE_LDAP=YES" + "-DENABLE_STRICT=NO") + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'separate-outputs + (lambda* (#:key outputs #:allow-other-keys) + (let ((tester-name (string-append #$name "_tester"))) + (for-each mkdir-p + (list (string-append #$output:tester "/bin") + (string-append #$output:tester "/share"))) + (rename-file (string-append #$output "/bin/" tester-name) + (string-append #$output:tester "/bin/" tester-name)) + (rename-file (string-append #$output "/bin/groupchat_benchmark") + (string-append #$output:tester "/bin/groupchat_benchmark")) + (rename-file (string-append #$output "/share/" tester-name) + (string-append #$output:tester "/share/" tester-name)))))))) (native-inputs (list graphviz doxygen @@ -774,16 +796,17 @@ device.") belle-sip belr bzrtp - openldap - xsd lime - mediastreamer2 libnotify + libxml2 + mediastreamer2 + openldap ortp soci sqlite - libxml2 - zlib)) + xsd + zlib + zxing-cpp)) (synopsis "Belledonne Communications Softphone Library") (description "Liblinphone is a high-level SIP library integrating all calling and instant messaging features into an unified @@ -796,7 +819,7 @@ and video calls or instant messaging capabilities to an application.") (define-public linphone-desktop (package (name "linphone-desktop") - (version "4.2.5") + (version "5.0.14") (source (origin (method git-fetch) @@ -805,41 +828,55 @@ and video calls or instant messaging capabilities to an application.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1gq4l9p21rbrcksa7fbkzn9fzbbynqmn6ni6lhnvzk359sb1xvbz")) + (base32 "0glrfsp087ni5hn6x6p4f6y63r4nyp061yyy0rfgddbxkzdqi2j1")) (patches (search-patches "linphone-desktop-without-sdk.patch")))) (build-system qt-build-system) (outputs '("out" "debug")) (arguments - `(#:tests? #f ; No test target - #:configure-flags (list "-DENABLE_UPDATE_CHECK=NO" - "-DENABLE_DAEMON=YES" - "-DENABLE_CONSOLE_UI=YES") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'pre-configure - (lambda _ - (make-file-writable "linphone-app/linphoneqt_version.cmake") - (substitute* "linphone-app/linphoneqt_version.cmake" - (("\\$\\{GUIX-SET-VERSION\\}") ,version)))) - (add-after 'install 'post-install - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (liblinphone (assoc-ref inputs "liblinphone")) - (grammar-dest (string-append out "/share/belr/grammars"))) - ;; Remove unnecessary Qt configuration file. - (delete-file (string-append out "/bin/qt.conf")) - ;; Not using the FHS exposes an issue where the client - ;; refers to its own directories, which lacks files - ;; installed by the dependencies. - (symlink (string-append liblinphone "/lib") - (string-append out "/lib")) - (symlink (string-append liblinphone "/share/sounds") - (string-append out "/share/sounds")) - (symlink (string-append liblinphone "/share/linphone/rootca.pem") - (string-append out "/share/linphone/rootca.pem")) - (mkdir-p (dirname grammar-dest)) - (symlink (string-append liblinphone "/share/belr/grammars") - grammar-dest))))))) + (list + #:tests? #f ; No test target + #:configure-flags + #~(list (string-append "-DFULL_VERSION=" #$version) + (string-append "-DCMAKE_INSTALL_PREFIX=" #$output) + (string-append "-DCMAKE_INSTALL_BINDIR=" #$output "/bin") + (string-append "-DCMAKE_INSTALL_DATAROOTDIR=" #$output "/share") + (string-append "-DCMAKE_INSTALL_LIBDIR=" #$output "/lib") + "-DENABLE_UPDATE_CHECK=NO" + "-DENABLE_DAEMON=YES" + "-DENABLE_CONSOLE_UI=YES") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'pre-configure + (lambda _ + (make-file-writable "linphone-app/linphoneqt_version.cmake") + (substitute* "linphone-app/linphoneqt_version.cmake" + (("\\$\\{GUIX-SET-VERSION\\}") #$version)))) + (add-before 'install 'pre-install + (lambda _ + (mkdir-p (string-append #$output "/share/linphone")) + (symlink (string-append #$(this-package-input "liblinphone") + "/share/sounds") + (string-append #$output + "/share/sounds")))) + (add-after 'install 'post-install + (lambda _ + (let* ((liblinphone #$(this-package-input "liblinphone")) + (grammar-dest (string-append #$output "/share/belr/grammars"))) + ;; Remove unnecessary Qt configuration file. + (delete-file (string-append #$output "/bin/qt.conf")) + ;; Not using the FHS exposes an issue where the client + ;; refers to its own directories, which lacks files + ;; installed by the dependencies. + (for-each + (lambda (file) + (symlink file + (string-append #$output "/lib/" (basename file)))) + (find-files (string-append liblinphone "/lib"))) + (symlink (string-append liblinphone "/share/linphone/rootca.pem") + (string-append #$output "/share/linphone/rootca.pem")) + (mkdir-p (dirname grammar-dest)) + (symlink (string-append liblinphone "/share/belr/grammars") + grammar-dest))))))) (native-inputs (list pkg-config qttools-5)) (inputs diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 47366d0641..29213f5fd1 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -774,11 +774,11 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The following package is used in the early bootstrap, and thus must be kept ;; stable and with minimal build requirements. -(define-public linux-libre-headers-5.10.35 - (make-linux-libre-headers "5.10.35" "gnu" - "0q2rnchad55d49f3rajrkazz0fcjv1irwrdb1hwjnl01fzm2gjk3")) +(define-public linux-libre-headers-5.15.49 + (make-linux-libre-headers "5.15.49" "gnu" + "13zqdcm4664vh7g57sxbfrlpsxm7zrma72mxdfdz7d9yndy2gfv8")) -(define-public linux-libre-headers linux-libre-headers-5.10.35) +(define-public linux-libre-headers linux-libre-headers-5.15.49) ;;; @@ -1786,7 +1786,7 @@ which need to be installed separately.") (define-public linux-pam (package (name "linux-pam") - (version "1.5.1") + (version "1.5.2") (source (origin (method url-fetch) @@ -1795,8 +1795,9 @@ which need to be installed separately.") version "/Linux-PAM-" version ".tar.xz")) (sha256 (base32 - "1z4jayf69qyyxln1gl6ch4qxfd66ib1g42garnrv2d8i1drl0790")) - (patches (search-patches "linux-pam-no-setfsuid.patch")))) + "0kgrsj2scv5mx6w925h9hxf11jnqqs9z8s22aw94b90xm4qp3v74")) + (patches (search-patches "linux-pam-unix_chkpwd.patch" + "linux-pam-no-setfsuid.patch")))) (build-system gnu-build-system) (native-inputs @@ -1806,22 +1807,39 @@ which need to be installed separately.") ;; ("cracklib" ,cracklib) )) (arguments - `(;; Most users, such as `shadow', expect the headers to be under - ;; `security'. - #:configure-flags (list (string-append "--includedir=" - (assoc-ref %outputs "out") - "/include/security") - - ;; XXX: <rpc/rpc.h> is missing from glibc when - ;; cross-compiling, so we have to disable NIS - ;; support altogether. - ,@(if (%current-target-system) - '("--disable-nis") - '())) - - ;; XXX: Tests won't run in chroot, presumably because /etc/pam.d - ;; isn't available. - #:tests? #f)) + (list + ;; Most users, such as `shadow', expect the headers to be under + ;; `security'. + #:configure-flags #~(list (string-append "--includedir=" + (assoc-ref %outputs "out") + "/include/security") + ;; explicit libdir for pkgconfig files + ;; drop with 1.5.3, which fixes + ;; https://github.com/linux-pam/linux-pam/issues/466 + (string-append "--libdir=" + (assoc-ref %outputs "out") + "/lib") + + ;; XXX: <rpc/rpc.h> is missing from glibc when + ;; cross-compiling, so we have to disable NIS + ;; support altogether. + #$@(if (%current-target-system) + #~("--disable-nis") + #~())) + + #:phases (if (target-hurd?) + #~(modify-phases %standard-phases + (add-after 'unpack 'skip-pam-limits + (lambda _ + ;; 'pam_limits.c' uses <sys/prctl.h>, which is + ;; Linux-specific. Skip it on GNU/Hurd. + (substitute* "modules/Makefile.in" + (("pam_limits") ""))))) + #~%standard-phases) + + ;; XXX: Tests won't run in chroot, presumably because /etc/pam.d + ;; isn't available. + #:tests? #f)) (home-page "http://www.linux-pam.org/") (synopsis "Pluggable authentication modules for Linux") (description @@ -2050,8 +2068,7 @@ providing the system administrator with some help in common tasks.") (define-public util-linux (package (name "util-linux") - (replacement util-linux/fixed) - (version "2.37.2") + (version "2.37.4") (source (origin (method url-fetch) (uri (string-append "mirror://kernel.org/linux/utils/" @@ -2059,7 +2076,7 @@ providing the system administrator with some help in common tasks.") "util-linux-" version ".tar.xz")) (sha256 (base32 - "1ng9517c37mdp858425a4zyybma7dh7jrpd6z1z61yz7mb0n81va")) + "10svcnsqmrsd660bzcm7k6dm8sa7hkknhr3bag1nccwimlb6jkk3")) (patches (search-patches "util-linux-tests.patch")) (modules '((guix build utils))) (snippet @@ -2076,102 +2093,101 @@ providing the system administrator with some help in common tasks.") "lib" ;8.8 MiB shared libraries, headers and locales "static")) ;2.9 MiB static .a libraries (arguments - `(#:configure-flags (list "--disable-use-tty-group" - (string-append - "--enable-fs-paths-default=" - "/run/setuid-programs" - ":/run/current-system/profile/sbin") - ;; Don't try to chown root:root mount and umount - "--disable-makeinstall-chown" - "--localstatedir=/var" - (string-append "--localedir=" - (assoc-ref %outputs "lib") - "/share/locale") - ;; Install completions where our - ;; bash-completion package expects them. - (string-append "--with-bashcompletiondir=" - (assoc-ref %outputs "out") - "/etc/bash_completion.d")) - - ;; FIXME: For now we cannot reliably run tests on GNU/Hurd: - ;; <https://bugs.gnu.org/47791>. - #:tests? ,(and (not (%current-target-system)) - (not (string-suffix? "-gnu" (%current-system)))) + (list #:configure-flags + #~(list "--disable-use-tty-group" + (string-append + "--enable-fs-paths-default=" + "/run/setuid-programs" + ":/run/current-system/profile/sbin") + ;; Don't try to chown root:root mount and umount + "--disable-makeinstall-chown" + "--localstatedir=/var" + (string-append "--localedir=" #$output:lib + "/share/locale") + ;; Install completions where our bash-completion package + ;; expects them. + (string-append "--with-bashcompletiondir=" #$output + "/etc/bash_completion.d")) + + ;; FIXME: For now we cannot reliably run tests on GNU/Hurd: + ;; <https://bugs.gnu.org/47791>. + #:tests? (and (not (%current-target-system)) + (not (string-suffix? "-gnu" (%current-system)))) - #:phases (modify-phases %standard-phases - (add-before 'configure 'patch-build-scripts - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "configure" - ;; The build system assumes that we want to install - ;; libraries below $exec_prefix when $libdir does not - ;; match any of the "usual" locations. Fix that. - (("usrlib_execdir='\\$\\{exec_prefix\\}'\\$libdir") - "usrlib_execdir=$libdir")))) - (add-before 'build 'set-umount-file-name - (lambda* (#:key outputs #:allow-other-keys) - ;; Tell 'eject' the right file name of 'umount'. - (let ((out (assoc-ref outputs "out"))) - (substitute* "sys-utils/eject.c" - (("\"/bin/umount\"") - (string-append "\"" out "/bin/umount\"")))))) - (add-before 'check 'pre-check - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (let ((services (search-input-file (or native-inputs inputs) - "etc/services"))) - ;; Change the test to refer to the right file. - (substitute* "tests/ts/misc/mcookie" - (("/etc/services") - services)) - - ;; The C.UTF-8 locale does not exist in our libc. - (substitute* "tests/ts/column/invalid-multibyte" - (("C\\.UTF-8") "en_US.utf8"))))) - (add-before 'check 'disable-setarch-test - (lambda _ - ;; The setarch tests are unreliable in QEMU's user-mode - ;; emulation, which is our primary method of building - ;; ARMv7 packages. See - ;; <https://github.com/karelzak/util-linux/issues/601>. - (substitute* "tests/ts/misc/setarch" - (("ts_init_subtest.*" all) - (string-append - all "\n" - "ts_skip \"setarch tests are unreliable under QEMU\""))))) - (add-before 'check 'disable-lsns-test - (lambda _ - ;; The lsns tests can fail due to ioctl(_, NS_GET_USERNS) - ;; returning ENOTTY, indicating this kernel does not - ;; support user namespaces. Curiously, this test can fail - ;; on i686 even if the same test passes on x86_64 on the - ;; same machine. See <https://issues.guix.gnu.org/49933>. - (delete-file "tests/ts/lsns/ioctl_ns"))) - (add-after 'install 'move-static-libraries - (lambda* (#:key outputs #:allow-other-keys) - (let ((lib (assoc-ref outputs "lib")) - (static (assoc-ref outputs "static"))) - - ;; Move static libraries to the "static" output. - (mkdir-p (string-append static "/lib")) - (with-directory-excursion lib - (for-each (lambda (file) - (rename-file file - (string-append static "/" - file))) - (find-files "lib" "\\.a$")) - - ;; Remove references to the static library from the '.la' - ;; files so that Libtool does the right thing when both - ;; the shared and static library is available. - (substitute* (find-files "lib" "\\.la$") - (("old_library=.*") "old_library=''\n")))))) - (add-after 'install 'adjust-pkg-config-files - (lambda* (#:key outputs #:allow-other-keys) - (let ((lib (assoc-ref outputs "lib"))) - ;; Drop the unused "prefix=" and "exec_prefix=" variables from - ;; the pkg-config files to avoid a cyclic reference on "out". - (substitute* (find-files (string-append lib "/lib/pkgconfig") - "\\.pc$") - (("^(exec_)?prefix=.*") "")))))))) + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'patch-build-scripts + (lambda _ + (substitute* "configure" + ;; The build system assumes that we want to install + ;; libraries below $exec_prefix when $libdir does not + ;; match any of the "usual" locations. Fix that. + (("usrlib_execdir='\\$\\{exec_prefix\\}'\\$libdir") + "usrlib_execdir=$libdir")))) + (add-before 'build 'set-umount-file-name + (lambda _ + ;; Tell 'eject' the right file name of 'umount'. + (substitute* "sys-utils/eject.c" + (("\"/bin/umount\"") + (string-append "\"" #$output "/bin/umount\""))))) + (add-before 'check 'pre-check + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (let ((services (search-input-file (or native-inputs inputs) + "etc/services"))) + ;; Change the test to refer to the right file. + (substitute* "tests/ts/misc/mcookie" + (("/etc/services") + services)) + + ;; The C.UTF-8 locale does not exist in our libc. + (substitute* "tests/ts/column/invalid-multibyte" + (("C\\.UTF-8") "en_US.utf8"))))) + (add-before 'check 'disable-setarch-test + (lambda _ + ;; The setarch tests are unreliable in QEMU's user-mode + ;; emulation, which is our primary method of building + ;; ARMv7 packages. See + ;; <https://github.com/karelzak/util-linux/issues/601>. + (substitute* "tests/ts/misc/setarch" + (("ts_init_subtest.*" all) + (string-append + all "\n" + "ts_skip \"setarch tests are unreliable under QEMU\""))))) + (add-before 'check 'disable-lsns-test + (lambda _ + ;; The lsns tests can fail due to ioctl(_, NS_GET_USERNS) + ;; returning ENOTTY, indicating this kernel does not + ;; support user namespaces. Curiously, this test can fail + ;; on i686 even if the same test passes on x86_64 on the + ;; same machine. See <https://issues.guix.gnu.org/49933>. + (delete-file "tests/ts/lsns/ioctl_ns"))) + (add-after 'install 'move-static-libraries + (lambda _ + (let ((lib #$output:lib) + (static #$output:static)) + + ;; Move static libraries to the "static" output. + (mkdir-p (string-append static "/lib")) + (with-directory-excursion lib + (for-each (lambda (file) + (rename-file file + (string-append static "/" + file))) + (find-files "lib" "\\.a$")) + + ;; Remove references to the static library from the '.la' + ;; files so that Libtool does the right thing when both + ;; the shared and static library is available. + (substitute* (find-files "lib" "\\.la$") + (("old_library=.*") "old_library=''\n")))))) + (add-after 'install 'adjust-pkg-config-files + (lambda _ + ;; Drop the unused "prefix=" and "exec_prefix=" variables from + ;; the pkg-config files to avoid a cyclic reference on "out". + (substitute* (find-files (string-append #$output:lib + "/lib/pkgconfig") + "\\.pc$") + (("^(exec_)?prefix=.*") ""))))))) (inputs (list file ;for libmagic ncurses @@ -2203,21 +2219,6 @@ block devices, UUIDs, TTYs, and many other tools.") (modify-inputs (package-inputs util-linux) (prepend eudev))))) -;; This is mostly equivalent to the upstream release version v2.37.3, except -;; that the upstream tarball was generated improperly, which breaks the build. -;; There will not be a v2.37.3-fixed release or anything like that to fix it: -;; https://github.com/util-linux/util-linux/issues/1577 -(define-public util-linux/fixed - (hidden-package - (package - (inherit util-linux) - (source (origin - (inherit (package-source util-linux)) - (patches (append (search-patches "util-linux-CVE-2021-3995.patch" - "util-linux-CVE-2021-3996.patch") - (origin-patches (package-source util-linux))))))))) - - (define-public ddate (package (name "ddate") @@ -2322,39 +2323,38 @@ parameters.") (define-public procps (package (name "procps") - (version "3.3.16") + (version "4.0.3") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/procps-ng/Production/" "procps-ng-" version ".tar.xz")) (sha256 (base32 - "1br0g93ysqhlv13i1k4lfbimsgxnpy5rgs4lxfc9rkzdbpbaqplj")))) - (build-system gnu-build-system) - (arguments - `(#:modules ((guix build utils) - (guix build gnu-build-system) - (srfi srfi-1) - (srfi srfi-26)) - ,@(if (%current-target-system) - '(#:configure-flags - (list - "ac_cv_func_malloc_0_nonnull=yes" - "ac_cv_func_realloc_0_nonnull=yes")) - '()) - #:phases - (modify-phases %standard-phases - (add-after - 'install 'post-install - ;; Remove commands and man pages redudant with - ;; Coreutils. - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (dup (append-map (cut find-files out <>) - '("^kill" "^uptime")))) - (for-each delete-file dup) - #t)))))) + "14ms9mkqr1mgl3h5yl6w8m57cf39k382nv7qms78vqbaz728wg1h")) + (patches (search-patches "procps-strtod-test.patch")))) + (build-system gnu-build-system) + (arguments + (list #:modules '((guix build utils) + (guix build gnu-build-system) + (srfi srfi-1) + (srfi srfi-26)) + #:configure-flags + (if (%current-target-system) + #~'("ac_cv_func_malloc_0_nonnull=yes" + "ac_cv_func_realloc_0_nonnull=yes") + #~'()) + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'post-install + ;; Remove commands and man pages redudant with + ;; Coreutils. + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out #$output) + (dup (append-map (cut find-files out <>) + '("^kill" "^uptime")))) + (for-each delete-file dup))))))) (inputs (list ncurses)) + (native-inputs (list pkg-config)) (home-page "https://gitlab.com/procps-ng/procps/") (synopsis "Utilities that give information about processes") (description @@ -2905,16 +2905,14 @@ external rate conversion.") (define-public iptables (package (name "iptables") - (version "1.8.7") + (version "1.8.8") (source (origin (method url-fetch) (uri (list (string-append "mirror://netfilter.org/iptables/iptables-" - version ".tar.bz2") - (string-append "https://www.netfilter.org/projects/iptables/" - "files/iptables-" version ".tar.bz2"))) + version ".tar.bz2"))) (sha256 - (base32 "1w6qx3sxzkv80shk21f63rq41c84irpx68k62m2cv629n1mwj2f1")))) + (base32 "17w5a4znq8rdj5djcldmy6mbnxq1v88ibssk2mipc1kivj4miivi")))) (build-system gnu-build-system) (native-inputs (list pkg-config flex bison)) @@ -2923,11 +2921,7 @@ external rate conversion.") (arguments (list #:tests? #f ; no test suite #:configure-flags ; add $libdir to the RUNPATH of executables - ;; XXX TODO: Replace with simply #$OUTPUT on core-updates. - #~(list (string-append "LDFLAGS=-Wl,-rpath=" - #$(if (%current-target-system) - #~#$output - #~%output) "/lib")))) + #~(list (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib")))) (home-page "https://www.netfilter.org/projects/iptables/index.html") (synopsis "Programs to configure Linux IP packet filtering rules") (description @@ -2939,6 +2933,8 @@ This package also includes @command{ip6tables}, which is used to configure the IPv6 packet filter. Both commands are targeted at system administrators.") + (properties + '((release-monitoring-url . "https://www.netfilter.org/pub/iptables/"))) (license license:gpl2+))) (define-public bolt @@ -3087,7 +3083,7 @@ that the Ethernet protocol is much simpler than the IP protocol.") (define-public iproute (package (name "iproute2") - (version "5.15.0") + (version "6.0.0") (source (origin (method url-fetch) (uri (string-append @@ -3095,44 +3091,40 @@ that the Ethernet protocol is much simpler than the IP protocol.") version ".tar.xz")) (sha256 (base32 - "1zwin8sjnnwf2a9rjwzb3q8lkhcpy06s29sh05f5gxd7z6jy9qrq")))) + "02jq36p7py8zs8s8jj49ap82sgf5wi5yfbgsfiirkv1awzlkjcaj")))) (build-system gnu-build-system) (arguments - `( ;; There is a test suite, but it wants network namespaces and sudo. - #:tests? #f - #:make-flags (let ((out (assoc-ref %outputs "out"))) - (list "DESTDIR=" - (string-append "CC=" ,(cc-for-target)) - "HOSTCC=gcc" - (string-append "BASH_COMPDIR=" out - "/etc/bash_completion.d") - (string-append "LIBDIR=" out "/lib") - (string-append "HDRDIR=" out "/include") - (string-append "SBINDIR=" out "/sbin") - (string-append "CONFDIR=" out "/etc") - (string-append "DOCDIR=" out "/share/doc/" - ,name "-" ,version) - (string-append "MANDIR=" out "/share/man"))) - #:phases (modify-phases %standard-phases - (add-before 'install 'pre-install - (lambda _ - ;; Don't attempt to create /var/lib/arpd. - (substitute* "Makefile" - (("^.*ARPDDIR.*$") "")) - #t)) - (add-after 'unpack 'patch-configure - (lambda _ - (let ((target ,(%current-target-system))) - (substitute* "configure" - (("pkg-config") - (if target - (string-append target "-pkg-config") - "pkg-config"))) - #t)))))) + (list + ;; There is a test suite, but it wants network namespaces and sudo. + #:tests? #f + #:make-flags + #~(let ((out #$output)) + (list (string-append "CC=" #$(cc-for-target)) + "HOSTCC=gcc" + (string-append "BASH_COMPDIR=" out + "/etc/bash_completion.d") + (string-append "LIBDIR=" out "/lib") + (string-append "HDRDIR=" out "/include") + (string-append "SBINDIR=" out "/sbin") + (string-append "CONFDIR=" out "/etc") + (string-append "MANDIR=" out "/share/man"))) + #:phases + #~(modify-phases %standard-phases + (replace 'configure + (lambda* (#:key (configure-flags #~'()) #:allow-other-keys) + ;; The configure script does not understand some of the + ;; default options of gnu-build-system. + (setenv "PKG_CONFIG" #$(pkg-config-for-target)) + (apply invoke "./configure" + "--prefix" #$output + configure-flags))) + (add-before 'install 'pre-install + (lambda _ + ;; Don't attempt to create /var/lib/arpd. + (substitute* "Makefile" + (("^.*ARPDDIR.*$") ""))))))) (inputs - `(("db4" ,bdb) - ("iptables" ,iptables) - ("libmnl" ,libmnl))) + (list bdb iptables libmnl)) (native-inputs (list bison flex pkg-config)) ;; For tests. @@ -3233,7 +3225,7 @@ configuration (iptunnel, ipmaddr).") (define-public libcap (package (name "libcap") - (version "2.62") + (version "2.64") (source (origin (method url-fetch) (uri (string-append @@ -3241,7 +3233,7 @@ configuration (iptunnel, ipmaddr).") "libcap2/libcap-" version ".tar.xz")) (sha256 (base32 - "18l3pngsbaahdjzz01rmzrjgcqny4zld685fkq96mq5yr6m5n30r")))) + "04qy0z6yhlljb29xxcb2srbdnymcrhsi28wrc705z3861cgmwin8")))) (build-system gnu-build-system) (arguments (list #:phases @@ -5611,7 +5603,7 @@ Linux Device Mapper multipathing driver: (define-public libaio (package (name "libaio") - (version "0.3.112") + (version "0.3.113") (source (origin (method url-fetch) (uri (list @@ -5619,37 +5611,17 @@ Linux Device Mapper multipathing driver: name "-" version ".tar.gz"))) (sha256 (base32 - "14mlqdapjqq1dhpkdgy5z83mvsaz36fcxca7a4z6hinmr7r6415b")))) + "02r0g2vfv6kfljplm3ga93w4xw13q2wixbn9hwi7ahqdzp2x2i1c")) + (patches (search-patches "libaio-32bit-test.patch")))) (build-system gnu-build-system) (arguments (list #:make-flags - #~(let ((target #$(%current-target-system))) - ;; XXX TODO: Replace with simply #$OUTPUT on core-updates. - (list (string-append "prefix=" #$(if (%current-target-system) - #~#$output - #~%output)) - (string-append - "CC=" (if target - (string-append (assoc-ref %build-inputs - "cross-gcc") - "/bin/" target "-gcc") - "gcc")))) + #~(list (string-append "prefix=" #$output) + (string-append "CC=" #$(cc-for-target))) #:test-target "partcheck" ; need root for a full 'check' #:phases #~(modify-phases %standard-phases - (delete 'configure) ; no configure script - ;; TODO: Make this phase unconditional on core-updates. - #$@(if (target-riscv64?) - '((add-before 'check 'patch-for-riscv-support - (lambda _ - ;; Taken from the upstream repo: - ;; https://pagure.io/libaio/c/f322f467c3cd2ac4d8d08a19bd281eabb65433b1?branch=master - (substitute* "harness/cases/16.t" - (("(elif defined\\(__aarch64__\\))" all) - (string-append all " || defined(__riscv)")) - (("(endif /* __aarch64__)" all) - (string-append all " || __riscv ")))))) - '())))) + (delete 'configure)))) ; no configure script (home-page "https://pagure.io/libaio") (synopsis "Linux-native asynchronous I/O access library") (description @@ -5761,24 +5733,26 @@ Bluetooth audio output devices like headphones or loudspeakers.") (("tester_init\\(&argc, &argv\\);") "return 77;")))) (add-after 'install 'post-install (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out #$output) - (servicedir (string-append out "/share/dbus-1/services")) + (let* ((servicedir (string-append #$output + "/share/dbus-1/services")) (service "obexd/src/org.bluez.obex.service") (rule (string-append - out "/lib/udev/rules.d/97-hid2hci.rules"))) + #$output "/lib/udev/rules.d/97-hid2hci.rules"))) ;; Install the obex dbus service file. (substitute* service (("/bin/false") - (string-append out "/libexec/bluetooth/obexd"))) + (string-append #$output "/libexec/bluetooth/obexd"))) (install-file service servicedir) ;; Fix paths in the udev rule. (substitute* rule (("hid2hci --method") - (string-append out "/lib/udev/hid2hci --method")) + (string-append #$output "/lib/udev/hid2hci --method")) (("/sbin/udevadm") (search-input-file inputs "/bin/udevadm"))))))))) (native-inputs - (list pkg-config python-docutils gettext-minimal)) + (list gettext-minimal + pkg-config + python-docutils)) (inputs (list glib dbus eudev libical readline)) (home-page "http://www.bluez.org/") @@ -7719,7 +7693,7 @@ machines (PowerMac G4 is known to work).") (define-public libmnl (package (name "libmnl") - (version "1.0.4") + (version "1.0.5") (source (origin (method url-fetch) @@ -7727,7 +7701,7 @@ machines (PowerMac G4 is known to work).") "libmnl-" version ".tar.bz2")) (sha256 (base32 - "108zampspaalv44zn0ar9h386dlfixpd149bnxa5hsi8kxlqj7qp")))) + "09851ns07399rbz0y8slrlmnw3fn1nakr8d37pxjn5gkks8rnjr7")))) (build-system gnu-build-system) (home-page "https://www.netfilter.org/projects/libmnl/") (synopsis "Netlink utility library") @@ -7736,6 +7710,8 @@ Netlink developers. There are a lot of common tasks in parsing, validating, constructing of both the Netlink header and TLVs that are repetitive and easy to get wrong. This library aims to provide simple helpers that allows you to re-use code and to avoid re-inventing the wheel.") + (properties + '((release-monitoring-url . "https://www.netfilter.org/pub/libmnl/"))) (license license:lgpl2.1+))) (define-public libnftnl @@ -7770,14 +7746,14 @@ used by nftables.") ;; variant to avoid accidental rebuilds of rust. (define-public libnftnl/pinned (package (inherit libnftnl) - (version "1.2.0") + (version "1.2.3") (source (origin (method url-fetch) (uri (string-append "mirror://netfilter.org/libnftnl/" "libnftnl-" version ".tar.bz2")) (sha256 - (base32 "1xblq1cbcxhr6qmjpy98i1qdza148idgz99vbhjc7s4vzvfizc4h")))) + (base32 "0m82bmh8i24hwxmz7rxwxjll4904ghd2b1x1p5h8algrg6dyl5p9")))) (build-system gnu-build-system) (native-inputs (list pkg-config)) @@ -8673,7 +8649,7 @@ privileges.") (define-public psm2 (package (name "psm2") - (version "11.2.185") + (version "11.2.230") (source (origin (method git-fetch) (uri (git-reference @@ -8682,7 +8658,7 @@ privileges.") (file-name (git-file-name name version)) (sha256 (base32 - "062hg4r6gz7pla9df70nqs5i2a3mp1wszmp4l0g771fykhhrxsjg")))) + "1bm7ndhi8qzmd0plnggj2h52yb34bab4k38530nsnkmv9smwdivl")))) (build-system gnu-build-system) (arguments (list #:make-flags diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index d7b0531bcc..aa7a73b7cf 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -4385,61 +4385,57 @@ is statically typed so there are differences.") (sbcl-package->cl-source-package sbcl-varjo)) (define-public sbcl-cffi - (package - (name "sbcl-cffi") - (version "0.24.1") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/cffi/cffi") - (commit (string-append "v" version)))) - (file-name (git-file-name "cl-cffi" version)) - (sha256 - (base32 "17ryim4xilb1rzxydfr7595dnhqkk02lmrbkqrkvi9091shi4cj3")))) - (build-system asdf-build-system/sbcl) - (inputs - (list libffi - sbcl-alexandria - sbcl-babel - sbcl-trivial-features)) - (native-inputs - (list pkg-config - sbcl-bordeaux-threads - sbcl-rt)) - (arguments - '(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-arm-support - (lambda _ - ;; This is apparently deprecated since libffi-3.3. - (substitute* "libffi/libffi-types.lisp" - (("\\\(\\\(:unix64.*") ")\n")))) - (add-after 'unpack 'fix-paths - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "libffi/libffi.lisp" - (("libffi.so.7" all) (string-append - (assoc-ref inputs "libffi") - "/lib/" all))) - (substitute* "toolchain/c-toolchain.lisp" - (("\"cc\"") (format #f "~S" (which "gcc")))))) - (add-after 'build 'install-headers - (lambda* (#:key outputs #:allow-other-keys) - (install-file "grovel/common.h" - (string-append - (assoc-ref outputs "out") - "/include/grovel"))))) - #:asd-systems '("cffi" - "cffi-libffi" - "cffi-uffi-compat"))) - (home-page "https://common-lisp.net/project/cffi/") - (synopsis "Common Foreign Function Interface for Common Lisp") - (description "The Common Foreign Function Interface (CFFI) + (let ((commit "33970351e71bb5f12ba56fc40270089e948ae112") + (revision "1")) + (package + (name "sbcl-cffi") + (version (git-version "0.24.1" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/cffi/cffi") + (commit commit))) + (file-name (git-file-name "cl-cffi" version)) + (sha256 + (base32 "1h7cw15f08gm6m4yz8hk7qkfwp7mwwnykjc5py6dhjakv0wh1g37")))) + (build-system asdf-build-system/sbcl) + (inputs + (list libffi + sbcl-alexandria + sbcl-babel + sbcl-trivial-features)) + (native-inputs + (list pkg-config + sbcl-bordeaux-threads + sbcl-rt)) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "libffi/libffi.lisp" + (("libffi.so.8" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "toolchain/c-toolchain.lisp" + (("\"cc\"") + (format #f "~S" (which "gcc")))))) + (add-after 'build 'install-headers + (lambda _ + (install-file "grovel/common.h" + (string-append #$output + "/include/grovel"))))) + #:asd-systems ''("cffi" + "cffi-libffi" + "cffi-uffi-compat"))) + (home-page "https://common-lisp.net/project/cffi/") + (synopsis "Common Foreign Function Interface for Common Lisp") + (description "The Common Foreign Function Interface (CFFI) purports to be a portable foreign function interface for Common Lisp. The CFFI library is composed of a Lisp-implementation-specific backend in the CFFI-SYS package, and a portable frontend in the CFFI package.") - (license license:expat))) + (license license:expat)))) (define-public cl-cffi (sbcl-package->cl-source-package sbcl-cffi)) @@ -4900,68 +4896,73 @@ Lisp implementations.") (sbcl-package->ecl-package sbcl-closer-mop)) (define-public sbcl-cl-cffi-gtk - (let ((commit "e9a46df65995d9a16e6c8dbdc1e09b775eb4a966")) + (let ((commit "1700fe672c65455c1fc33061ec92a3df84287ec7") + (revision "3")) (package (name "sbcl-cl-cffi-gtk") - (version (git-version "0.11.2" "2" commit)) + (version (git-version "3.8.8" revision commit)) (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/Ferada/cl-cffi-gtk/") + (url "https://github.com/sharplispers/cl-cffi-gtk/") (commit commit))) (file-name (git-file-name "cl-cffi-gtk" version)) (sha256 - (base32 - "04vix0gmqsj91lm975sx7jhlnz5gq1xf9jp873mp7c8frc5dk1jj")))) + (base32 "1cn2f6b62axjzdzfv971218ably32dvqfdy499li25vjd8nb2qm3")))) (build-system asdf-build-system/sbcl) (native-inputs (list sbcl-fiveam)) (inputs - `(("bordeaux-threads" ,sbcl-bordeaux-threads) - ("cairo" ,cairo) - ("cffi" ,sbcl-cffi) - ("closer-mop" ,sbcl-closer-mop) - ("gdk-pixbuf" ,gdk-pixbuf) - ("glib" ,glib) - ("gtk" ,gtk+) - ("iterate" ,sbcl-iterate) - ("pango" ,pango) - ("trivial-features" ,sbcl-trivial-features) - ("trivial-garbage" ,sbcl-trivial-garbage))) + (list cairo + gdk-pixbuf + glib + gtk+ + pango + sbcl-bordeaux-threads + sbcl-cffi + sbcl-closer-mop + sbcl-iterate + sbcl-trivial-features + sbcl-trivial-garbage)) (arguments - `(;; TODO: Tests fail with memory fault. - ;; See https://github.com/Ferada/cl-cffi-gtk/issues/24. - #:tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-paths - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "glib/glib.init.lisp" - (("libglib|libgthread" all) - (string-append (assoc-ref inputs "glib") "/lib/" all))) - (substitute* "gobject/gobject.init.lisp" - (("libgobject" all) - (string-append (assoc-ref inputs "glib") "/lib/" all))) - (substitute* "gio/gio.init.lisp" - (("libgio" all) - (string-append (assoc-ref inputs "glib") "/lib/" all))) - (substitute* "cairo/cairo.init.lisp" - (("libcairo" all) - (string-append (assoc-ref inputs "cairo") "/lib/" all))) - (substitute* "pango/pango.init.lisp" - (("libpango" all) - (string-append (assoc-ref inputs "pango") "/lib/" all))) - (substitute* "gdk-pixbuf/gdk-pixbuf.init.lisp" - (("libgdk_pixbuf" all) - (string-append (assoc-ref inputs "gdk-pixbuf") "/lib/" all))) - (substitute* "gdk/gdk.init.lisp" - (("libgdk" all) - (string-append (assoc-ref inputs "gtk") "/lib/" all))) - (substitute* "gdk/gdk.package.lisp" - (("libgtk" all) - (string-append (assoc-ref inputs "gtk") "/lib/" all)))))))) - (home-page "https://github.com/Ferada/cl-cffi-gtk/") + (list + ;; TODO: Tests fail with memory fault. + ;; See https://github.com/Ferada/cl-cffi-gtk/issues/24. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "glib/glib.init.lisp" + (("libglib-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all))) + (("libgthread-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "gobject/gobject.init.lisp" + (("libgobject-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "gio/gio.init.lisp" + (("libgio-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "cairo/cairo.init.lisp" + (("libcairo\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "pango/pango.init.lisp" + (("libpango-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all))) + (("libpangocairo-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "gdk-pixbuf/gdk-pixbuf.init.lisp" + (("libgdk_pixbuf-[0-9.]*\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "gdk/gdk.init.lisp" + (("libgdk-[0-9]\\.so" all) + (search-input-file inputs (string-append "/lib/" all)))) + (substitute* "gdk/gdk.package.lisp" + (("libgtk-[0-9]\\.so" all) + (search-input-file inputs (string-append "/lib/" all))))))))) + (home-page "https://github.com/sharplispers/cl-cffi-gtk/") (synopsis "Common Lisp binding for GTK+3") (description "@command{cl-cffi-gtk} is a Lisp binding to GTK+ 3 (GIMP Toolkit) which @@ -7583,13 +7584,19 @@ high-level way. This library provides such operators.") (setenv "BB_PYTHON3_DYLIB" (string-append python "/lib/libpython3.so")) #t))) - (add-after 'unpack 'adjust-for-python-3.9 + (add-after 'unpack 'adjust-for-python-3.10 (lambda _ ;; These methods are no longer part of the public API. (substitute* "ffi-interface.lisp" ((".*PyEval_ReInitThreads.*") "") ((".*\"PyErr_Warn\".*") "") - ((".*\"PyFloat_ClearFreeList\".*") ""))))))) + ((".*\"PyFloat_ClearFreeList\".*") "") + ((".*\"PyParser_SimpleParseString\".*") "") + ((".*\"PyParser_SimpleParseStringFlags\".*") "") + ((".*\"PyParser_SimpleParseStringFlagsFilename\".*") "") + ((".*\"PyParser_SimpleParseFile\".*") "") + ((".*\"PyParser_SimpleParseFileFlags\".*") "") + ((".*\"PyLong_FromUnicode\".*") ""))))))) (native-inputs (list sbcl-cl-fad sbcl-lift sbcl-cl-quickcheck)) (inputs @@ -10808,16 +10815,35 @@ sacrificing much in the way of power.") (propagated-inputs (list gnuplot)) ;; for gnuplot-interface (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-paths - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "hdf-cffi/src/library.lisp" - (("libhdf5.so") - (search-input-file inputs "/lib/libhdf5.so"))) - (substitute* "gsl-cffi/gsl-cffi.lisp" - (("libgsl.so") - (search-input-file inputs "/lib/libgsl.so")))))))) + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "hdf-cffi/src/library.lisp" + (("libhdf5.so") + (search-input-file inputs "/lib/libhdf5.so"))) + (substitute* (list "gsl-cffi/gsl-cffi.lisp" + "spline/spline.lisp") + (("libgsl.so") + (search-input-file inputs "/lib/libgsl.so"))))) + (add-after 'fix-paths 'fix-newer-hdf5-compatibility + (lambda _ + (substitute* (list "hdf-cffi/src/h5-grovel.lisp" + "hdf-cffi/src/h5a-grovel.lisp" + "hdf-cffi/src/h5d-grovel.lisp" + "hdf-cffi/src/h5f-grovel.lisp" + "hdf-cffi/src/h5g-grovel.lisp" + "hdf-cffi/src/h5i-grovel.lisp" + "hdf-cffi/src/h5l-grovel.lisp" + "hdf-cffi/src/h5o-grovel.lisp" + "hdf-cffi/src/h5p-grovel.lisp" + "hdf-cffi/src/h5pl-grovel.lisp" + "hdf-cffi/src/h5r-grovel.lisp" + "hdf-cffi/src/h5s-grovel.lisp" + "hdf-cffi/src/h5t-grovel.lisp" + "hdf-cffi/src/h5z-grovel.lisp") + (("_H5private_H") + "H5private_H"))))))) (synopsis "Common Lisp data analysis library") (description "CL-ANA is a data analysis library in Common Lisp providing tabular and @@ -12181,10 +12207,9 @@ them as PNG files.") (uri (git-reference (url "https://github.com/hdfgroup/hdf5-cffi") (commit commit))) - (file-name (git-file-name name version)) + (file-name (git-file-name "cl-hdf5-cffi" version)) (sha256 - (base32 - "0vda3075423xz83qky998lpac5b04dwfv7bwgh9jq8cs5v0zrxjf")))) + (base32 "0vda3075423xz83qky998lpac5b04dwfv7bwgh9jq8cs5v0zrxjf")))) (build-system asdf-build-system/sbcl) (synopsis "Common Lisp bindings for the HDF5 library") (description @@ -12195,28 +12220,43 @@ them as PNG files.") commit "/LICENSE"))) (inputs - `(("cffi" ,sbcl-cffi) - ("hdf5" ,hdf5-1.10))) + (list hdf5-1.10 sbcl-cffi)) (native-inputs (list sbcl-fiveam)) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-paths - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "src/library.lisp" - (("libhdf5.so") - (string-append - (assoc-ref inputs "hdf5") - "/lib/libhdf5.so"))))) - (add-after 'unpack 'fix-dependencies - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "hdf5-cffi.asd" - ((":depends-on \\(:cffi\\)") - ":depends-on (:cffi :cffi-grovel)")) - (substitute* "hdf5-cffi.test.asd" - ((":depends-on \\(:cffi :hdf5-cffi") - ":depends-on (:cffi :cffi-grovel :hdf5-cffi")))))))))) + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "src/library.lisp" + (("libhdf5.so") + (search-input-file inputs "/lib/libhdf5.so"))))) + (add-after 'fix-paths 'fix-newer-hdf5-compatibility + (lambda _ + (substitute* (list "src/h5-grovel.lisp" + "src/h5a-grovel.lisp" + "src/h5d-grovel.lisp" + "src/h5f-grovel.lisp" + "src/h5g-grovel.lisp" + "src/h5i-grovel.lisp" + "src/h5l-grovel.lisp" + "src/h5o-grovel.lisp" + "src/h5p-grovel.lisp" + "src/h5pl-grovel.lisp" + "src/h5r-grovel.lisp" + "src/h5s-grovel.lisp" + "src/h5t-grovel.lisp" + "src/h5z-grovel.lisp") + (("_H5private_H") + "H5private_H")))) + (add-after 'unpack 'fix-dependencies + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "hdf5-cffi.asd" + ((":depends-on \\(:cffi\\)") + ":depends-on (:cffi :cffi-grovel)")) + (substitute* "hdf5-cffi.test.asd" + ((":depends-on \\(:cffi :hdf5-cffi") + ":depends-on (:cffi :cffi-grovel :hdf5-cffi")))))))))) (define-public cl-hdf5-cffi (sbcl-package->cl-source-package sbcl-hdf5-cffi)) diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm index e5bf9f5cae..f59c8e9592 100644 --- a/gnu/packages/llvm.scm +++ b/gnu/packages/llvm.scm @@ -666,7 +666,7 @@ of programming tools as well as libraries with equivalent functionality.") "-DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE" "-DBUILD_SHARED_LIBS:BOOL=TRUE" "-DLLVM_ENABLE_FFI:BOOL=TRUE" - "-DLLVM_REQUIRES_RTTI=1" ;for some third-party utilities + "-DLLVM_ENABLE_RTTI:BOOL=TRUE" ;for some third-party utilities "-DLLVM_INSTALL_UTILS=ON") ;needed for rustc ;; Don't use '-g' during the build, to save space. #:build-type "Release" @@ -722,11 +722,7 @@ of programming tools as well as libraries with equivalent functionality.") #~(modify-phases #$phases (add-after 'unpack 'change-directory (lambda _ - (chdir "compiler-rt"))))))) - (native-inputs - `(;; FIXME: libfuzzer fails to build with GCC 10. - ("gcc" ,gcc-11) - ,@(package-native-inputs template)))))) + (chdir "compiler-rt")))))))))) (define-public clang-15 (clang-from-llvm @@ -918,7 +914,7 @@ Library.") "-DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE" "-DBUILD_SHARED_LIBS:BOOL=TRUE" "-DLLVM_ENABLE_FFI:BOOL=TRUE" - "-DLLVM_REQUIRES_RTTI=1" ; For some third-party utilities + "-DLLVM_ENABLE_RTTI:BOOL=TRUE" ; For some third-party utilities "-DLLVM_INSTALL_UTILS=ON")) ; Needed for rustc. ;; Don't use '-g' during the build, to save space. #:build-type "Release" @@ -998,23 +994,24 @@ Library.") (define-public llvm-11 (package (inherit llvm-12) - (version "11.0.0") + (version "11.1.0") (source (origin (method url-fetch) (uri (llvm-uri "llvm" version)) + (patches (search-patches "llvm-8-missing-include.patch")) (sha256 (base32 - "0s94lwil98w7zb7cjrbnxli0z7gklb312pkw74xs1d6zk346hgwi")))))) + "199yq3a214avcbi4kk2q0ajriifkvsr0l2dkx3a666m033ihi1ff")))))) (define-public clang-runtime-11 (clang-runtime-from-llvm llvm-11 - "0d5j5l8phwqjjscmk8rmqn0i2i0abl537gdbkagl8fjpzy1gyjip")) + "0x1j8ngf1zj63wlnns9vlibafq48qcm72p4jpaxkmkb4qw0grwfy")) (define-public clang-11 (clang-from-llvm llvm-11 clang-runtime-11 - "02ajkij85966vd150iy246mv16dsaph1kfi0y8wnncp8w6nar5hg" + "12sm91qx2m79cvj75a9aazf2x8xybjbd593dv6v7rxficpq8i0ha" #:legacy-build-shared-libs? #t #:patches '("clang-11.0-libc-search-path.patch") #:tools-extra @@ -1024,7 +1021,7 @@ Library.") (package-version llvm-11))) (sha256 (base32 - "02bcwwn54661madhq4nxc069s7p7pj5gpqi8ww50w3anbpviilzy"))))) + "18n1w1hkv931xzq02b34wglbv6zd6sd0r5kb8piwvag7klj7qw3n"))))) (define-public libomp-11 (package @@ -1035,7 +1032,7 @@ Library.") (uri (llvm-uri "openmp" version)) (sha256 (base32 - "0k389d0g9zlfyzh1kpb3i5jdawzpn0hrdxzbjinpvdv7rbw4sw1d")) + "0bh5cswgpc79awlq8j5i7hp355adaac7s6zaz0zwp6mkflxli1yi")) (file-name (string-append "libomp-" version ".tar.xz")))) (native-inputs (modify-inputs (package-native-inputs libomp-12) @@ -1053,6 +1050,7 @@ Library.") (origin (method url-fetch) (uri (llvm-uri "llvm" version)) + (patches (search-patches "llvm-8-missing-include.patch")) (sha256 (base32 "1wydhbp9kyjp5y0rc627imxgkgqiv3dfirbqil9dgpnbaw5y7n65")))) @@ -1114,6 +1112,7 @@ Library.") (base32 "16hwp3qa54c3a3v7h8nlw0fh5criqh0hlr1skybyk0cz70gyx880")) (patches (search-patches + "llvm-8-missing-include.patch" "llvm-9-fix-bitcast-miscompilation.patch" "llvm-9-fix-scev-miscompilation.patch" "llvm-9-fix-lpad-miscompilation.patch")))) @@ -1174,7 +1173,8 @@ Library.") (sha256 (base32 "1rvm5gqp5v8hfn17kqws3zhk94w4kxndal12bqa0y57p09nply24")) - (patches (search-patches "llvm-8-fix-build-with-gcc-10.patch")))) + (patches (search-patches "llvm-8-fix-build-with-gcc-10.patch" + "llvm-8-missing-include.patch")))) (license license:ncsa))) (define-public clang-runtime-8 @@ -1891,38 +1891,18 @@ requirements according to version 1.1 of the OpenCL specification.") (define-public python-llvmlite (package (name "python-llvmlite") - (version "0.38.0") + (version "0.39.1") (source (origin (method url-fetch) (uri (pypi-uri "llvmlite" version)) (sha256 (base32 - "0p4nyic9rm7s2fm3m3wpkh568594p9q9nfyjkqxny49vrxn1d7d9")))) + "0wnm0l0301sj8xp6skg3ci1gii56x5dk6l2x88f2c1g8h9ybsfml")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'patch-reference-to-llvmlite.so - ;; ctypes.CDLL uses dlopen to load libllvmlite.so, which - ;; fails, so locate it by its absolute path. Change it in - ;; ffi.py, not utils.py, because setup.py relies on the - ;; output of get_library_name for proper installation. - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (libllvmlite.so (string-append out "/lib/python" - ,(version-major+minor - (package-version python)) - "/site-packages/llvmlite/" - "binding/libllvmlite.so"))) - (substitute* "llvmlite/binding/ffi.py" - (("_lib_name = get_library_name\\(\\)") - (format #f "_lib_name = ~s" libllvmlite.so)))))) - (add-after 'unpack 'skip-failing-tests - (lambda _ - (substitute* "llvmlite/tests/test_binding.py" - ((" def test_libm\\(self\\).*" all) - (string-append " @unittest.skip('Fails on Guix')\n" all))))) (add-before 'build 'set-compiler/linker-flags (lambda* (#:key inputs #:allow-other-keys) (let ((llvm (assoc-ref inputs "llvm"))) @@ -2069,6 +2049,52 @@ using @code{clang-rename}."))) ;;; LLVM variants. ;;; +(define-public llvm-for-mesa + ;; Note: update the 'clang' input of mesa-opencl when bumping this. + (let ((base-llvm llvm-15)) + (package + (inherit base-llvm) + (name "llvm-for-mesa") + (arguments + (substitute-keyword-arguments (package-arguments base-llvm) + ((#:modules modules '((guix build cmake-build-system) + (guix build utils))) + `((ice-9 regex) + (srfi srfi-1) + (srfi srfi-26) + ,@modules)) + ((#:configure-flags cf ''()) + #~(cons* + ;; AMDGPU is needed by the vulkan drivers. + #$(string-append "-DLLVM_TARGETS_TO_BUILD=" + (system->llvm-target) ";AMDGPU") + ;; Skipping tools and utils decreases the output by ~100 MiB. + "-DLLVM_BUILD_TOOLS=NO" + (remove (cut string-match + "-DLLVM_(TARGETS_TO_BUILD|INSTALL_UTILS).*" <>) + #$cf))) + ((#:phases phases '%standard-phases) + #~(modify-phases #$phases + (add-after 'install 'delete-static-libraries + ;; If these are just relocated then llvm-config can't find them. + (lambda* (#:key outputs #:allow-other-keys) + (for-each delete-file + (find-files (string-append + (assoc-ref outputs "out") "/lib") + "\\.a$")))) + ;; llvm-config is how mesa and others find the various + ;; libraries and headers they use. + (add-after 'install 'build-and-install-llvm-config + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (substitute* + "tools/llvm-config/CMakeFiles/llvm-config.dir/link.txt" + (((string-append (getcwd) "/build/lib")) + (string-append out "/lib"))) + (invoke "make" "llvm-config") + (install-file "bin/llvm-config" + (string-append out "/bin")))))))))))) + (define make-ocaml-llvm ;; Make it a memoizing procedure so its callers below don't end up defining ;; two equal-but-not-eq "ocaml-llvm" packages for the default LLVM. diff --git a/gnu/packages/lxde.scm b/gnu/packages/lxde.scm index 0657db6eb8..0291f50302 100644 --- a/gnu/packages/lxde.scm +++ b/gnu/packages/lxde.scm @@ -562,7 +562,7 @@ in LXDE.") (delete-file "configure")))))) (inputs (list gtk+ - polkit-duktape)) + polkit)) (native-inputs (list pkg-config intltool diff --git a/gnu/packages/lxqt.scm b/gnu/packages/lxqt.scm index 04373de961..ee6a19f415 100644 --- a/gnu/packages/lxqt.scm +++ b/gnu/packages/lxqt.scm @@ -675,7 +675,8 @@ allows for launching applications or shutting down the system.") (uri (string-append "https://github.com/lxqt/" name "/releases/download/" version "/" name "-" version ".tar.xz")) (sha256 - (base32 "0rjw3rw6kpaa3csrga005qg5bxmdxfgrnn1qngs2nrny35v97ckl")))) + (base32 "0rjw3rw6kpaa3csrga005qg5bxmdxfgrnn1qngs2nrny35v97ckl")) + (patches (search-patches "lxqt-session-procps-4.patch")))) (build-system cmake-build-system) (inputs (list eudev diff --git a/gnu/packages/m4.scm b/gnu/packages/m4.scm index 090f5578e3..fbc075a2cb 100644 --- a/gnu/packages/m4.scm +++ b/gnu/packages/m4.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012, 2013, 2015 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -27,34 +28,40 @@ (define-public m4 (package (name "m4") - (version "1.4.18") + (version "1.4.19") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/m4/m4-" version ".tar.xz")) - (patches (search-patches "m4-gnulib-libio.patch")) (sha256 (base32 - "01sfjd5a4waqw83bibvmn522g69qfqvwig9i2qlgy154l1nfihgj")))) + "15mghcksh11saylpm86h1zkz4in0rbi0pk8i6nqxkdikdmfdxbk3")))) (build-system gnu-build-system) (arguments `(;; Explicitly disable tests when cross-compiling, otherwise 'make check' ;; proceeds and fails, unsurprisingly. #:tests? ,(not (%current-target-system)) - #:phases (modify-phases %standard-phases - (add-before 'check 'pre-check - (lambda* (#:key inputs #:allow-other-keys) - ;; Fix references to /bin/sh. - (let ((bash (assoc-ref inputs "bash"))) - (for-each patch-shebang - (find-files "tests" "\\.sh$")) - (substitute* (find-files "tests" - "posix_spawn") - (("/bin/sh") - (format #f "~a/bin/sh" bash))) - #t)))))) + (add-after 'unpack 'disable-test + (lambda _ + ;; Test 5 raises SIGINT from a child and immediately returns + ;; code 71, and tests whether the child was killed by a signal. + ;; Since there is no signal handler for SIGINT in the build + ;; container, the parent sees the return code, and fails. + ;; XXX: For some reason adding signal handlers in Guile before + ;; running tests has no effect. + (substitute* "tests/test-execute.sh" + (("4 5 6") + "4 6")))) + (add-after 'unpack 'configure-shell + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (let ((/bin/sh (search-input-file (or native-inputs inputs) + "/bin/sh"))) + ;; Adjust hard-coded /bin/sh for tests. + (substitute* "lib/config.hin" + (("\"/bin/sh\"") + (format #f "\"~a\"" /bin/sh))))))))) (synopsis "Macro processor") (description "GNU M4 is an implementation of the M4 macro language, which features diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index 90a3e153ce..1a08b3c0a2 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -2176,7 +2176,7 @@ Python.") ;; SOURCE_DATE_EPOCH is respected, which we set to some time in ;; 1980. (lambda _ (setenv "SOURCE_DATE_EPOCH" "315532800") #t)) - (add-after 'unpack 'python3.9-compatibility + (add-after 'unpack 'python3.10-compatibility (lambda _ ;; See https://github.com/tensorflow/tensorflow/issues/20517#issuecomment-406373913 (substitute* '("tensorflow/python/eager/pywrap_tfe_src.cc" @@ -2198,6 +2198,33 @@ Python.") (("(nullptr,)(\\ +/. tp_print)" _ _ tp_print) (string-append "NULL, " tp_print))) + ;; Many collections classes have been moved to collections.abc + (substitute* '("tensorflow/python/framework/ops.py" + "tensorflow/python/ops/clip_ops.py" + "tensorflow/python/ops/data_flow_ops.py" + "tensorflow/python/ops/gradients_impl.py" + "tensorflow/python/training/input.py" + "tensorflow/python/training/checkpointable/data_structures.py" + "tensorflow/python/util/nest.py" + "tensorflow/python/util/protobuf/compare.py") + (("collections.Mapping") "collections.abc.Mapping") + (("collections.Sequence") "collections.abc.Sequence")) + (substitute* "tensorflow/python/feature_column/feature_column.py" + (("collections.Iterator") "collections.abc.Iterator")) + (substitute* "tensorflow/python/ops/sparse_ops.py" + (("collections.Iterable") "collections.abc.Iterable")) + (substitute* "tensorflow/python/keras/callbacks.py" + (("from collections import Iterable") + "from collections.abc import Iterable")) + + ;; XXX: it is not clear if this is a good idea, but the build + ;; system tries to overwrite the __or__ and __ror__ methods of + ;; the Tensor class. + (substitute* "tensorflow/python/framework/ops.py" + (("if not isinstance\\(existing, type\\(object.__lt__\\)\\)" m) + (string-append m + " and not isinstance(existing, type(object.__or__))"))) + ;; Fix the build with numpy >= 1.19. ;; Suggested in https://github.com/tensorflow/tensorflow/issues/41086#issuecomment-656833081 (substitute* "tensorflow/python/lib/core/bfloat16.cc" @@ -2205,7 +2232,7 @@ Python.") "void BinaryUFunc(char** args, npy_intp const* dimensions, npy_intp const* steps,") (("void CompareUFunc\\(char\\*\\* args, npy_intp\\* dimensions, npy_intp\\* steps,") "void CompareUFunc(char** args, npy_intp const* dimensions, npy_intp const* steps,")))) - (add-after 'python3.9-compatibility 'chdir + (add-after 'python3.10-compatibility 'chdir (lambda _ (chdir "tensorflow/contrib/cmake"))) (add-after 'chdir 'disable-downloads (lambda* (#:key inputs #:allow-other-keys) @@ -2336,6 +2363,12 @@ set(eigen_INCLUDE_DIRS ${CMAKE_CURRENT_BINARY_DIR}/external/eigen_archive " "nsync" "re2")) + ;; https://github.com/google/farmhash/issues/24 + (substitute* "../build/farmhash/src/farmhash/src/farmhash.cc" + (("using namespace std;") "") + (("make_pair") "std::make_pair") + (("pair<") "std::pair<")) + (rename-file "../build/cub/src/cub/cub-1.8.0/" "../build/cub/src/cub/cub/") @@ -2350,6 +2383,12 @@ set(eigen_INCLUDE_DIRS ${CMAKE_CURRENT_BINARY_DIR}/external/eigen_archive " (mkdir-p "eigen-src") (copy-recursively (assoc-ref inputs "eigen:src") "eigen-src") + ;; distutils.sysconfig is deprecated and prints a deprecation + ;; warning that breaks the generated CXX_INCLUDES line. + (substitute* "tensorflow/contrib/cmake/tf_python.cmake" + (("import distutils.sysconfig; print\\(distutils.sysconfig.get_python_inc\\(\\)\\)") + "import sysconfig; print(sysconfig.get_path('include'))")) + (substitute* "tensorflow/contrib/cmake/tf_python.cmake" ;; Take protobuf source files from our source package. (("\\$\\{CMAKE_CURRENT_BINARY_DIR\\}/protobuf/src/protobuf/src/google") diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm index 51b2cb3267..6bafc5697c 100644 --- a/gnu/packages/make-bootstrap.scm +++ b/gnu/packages/make-bootstrap.scm @@ -3,8 +3,8 @@ ;;; Copyright © 2017, 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018, 2019 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2018, 2019, 2021 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> -;;; Copyright © 2019, 2020 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2018, 2019, 2021, 2022 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> +;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2021 Pierre Langlois <pierre.langlois@gmx.com> ;;; @@ -53,8 +53,6 @@ %glibc-bootstrap-tarball %gcc-bootstrap-tarball %guile-bootstrap-tarball - %mescc-tools-bootstrap-tarball - %mes-bootstrap-tarball %bootstrap-tarballs %guile-static-stripped)) @@ -75,8 +73,7 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (inherit base) (source (origin (inherit (package-source base)) (patches (append (search-patches - "glibc-bootstrap-system.patch" - "glibc-static-nss.patch") + "glibc-bootstrap-system.patch") (origin-patches (package-source base)))))) (arguments (substitute-keyword-arguments (package-arguments base) @@ -162,57 +159,55 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (define %static-inputs ;; Packages that are to be used as %BOOTSTRAP-INPUTS. - (let ((coreutils (package (inherit coreutils) - (arguments - `(#:configure-flags - '("--disable-nls" - "--disable-silent-rules" - "--enable-no-install-program=stdbuf,libstdbuf.so" - "CFLAGS=-Os -g0" ; smaller, please - "LDFLAGS=-static -pthread" - - ;; Work around a cross-compilation bug whereby libcoreutils.a - ;; would provide '__mktime_internal', which conflicts with the - ;; one in libc.a. - ,@(if (%current-target-system) - `("gl_cv_func_working_mktime=yes") - '())) - - #:tests? #f ; signal-related Gnulib tests fail - ,@(package-arguments coreutils))) - - ;; Remove optional dependencies such as GMP. Keep Perl - ;; except if it's missing (which is the case when - ;; cross-compiling). - (inputs (match (assoc "perl" (package-inputs coreutils)) - (#f '()) - (x (list x)))) + (let ((coreutils (package + (inherit coreutils) + (arguments + (substitute-keyword-arguments + (package-arguments coreutils) + ((#:configure-flags _ #~'()) + #~'("--disable-nls" + "--disable-silent-rules" + "--enable-no-install-program=stdbuf,libstdbuf.so" + "CFLAGS=-Os -g0" ; smaller, please + "LDFLAGS=-static -pthread" + + ;; Work around a cross-compilation bug whereby libcoreutils.a + ;; would provide '__mktime_internal', which conflicts with the + ;; one in libc.a. + #$@(if (%current-target-system) + #~("gl_cv_func_working_mktime=yes") + #~()))) + ((#:tests? _ #t) + #f))) ;signal-related Gnulib tests fail + + ;; Remove optional dependencies such as GMP. + (inputs '()) ;; Remove the 'debug' output (see above for the reason.) (outputs '("out")))) - (bzip2 (package (inherit bzip2) + (bzip2 (package + (inherit bzip2) (arguments (substitute-keyword-arguments (package-arguments bzip2) ((#:phases phases) - `(modify-phases ,phases - (add-before 'build 'dash-static - (lambda _ - (substitute* "Makefile" - (("^LDFLAGS[[:blank:]]*=.*$") - "LDFLAGS = -static")) - #t)))))))) - (xz (package (inherit xz) + #~(modify-phases #$phases + (add-before 'build 'dash-static + (lambda _ + (substitute* "Makefile" + (("^LDFLAGS[[:blank:]]*=.*$") + "LDFLAGS = -static")))))))))) + (xz (package + (inherit xz) (outputs '("out")) (arguments - `(#:strip-flags '("--strip-all") - #:phases (modify-phases %standard-phases - (add-before 'configure 'static-executable - (lambda _ - ;; Ask Libtool for a static executable. - (substitute* "src/xz/Makefile.in" - (("^xz_LDADD =") - "xz_LDADD = -all-static")) - #t))))))) + (list #:strip-flags #~'("--strip-all") + #:phases #~(modify-phases %standard-phases + (add-before 'configure 'static-executable + (lambda _ + ;; Ask Libtool for a static executable. + (substitute* "src/xz/Makefile.in" + (("^xz_LDADD =") + "xz_LDADD = -all-static"))))))))) (gawk (package (inherit gawk) (source (origin @@ -228,45 +223,44 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (origin-patches (package-source gawk)))))) (arguments - `(;; Starting from gawk 4.1.0, some of the tests for the - ;; plug-in mechanism just fail on static builds: - ;; - ;; ./fts.awk:1: error: can't open shared library `filefuncs' for reading (No such file or directory) - ;; - ;; Therefore disable extensions support. - #:configure-flags (list "--disable-extensions") - - ,@(substitute-keyword-arguments (package-arguments gawk) - ((#:phases phases) - `(modify-phases ,phases - (add-before 'configure 'no-export-dynamic - (lambda _ - ;; Since we use `-static', remove - ;; `-export-dynamic'. - (substitute* "configure" - (("-Wl,-export-dynamic") "")) - #t))))))) + (substitute-keyword-arguments (package-arguments gawk) + ((#:configure-flags _ #~'()) + ;; Starting from gawk 4.1.0, some of the tests for the + ;; plug-in mechanism just fail on static builds: + ;; + ;; ./fts.awk:1: error: can't open shared library `filefuncs' for reading (No such file or directory) + ;; + ;; Therefore disable extensions support. + #~(list "--disable-extensions")) + ((#:phases phases) + #~(modify-phases #$phases + (add-before 'configure 'no-export-dynamic + (lambda _ + ;; Since we use `-static', remove + ;; `-export-dynamic'. + (substitute* "configure" + (("-Wl,-export-dynamic") "")))))))) (inputs (if (%current-target-system) - `(("bash" ,static-bash)) + (list static-bash) '())))) - (tar (package (inherit tar) + (tar (package + (inherit tar) (arguments - `(;; Work around a cross-compilation bug whereby libgnu.a would provide - ;; '__mktime_internal', which conflicts with the one in libc.a. - ,@(if (%current-target-system) - `(#:configure-flags '("gl_cv_func_working_mktime=yes")) - '()) - ,@(substitute-keyword-arguments (package-arguments tar) - ((#:phases phases) - `(modify-phases ,phases - (replace 'set-shell-file-name - (lambda _ - ;; Do not use "/bin/sh" to run programs; see - ;; <http://lists.gnu.org/archive/html/guix-devel/2016-09/msg02272.html>. - (substitute* "src/system.c" - (("/bin/sh") "sh") - (("execv ") "execvp ")) - #t))))))))) + (substitute-keyword-arguments (package-arguments tar) + ((#:configure-flags flags #~'()) + ;; Work around a cross-compilation bug whereby libgnu.a + ;; would provide '__mktime_internal', which conflicts + ;; with the one in libc.a. + #~'("gl_cv_func_working_mktime=yes")) + ((#:phases phases) + #~(modify-phases #$phases + (replace 'set-shell-file-name + (lambda _ + ;; Do not use "/bin/sh" to run programs; see + ;; <http://lists.gnu.org/archive/html/guix-devel/2016-09/msg02272.html>. + (substitute* "src/system.c" + (("/bin/sh") "sh") + (("execv ") "execvp ")))))))))) ;; We don't want to retain a reference to /gnu/store in the bootstrap ;; versions of egrep/fgrep, so we remove the custom phase added since ;; grep@2.25. The effect is 'egrep' and 'fgrep' look for 'grep' in @@ -388,6 +382,10 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (package-arguments binutils)) ((#:configure-flags flags _ ...) flags))) + #:make-flags ,(match (memq #:make-flags (package-arguments binutils)) + ((#:make-flags flags _ ...) + flags) + (_ ''())) #:strip-flags '("--strip-all") #:phases (modify-phases %standard-phases (add-before 'configure 'all-static @@ -591,92 +589,6 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." "--version")) '("gcc" "g++" "cpp")))))))))) -;; Two packages: first build static, bare minimum content. -(define %mescc-tools-static - ;; A statically linked MesCC Tools. - (package - (inherit mescc-tools) - (name "mescc-tools-static") - (arguments - `(#:system "i686-linux" - ,@(substitute-keyword-arguments (package-arguments mescc-tools) - ((#:make-flags flags) - `(cons "CC=gcc -static" ,flags))))))) - -;; ... next remove store references. -(define %mescc-tools-static-stripped - ;; A statically linked Mescc Tools with store references removed, for - ;; bootstrap. - (package - (inherit %mescc-tools-static) - (name (string-append (package-name %mescc-tools-static) "-stripped")) - (build-system trivial-build-system) - (arguments - (list #:modules '((guix build utils)) - #:builder - #~(begin - (use-modules (guix build utils)) - (let* ((in #$%mescc-tools-static) - (out #$output) - (bin (string-append out "/bin"))) - (mkdir-p bin) - (for-each (lambda (file) - (let ((target (string-append bin "/" file))) - (format #t "copying `~a'...~%" file) - (copy-file (string-append in "/bin/" file) - target) - (remove-store-references target))) - '( "M1" "blood-elf" "hex2")))))))) - -;; Two packages: first build static, bare minimum content. -(define-public %mes-minimal - ;; A minimal Mes without documentation. - (package - (inherit mes) - (name "mes-minimal") - (native-inputs (list guile-3.0)) - (arguments - `(#:system "i686-linux" - #:strip-binaries? #f - #:configure-flags '("--mes") - #:phases - (modify-phases %standard-phases - (delete 'patch-shebangs) - (add-after 'install 'strip-install - (lambda _ - (let* ((out (assoc-ref %outputs "out")) - (share (string-append out "/share"))) - (delete-file-recursively (string-append out "/lib/guile")) - (delete-file-recursively (string-append share "/guile")) - - (for-each delete-file - (find-files - (string-append share "/mes/lib") - "\\.(h|c)")))))))))) - -;; next remove store references. -(define %mes-minimal-stripped - ;; A minimal Mes with store references removed, for bootstrap. - (package - (inherit %mes-minimal) - (name (string-append (package-name %mes-minimal) "-stripped")) - (build-system trivial-build-system) - (arguments - (list #:modules '((guix build utils)) - #:allowed-references '() - #:builder - #~(begin - (use-modules (guix build utils)) - (let ((in #$%mes-minimal) - (out #$output)) - - (copy-recursively in out) - (for-each (lambda (dir) - (for-each remove-store-references - (find-files (string-append out "/" dir) - ".*"))) - '("bin" "share/mes")))))))) - (define* (make-guile-static guile patches) (package-with-relocatable-glibc (static-package @@ -698,47 +610,47 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (propagated-inputs (modify-inputs (package-propagated-inputs guile) - (replace "bdw-gc" libgc/static-libs))) + (replace "libgc" libgc/static-libs))) (arguments (substitute-keyword-arguments (package-arguments guile) - ((#:configure-flags flags '()) + ((#:configure-flags flags #~'()) ;; When `configure' checks for ltdl availability, it ;; doesn't try to link using libtool, and thus fails ;; because of a missing -ldl. Work around that. - `(list "LDFLAGS=-ldl" "--enable-mini-gmp" - - ;; Guile does an LTO build by default, but in 3.0.9 it - ;; wrongfully picks 'ar' instead of 'gcc-ar', so work around - ;; it (see <https://issues.guix.gnu.org/61086>). - ,@(if (version-prefix? "3.0" (package-version guile)) - '("AR=gcc-ar" "RANLIB=gcc-ranlib") - '()) - - ,@(if (hurd-target?) - '("--disable-jit") - '()))) + #~(list "LDFLAGS=-ldl" "--enable-mini-gmp" + + ;; Guile does an LTO build by default, but in 3.0.9 it + ;; wrongfully picks 'ar' instead of 'gcc-ar', so work around + ;; it (see <https://issues.guix.gnu.org/61086>). + #$@(if (version-prefix? "3.0" (package-version guile)) + #~("AR=gcc-ar" "RANLIB=gcc-ranlib") + #~()) + + #$@(if (hurd-target?) + #~("--disable-jit") + #~()))) ((#:phases phases '%standard-phases) - `(modify-phases ,phases - - ;; Do not record the absolute file name of 'sh' in - ;; (ice-9 popen). This makes 'open-pipe' unusable in - ;; a build chroot ('open-pipe*' is fine) but avoids - ;; keeping a reference to Bash. - (delete 'pre-configure) - - (add-before 'configure 'static-guile - (lambda _ - (substitute* "libguile/Makefile.in" - ;; Create a statically-linked `guile' - ;; executable. - (("^guile_LDFLAGS =") - "guile_LDFLAGS = -all-static") - - ;; Add `-ldl' *after* libguile-2.0.la. - (("^guile_LDADD =(.*)$" _ ldadd) - (string-append "guile_LDADD = " - (string-trim-right ldadd) - " -ldl\n"))))))) + #~(modify-phases #$phases + + ;; Do not record the absolute file name of 'sh' in + ;; (ice-9 popen). This makes 'open-pipe' unusable in + ;; a build chroot ('open-pipe*' is fine) but avoids + ;; keeping a reference to Bash. + (delete 'pre-configure) + + (add-before 'configure 'static-guile + (lambda _ + (substitute* "libguile/Makefile.in" + ;; Create a statically-linked `guile' + ;; executable. + (("^guile_LDFLAGS =") + "guile_LDFLAGS = -all-static") + + ;; Add `-ldl' *after* libguile-2.0.la. + (("^guile_LDADD =(.*)$" _ ldadd) + (string-append "guile_LDADD = " + (string-trim-right ldadd) + " -ldl\n"))))))) ((#:tests? _ #f) ;; There are uses of `dynamic-link' in ;; {foreign,coverage}.test that don't fly here. @@ -868,14 +780,6 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." ;; A tarball with the statically-linked, relocatable Guile. (tarball-package %guile-static-stripped)) -(define %mescc-tools-bootstrap-tarball - ;; A tarball with statically-linked MesCC binary seed. - (tarball-package %mescc-tools-static-stripped)) - -(define %mes-bootstrap-tarball - ;; A tarball with Mes binary seed. - (tarball-package %mes-minimal-stripped)) - (define %bootstrap-tarballs ;; A single derivation containing all the bootstrap tarballs, for ;; convenience. @@ -909,9 +813,7 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." (append (list %guile-bootstrap-tarball) (match (or (%current-target-system) (%current-system)) ((or "i686-linux" "x86_64-linux") - (list %mescc-tools-bootstrap-tarball - %mes-bootstrap-tarball - %linux-libre-headers-bootstrap-tarball)) + (list %linux-libre-headers-bootstrap-tarball)) (_ (list %gcc-bootstrap-tarball %binutils-bootstrap-tarball diff --git a/gnu/packages/man.scm b/gnu/packages/man.scm index 00efff0387..71fcf2f4bc 100644 --- a/gnu/packages/man.scm +++ b/gnu/packages/man.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2015, 2016, 2020 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017–2022 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018, 2019 Rutger Helling <rhelling@mykolab.com> -;;; Copyright © 2018, 2019 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2018, 2019, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2021 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> @@ -127,14 +127,14 @@ a flexible and convenient way.") (define-public man-db (package (name "man-db") - (version "2.10.2") + (version "2.11.1") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/man-db/man-db-" version ".tar.xz")) (sha256 (base32 - "0kaiymd5lh4dnp6z15fnvfg0ir81kdxp5l690ccp64ra956rb5zf")))) + "1k5nhy2c33k0p2f1sbb4hxpwrjw6v4scchwykkg4g61la59amarf")))) (build-system gnu-build-system) (arguments (list #:phases @@ -352,36 +352,36 @@ on any distribution, and the nroff source is included.")))) ;; input "locales" contain the original (English) text. (package (name "help2man") - (version "1.48.5") + (version "1.49.2") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/help2man/help2man-" - version ".tar.xz")) - (sha256 - (base32 - "1gl24n9am3ivhql1gs9lffb415irg758fhxyk4ryssiflk5f8fb7")))) + (method url-fetch) + (uri (string-append "mirror://gnu/help2man/help2man-" + version ".tar.xz")) + (sha256 + (base32 + "0dnxx96lbcb8ab8yrdkqll14cl5n0bch8qpd9qj3c2ky78hhwbly")))) (build-system gnu-build-system) - (arguments `(;; There's no `check' target. - #:tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-help2man-with-perl-gettext - (lambda* (#:key inputs #:allow-other-keys) - (let ((lib (assoc-ref inputs "perl-gettext")) - (fmt "use lib '~a/lib/perl5/site_perl';~%~a")) - (substitute* "help2man.PL" - (("^use Locale::gettext.*$" load) - (format #f fmt lib load)))) - #t))))) + (arguments + (list + #:tests? #f ;no `check' target + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-help2man-with-perl-gettext + (lambda* (#:key inputs #:allow-other-keys) + (let ((lib #$(this-package-input "perl-gettext")) + (fmt "use lib '~a/lib/perl5/site_perl';~%~a")) + (substitute* "help2man.PL" + (("^use Locale::gettext.*$" load) + (format #f fmt lib load))))))))) (inputs - `(("perl" ,perl) - ,@(if (%current-target-system) - '() - `(("perl-gettext" ,perl-gettext))))) + (append + (list perl) + (if (%current-target-system) + '() + (list perl-gettext)))) (native-inputs - `(("perl" ,perl) - ("gettext" ,gettext-minimal))) + (list perl gettext-minimal)) (home-page "https://www.gnu.org/software/help2man/") (synopsis "Automatically generate man pages from program --help") (description diff --git a/gnu/packages/mate.scm b/gnu/packages/mate.scm index 2f38946fe1..4874aaf7f9 100644 --- a/gnu/packages/mate.scm +++ b/gnu/packages/mate.scm @@ -521,7 +521,7 @@ assorted menu related utility programs.") docbook-xml gobject-introspection)) (inputs - (list atk + (list at-spi2-core dbus dbus-glib glib @@ -732,7 +732,7 @@ infamous 'Wanda the Fish'.") ("xmllint" ,libxml2) ("zlib" ,zlib))) (inputs - `(("atk" ,atk) + `(("at-spi2-core" ,at-spi2-core) ("cairo" ,cairo) ("caja" ,caja) ("dconf" ,dconf) @@ -921,7 +921,7 @@ icons on the MATE desktop. It works on local and remote file systems.") xmodmap gobject-introspection)) (inputs - `(("atk" ,atk) + `(("at-spi2-core" ,at-spi2-core) ("cairo" ,cairo) ("caja" ,caja) ("dconf" ,dconf) @@ -1061,7 +1061,7 @@ sessions, panels, menus, file management, and preferences.") (native-inputs (list gettext-minimal intltool pkg-config yelp-tools)) (inputs - (list atk + (list at-spi2-core glib gtk+ libxml2 @@ -1228,7 +1228,7 @@ can be used as backgrounds in the MATE Desktop environment.") xorgproto yelp-tools)) (inputs - (list atk + (list at-spi2-core cairo glib gtk+ @@ -1277,7 +1277,7 @@ can be used as backgrounds in the MATE Desktop environment.") pkg-config yelp-tools)) (inputs - (list atk + (list at-spi2-core cairo dconf dbus @@ -1382,7 +1382,7 @@ can be used as backgrounds in the MATE Desktop environment.") ("pkg-config" ,pkg-config) ("yelp-tools" ,yelp-tools))) (inputs - (list atk + (list at-spi2-core cairo enchant-1.6 glib diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index ff3f1cf007..9ac365fbb4 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -26,7 +26,7 @@ ;;; Copyright © 2018 Joshua Sierles, Nextjournal <joshua@nextjournal.com> ;;; Copyright © 2018 Nadya Voronova <voronovank@gmail.com> ;;; Copyright © 2018 Adam Massmann <massmannak@gmail.com> -;;; Copyright © 2018, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2018, 2020-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2018 Eric Brown <brown@fastmail.com> ;;; Copyright © 2018, 2021 Julien Lepiller <julien@lepiller.eu> ;;; Copyright © 2018 Amin Bandali <bandali@gnu.org> @@ -634,14 +634,14 @@ precision floating point numbers.") (define-public gsl (package (name "gsl") - (version "2.7") + (version "2.7.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gsl/gsl-" version ".tar.gz")) (sha256 (base32 - "0av04cpblphvvs3kl5rwphniarml503501vrpqw31rd0bmwg7fzg")))) + "0jxkxrnpys2j3rh8bzx0bmnh4w6xm28jd57rgxsjp0s863agpc6w")))) (build-system gnu-build-system) (arguments (let ((system (%current-system))) @@ -853,7 +853,7 @@ integer programming problems and computes Markov bases for statistics.") libtool texlive-amsfonts texlive-dvips-l3backend - texlive-latex-graphics + texlive-graphics texlive-latex-l3backend texlive-tiny)) (arguments @@ -4582,66 +4582,67 @@ parts of it.") "0r4sz3rn68fyc2paq0a04pgfi7iszpm95f6ggbzxpvjzx9qxbcql")))) (build-system gnu-build-system) (arguments - `(#:test-target "test" - ;; DYNAMIC_ARCH is only supported on x86. When it is disabled and no - ;; TARGET is specified, OpenBLAS will tune itself to the build host, so - ;; we need to disable substitutions. - #:substitutable? - ,(let ((system (or (%current-target-system) (%current-system)))) - (or (string-prefix? "x86_64" system) - (string-prefix? "i686" system) - (string-prefix? "mips" system) - (string-prefix? "aarch64" system))) - #:make-flags - (list (string-append "PREFIX=" (assoc-ref %outputs "out")) - "SHELL=bash" - "MAKE_NB_JOBS=0" ;use jobserver for submakes - "NO_STATIC=1" ;avoid a 67 MiB static archive - - ;; This is the maximum number of threads OpenBLAS will ever use (that - ;; is, if $OPENBLAS_NUM_THREADS is greater than that, then NUM_THREADS - ;; is used.) If we don't set it, the makefile sets it to the number - ;; of cores of the build machine, which is obviously wrong. - "NUM_THREADS=128" - - ;; Build the library for all supported CPUs. This allows - ;; switching CPU targets at runtime with the environment variable - ;; OPENBLAS_CORETYPE=<type>, where "type" is a supported CPU type. - ;; Unfortunately, this is not supported on all architectures, - ;; where it leads to failed builds. - ,@(let ((system (or (%current-target-system) (%current-system)))) - (cond - ((or (string-prefix? "x86_64" system) - (string-prefix? "i686" system) - (string-prefix? "powerpc64le" system) - (string-prefix? "aarch64" system)) - ;; Dynamic older enables a few extra CPU architectures that - ;; were released before 2010. - '("DYNAMIC_ARCH=1" "DYNAMIC_OLDER=1" "TARGET=GENERIC")) - ;; On some of these architectures the CPU can't be detected. - ;; On MIPS we force the "SICORTEX" TARGET, as for the other - ;; two available MIPS targets special extended instructions - ;; for Loongson cores are used. - ((string-prefix? "mips" system) - '("TARGET=SICORTEX")) - ;; Failed to detect CPU. - ((string-prefix? "armhf" system) - '("TARGET=ARMV7")) - ((string-prefix? "riscv64" system) - '("TARGET=RISCV64_GENERIC")) - (else '())))) - ;; no configure script - #:phases - (modify-phases %standard-phases - (delete 'configure) - (add-before 'build 'set-extralib - (lambda* (#:key inputs #:allow-other-keys) - ;; Get libgfortran found when building in utest. - (setenv "FEXTRALIB" - (string-append - "-L" - (dirname - (search-input-file inputs "/lib/libgfortran.so"))))))))) + (list + #:test-target "test" + ;; DYNAMIC_ARCH is only supported on x86. When it is disabled and no + ;; TARGET is specified, OpenBLAS will tune itself to the build host, so + ;; we need to disable substitutions. + #:substitutable? + (let ((system (or (%current-target-system) (%current-system)))) + (or (string-prefix? "x86_64" system) + (string-prefix? "i686" system) + (string-prefix? "mips" system) + (string-prefix? "aarch64" system))) + #:make-flags + #~(list (string-append "PREFIX=" #$output) + "SHELL=bash" + "MAKE_NB_JOBS=0" ;use jobserver for submakes + "NO_STATIC=1" ;avoid a 67 MiB static archive + + ;; This is the maximum number of threads OpenBLAS will ever use (that + ;; is, if $OPENBLAS_NUM_THREADS is greater than that, then NUM_THREADS + ;; is used.) If we don't set it, the makefile sets it to the number + ;; of cores of the build machine, which is obviously wrong. + "NUM_THREADS=128" + + ;; Build the library for all supported CPUs. This allows + ;; switching CPU targets at runtime with the environment variable + ;; OPENBLAS_CORETYPE=<type>, where "type" is a supported CPU type. + ;; Unfortunately, this is not supported on all architectures, + ;; where it leads to failed builds. + #$@(let ((system (or (%current-target-system) (%current-system)))) + (cond + ((or (string-prefix? "x86_64" system) + (string-prefix? "i686" system) + (string-prefix? "powerpc64le" system) + (string-prefix? "aarch64" system)) + ;; Dynamic older enables a few extra CPU architectures that + ;; were released before 2010. + '("DYNAMIC_ARCH=1" "DYNAMIC_OLDER=1" "TARGET=GENERIC")) + ;; On some of these architectures the CPU can't be detected. + ;; On MIPS we force the "SICORTEX" TARGET, as for the other + ;; two available MIPS targets special extended instructions + ;; for Loongson cores are used. + ((string-prefix? "mips" system) + '("TARGET=SICORTEX")) + ;; Failed to detect CPU. + ((string-prefix? "armhf" system) + '("TARGET=ARMV7")) + ((string-prefix? "riscv64" system) + '("TARGET=RISCV64_GENERIC")) + (else '())))) + ;; no configure script + #:phases + #~(modify-phases %standard-phases + (delete 'configure) + (add-before 'build 'set-extralib + (lambda* (#:key inputs #:allow-other-keys) + ;; Get libgfortran found when building in utest. + (setenv "FEXTRALIB" + (string-append + "-L" + (dirname + (search-input-file inputs "/lib/libgfortran.so"))))))))) (inputs (list `(,gfortran "lib"))) (native-inputs @@ -4658,9 +4659,9 @@ parts of it.") (supported-systems '("x86_64-linux" "aarch64-linux" "mips64el-linux")) (arguments (substitute-keyword-arguments (package-arguments openblas) - ((#:make-flags flags '()) - `(append (list "INTERFACE64=1" "LIBNAMESUFFIX=ilp64") - ,flags)))) + ((#:make-flags flags #~'()) + #~(append (list "INTERFACE64=1" "LIBNAMESUFFIX=ilp64") + #$flags)))) (synopsis "Optimized BLAS library based on GotoBLAS (ILP64 version)") (license license:bsd-3))) @@ -5210,6 +5211,13 @@ with C89.") (build-system cmake-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-before 'configure 'set-environment + (lambda _ + ;; Pass "-fno-ipa-modref" flag to the compiler to work + ;; around a test failure with GCC 11. This is a + ;; header-only library so these flags only affect tests. + ;; See <https://github.com/g-truc/glm/pull/1087>. + (setenv "CXXFLAGS" "-O2 -g -fno-ipa-modref"))) (replace 'install (lambda* (#:key outputs #:allow-other-keys) ;; Since version 0.9.9.6, 'make install' is not supported @@ -5764,6 +5772,8 @@ set.") texlive-cm texlive-courier texlive-etoolbox + texlive-fancyhdr + texlive-fancyvrb texlive-helvetic texlive-jknappen texlive-sectsty @@ -5775,8 +5785,6 @@ set.") texlive-latex-cmap texlive-latex-colortbl texlive-latex-etoc - texlive-latex-fancyhdr - texlive-latex-fancyvrb texlive-latex-float texlive-latex-fncychap texlive-latex-framed @@ -5790,10 +5798,10 @@ set.") texlive-latex-parskip texlive-latex-stackengine texlive-latex-tabulary - texlive-latex-titlesec texlive-latex-tocloft texlive-latex-upquote texlive-latex-varwidth + texlive-titlesec texlive-ulem texlive-wasysym texlive-wrapfig)))) diff --git a/gnu/packages/matrix.scm b/gnu/packages/matrix.scm index 2ed7a9a782..f356674ed9 100644 --- a/gnu/packages/matrix.scm +++ b/gnu/packages/matrix.scm @@ -186,9 +186,9 @@ homeserver and generally help bootstrap the ecosystem.") "not test_upload_binary_file_object " "and not test_connect_wrapper")))))))) (native-inputs - `(("python-pytest" ,python-pytest-6) + `(("python-pytest" ,python-pytest) ("python-hyperframe" ,python-hyperframe) - ("python-hypothesis" ,python-hypothesis-next) + ("python-hypothesis" ,python-hypothesis) ("python-hpack" ,python-hpack) ("python-faker" ,python-faker) ("python-pytest-aiohttp" ,python-pytest-aiohttp) @@ -218,7 +218,7 @@ homeserver and generally help bootstrap the ecosystem.") python-future python-h11 python-h2 - python-jsonschema-next + python-jsonschema python-logbook python-olm python-peewee diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index ebb9bc17b3..2fa1c45f98 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -35,7 +35,7 @@ ;;; Copyright © 2022 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com> ;;; Copyright © 2022 Jack Hill <jackhill@jackhill.us> -;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Giovanni Biscuolo <g@xelera.eu> ;;; Copyright © 2023 Giacomo Leidi <goodoldpaul@autistici.org> ;;; Copyright © 2023 Yovan Naumovski <yovan@gorski.stream> @@ -210,43 +210,29 @@ XMPP-based sessions.") (build-system meson-build-system) (outputs '("out" "doc")) (arguments - `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-ncurses-path - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "meson.build" - (("'/usr'") - (string-append "'" - (assoc-ref inputs "ncurses") - "'"))))) - (add-before 'configure 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "doc" - (substitute* "libgnt-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.1.2/") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/")))))) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/gtk-doc") - (string-append doc "/share/gtk-doc")))))))) + (list #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-ncurses-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "meson.build" + (("'/usr'") + (string-append "'" #$(this-package-input "ncurses") + "'"))))) + (add-after 'install 'move-doc + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/gtk-doc") + (string-append #$output:doc "/share/gtk-doc"))))))) (native-inputs - `(("docbook-xml" ,docbook-xml-4.1.2) - ("glib:bin" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("gtk-doc" ,gtk-doc) - ("pkg-config" ,pkg-config))) - (inputs - (list ncurses)) - (propagated-inputs - `(("glib" ,glib) - ("libxml" ,libxml2) - ("python" ,python-2))) + (list docbook-xml-4.1.2 + `(,glib "bin") + gobject-introspection + gtk-doc + pkg-config)) + (inputs (list ncurses)) + (propagated-inputs (list glib libxml2 python-2)) (synopsis "GLib Ncurses Toolkit") (description "GNT is an ncurses toolkit for creating text-mode graphical user interfaces in a fast and easy way. It is based on GLib and ncurses.") @@ -417,7 +403,7 @@ TCP sessions from existing clients.") (define-public poezio (package (name "poezio") - (version "0.13.2") + (version "0.14") (source (origin (method git-fetch) @@ -429,10 +415,11 @@ TCP sessions from existing clients.") (file-name (git-file-name name version)) (sha256 - (base32 "0p92k8ssjsgavyfv1fd5cgzyw87dmdd84vaz7zvfsf5crvpr1mkf")))) + (base32 "15vlmymqlcf94h1g6dvgzjvj15c47dqsm78qs40wl2dlwspvqkxj")))) (build-system python-build-system) (arguments - (list #:phases + (list #:tests? #f ; tests fails without the OTR plugin + #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch (lambda _ @@ -443,7 +430,6 @@ TCP sessions from existing clients.") (list pkg-config python-setuptools python-sphinx)) (inputs (list python-mpd2 - python-potr python-pyasn1 python-pyasn1-modules python-pygments @@ -461,7 +447,7 @@ made in a configuration file or directly from the client. You'll find the light, fast, geeky and anonymous spirit of IRC while using a powerful, standard and open protocol.") (home-page "https://poez.io/en/") - (license license:zlib))) + (license license:gpl3+))) (define-public libotr (package @@ -474,6 +460,12 @@ powerful, standard and open protocol.") version ".tar.gz")) (sha256 (base32 "1x8rliydhbibmzwdbyr7pd7n87m2jmxnqkpvaalnf4154hj1hfwb")) + (modules '((guix build utils))) + (snippet + ;; Add missing #include that causes a build failure with glibc 2.35. + #~(substitute* "tests/regression/client/client.c" + (("_GNU_SOURCE" all) + (string-append all "\n#include <sys/socket.h>\n")))) (patches (search-patches "libotr-test-auth-fix.patch")))) (build-system gnu-build-system) @@ -1374,7 +1366,7 @@ Encryption to Gajim.") vala)) (inputs (list adwaita-icon-theme - atk + at-spi2-core bash-minimal cairo librsvg @@ -1396,7 +1388,7 @@ Encryption to Gajim.") libsignal-protocol-c libsoup libsrtp ;for calls support - pango-next ;gtk4 wants pango 1.50+ + pango ;gtk4 wants pango 1.50+ qrencode sqlite webrtc-audio-processing)) ;for A/V support diff --git a/gnu/packages/moreutils.scm b/gnu/packages/moreutils.scm index 4b0b617bde..d219c78d4f 100644 --- a/gnu/packages/moreutils.scm +++ b/gnu/packages/moreutils.scm @@ -71,7 +71,7 @@ ;; For building the manual pages. (native-inputs (list docbook-xml-4.4 - docbook-xsl-next ;without -next, man pages are corrupted + docbook-xsl ;without -next, man pages are corrupted libxml2 libxslt)) (home-page "https://joeyh.name/code/moreutils/") diff --git a/gnu/packages/multiprecision.scm b/gnu/packages/multiprecision.scm index 080a8100df..6ba08be3a3 100644 --- a/gnu/packages/multiprecision.scm +++ b/gnu/packages/multiprecision.scm @@ -119,13 +119,13 @@ It is aimed at use in, for example, cryptography and computational algebra.") (define-public mpfr (package (name "mpfr") - (version "4.1.0") + (version "4.2.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/mpfr/mpfr-" version ".tar.xz")) (sha256 (base32 - "0zwaanakrqjf84lfr5hfsdr7hncwv9wj0mchlr7cmxigfgqs760c")))) + "14yr4sf4mys64nzbgnd997l6l4n8l9vsjnnvnb0lh4jh2ggpi8q6")))) (build-system gnu-build-system) (outputs '("out" "debug")) (propagated-inputs (list gmp)) ; <mpfr.h> refers to <gmp.h> @@ -140,14 +140,14 @@ correct rounding.") (define-public mpc (package (name "mpc") - (version "1.2.1") + (version "1.3.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/mpc/mpc-" version ".tar.gz")) (sha256 (base32 - "0n846hqfqvmsmim7qdlms0qr86f1hck19p12nq3g3z2x74n3sl0p")))) + "1f2rqz0hdrrhx4y1i5f8pv6yv08a876k1dqcm9s2p26gyn928r5b")))) (build-system gnu-build-system) (outputs '("out" "debug")) (propagated-inputs (list gmp ; <mpc.h> refers to both diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index b5690f3ad9..7372e5db48 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -4019,7 +4019,7 @@ websites such as Libre.fm.") python-flask python-mock python-py7zr - python-pytest-6 + python-pytest python-responses)) (inputs (list bash-minimal @@ -6514,7 +6514,7 @@ and as an LV2 plugin.") libyaml lilv lv2 - pango-next + pango pipewire pulseaudio reproc @@ -7131,7 +7131,7 @@ streaming audio server.") gst-plugins-ugly gstreamer gtk+ - gtksourceview ; undo, redo, multiline text fields + gtksourceview-4 ; undo, redo, multiline text fields hicolor-icon-theme keybinder-3.0 ; keybindings outside of GNOME librsvg diff --git a/gnu/packages/ncurses.scm b/gnu/packages/ncurses.scm index c33b0a2511..c5f63e0b67 100644 --- a/gnu/packages/ncurses.scm +++ b/gnu/packages/ncurses.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012, 2013, 2014, 2015, 2017, 2018, 2019, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2016 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015, 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016 Nikita <nikita@n0.is> @@ -27,6 +27,7 @@ (define-module (gnu packages ncurses) #:use-module (gnu packages) #:use-module (guix licenses) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix build-system gnu) @@ -37,8 +38,22 @@ #:use-module (gnu packages swig) #:use-module (gnu packages linux) #:use-module (guix utils) + #:use-module ((guix memoization) #:select (mlambda)) #:use-module (ice-9 match)) +(define ncurses-rollup-patch + (mlambda (version) + (origin + (method url-fetch) + (uri (match (string-split (version-major+minor+point version) #\.) + ((major minor point) + (string-append "https://invisible-mirror.net/archives" + "/ncurses/" major "." minor "/ncurses-" + major "." minor "-" point "-patch.sh.bz2")))) + (sha256 + (base32 + "1b6522cvi4066bgh9lp93q8lk93zcjjssvnw1512z447xvazy2y6"))))) + (define-public ncurses (package (name "ncurses") @@ -56,170 +71,152 @@ "doc")) ;1 MiB of man pages (arguments (let ((patch-makefile-phase - '(lambda _ - (for-each patch-makefile-SHELL - (find-files "." "Makefile.in")))) + #~(lambda _ + (for-each patch-makefile-SHELL + (find-files "." "Makefile.in")))) (configure-phase ;; The 'configure' script does not understand '--docdir', so we must ;; override that and use '--mandir' instead. - '(lambda* (#:key build target outputs configure-flags - #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (apply invoke "./configure" - (string-append "SHELL=" (which "sh")) - (string-append "--build=" build) - (string-append "--prefix=" out) - (string-append "--mandir=" doc "/share/man") - (if target - (cons (string-append "--host=" target) - configure-flags) - configure-flags))))) + #~(lambda* (#:key build target outputs configure-flags + #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (doc (assoc-ref outputs "doc"))) + (apply invoke "./configure" + (string-append "SHELL=" (which "sh")) + (string-append "--build=" build) + (string-append "--prefix=" out) + (string-append "--mandir=" doc "/share/man") + (if target + (cons (string-append "--host=" target) + configure-flags) + configure-flags))))) (apply-rollup-patch-phase ;; Ncurses distributes "stable" patchsets to be applied on top ;; of the release tarball. These are only available as shell ;; scripts(!) so we decompress and apply them in a phase. ;; See <https://invisible-mirror.net/archives/ncurses/6.1/README>. - '(lambda* (#:key inputs native-inputs #:allow-other-keys) - (let ((rollup-patch (assoc-ref (or native-inputs inputs) - "rollup-patch"))) - (when rollup-patch - (copy-file rollup-patch - (string-append (getcwd) "/rollup-patch.sh.bz2")) - (invoke "bzip2" "-d" "rollup-patch.sh.bz2") - (invoke "sh" "rollup-patch.sh"))))) + #~(lambda* (#:key inputs native-inputs #:allow-other-keys) + (let ((rollup-patch #$(ncurses-rollup-patch + (package-version this-package)))) + (copy-file rollup-patch + (string-append (getcwd) "/rollup-patch.sh.bz2")) + (invoke "bzip2" "-d" "rollup-patch.sh.bz2") + (invoke "sh" "rollup-patch.sh")))) (remove-shebang-phase - '(lambda _ - ;; To avoid retaining a reference to the bootstrap Bash via the - ;; shebang of the 'ncursesw6-config' script, simply remove that - ;; shebang: it'll work just as well without it. Likewise, do not - ;; retain a reference to the "doc" output. - (substitute* "misc/ncurses-config.in" - (("#!@SHELL@") - "# No shebang here, use /bin/sh!\n") - (("@SHELL@ \\$0") - "$0") - (("mandir=.*$") - "mandir=share/man")))) + #~(lambda _ + ;; To avoid retaining a reference to the bootstrap Bash via the + ;; shebang of the 'ncursesw6-config' script, simply remove that + ;; shebang: it'll work just as well without it. Likewise, do not + ;; retain a reference to the "doc" output. + (substitute* "misc/ncurses-config.in" + (("#!@SHELL@") + "# No shebang here, use /bin/sh!\n") + (("@SHELL@ \\$0") + "$0") + (("mandir=.*$") + "mandir=share/man")))) (post-install-phase - `(lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - ;; When building a wide-character (Unicode) build, create backward - ;; compatibility links from the the "normal" libraries to the - ;; wide-character ones (e.g. libncurses.so to libncursesw.so). - ,@(if (target-mingw?) - '( ;; TODO: create .la files to link to the .dll? - (with-directory-excursion (string-append out "/bin") - (for-each - (lambda (lib) - (define lib.dll - (string-append "lib" lib ".dll")) - (define libw6.dll - (string-append "lib" lib "w6.dll")) + #~(lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + ;; When building a wide-character (Unicode) build, create backward + ;; compatibility links from the the "normal" libraries to the + ;; wide-character ones (e.g. libncurses.so to libncursesw.so). + #$@(if (target-mingw?) + '( ;; TODO: create .la files to link to the .dll? + (with-directory-excursion (string-append out "/bin") + (for-each + (lambda (lib) + (define lib.dll + (string-append "lib" lib ".dll")) + (define libw6.dll + (string-append "lib" lib "w6.dll")) - (when (file-exists? libw6.dll) - (format #t "creating symlinks for `lib~a'~%" lib) - (symlink libw6.dll lib.dll))) - '("curses" "ncurses" "form" "panel" "menu")))) - '()) - (with-directory-excursion (string-append out "/lib") - (for-each (lambda (lib) - (define libw.a - (string-append "lib" lib "w.a")) - (define lib.a - (string-append "lib" lib ".a")) + (when (file-exists? libw6.dll) + (format #t "creating symlinks for `lib~a'~%" lib) + (symlink libw6.dll lib.dll))) + '("curses" "ncurses" "form" "panel" "menu")))) + #~()) + (with-directory-excursion (string-append out "/lib") + (for-each (lambda (lib) + (define libw.a + (string-append "lib" lib "w.a")) + (define lib.a + (string-append "lib" lib ".a")) - ,@(if (not (target-mingw?)) - '((define libw.so.x - (string-append "lib" lib "w.so.6")) - (define lib.so.x - (string-append "lib" lib ".so.6")) - (define lib.so - (string-append "lib" lib ".so")) - (define packagew.pc - (string-append lib "w.pc")) - (define package.pc - (string-append lib ".pc"))) - '()) + #$@(if (not (target-mingw?)) + #~((define libw.so.x + (string-append "lib" lib "w.so.6")) + (define lib.so.x + (string-append "lib" lib ".so.6")) + (define lib.so + (string-append "lib" lib ".so")) + (define packagew.pc + (string-append lib "w.pc")) + (define package.pc + (string-append lib ".pc"))) + #~()) - (when (file-exists? libw.a) - (format #t "creating symlinks for `lib~a'~%" lib) - (symlink libw.a lib.a) - ,@(if (not (target-mingw?)) - '((symlink libw.so.x lib.so.x) - (false-if-exception (delete-file lib.so)) - (call-with-output-file lib.so - (lambda (p) - (format p "INPUT (-l~aw)~%" lib))) - (with-directory-excursion "pkgconfig" - (format #t "creating symlink for `~a'~%" - package.pc) - (when (file-exists? packagew.pc) - (symlink packagew.pc package.pc)))) - '()))) - '("curses" "ncurses" "form" "panel" "menu"))))))) - `(#:configure-flags - ,(cons* - 'quasiquote - `(("--with-shared" "--without-debug" "--enable-widec" + (when (file-exists? libw.a) + (format #t "creating symlinks for `lib~a'~%" lib) + (symlink libw.a lib.a) + #$@(if (not (target-mingw?)) + '((symlink libw.so.x lib.so.x) + (false-if-exception (delete-file lib.so)) + (call-with-output-file lib.so + (lambda (p) + (format p "INPUT (-l~aw)~%" lib))) + (with-directory-excursion "pkgconfig" + (format #t "creating symlink for `~a'~%" + package.pc) + (when (file-exists? packagew.pc) + (symlink packagew.pc package.pc)))) + #~()))) + '("curses" "ncurses" "form" "panel" "menu"))))))) + (list #:configure-flags + #~`("--with-shared" "--without-debug" "--enable-widec" - "--enable-pc-files" - ,(list 'unquote '(string-append "--with-pkg-config-libdir=" - (assoc-ref %outputs "out") - "/lib/pkgconfig")) + "--enable-pc-files" + ,(string-append "--with-pkg-config-libdir=" + #$output "/lib/pkgconfig") - ;; By default headers land in an `ncursesw' subdir, which is not - ;; what users expect. - ,(list 'unquote '(string-append "--includedir=" (assoc-ref %outputs "out") - "/include")) - "--enable-overwrite" ;really honor --includedir + ;; By default headers land in an `ncursesw' subdir, which is not + ;; what users expect. + ,(string-append "--includedir=" #$output "/include") + "--enable-overwrite" ;really honor --includedir - ;; Make sure programs like 'tic', 'reset', and 'clear' have a - ;; correct RUNPATH. - ,(list 'unquote '(string-append "LDFLAGS=-Wl,-rpath=" (assoc-ref %outputs "out") - "/lib")) + ;; Make sure programs like 'tic', 'reset', and 'clear' have a + ;; correct RUNPATH. + ,(string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib") - ;; Starting from ncurses 6.1, "make install" runs "install -s" - ;; by default, which doesn't work for cross-compiled binaries - ;; because it invokes 'strip' instead of 'TRIPLET-strip'. Work - ;; around this. - ,@(if (%current-target-system) '("--disable-stripping") '()) + ;; Starting from ncurses 6.1, "make install" runs "install -s" + ;; by default, which doesn't work for cross-compiled binaries + ;; because it invokes 'strip' instead of 'TRIPLET-strip'. Work + ;; around this. + #$@(if (%current-target-system) #~("--disable-stripping") #~()) - ;; Do not assume a default search path in ld, even if it is only to - ;; filter it out in ncurses-config. Mainly because otherwise it ends - ;; up using the libdir from binutils, which makes little sense and - ;; causes an unnecessary runtime dependency. - "cf_cv_ld_searchpath=/no-ld-searchpath" + ;; Do not assume a default search path in ld, even if it is only to + ;; filter it out in ncurses-config. Mainly because otherwise it ends + ;; up using the libdir from binutils, which makes little sense and + ;; causes an unnecessary runtime dependency. + "cf_cv_ld_searchpath=/no-ld-searchpath" - ;; MinGW: Use term-driver created for the MinGW port. - ,@(if (target-mingw?) '("--enable-term-driver") '())))) - #:tests? #f ; no "check" target - #:phases (modify-phases %standard-phases - (add-after 'unpack 'apply-rollup-patch - ,apply-rollup-patch-phase) - (replace 'configure ,configure-phase) - (add-after 'install 'post-install - ,post-install-phase) - (add-before 'configure 'patch-makefile-SHELL - ,patch-makefile-phase) - (add-before 'patch-source-shebangs 'remove-unneeded-shebang - ,remove-shebang-phase))))) + ;; MinGW: Use term-driver created for the MinGW port. + #$@(if (target-mingw?) #~("--enable-term-driver") #~())) + #:tests? #f ; no "check" target + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'apply-rollup-patch + #$apply-rollup-patch-phase) + (replace 'configure #$configure-phase) + (add-after 'install 'post-install + #$post-install-phase) + (add-before 'configure 'patch-makefile-SHELL + #$patch-makefile-phase) + (add-before 'patch-source-shebangs 'remove-unneeded-shebang + #$remove-shebang-phase))))) (native-inputs - `(,@(if (%current-target-system) - `(("self" ,this-package)) ;for `tic' - '()) - ("rollup-patch" - ,(origin - (method url-fetch) - (uri (match (string-split (version-major+minor+point version) #\.) - ((major minor point) - (string-append "https://invisible-mirror.net/archives" - "/ncurses/" major "." minor "/ncurses-" - major "." minor "-" point "-patch.sh.bz2")))) - (sha256 - (base32 - "1b6522cvi4066bgh9lp93q8lk93zcjjssvnw1512z447xvazy2y6")))) - ("pkg-config" ,pkg-config))) + (if (%current-target-system) + (list pkg-config this-package) ;for 'tic' + (list pkg-config))) (native-search-paths (list (search-path-specification (variable "TERMINFO_DIRS") @@ -240,12 +237,11 @@ ncursesw library provides wide character support.") (arguments (substitute-keyword-arguments (package-arguments ncurses) ((#:configure-flags cf) - `(cons (string-append "--with-gpm=" - (assoc-ref %build-inputs "gpm") - "/lib/libgpm.so.2") - ,cf)))) - (inputs - `(("gpm" ,gpm))))) + #~(cons (string-append "--with-gpm=" + #$(this-package-input "gpm") + "/lib/libgpm.so.2") + #$cf)))) + (inputs (list gpm)))) ;; Needed by u-boot 2022.04+ ;; Consider merging into ncurses for next core-updates cycle. @@ -255,8 +251,7 @@ ncursesw library provides wide character support.") (arguments (substitute-keyword-arguments (package-arguments ncurses) ((#:configure-flags cf) - `(cons "--with-termlib=tinfo" - ,cf)))))) + #~(cons "--with-termlib=tinfo" #$cf)))))) (define-public dialog (package diff --git a/gnu/packages/nettle.scm b/gnu/packages/nettle.scm index ea26ba3b2d..96ffb8821a 100644 --- a/gnu/packages/nettle.scm +++ b/gnu/packages/nettle.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012, 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2016, 2021 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2017, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017, 2020-2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. @@ -83,14 +83,14 @@ themselves.") ;; This version is not API-compatible with version 2. In particular, lsh ;; cannot use it yet. So keep it separate. (package (inherit nettle-2) - (version "3.7.3") + (version "3.8.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/nettle/nettle-" version ".tar.gz")) (sha256 (base32 - "1w5wwc3q0r97d2ifhx77cw7y8s20bm8x52is9j93p2h47yq5w7v6")))) + "1znb87fi4gd2jkwbca74fl64pr9lr0cm5i6p7zlcszfdfwmkwkrn")))) (arguments (substitute-keyword-arguments (package-arguments nettle-2) ((#:configure-flags flags) diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm index a5f0433652..e456b40a20 100644 --- a/gnu/packages/networking.scm +++ b/gnu/packages/networking.scm @@ -414,79 +414,76 @@ Android, and ChromeOS.") (license license:lgpl2.1+))) (define-public libnice - ;; The latest release is old and randomly fails tests with GStreamer 1.18.5, - ;; such as: "test-bind: ../libnice-0.1.18/stun/tests/test-bind.c:234: - ;; bad_responses: Assertion `len >= 20' failed" - (let ((revision "0") - (commit "47a96334448838c43d7e72f4ef51b317befbfae1")) - (package - (name "libnice") - (version (git-version "0.1.18" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://gitlab.freedesktop.org/libnice/libnice") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "19ypjazslmsb9vqs2wyyzvi72h5jbn16dbng7pxh485djdrmgcg4")))) - (build-system meson-build-system) - (outputs '("out" "doc")) - (arguments - `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas - #:configure-flags - (list - "-Dgtk_doc=enabled") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "tests/meson.build" - ;; ‘test-set-port-range.c:66:main: assertion failed: - ;; (nice_agent_gather_candidates (agent, stream1))’ - (("'test-set-port-range'" all) - (string-append "# " all)) - ;; The following test is disabled as it fails in a - ;; nondeterministic fashion (see: - ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/151). - (("'test-bsd'" all) - (string-append "# " all))) - (substitute* "stun/tests/meson.build" - ;; test-bind.c:234: bad_responses: Assertion `len >= 20' - ;; failed (see: - ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/150). - (("'bind', ") - "")))) - (add-after 'install 'move-docs - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc"))) - (mkdir-p (string-append doc "/share")) - (rename-file - (string-append out "/share/gtk-doc") - (string-append doc "/share/gtk-doc")))))))) - (native-inputs - `(("glib:bin" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("graphviz" ,graphviz) - ("gtk-doc" ,gtk-doc/stable) - ("pkg-config" ,pkg-config))) - (inputs - (list gstreamer gst-plugins-base libnsl)) - (propagated-inputs - (list glib glib-networking gnutls)) - (synopsis "GLib ICE implementation") - (description "LibNice is a library that implements the Interactive + (package + (name "libnice") + (version "0.1.21") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.freedesktop.org/libnice/libnice") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0zxh1mdrl4p2vih8f4yqzm3pp4jsmc8aq7l43dlndaz4sj4c8j44")))) + (build-system meson-build-system) + (outputs '("out" "doc")) + (arguments + (list + #:glib-or-gtk? #t ; To wrap binaries and/or compile schemas + #:configure-flags + #~(list"-Dgtk_doc=enabled") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "tests/meson.build" + ;; ‘test-set-port-range.c:66:main: assertion failed: + ;; (nice_agent_gather_candidates (agent, stream1))’ + (("'test-set-port-range'" all) + (string-append "# " all)) + ;; The following test is disabled as it fails in a + ;; nondeterministic fashion (see: + ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/151). + (("'test-bsd'" all) + (string-append "# " all))) + (substitute* "stun/tests/meson.build" + ;; test-bind.c:234: bad_responses: Assertion `len >= 20' + ;; failed (see: + ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/150). + (("'bind', ") + "")))) + (add-after 'install 'move-docs + (lambda _ + (mkdir-p (string-append #$output:doc "/share")) + (rename-file + (string-append #$output "/share/gtk-doc") + (string-append #$output:doc "/share/gtk-doc"))))))) + (native-inputs + (list `(,glib "bin") + gobject-introspection + graphviz + gtk-doc/stable + pkg-config)) + (inputs + (list gstreamer + gst-plugins-base + libnsl)) + (propagated-inputs + (list glib + glib-networking + gnutls)) + (synopsis "GLib ICE implementation") + (description "LibNice is a library that implements the Interactive Connectivity Establishment (ICE) standard (RFC 5245 & RFC 8445). It provides a GLib-based library, libnice, as well as GStreamer elements to use it.") - (home-page "https://libnice.freedesktop.org/") - (license - ;; This project is dual-licensed. - (list - license:lgpl2.1+ - license:mpl1.1))))) + (home-page "https://libnice.freedesktop.org/") + (license + ;; This project is dual-licensed. + (list + license:lgpl2.1+ + license:mpl1.1)))) (define-public librecast (package @@ -1199,7 +1196,7 @@ and SSH, and it can use both TCP and UDP as transport mechanisms.") (define-public socat (package (name "socat") - (version "1.7.4.1") + (version "1.7.4.3") (source (origin (method url-fetch) (uri (string-append @@ -1207,7 +1204,7 @@ and SSH, and it can use both TCP and UDP as transport mechanisms.") version ".tar.bz2")) (sha256 (base32 - "1sbmqqvni3ss9wyay6ik5v81kxffkra80mh4ypgj74g82iba5b1z")))) + "01w0hpqf5xmgn40s1ablfd4y67dlrx5y9zlx24spc1qm8h81hwyl")))) (build-system gnu-build-system) (arguments '(#:tests? #f)) ; no test suite (inputs (list openssl)) @@ -1612,7 +1609,7 @@ intended as a substitute for the PPPStatus and EthStatus projects.") `(("gettext" ,gettext-minimal) ("pkg-config" ,pkg-config) ("docbook-xsl" ,docbook-xsl) - ("docbook-xml" ,docbook-xml-5) + ("docbook-xml" ,docbook-xml) ("libxml2" ,libxml2) ;for XML_CATALOG_FILES ("xsltproc" ,libxslt))) (inputs @@ -2542,7 +2539,7 @@ sockets in Perl.") (inputs (list dbus zlib)) (arguments - `(#:phases + '(#:phases (modify-phases %standard-phases (replace 'check (lambda* (#:key tests? #:allow-other-keys) @@ -3819,6 +3816,11 @@ and targeted primarily for asynchronous processing of HTTP-requests.") (lambda* (#:key tests? #:allow-other-keys) (when tests? (invoke "tests/opendht_unit_tests")))) + (add-before 'bootstrap 'delete-autogen.sh + (lambda _ + ;; The autogen.sh script lacks a shebang, cannot be executed + ;; directly. Let the bootstrap phase invoke autoreconf itself. + (delete-file "autogen.sh"))) (add-after 'install 'move-and-wrap-tools (lambda* (#:key inputs outputs #:allow-other-keys) (let* ((tools (assoc-ref outputs "tools")) diff --git a/gnu/packages/ninja.scm b/gnu/packages/ninja.scm index 4c4a2f37a7..42c9309b82 100644 --- a/gnu/packages/ninja.scm +++ b/gnu/packages/ninja.scm @@ -31,7 +31,7 @@ (define-public ninja (package (name "ninja") - (version "1.10.2") + (version "1.11.1") (source (origin (method git-fetch) (uri (git-reference @@ -40,9 +40,9 @@ (file-name (git-file-name name version)) (sha256 (base32 - "0mspq4mvx41qri2v2zlg2y3znx5gfw6d8s3czbcfpr2218qbpz55")))) + "14kshkxdn833nkz2qkzb3w531dcqj6haad90gxj70ic05lb7zx9f")))) (build-system gnu-build-system) - (inputs `(("python" ,python-wrapper))) + (inputs (list python-wrapper)) (arguments '(#:phases (modify-phases %standard-phases diff --git a/gnu/packages/node.scm b/gnu/packages/node.scm index 6137ed1dd3..d8d40e8fb4 100644 --- a/gnu/packages/node.scm +++ b/gnu/packages/node.scm @@ -290,8 +290,8 @@ (list c-ares http-parser icu4c - libuv - `(,nghttp2 "lib") + libuv-for-node + `(,nghttp2-for-node "lib") openssl-1.1 zlib ;; Regular build-time dependencies. @@ -310,8 +310,8 @@ c-ares http-parser icu4c - libuv - `(,nghttp2 "lib") + libuv-for-node + `(,nghttp2-for-node "lib") openssl python-wrapper ;for node-gyp (supports python3) zlib)) @@ -866,9 +866,9 @@ source files.") (list ;; Runtime dependencies for binaries used as a bootstrap. c-ares-for-node brotli - icu4c-71 + icu4c libuv-for-node - `(,nghttp2 "lib") + `(,nghttp2-for-node "lib") openssl-1.1 zlib ;; Regular build-time dependencies. @@ -881,11 +881,11 @@ source files.") (list bash-minimal coreutils c-ares-for-node - icu4c-71 + icu4c libuv-for-node llhttp-bootstrap brotli - `(,nghttp2 "lib") + `(,nghttp2-for-node "lib") openssl-1.1 zlib)))) diff --git a/gnu/packages/nss.scm b/gnu/packages/nss.scm index 056fdba450..7bb239dd27 100644 --- a/gnu/packages/nss.scm +++ b/gnu/packages/nss.scm @@ -1,11 +1,11 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2013-2019, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2021 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2016-2019, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020, 2021 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Jonathan Brielmaier <jonathan.brielmaier@web.de> -;;; Copyright © 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; ;;; This file is part of GNU Guix. @@ -29,8 +29,10 @@ #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix build-system gnu) + #:use-module (guix build-system mozilla) #:use-module ((guix licenses) #:prefix license:) #:use-module (gnu packages) + #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages check) #:use-module (gnu packages compression) @@ -69,16 +71,7 @@ #~(list "--disable-static" "--enable-64bit" (string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - ;; Mozilla deviates from Autotools conventions - ;; due to historical reasons. Adjust to Mozilla conventions, - ;; otherwise the Makefile will try to use TARGET-gcc - ;; as a ‘native’ compiler. - #$@(if (%current-target-system) - #~((string-append "--host=" - #$(nix-system->gnu-triplet (%current-system))) - (string-append "--target=" #$(%current-target-system))) - #~())) + (assoc-ref %outputs "out") "/lib")) ;; Use fixed timestamps for reproducibility. #:make-flags #~'("SH_DATE='1970-01-01 00:00:01'" ;; This is epoch 1 in microseconds. @@ -107,26 +100,12 @@ in the Mozilla clients.") (base32 "0v3zds1id71j5a5si42a658fjz8nv2f6zp6w4gqrqmdr6ksz8sxv")))))) -(define-public nspr-next - (package - (inherit nspr) - (version "4.35") - (source (origin - (method url-fetch) - (uri (string-append - "https://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v" - version "/src/nspr-" version ".tar.gz")) - (sha256 - (base32 - "13xwda56yhp1w7v02qvlxvlqiniw8kr4g3fxlljmv6wnlmz2k8vy")))))) - (define-public nss (package (name "nss") - (replacement nss/fixed) ;; Also update and test the nss-certs package, which duplicates version and ;; source to avoid a top-level variable reference & module cycle. - (version "3.85") + (version "3.88.1") (source (origin (method url-fetch) (uri (let ((version-with-underscores @@ -137,7 +116,7 @@ in the Mozilla clients.") "nss-" version ".tar.gz"))) (sha256 (base32 - "15yj2gddlp68wj1k9q4q70vs6r7zx5qkbavcppmls5di212xdndg")) + "15il9fsmixa1r4446zq1wl627sg0hz9h67w6kjxz273xz3nl7li7")) ;; Create nss.pc and nss-config. (patches (search-patches "nss-3.56-pkgconfig.patch" "nss-getcwd-nonnull.patch" @@ -223,12 +202,9 @@ in the Mozilla clients.") (copy-recursively "dist/public/nss" inc) (copy-recursively (string-append obj "/bin") bin) (copy-recursively (string-append obj "/lib") lib))))))) - (inputs - (list sqlite zlib)) - (propagated-inputs - (list nspr)) ;required by nss.pc. - (native-inputs - (list perl libfaketime)) ;for tests + (inputs (list sqlite zlib)) + (propagated-inputs (list nspr)) ;required by nss.pc. + (native-inputs (list perl libfaketime which)) ;for tests ;; The NSS test suite takes around 48 hours on Loongson 3A (MIPS) when ;; another build is happening concurrently on the same machine. @@ -244,24 +220,3 @@ PKCS #5, PKCS #7, PKCS #11, PKCS #12, S/MIME, X.509 v3 certificates, and other security standards.") (license license:mpl2.0))) -(define-public nss-next - (package - (inherit nss) - (version "3.88.1") - (source (origin - (inherit (package-source nss)) - (uri (let ((version-with-underscores - (string-join (string-split version #\.) "_"))) - (string-append - "https://ftp.mozilla.org/pub/mozilla.org/security/nss/" - "releases/NSS_" version-with-underscores "_RTM/src/" - "nss-" version ".tar.gz"))) - (sha256 - (base32 - "15il9fsmixa1r4446zq1wl627sg0hz9h67w6kjxz273xz3nl7li7")))) - (propagated-inputs (list nspr-next)))) ;required by nss.pc - -(define nss/fixed - (package - (inherit nss-next) - (version "3.88"))) ; slight inaccuracy to allow grafting diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 3b4fcf108b..95ddea92c5 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -134,6 +134,8 @@ (sha256 (base32 "1f5gl3hzvixbgk0v3kmxiyn432znyy3jh5fa65cfzcaxzgfv1i1c")) + (patches (search-patches + "camlboot-dynamically-allocate-stack-signal.patch")) (modules '((guix build utils))) (snippet `(begin @@ -317,7 +319,9 @@ functional, imperative and object-oriented styles of programming.") "http://caml.inria.fr/pub/distrib/ocaml-" (version-major+minor version) "/ocaml-" version ".tar.xz")) - (patches (search-patches "ocaml-4.09-multiple-definitions.patch")) + (patches (search-patches + "ocaml-4.09-multiple-definitions.patch" + "ocaml-4.09-dynamically-allocate-signal-stack.patch")) (sha256 (base32 "1v3z5ar326f3hzvpfljg4xj8b9lmbrl53fn57yih1bkbx3gr3yzj")))) @@ -366,7 +370,9 @@ patch-/bin/sh-references: ~a: changing `\"/bin/sh\"' to `~a'~%" (sha256 (base32 "1f07hgj5k45cylj1q3k5mk8yi02cwzx849b1fwnwia8xlcfqpr6z")) - (patches (search-patches "ocaml-multiple-definitions.patch")) + (patches (search-patches + "ocaml-multiple-definitions.patch" + "ocaml-4.07-dynamically-allocate-signal-stack.patch")) (modules '((guix build utils))) (snippet `(begin @@ -6654,7 +6660,12 @@ the OCaml code.") (substitute* "test/ppx_import_support/test.ml" (("\\(Failure") "Failure") ((" \"(Some ppx-es.*)\")" _ m) - (string-append " \"" m "\".")))))))) + (string-append " \"" m "\"."))))) + (add-after 'fix-test-format 'fix-egrep + (lambda _ + ;; egrep is obsolescent; using grep -E + (substitute* "test/expansion_context/run.t" + (("egrep") "grep -E"))))))) (propagated-inputs (list ocaml-compiler-libs ocaml-ppx-derivers @@ -9219,7 +9230,12 @@ variants.") "test/bin/mdx-test/misc/no-such-prelude/test.expected") (("`") "'") (("COMMAND") "[COMMAND]") - (("\\.\\.\\.") "…"))))))) + (("\\.\\.\\.") "…")))) + (add-after 'fix-test-format 'fix-egrep + (lambda _ + ;; egrep is obsolescent; using grep -E + (substitute* "test/bin/mdx-test/expect/padding/test-case.md" + (("egrep") "grep -E"))))))) (propagated-inputs (list ocaml-fmt ocaml-astring diff --git a/gnu/packages/onc-rpc.scm b/gnu/packages/onc-rpc.scm index 3928e80476..afeb26331c 100644 --- a/gnu/packages/onc-rpc.scm +++ b/gnu/packages/onc-rpc.scm @@ -41,12 +41,12 @@ (package (name "libtirpc") (version "1.3.1") - (replacement libtirpc/fixed) (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/libtirpc/libtirpc/" version "/libtirpc-" version ".tar.bz2")) + (patches (search-patches "libtirpc-CVE-2021-46828.patch")) (sha256 (base32 "05zf16ilwwkzv4cccaac32nssrj3rg444n9pskiwbgk6y359an14")))) @@ -89,13 +89,6 @@ IPv4 and IPv6. ONC RPC is notably used by the network file system (NFS).") #$(this-package-input "mit-krb5") "/bin/krb5-config"))))))) -(define libtirpc/fixed - (package - (inherit libtirpc) - (source (origin - (inherit (package-source libtirpc)) - (patches (search-patches "libtirpc-CVE-2021-46828.patch")))))) - (define-public rpcbind (package (name "rpcbind") diff --git a/gnu/packages/openldap.scm b/gnu/packages/openldap.scm index 3f3015bd80..d90cf6e66f 100644 --- a/gnu/packages/openldap.scm +++ b/gnu/packages/openldap.scm @@ -1,14 +1,15 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2014, 2015, 2019, 2020 Ludovic Courtès <ludo@gnu.org> -;;; Copyright © 2013 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2013, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2016, 2021 Leo Famulari <leo@famulari.name> -;;; Copyright © 2017, 2018, 2019, 2021, 2022 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2017, 2018, 2019, 2021, 2022, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Lars-Dominik Braun <ldb@leibniz-psychology.org> ;;; Copyright © 2020 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2023 Brian Cully <bjc@spork.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -65,76 +66,14 @@ (define-public openldap (package - (name "openldap") - (version "2.4.57") - (source (origin - (method url-fetch) - ;; See <http://www.openldap.org/software/download/> for a list of - ;; mirrors. - (uri (list (string-append - "ftp://mirror.switch.ch/mirror/OpenLDAP/" - "openldap-release/openldap-" version ".tgz") - (string-append - "https://www.openldap.org/software/download/OpenLDAP/" - "openldap-release/openldap-" version ".tgz") - (string-append - "ftp://ftp.dti.ad.jp/pub/net/OpenLDAP/" - "openldap-release/openldap-" version ".tgz"))) - (sha256 - (base32 - "0nmlyqhc52v24b4awh914sczmvxbazgq2cnlycvb9dgcwvhlgfn7")))) - (build-system gnu-build-system) - (inputs (list bdb-5.3 cyrus-sasl gnutls libgcrypt zlib)) - (native-inputs (list libtool groff bdb-5.3)) - (arguments - `(#:tests? #f - #:configure-flags - '("--disable-static" - ,@(if (%current-target-system) - '("--with-yielding_select=yes" - "ac_cv_func_memcmp_working=yes") - '())) - ;; Disable install stripping as it breaks cross-compiling. - #:make-flags '("STRIP=") - #:phases - (modify-phases %standard-phases - ,@(if (%current-target-system) - '((add-before 'configure 'fix-cross-gcc - (lambda* (#:key target #:allow-other-keys) - (setenv "CC" (string-append target "-gcc")) - #t))) - '()) - (add-after 'install 'patch-sasl-path - ;; Give -L arguments for cyrus-sasl to avoid propagation. - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (krb5 (assoc-ref inputs "mit-krb5"))) ;propagated from cyrus-sasl - - ;; The ancient Libtool bundled with OpenLDAP copies the linker flags - ;; from Cyrus-SASL and embeds them into its own .la files. Add an - ;; absolute reference to Kerberos so it does not have to be propagated. - (substitute* (map (lambda (f) (string-append out "/" f)) - '("lib/libldap.la" "lib/libldap_r.la")) - (("-lkrb5" lib) - (string-append "-L" krb5 "/lib " lib))) - #t)))))) - (synopsis "Implementation of the Lightweight Directory Access Protocol") - (description - "OpenLDAP is a free implementation of the Lightweight Directory Access Protocol.") - (license openldap2.8) - (home-page "https://www.openldap.org/"))) - -;; TODO: Update the main package in the next rebuild cycle. -(define-public openldap-2.6 - (package - (inherit openldap) - (version "2.6.3") + (name "openldap") + (version "2.6.4") (source (origin (method url-fetch) ;; See <http://www.openldap.org/software/download/> for a list of ;; mirrors. (uri (list (string-append - "http://mirror.eu.oneandone.net/software/openldap" + "http://repository.linagora.org/OpenLDAP" "/openldap-release/openldap-" version ".tgz") (string-append "https://www.openldap.org/software/download/OpenLDAP/" @@ -144,27 +83,35 @@ "openldap-release/openldap-" version ".tgz"))) (sha256 (base32 - "0ihddk8c6hg9lkjv0wk0w13g8kb75r8dfsn1n6b77mzk3pbs38nj")))) + "1489li52sjxm1f97v927jxaxzfk6v9sa32ixrw30qhvq07jh85ym")))) + (build-system gnu-build-system) + (inputs (list bdb-5.3 cyrus-sasl gnutls libgcrypt zlib)) + (native-inputs (list libtool groff bdb-5.3)) (arguments - (substitute-keyword-arguments (package-arguments openldap) - ((#:phases phases) - #~(modify-phases #$phases - (replace 'patch-sasl-path - ;; Give -L arguments for cyrus-sasl to avoid propagation. - (lambda* (#:key inputs #:allow-other-keys) - (let ((krb5 (search-input-file inputs "/lib/libkrb5.so"))) - (substitute* (string-append #$output "/lib/libldap.la") - (("-lkrb5" lib) - (string-append "-L" (dirname krb5) "/lib " lib)))))) - (add-after 'install 'provide-ldap_r - (lambda _ - ;; The re-entrant libldap_r no longer exists since 2.6 - ;; as it has become the default: provide a linker alias - ;; for now. - (call-with-output-file (string-append #$output - "/lib/libldap_r.so") - (lambda (port) - (format port "INPUT ( libldap.so )~%"))))))))))) + (list + #:tests? #f + #:configure-flags + #~(list "--disable-static" + #$@(if (%current-target-system) + '("--with-yielding_select=yes" + "ac_cv_func_memcmp_working=yes") + '())) + ;; Disable install stripping as it breaks cross-compiling. + #:make-flags + #~(list "STRIP=") + #:phases + #~(modify-phases %standard-phases + #$@(if (%current-target-system) + '((add-before 'configure 'fix-cross-gcc + (lambda* (#:key target #:allow-other-keys) + (setenv "CC" (string-append target "-gcc")) + (setenv "STRIP" (string-append target "-strip"))))) + '())))) + (synopsis "Implementation of the Lightweight Directory Access Protocol") + (description + "OpenLDAP is a free implementation of the Lightweight Directory Access Protocol.") + (license openldap2.8) + (home-page "https://www.openldap.org/"))) (define-public nss-pam-ldapd (package @@ -233,7 +180,7 @@ an LDAP server.") (setenv "SLAPD" slapd) (setenv "SCHEMA" schema))))))) (inputs - (list openldap-2.6 cyrus-sasl mit-krb5)) + (list openldap cyrus-sasl mit-krb5)) (propagated-inputs (list python-pyasn1 python-pyasn1-modules)) (home-page "https://www.python-ldap.org/") diff --git a/gnu/packages/orange.scm b/gnu/packages/orange.scm index 2a66fe429e..8b22124c35 100644 --- a/gnu/packages/orange.scm +++ b/gnu/packages/orange.scm @@ -25,6 +25,7 @@ #:use-module (gnu packages freedesktop) #:use-module (gnu packages graph) #:use-module (gnu packages machine-learning) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-science) #:use-module (gnu packages python-web) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 5d2416f35b..e2f76555ef 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -2008,7 +2008,7 @@ cp -r /tmp/locale/*/en_US.*"))) libsoup-minimal-2 libxau libxml2 - p11-kit-next + p11-kit util-linux xdg-dbus-proxy)) (propagated-inputs (list glib-networking gnupg gsettings-desktop-schemas)) diff --git a/gnu/packages/patches/autotrace-glib-compat.patch b/gnu/packages/patches/autotrace-glib-compat.patch deleted file mode 100644 index e63dcedf83..0000000000 --- a/gnu/packages/patches/autotrace-glib-compat.patch +++ /dev/null @@ -1,50 +0,0 @@ -Fix build with GLib 2.68 and later. - -Taken from upstream pull request: -https://github.com/autotrace/autotrace/pull/41 - -diff --git a/src/autotrace.h b/src/autotrace.h ---- a/src/autotrace.h -+++ b/src/autotrace.h -@@ -23,6 +23,9 @@ - - #include <stdio.h> - -+#include "types.h" -+#include "color.h" -+ - #ifdef __cplusplus - extern "C" { - #endif /* __cplusplus */ -@@ -35,9 +38,6 @@ extern "C" { - * Typedefs - * ===================================================================== */ - --#include "types.h" --#include "color.h" -- - /* Third degree is the highest we deal with. */ - enum _at_polynomial_degree { - AT_LINEARTYPE = 1, -diff --git a/src/color.h b/src/color.h ---- a/src/color.h -+++ b/src/color.h -@@ -24,6 +24,10 @@ - #include <glib.h> - #include <glib-object.h> - -+#ifdef __cplusplus -+extern "C" { -+#endif /* __cplusplus */ -+ - typedef struct _at_color at_color; - struct _at_color { - guint8 r; -@@ -43,4 +47,7 @@ void at_color_free(at_color * color); - GType at_color_get_type(void); - #define AT_TYPE_COLOR (at_color_get_type ()) - -+#ifdef __cplusplus -+} -+#endif /* __cplusplus */ - #endif /* not AT_COLOR_H */ diff --git a/gnu/packages/patches/bash-completion-directories.patch b/gnu/packages/patches/bash-completion-directories.patch index 021e34653b..a9b88203bd 100644 --- a/gnu/packages/patches/bash-completion-directories.patch +++ b/gnu/packages/patches/bash-completion-directories.patch @@ -4,24 +4,28 @@ up by the dynamic completion loader from there---whether they are part of bash-completion or installed by another package. On Guix systems, we want not only to search within bash-completion's own -directory, but also in the user's profile and in the system profile. +directory, but also in the user's profile and guix home profile, as well +as in the system profile. This is what this patch does. --- a/bash_completion +++ b/bash_completion -@@ -2016,7 +2016,13 @@ complete -F _minimal '' +@@ -2173,7 +2173,15 @@ complete -F _minimal '' __load_completion() { -- local -a dirs=( ${BASH_COMPLETION_USER_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/bash-completion}/completions ) +- local -a dirs=(${BASH_COMPLETION_USER_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/bash-completion}/completions) + local -a dirs=( + ${BASH_COMPLETION_USER_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/bash-completion}/completions -+ "$HOME/.guix-profile/share/bash-completion/completions/$base" -+ "$HOME/.guix-profile/etc/bash_completion.d/$base" -+ "/run/current-system/profile/share/bash-completion/completions/$base" -+ "/run/current-system/profile/etc/bash_completion.d/$base" ) ++ "$HOME/.guix-profile/share/bash-completion/completions" ++ "$HOME/.guix-profile/etc/bash_completion.d" ++ "$HOME/.guix-home/profile/share/bash-completion/completions" ++ "$HOME/.guix-home/profile/etc/bash_completion.d" ++ "/run/current-system/profile/share/bash-completion/completions" ++ "/run/current-system/profile/etc/bash_completion.d" ) + - local OIFS=$IFS IFS=: dir cmd="${1##*/}" compfile + local ifs=$IFS IFS=: dir cmd="${1##*/}" compfile + [[ -n $cmd ]] || return 1 for dir in ${XDG_DATA_DIRS:-/usr/local/share:/usr/share}; do dirs+=( $dir/bash-completion/completions ) diff --git a/gnu/packages/patches/bc-fix-cross-compilation.patch b/gnu/packages/patches/bc-fix-cross-compilation.patch index 14dfecdbde..04f2c92abf 100644 --- a/gnu/packages/patches/bc-fix-cross-compilation.patch +++ b/gnu/packages/patches/bc-fix-cross-compilation.patch @@ -1,15 +1,19 @@ -Patch taken from nix. - -commit fdda59736ddc048cf38a2c7103f4f5d9eeaf995e -Author: Ben Gamari <ben@smart-cactus.org> -Date: Tue Oct 17 10:51:34 2017 -0400 - - Try implementing cross-compilation +Patch adapted from Nix. +Upstream-status: Submitted to bug-bc@gnu.org. diff --git a/bc/Makefile.am b/bc/Makefile.am -index d9d412e..fdef633 100644 +index d9d412e..13f2b1e 100644 --- a/bc/Makefile.am +++ b/bc/Makefile.am +@@ -8,7 +8,7 @@ EXTRA_DIST = bc.h bcdefs.h const.h fix-libmath_h global.h libmath.b proto.h \ + sbc.y + noinst_HEADERS = libmath.h + +-DISTCLEANFILES = sbc sbc.c sbc.h libmath.h ++DISTCLEANFILES = fbc sbc sbc.c sbc.h libmath.h + + MAINTAINERCLEANFILES = Makefile.in bc.c bc.h scan.c \ + bc.y bcdefs.h const.h execute.c fix-libmath_h \ @@ -17,6 +17,7 @@ MAINTAINERCLEANFILES = Makefile.in bc.c bc.h scan.c \ AM_CPPFLAGS = -I$(srcdir) -I$(srcdir)/../h @@ -18,31 +22,36 @@ index d9d412e..fdef633 100644 LIBL = @LEXLIB@ LDADD = $(LIBBC) $(LIBL) @READLINELIB@ -@@ -29,12 +30,20 @@ $(PROGRAMS): libmath.h $(LIBBC) +@@ -29,15 +30,22 @@ $(PROGRAMS): libmath.h $(LIBBC) scan.o: bc.h global.o: libmath.h -+ -+main_host.c : main.c -+ cp $< $@ -fbcOBJ = main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o -+fbcOBJ = $(addsuffix _host,main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o) -+ -+%.o_host : CC:=$(CC_FOR_BUILD) -+ -+%.o_host : %.c -+ $(COMPILE) -c $(CFLAGS) $(INCLUDES) -o $@ $< ++%.o_host: CC := $(CC_FOR_BUILD) ++%.o_host: %.c ++ $(COMPILE) -c -o $@ $< -libmath.h: libmath.b $(fbcOBJ) $(LIBBC) -+libmath.h: libmath.b $(fbcOBJ) $(LIBBC_HOST) - echo '{0}' > libmath.h +- echo '{0}' > libmath.h - $(MAKE) global.o - $(LINK) -o fbc $(fbcOBJ) global.o $(LIBBC) $(LIBL) $(READLINELIB) $(LIBS) -+ $(MAKE) global.o_host -+ $(CC_FOR_BUILD) -o fbc $(fbcOBJ) global.o_host $(LIBBC_HOST) $(LIBL) ${READLINELIB} $(LIBS) - ./fbc -c $(srcdir)/libmath.b </dev/null >libmath.h +- ./fbc -c $(srcdir)/libmath.b </dev/null >libmath.h ++fbcOBJ = $(addsuffix _host,\ ++ main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o) ++ ++global_host.c: global.c ++ sed 's/#include "libmath.h"/{0}/' $< > $@ ++ ++fbc: $(fbcOBJ) global_host.o_host $(LIBBC_HOST) $(LIBS) ++ $(CC_FOR_BUILD) $(LIBL) $(READLINELIB) -o $@ $^ ++ ++libmath.h: libmath.b fbc $(LIBBC_HOST) ++ ./fbc -c $(srcdir)/libmath.b < /dev/null > libmath.h $(srcdir)/fix-libmath_h - rm -f ./fbc ./global.o +- rm -f ./fbc ./global.o + + sbcOBJ = main.o sbc.o scan.o execute.o global.o load.o storage.o util.o \ + warranty.o diff --git a/configure.ac b/configure.ac index fc74573..5cabb73 100644 --- a/configure.ac @@ -64,7 +73,7 @@ index fc74573..5cabb73 100644 AM_PROG_LEX diff --git a/lib/Makefile.am b/lib/Makefile.am -index ec4bf59..c670f5b 100644 +index ec4bf59..24c9f42 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1,5 +1,5 @@ @@ -74,14 +83,23 @@ index ec4bf59..c670f5b 100644 AM_CPPFLAGS = -I. -I.. -I$(srcdir)/../h -@@ -24,3 +24,11 @@ testmul: testmul.o number.o +@@ -7,8 +7,6 @@ libbc_a_SOURCES = getopt.c getopt1.c vfprintf.c number.c + + DEFS = @DEFS@ $(DEFSADD) + +-AM_CFLAGS = @CFLAGS@ +- + MAINTAINERCLEANFILES = Makefile.in number.c + CLEANFILES = testmul specialnumber muldigits.h + +@@ -24,3 +22,11 @@ testmul: testmul.o number.o specialnumber: newnumber.o cp newnumber.o number.o + -+%.o_host : CC:=$(CC_FOR_BUILD) ++%.o_host: CC := $(CC_FOR_BUILD) +%.o_host : %.c -+ $(COMPILE) -c $(CFLAGS) $(INCLUDES) -o $@ $< ++ $(COMPILE) -c -o $@ $< + +libbc_host.a : $(addsuffix _host,$(libbc_a_OBJECTS)) + ar cru $@ $+ diff --git a/gnu/packages/patches/binutils-2.37-file-descriptor-leak.patch b/gnu/packages/patches/binutils-2.37-file-descriptor-leak.patch deleted file mode 100644 index 1fd3d3d9b7..0000000000 --- a/gnu/packages/patches/binutils-2.37-file-descriptor-leak.patch +++ /dev/null @@ -1,231 +0,0 @@ -From 1c611b40e6bfc8029bff7696814330b5bc0ee5c0 Mon Sep 17 00:00:00 2001 -From: "H.J. Lu" <hjl.tools@gmail.com> -Date: Mon, 26 Jul 2021 05:59:55 -0700 -Subject: [PATCH] bfd: Close the file descriptor if there is no archive fd - -Close the file descriptor if there is no archive plugin file descriptor -to avoid running out of file descriptors on thin archives with many -archive members. - -bfd/ - - PR ld/28138 - * plugin.c (bfd_plugin_close_file_descriptor): Close the file - descriptor there is no archive plugin file descriptor. - -ld/ - - PR ld/28138 - * testsuite/ld-plugin/lto.exp: Run tmpdir/pr28138 only for - native build. - - PR ld/28138 - * testsuite/ld-plugin/lto.exp: Run ld/28138 tests. - * testsuite/ld-plugin/pr28138.c: New file. - * testsuite/ld-plugin/pr28138-1.c: Likewise. - * testsuite/ld-plugin/pr28138-2.c: Likewise. - * testsuite/ld-plugin/pr28138-3.c: Likewise. - * testsuite/ld-plugin/pr28138-4.c: Likewise. - * testsuite/ld-plugin/pr28138-5.c: Likewise. - * testsuite/ld-plugin/pr28138-6.c: Likewise. - * testsuite/ld-plugin/pr28138-7.c: Likewise. - -(cherry picked from commit 5a98fb7513b559e20dfebdbaa2a471afda3b4742) -(cherry picked from commit 7dc37e1e1209c80e0bab784df6b6bac335e836f2) ---- - bfd/plugin.c | 8 +++++++ - ld/testsuite/ld-plugin/lto.exp | 34 ++++++++++++++++++++++++++++++ - ld/testsuite/ld-plugin/pr28138-1.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-2.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-3.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-4.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-5.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-6.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138-7.c | 6 ++++++ - ld/testsuite/ld-plugin/pr28138.c | 20 ++++++++++++++++++ - 10 files changed, 104 insertions(+) - create mode 100644 ld/testsuite/ld-plugin/pr28138-1.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-2.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-3.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-4.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-5.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-6.c - create mode 100644 ld/testsuite/ld-plugin/pr28138-7.c - create mode 100644 ld/testsuite/ld-plugin/pr28138.c - -diff --git a/bfd/plugin.c b/bfd/plugin.c -index 6cfa2b66470..3bab8febe88 100644 ---- a/bfd/plugin.c -+++ b/bfd/plugin.c -@@ -291,6 +291,14 @@ bfd_plugin_close_file_descriptor (bfd *abfd, int fd) - && !bfd_is_thin_archive (abfd->my_archive)) - abfd = abfd->my_archive; - -+ /* Close the file descriptor if there is no archive plugin file -+ descriptor. */ -+ if (abfd->archive_plugin_fd == -1) -+ { -+ close (fd); -+ return; -+ } -+ - abfd->archive_plugin_fd_open_count--; - /* Dup the archive plugin file descriptor for later use, which - will be closed by _bfd_archive_close_and_cleanup. */ -diff --git a/ld/testsuite/ld-plugin/lto.exp b/ld/testsuite/ld-plugin/lto.exp -index def69e43ab3..999d911ce6a 100644 ---- a/ld/testsuite/ld-plugin/lto.exp -+++ b/ld/testsuite/ld-plugin/lto.exp -@@ -687,6 +687,40 @@ if { [is_elf_format] && [check_lto_shared_available] } { - } - } - -+run_cc_link_tests [list \ -+ [list \ -+ "Build pr28138.a" \ -+ "-T" "" \ -+ {pr28138-1.c pr28138-2.c pr28138-3.c pr28138-4.c pr28138-5.c \ -+ pr28138-6.c pr28138-7.c} {} "pr28138.a" \ -+ ] \ -+ [list \ -+ "Build pr28138.o" \ -+ "" "" \ -+ {pr28138.c} {} \ -+ ] \ -+] -+ -+set exec_output [run_host_cmd "sh" \ -+ "-c \"ulimit -n 20; \ -+ $CC -Btmpdir/ld -o tmpdir/pr28138 \ -+ tmpdir/pr28138.o tmpdir/pr28138.a\""] -+set exec_output [prune_warnings $exec_output] -+if [string match "" $exec_output] then { -+ if { [isnative] } { -+ set exec_output [run_host_cmd "tmpdir/pr28138" ""] -+ if [string match "PASS" $exec_output] then { -+ pass "PR ld/28138" -+ } else { -+ fail "PR ld/28138" -+ } -+ } else { -+ pass "PR ld/28138" -+ } -+} else { -+ fail "PR ld/28138" -+} -+ - set testname "Build liblto-11.a" - remote_file host delete "tmpdir/liblto-11.a" - set catch_output [run_host_cmd "$ar" "rc $plug_opt tmpdir/liblto-11.a tmpdir/lto-11a.o tmpdir/lto-11b.o tmpdir/lto-11c.o"] -diff --git a/ld/testsuite/ld-plugin/pr28138-1.c b/ld/testsuite/ld-plugin/pr28138-1.c -new file mode 100644 -index 00000000000..51d119e1642 ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-1.c -@@ -0,0 +1,6 @@ -+extern int a0(void); -+int -+a1(void) -+{ -+ return 1 + a0(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-2.c b/ld/testsuite/ld-plugin/pr28138-2.c -new file mode 100644 -index 00000000000..1120cd797e9 ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-2.c -@@ -0,0 +1,6 @@ -+extern int a1(void); -+int -+a2(void) -+{ -+ return 1 + a1(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-3.c b/ld/testsuite/ld-plugin/pr28138-3.c -new file mode 100644 -index 00000000000..ec464947ee6 ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-3.c -@@ -0,0 +1,6 @@ -+extern int a2(void); -+int -+a3(void) -+{ -+ return 1 + a2(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-4.c b/ld/testsuite/ld-plugin/pr28138-4.c -new file mode 100644 -index 00000000000..475701b2c5c ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-4.c -@@ -0,0 +1,6 @@ -+extern int a3(void); -+int -+a4(void) -+{ -+ return 1 + a3(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-5.c b/ld/testsuite/ld-plugin/pr28138-5.c -new file mode 100644 -index 00000000000..e24f86c363e ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-5.c -@@ -0,0 +1,6 @@ -+extern int a4(void); -+int -+a5(void) -+{ -+ return 1 + a4(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-6.c b/ld/testsuite/ld-plugin/pr28138-6.c -new file mode 100644 -index 00000000000..b5b938bdb21 ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-6.c -@@ -0,0 +1,6 @@ -+extern int a5(void); -+int -+a6(void) -+{ -+ return 1 + a5(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138-7.c b/ld/testsuite/ld-plugin/pr28138-7.c -new file mode 100644 -index 00000000000..4ef75bf0f0c ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138-7.c -@@ -0,0 +1,6 @@ -+extern int a6(void); -+int -+a7(void) -+{ -+ return 1 + a6(); -+} -diff --git a/ld/testsuite/ld-plugin/pr28138.c b/ld/testsuite/ld-plugin/pr28138.c -new file mode 100644 -index 00000000000..68252c9f382 ---- /dev/null -+++ b/ld/testsuite/ld-plugin/pr28138.c -@@ -0,0 +1,20 @@ -+#include <stdio.h> -+ -+extern int a7(void); -+ -+int -+a0(void) -+{ -+ return 0; -+} -+ -+int -+main() -+{ -+ if (a7() == 7) -+ { -+ printf ("PASS\n"); -+ return 0; -+ } -+ return 1; -+} --- -2.27.0 diff --git a/gnu/packages/patches/binutils-CVE-2021-45078.patch b/gnu/packages/patches/binutils-CVE-2021-45078.patch deleted file mode 100644 index fca692bdb5..0000000000 --- a/gnu/packages/patches/binutils-CVE-2021-45078.patch +++ /dev/null @@ -1,257 +0,0 @@ -Fix CVE-2021-45078 (incomplete fix for CVE-2018-12699): - -https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-45078 -https://sourceware.org/bugzilla/show_bug.cgi?id=28694 - -Patch copied from upstream source repository: - -https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=161e87d12167b1e36193385485c1f6ce92f74f02 - -From 161e87d12167b1e36193385485c1f6ce92f74f02 Mon Sep 17 00:00:00 2001 -From: Alan Modra <amodra@gmail.com> -Date: Wed, 15 Dec 2021 11:48:42 +1030 -Subject: [PATCH] PR28694, Out-of-bounds write in stab_xcoff_builtin_type - - PR 28694 - * stabs.c (stab_xcoff_builtin_type): Make typenum unsigned. - Negate typenum earlier, simplifying bounds checking. Correct - off-by-one indexing. Adjust switch cases. ---- - binutils/stabs.c | 87 ++++++++++++++++++++++++------------------------ - 1 file changed, 43 insertions(+), 44 deletions(-) - -diff --git a/binutils/stabs.c b/binutils/stabs.c -index 274bfb0e7fa..83ee3ea5fa4 100644 ---- a/binutils/stabs.c -+++ b/binutils/stabs.c -@@ -202,7 +202,7 @@ static debug_type stab_find_type (void *, struct stab_handle *, const int *); - static bool stab_record_type - (void *, struct stab_handle *, const int *, debug_type); - static debug_type stab_xcoff_builtin_type -- (void *, struct stab_handle *, int); -+ (void *, struct stab_handle *, unsigned int); - static debug_type stab_find_tagged_type - (void *, struct stab_handle *, const char *, int, enum debug_type_kind); - static debug_type *stab_demangle_argtypes -@@ -3496,166 +3496,167 @@ stab_record_type (void *dhandle ATTRIBUTE_UNUSED, struct stab_handle *info, - - static debug_type - stab_xcoff_builtin_type (void *dhandle, struct stab_handle *info, -- int typenum) -+ unsigned int typenum) - { - debug_type rettype; - const char *name; - -- if (typenum >= 0 || typenum < -XCOFF_TYPE_COUNT) -+ typenum = -typenum - 1; -+ if (typenum >= XCOFF_TYPE_COUNT) - { -- fprintf (stderr, _("Unrecognized XCOFF type %d\n"), typenum); -+ fprintf (stderr, _("Unrecognized XCOFF type %d\n"), -typenum - 1); - return DEBUG_TYPE_NULL; - } -- if (info->xcoff_types[-typenum] != NULL) -- return info->xcoff_types[-typenum]; -+ if (info->xcoff_types[typenum] != NULL) -+ return info->xcoff_types[typenum]; - -- switch (-typenum) -+ switch (typenum) - { -- case 1: -+ case 0: - /* The size of this and all the other types are fixed, defined - by the debugging format. */ - name = "int"; - rettype = debug_make_int_type (dhandle, 4, false); - break; -- case 2: -+ case 1: - name = "char"; - rettype = debug_make_int_type (dhandle, 1, false); - break; -- case 3: -+ case 2: - name = "short"; - rettype = debug_make_int_type (dhandle, 2, false); - break; -- case 4: -+ case 3: - name = "long"; - rettype = debug_make_int_type (dhandle, 4, false); - break; -- case 5: -+ case 4: - name = "unsigned char"; - rettype = debug_make_int_type (dhandle, 1, true); - break; -- case 6: -+ case 5: - name = "signed char"; - rettype = debug_make_int_type (dhandle, 1, false); - break; -- case 7: -+ case 6: - name = "unsigned short"; - rettype = debug_make_int_type (dhandle, 2, true); - break; -- case 8: -+ case 7: - name = "unsigned int"; - rettype = debug_make_int_type (dhandle, 4, true); - break; -- case 9: -+ case 8: - name = "unsigned"; - rettype = debug_make_int_type (dhandle, 4, true); - break; -- case 10: -+ case 9: - name = "unsigned long"; - rettype = debug_make_int_type (dhandle, 4, true); - break; -- case 11: -+ case 10: - name = "void"; - rettype = debug_make_void_type (dhandle); - break; -- case 12: -+ case 11: - /* IEEE single precision (32 bit). */ - name = "float"; - rettype = debug_make_float_type (dhandle, 4); - break; -- case 13: -+ case 12: - /* IEEE double precision (64 bit). */ - name = "double"; - rettype = debug_make_float_type (dhandle, 8); - break; -- case 14: -+ case 13: - /* This is an IEEE double on the RS/6000, and different machines - with different sizes for "long double" should use different - negative type numbers. See stabs.texinfo. */ - name = "long double"; - rettype = debug_make_float_type (dhandle, 8); - break; -- case 15: -+ case 14: - name = "integer"; - rettype = debug_make_int_type (dhandle, 4, false); - break; -- case 16: -+ case 15: - name = "boolean"; - rettype = debug_make_bool_type (dhandle, 4); - break; -- case 17: -+ case 16: - name = "short real"; - rettype = debug_make_float_type (dhandle, 4); - break; -- case 18: -+ case 17: - name = "real"; - rettype = debug_make_float_type (dhandle, 8); - break; -- case 19: -+ case 18: - /* FIXME */ - name = "stringptr"; - rettype = NULL; - break; -- case 20: -+ case 19: - /* FIXME */ - name = "character"; - rettype = debug_make_int_type (dhandle, 1, true); - break; -- case 21: -+ case 20: - name = "logical*1"; - rettype = debug_make_bool_type (dhandle, 1); - break; -- case 22: -+ case 21: - name = "logical*2"; - rettype = debug_make_bool_type (dhandle, 2); - break; -- case 23: -+ case 22: - name = "logical*4"; - rettype = debug_make_bool_type (dhandle, 4); - break; -- case 24: -+ case 23: - name = "logical"; - rettype = debug_make_bool_type (dhandle, 4); - break; -- case 25: -+ case 24: - /* Complex type consisting of two IEEE single precision values. */ - name = "complex"; - rettype = debug_make_complex_type (dhandle, 8); - break; -- case 26: -+ case 25: - /* Complex type consisting of two IEEE double precision values. */ - name = "double complex"; - rettype = debug_make_complex_type (dhandle, 16); - break; -- case 27: -+ case 26: - name = "integer*1"; - rettype = debug_make_int_type (dhandle, 1, false); - break; -- case 28: -+ case 27: - name = "integer*2"; - rettype = debug_make_int_type (dhandle, 2, false); - break; -- case 29: -+ case 28: - name = "integer*4"; - rettype = debug_make_int_type (dhandle, 4, false); - break; -- case 30: -+ case 29: - /* FIXME */ - name = "wchar"; - rettype = debug_make_int_type (dhandle, 2, false); - break; -- case 31: -+ case 30: - name = "long long"; - rettype = debug_make_int_type (dhandle, 8, false); - break; -- case 32: -+ case 31: - name = "unsigned long long"; - rettype = debug_make_int_type (dhandle, 8, true); - break; -- case 33: -+ case 32: - name = "logical*8"; - rettype = debug_make_bool_type (dhandle, 8); - break; -- case 34: -+ case 33: - name = "integer*8"; - rettype = debug_make_int_type (dhandle, 8, false); - break; -@@ -3664,9 +3665,7 @@ stab_xcoff_builtin_type (void *dhandle, struct stab_handle *info, - } - - rettype = debug_name_type (dhandle, name, rettype); -- -- info->xcoff_types[-typenum] = rettype; -- -+ info->xcoff_types[typenum] = rettype; - return rettype; - } - --- -2.27.0 - diff --git a/gnu/packages/patches/camlboot-dynamically-allocate-stack-signal.patch b/gnu/packages/patches/camlboot-dynamically-allocate-stack-signal.patch new file mode 100644 index 0000000000..d27232214b --- /dev/null +++ b/gnu/packages/patches/camlboot-dynamically-allocate-stack-signal.patch @@ -0,0 +1,52 @@ +From 883d68803d17d6f64cdabf2c8ef846345e2d0094 Mon Sep 17 00:00:00 2001 +From: Julien Lepiller <julien@lepiller.eu> +Date: Sun, 19 Feb 2023 10:20:19 +0100 +Subject: [PATCH] Dynamically allocate the alternate signal stack. + +This patch is a backport of https://github.com/ocaml/ocaml/pull/10266. +--- + ocaml-src/asmrun/signals_asm.c | 19 +++++++++++-------- + 1 file changed, 11 insertions(+), 8 deletions(-) + +diff --git a/ocaml-src/asmrun/signals_asm.c b/ocaml-src/asmrun/signals_asm.c +index 3895d75..d37b481 100644 +--- a/ocaml-src/asmrun/signals_asm.c ++++ b/ocaml-src/asmrun/signals_asm.c +@@ -182,7 +182,6 @@ DECLARE_SIGNAL_HANDLER(trap_handler) + #ifdef HAS_STACK_OVERFLOW_DETECTION + + static char * system_stack_top; +-static char sig_alt_stack[SIGSTKSZ]; + + #if defined(SYS_linux) + /* PR#4746: recent Linux kernels with support for stack randomization +@@ -274,15 +273,19 @@ void caml_init_signals(void) + #ifdef HAS_STACK_OVERFLOW_DETECTION + { + stack_t stk; +- struct sigaction act; +- stk.ss_sp = sig_alt_stack; ++ stk.ss_sp = malloc(SIGSTKSZ); + stk.ss_size = SIGSTKSZ; + stk.ss_flags = 0; +- SET_SIGACT(act, segv_handler); +- act.sa_flags |= SA_ONSTACK | SA_NODEFER; +- sigemptyset(&act.sa_mask); +- system_stack_top = (char *) &act; +- if (sigaltstack(&stk, NULL) == 0) { sigaction(SIGSEGV, &act, NULL); } ++ if (stk.ss_sp != NULL) { ++ if (sigaltstack(&stk, NULL) != -1) { ++ struct sigaction act; ++ SET_SIGACT(act, segv_handler); ++ act.sa_flags |= SA_ONSTACK | SA_NODEFER; ++ sigemptyset(&act.sa_mask); ++ system_stack_top = (char *) &act; ++ sigaction(SIGSEGV, &act, NULL); ++ } ++ } + } + #endif + } +-- +2.38.1 + diff --git a/gnu/packages/patches/cmake-curl-certificates.patch b/gnu/packages/patches/cmake-curl-certificates.patch deleted file mode 100644 index 7fe2615271..0000000000 --- a/gnu/packages/patches/cmake-curl-certificates.patch +++ /dev/null @@ -1,40 +0,0 @@ -By default commands such as "ctest" would not look for certificates -at all: <https://issues.guix.gnu.org/issue/37371>. - -This changes CMake such that commands honor SSL_CERT_FILE and SSL_CERT_DIR -as well as /etc/ssl/certs. - ---- cmake-3.13.1/Source/cmCurl.cxx 2019-09-10 17:27:36.926907260 +0200 -+++ cmake-3.13.1/Source/cmCurl.cxx 2019-09-10 17:52:35.475903919 +0200 -@@ -2,11 +2,8 @@ - file Copyright.txt or https://cmake.org/licensing for details. */ - #include "cmCurl.h" - --#if !defined(CMAKE_USE_SYSTEM_CURL) && !defined(_WIN32) && \ -- !defined(__APPLE__) && !defined(CURL_CA_BUNDLE) && !defined(CURL_CA_PATH) - # define CMAKE_FIND_CAFILE - # include "cmSystemTools.h" --#endif - #include "cmStringAlgorithms.h" - - // curl versions before 7.21.5 did not provide this error code -@@ -30,6 +27,19 @@ - ::CURLcode res = ::curl_easy_setopt(curl, CURLOPT_CAINFO, cafile); - check_curl_result(res, "Unable to set TLS/SSL Verify CAINFO: "); - } -+ -+ /* Honor the usual environment variables. */ -+ else if (cmSystemTools::GetEnv("SSL_CERT_FILE", e)) { -+ ::CURLcode res = -+ ::curl_easy_setopt(curl, CURLOPT_CAINFO, e.c_str()); -+ check_curl_result(res, "Unable to set TLS/SSL Verify CAINFO: "); -+ } -+ else if (cmSystemTools::GetEnv("SSL_CERT_DIR", e)) { -+ ::CURLcode res = -+ ::curl_easy_setopt(curl, CURLOPT_CAPATH, e.c_str()); -+ check_curl_result(res, "Unable to set TLS/SSL Verify CAINFO: "); -+ } -+ - #ifdef CMAKE_FIND_CAFILE - # define CMAKE_CAFILE_FEDORA "/etc/pki/tls/certs/ca-bundle.crt" - else if (cmSystemTools::FileExists(CMAKE_CAFILE_FEDORA, true)) { diff --git a/gnu/packages/patches/coreutils-ls.patch b/gnu/packages/patches/coreutils-ls.patch deleted file mode 100644 index 59cbbf00b5..0000000000 --- a/gnu/packages/patches/coreutils-ls.patch +++ /dev/null @@ -1,117 +0,0 @@ -Patch taken from upstream to fix cross-compilation for aarch64. This can be -removed on the next coreutils release. - -From 10fcb97bd728f09d4a027eddf8ad2900f0819b0a Mon Sep 17 00:00:00 2001 -From: Paul Eggert <eggert@cs.ucla.edu> -Date: Thu, 5 Mar 2020 17:25:29 -0800 -Subject: [PATCH] ls: restore 8.31 behavior on removed directories - -* NEWS: Mention this. -* src/ls.c: Do not include <sys/sycall.h> -(print_dir): Don't worry about whether the directory is removed. -* tests/ls/removed-directory.sh: Adjust to match new (i.e., old) -behavior. ---- - NEWS | 6 ++++++ - src/ls.c | 22 ---------------------- - tests/ls/removed-directory.sh | 10 ++-------- - 3 files changed, 8 insertions(+), 30 deletions(-) - -diff --git a/NEWS b/NEWS -index fdc8bf5db..653e7178b 100644 ---- a/NEWS -+++ b/NEWS -@@ -2,6 +2,12 @@ GNU coreutils NEWS -*- outline -*- - - * Noteworthy changes in release ?.? (????-??-??) [?] - -+** Changes in behavior -+ -+ On GNU/Linux systems, ls no longer issues an error message on -+ directory merely because it was removed. This reverts a change -+ that was made in release 8.32. -+ - - * Noteworthy changes in release 8.32 (2020-03-05) [stable] - -diff --git a/src/ls.c b/src/ls.c -index 24b983287..4acf5f44d 100644 ---- a/src/ls.c -+++ b/src/ls.c -@@ -49,10 +49,6 @@ - # include <sys/ptem.h> - #endif - --#ifdef __linux__ --# include <sys/syscall.h> --#endif -- - #include <stdio.h> - #include <assert.h> - #include <setjmp.h> -@@ -2896,7 +2892,6 @@ print_dir (char const *name, char const *realname, bool command_line_arg) - struct dirent *next; - uintmax_t total_blocks = 0; - static bool first = true; -- bool found_any_entries = false; - - errno = 0; - dirp = opendir (name); -@@ -2972,7 +2967,6 @@ print_dir (char const *name, char const *realname, bool command_line_arg) - next = readdir (dirp); - if (next) - { -- found_any_entries = true; - if (! file_ignored (next->d_name)) - { - enum filetype type = unknown; -@@ -3018,22 +3012,6 @@ print_dir (char const *name, char const *realname, bool command_line_arg) - if (errno != EOVERFLOW) - break; - } --#ifdef __linux__ -- else if (! found_any_entries) -- { -- /* If readdir finds no directory entries at all, not even "." or -- "..", then double check that the directory exists. */ -- if (syscall (SYS_getdents, dirfd (dirp), NULL, 0) == -1 -- && errno != EINVAL) -- { -- /* We exclude EINVAL as that pertains to buffer handling, -- and we've passed NULL as the buffer for simplicity. -- ENOENT is returned if appropriate before buffer handling. */ -- file_failure (command_line_arg, _("reading directory %s"), name); -- } -- break; -- } --#endif - else - break; - -diff --git a/tests/ls/removed-directory.sh b/tests/ls/removed-directory.sh -index e8c835dab..fe8f929a1 100755 ---- a/tests/ls/removed-directory.sh -+++ b/tests/ls/removed-directory.sh -@@ -26,20 +26,14 @@ case $host_triplet in - *) skip_ 'non linux kernel' ;; - esac - --LS_FAILURE=2 -- --cat <<\EOF >exp-err || framework_failure_ --ls: reading directory '.': No such file or directory --EOF -- - cwd=$(pwd) - mkdir d || framework_failure_ - cd d || framework_failure_ - rmdir ../d || framework_failure_ - --returns_ $LS_FAILURE ls >../out 2>../err || fail=1 -+ls >../out 2>../err || fail=1 - cd "$cwd" || framework_failure_ - compare /dev/null out || fail=1 --compare exp-err err || fail=1 -+compare /dev/null err || fail=1 - - Exit $fail diff --git a/gnu/packages/patches/curl-easy-lock.patch b/gnu/packages/patches/curl-easy-lock.patch deleted file mode 100644 index 137106f57c..0000000000 --- a/gnu/packages/patches/curl-easy-lock.patch +++ /dev/null @@ -1,31 +0,0 @@ -This patch is taken from upstream master, and should probably be dropped -with the next release. - -ihttps://github.com/curl/curl/commit/e2e7f54b7bea521fa8373095d0f43261a720cda0.patch - -From e2e7f54b7bea521fa8373095d0f43261a720cda0 Mon Sep 17 00:00:00 2001 -From: Daniel Stenberg <daniel@haxx.se> -Date: Mon, 27 Jun 2022 08:46:21 +0200 -Subject: [PATCH] easy_lock.h: include sched.h if available to fix build - -Patched-by: Harry Sintonen - -Closes #9054 ---- - lib/easy_lock.h | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/lib/easy_lock.h b/lib/easy_lock.h -index 819f50ce815b8..1f54289ceb2d3 100644 ---- a/lib/easy_lock.h -+++ b/lib/easy_lock.h -@@ -36,6 +36,9 @@ - - #elif defined (HAVE_ATOMIC) - #include <stdatomic.h> -+#if defined(HAVE_SCHED_YIELD) -+#include <sched.h> -+#endif - - #define curl_simple_lock atomic_bool - #define CURL_SIMPLE_LOCK_INIT false diff --git a/gnu/packages/patches/cyrus-sasl-CVE-2019-19906.patch b/gnu/packages/patches/cyrus-sasl-CVE-2019-19906.patch deleted file mode 100644 index acdf682430..0000000000 --- a/gnu/packages/patches/cyrus-sasl-CVE-2019-19906.patch +++ /dev/null @@ -1,25 +0,0 @@ -From dcc9f51cbd4ed622cfb0f9b1c141eb2ffe3b12f1 Mon Sep 17 00:00:00 2001 -From: Quanah Gibson-Mount <quanah@symas.com> -Date: Tue, 18 Feb 2020 19:05:12 +0000 -Subject: [PATCH] Fix #587 - -Off by one error in common.c, CVE-2019-19906. - -Thanks to Stephan Zeisberg for reporting ---- - lib/common.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/lib/common.c b/lib/common.c -index bc3bf1df..9969d6aa 100644 ---- a/lib/common.c -+++ b/lib/common.c -@@ -190,7 +190,7 @@ int _sasl_add_string(char **out, size_t *alloclen, - - if (add==NULL) add = "(null)"; - -- addlen=strlen(add); /* only compute once */ -+ addlen=strlen(add)+1; /* only compute once */ - if (_buf_alloc(out, alloclen, (*outlen)+addlen)!=SASL_OK) - return SASL_NOMEM; - diff --git a/gnu/packages/patches/emacs-xelb-ignore-length-element.patch b/gnu/packages/patches/emacs-xelb-ignore-length-element.patch new file mode 100644 index 0000000000..48c3e35155 --- /dev/null +++ b/gnu/packages/patches/emacs-xelb-ignore-length-element.patch @@ -0,0 +1,19 @@ +Work around build failure due to XCB "length" element. +Patch from <https://sources.debian.org/patches/xelb/0.18-4/>. + +Author: Martin <debacle@debian.org> +Bug: https://github.com/ch11ng/xelb/issues/28 +Bug-Debian: https://bugs.debian.org/1017294 + +--- +--- a/el_client.el ++++ b/el_client.el +@@ -519,7 +519,7 @@ + (`list (xelb-parse-list node)) + (`exprfield (xelb-parse-exprfield node)) + (`switch (xelb-parse-switch node)) +- ((or `comment `doc)) ;simply ignored ++ ((or `comment `doc `length)) ;simply ignored + (x (error "Unsupported structure content: <%s>" x)))) + + ;; The car of the result shall be renamed to prevent duplication of slot names diff --git a/gnu/packages/patches/freeimage-libtiff-compat.patch b/gnu/packages/patches/freeimage-libtiff-compat.patch new file mode 100644 index 0000000000..00c5bf659a --- /dev/null +++ b/gnu/packages/patches/freeimage-libtiff-compat.patch @@ -0,0 +1,19 @@ +Use the new TIFFFieldSetGetSize API from libtiff 4.4 instead of the +private and removed _TIFFDataSize declared in the unbundling patch. + +Patch taken from Fedora: + + https://src.fedoraproject.org/rpms/freeimage/blob/rawhide/f/freeimage-libtiff44.patch + +diff -rupN --no-dereference freeimage-svn-r1889-FreeImage-trunk/Source/Metadata/XTIFF.cpp freeimage-svn-r1889-FreeImage-trunk-new/Source/Metadata/XTIFF.cpp +--- freeimage-svn-r1889-FreeImage-trunk/Source/Metadata/XTIFF.cpp 2022-06-23 11:56:32.561043826 +0200 ++++ freeimage-svn-r1889-FreeImage-trunk-new/Source/Metadata/XTIFF.cpp 2022-06-23 11:56:32.764043827 +0200 +@@ -747,7 +747,7 @@ tiff_write_exif_tags(TIFF *tif, TagLib:: + continue; + } + // type of storage may differ (e.g. rationnal array vs float array type) +- if((unsigned)_TIFFDataSize(tif_tag_type) != FreeImage_TagDataWidth(tag_type)) { ++ if((unsigned)TIFFFieldSetGetSize(fld) != FreeImage_TagDataWidth(tag_type)) { + // skip tag or _TIFFmemcpy will fail + continue; + } diff --git a/gnu/packages/patches/gash-utils-ls-test.patch b/gnu/packages/patches/gash-utils-ls-test.patch deleted file mode 100644 index e1dfb9c23b..0000000000 --- a/gnu/packages/patches/gash-utils-ls-test.patch +++ /dev/null @@ -1,25 +0,0 @@ -'ls.scm' monkey-patches (ice-9 getopt-long) to allow it to recognize '-1' -as a valid option. Unfortunately, monkey patching no longer works with -Guile 3.0 due to inlining, so change the test to make do without '-1'. - -diff --git a/tests/core-utils.org b/tests/core-utils.org -index d35ede8..22718e3 100644 ---- a/tests/core-utils.org -+++ b/tests/core-utils.org -@@ -93,14 +93,11 @@ - * ls - :script: - #+begin_src sh -- ls -1 tests/data/star -+ ls tests/data/star - #+end_src - :stdout: - #+begin_example -- 0 -- 1 -- 2 -- 3 -+ 0 1 2 3 - #+end_example - - * test-file diff --git a/gnu/packages/patches/gcc-10-tree-sra-union-handling.patch b/gnu/packages/patches/gcc-10-tree-sra-union-handling.patch new file mode 100644 index 0000000000..aae5fc9f72 --- /dev/null +++ b/gnu/packages/patches/gcc-10-tree-sra-union-handling.patch @@ -0,0 +1,33 @@ +Fix a regression in GCC 10/11/12 where some union structures +could get miscompiled when optimizations are enabled: + + https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105860 + +Taken from upstream: + + https://gcc.gnu.org/g:16afe2e2862f3dd93c711d7f8d436dee23c6c34d + +diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c +index 09d951a261b..420329f63f6 100644 +--- a/gcc/tree-sra.c ++++ b/gcc/tree-sra.c +@@ -1647,7 +1647,18 @@ build_ref_for_offset (location_t loc, tree base, poly_int64 offset, + static tree + build_reconstructed_reference (location_t, tree base, struct access *model) + { +- tree expr = model->expr, prev_expr = NULL; ++ tree expr = model->expr; ++ /* We have to make sure to start just below the outermost union. */ ++ tree start_expr = expr; ++ while (handled_component_p (expr)) ++ { ++ if (TREE_CODE (TREE_TYPE (TREE_OPERAND (expr, 0))) == UNION_TYPE) ++ start_expr = expr; ++ expr = TREE_OPERAND (expr, 0); ++ } ++ ++ expr = start_expr; ++ tree prev_expr = NULL_TREE; + while (!types_compatible_p (TREE_TYPE (expr), TREE_TYPE (base))) + { + if (!handled_component_p (expr)) diff --git a/gnu/packages/patches/gcc-11-libstdc++-hurd-libpthread.patch b/gnu/packages/patches/gcc-11-libstdc++-hurd-libpthread.patch new file mode 100644 index 0000000000..1845583ac5 --- /dev/null +++ b/gnu/packages/patches/gcc-11-libstdc++-hurd-libpthread.patch @@ -0,0 +1,62 @@ +From f0065f207cf19cd960b33d961472c6d69514336f Mon Sep 17 00:00:00 2001 +From: Samuel Thibault <samuel.thibault@gnu.org> +Date: Fri, 7 Oct 2022 22:45:06 +0200 +Subject: [PATCH] libstdc++: Mark pieces of gnu-linux/os_support.h + linux-specific + +This is notably needed because in glibc 2.34, the move of pthread functions +into libc.so happened for Linux only, not GNU/Hurd. + +The pthread_self() function can also always be used fine as it is on +GNU/Hurd. + +libstdc++-v3/ChangeLog: + + * config/os/gnu-linux/os_defines.h [!__linux__] + (_GLIBCXX_NATIVE_THREAD_ID, _GLIBCXX_GTHREAD_USE_WEAK): Do not define. + +Reviewed-by: Jonathan Wakely <jwakely@redhat.com> +--- + libstdc++-v3/config/os/gnu-linux/os_defines.h | 22 +++++++++++-------- + 1 file changed, 13 insertions(+), 9 deletions(-) + +diff --git a/libstdc++-v3/config/os/gnu-linux/os_defines.h b/libstdc++-v3/config/os/gnu-linux/os_defines.h +index 3064f8d908ac2..87317031fcd71 100644 +--- a/libstdc++-v3/config/os/gnu-linux/os_defines.h ++++ b/libstdc++-v3/config/os/gnu-linux/os_defines.h +@@ -60,22 +60,26 @@ + # define _GLIBCXX_HAVE_FLOAT128_MATH 1 + #endif + +-#if __GLIBC_PREREQ(2, 27) ++#ifdef __linux__ ++// The following libpthread properties only apply to Linux, not GNU/Hurd. ++ ++# if __GLIBC_PREREQ(2, 27) + // Since glibc 2.27 pthread_self() is usable without linking to libpthread. +-# define _GLIBCXX_NATIVE_THREAD_ID pthread_self() +-#else ++# define _GLIBCXX_NATIVE_THREAD_ID pthread_self() ++# else + // Before then it was in libc.so.6 but not libc.a, and always returns 0, + // which breaks the invariant this_thread::get_id() != thread::id{}. + // So only use it if we know the libpthread version is available. + // Otherwise use (__gthread_t)1 as the ID of the main (and only) thread. +-# define _GLIBCXX_NATIVE_THREAD_ID \ +- (__gthread_active_p() ? __gthread_self() : (__gthread_t)1) +-#endif ++# define _GLIBCXX_NATIVE_THREAD_ID \ ++ (__gthread_active_p() ? __gthread_self() : (__gthread_t)1) ++# endif + +-#if __GLIBC_PREREQ(2, 34) ++# if __GLIBC_PREREQ(2, 34) + // Since glibc 2.34 all pthreads functions are usable without linking to + // libpthread. +-# define _GLIBCXX_GTHREAD_USE_WEAK 0 +-#endif ++# define _GLIBCXX_GTHREAD_USE_WEAK 0 ++# endif ++#endif // __linux__ + + #endif diff --git a/gnu/packages/patches/gcc-11-libstdc++-powerpc.patch b/gnu/packages/patches/gcc-11-libstdc++-powerpc.patch new file mode 100644 index 0000000000..c0b96c3bc8 --- /dev/null +++ b/gnu/packages/patches/gcc-11-libstdc++-powerpc.patch @@ -0,0 +1,20 @@ +--- a/libstdc++-v3/src/c++17/floating_from_chars.cc ++++ b/libstdc++-v3/src/c++17/floating_from_chars.cc +@@ -495,10 +495,16 @@ + from_chars(const char* first, const char* last, __ieee128& value, + chars_format fmt) noexcept + { ++ errc ec = errc::invalid_argument; ++#if _GLIBCXX_USE_CXX11_ABI + buffer_resource mr; + pmr::string buf(&mr); ++#else ++ string buf; ++ if (!reserve_string(buf)) ++ return make_result(first, 0, {}, ec); ++#endif + size_t len = 0; +- errc ec = errc::invalid_argument; + __try + { + if (const char* pat = pattern(first, last, fmt, buf)) [[likely]] diff --git a/gnu/packages/patches/gdb-fix-gnu-nat-build.patch b/gnu/packages/patches/gdb-fix-gnu-nat-build.patch deleted file mode 100644 index b0249d9cec..0000000000 --- a/gnu/packages/patches/gdb-fix-gnu-nat-build.patch +++ /dev/null @@ -1,254 +0,0 @@ -Fix build on the Hurd. - -Patch #1 taken from upstream - - https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=a1700a3199d31910b87cd7db3c394ddd091cfcde - -Patch #2 taken from upstream mailing list - - https://sourceware.org/pipermail/gdb/2021-November/049777.html - -Patch #3 sent to upstream - - https://sourceware.org/pipermail/gdb/2021-November/049788.html - -From 30d89407ad6bb62fafc72fa9c547c2d7ff371401 Mon Sep 17 00:00:00 2001 -From: Simon Marchi <simon.marchi@polymtl.ca> -Date: Wed, 3 Nov 2021 15:09:19 -0400 -Subject: [PATCH 1/3] gdb: fix gnu-nat build -Content-Transfer-Encoding: 8bit -Content-Type: text/plain; charset=UTF-8 - -When building gnu-nat.c, we get: - - CXX gnu-nat.o - gnu-nat.c: In member function 'virtual void gnu_nat_target::create_inferior(const char*, const string&, char**, int)': - gnu-nat.c:2117:13: error: 'struct inf' has no member named 'target_is_pushed' - 2117 | if (!inf->target_is_pushed (this)) - | ^~~~~~~~~~~~~~~~ - gnu-nat.c:2118:10: error: 'struct inf' has no member named 'push_target' - 2118 | inf->push_target (this); - | ^~~~~~~~~~~ - -This is because of a confusion between the generic `struct inferior` -variable and the gnu-nat-specific `struct inf` variable. Fix by -referring to `inferior`, not `inf`. - -Adjust the comment on top of `struct inf` to clarify the purpose of that -type. - -Co-Authored-By: Andrea Monaco <andrea.monaco@autistici.org> -Change-Id: I2fe2f7f6ef61a38d79860fd262b08835c963fc77 ---- - gdb/gnu-nat.c | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c -index 67ce00e9c30..ab539b4d8b4 100644 ---- a/gdb/gnu-nat.c -+++ b/gdb/gnu-nat.c -@@ -149,7 +149,7 @@ struct inf_wait - int suppress; /* Something trivial happened. */ - }; - --/* The state of an inferior. */ -+/* Further Hurd-specific state of an inferior. */ - struct inf - { - /* Fields describing the current inferior. */ -@@ -2114,8 +2114,8 @@ gnu_nat_target::create_inferior (const char *exec_file, - - inf_debug (inf, "creating inferior"); - -- if (!inf->target_is_pushed (this)) -- inf->push_target (this); -+ if (!inferior->target_is_pushed (this)) -+ inferior->push_target (this); - - pid = fork_inferior (exec_file, allargs, env, gnu_ptrace_me, - NULL, NULL, NULL, NULL); -From ebc0837f4693232f74eb2cc3033515b18a8f0900 Mon Sep 17 00:00:00 2001 -From: "Jan (janneke) Nieuwenhuizen" <janneke@gnu.org> -Date: Mon, 22 Nov 2021 07:47:28 +0100 -Subject: [PATCH 2/3] gdb: gnu-nat.c: port-rights. -Content-Transfer-Encoding: 8bit -Content-Type: text/plain; charset=UTF-8 - -Taken from: - - https://sourceware.org/pipermail/gdb/2021-November/049777.html ---- - gdb/gnu-nat.c | 18 ++++++++++-------- - 1 file changed, 10 insertions(+), 8 deletions(-) - -diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c -index ab539b4d8b4..8cd876b21d0 100644 ---- a/gdb/gnu-nat.c -+++ b/gdb/gnu-nat.c -@@ -3292,15 +3292,17 @@ This is the same as setting `task pause', `exceptions', and\n\ - _("Show information about the task's send rights.")); - add_info ("receive-rights", info_recv_rights_cmd, - _("Show information about the task's receive rights.")); -- add_info ("port-rights", info_port_rights_cmd, -- _("Show information about the task's port rights.")); -- add_info ("port-sets", info_port_sets_cmd, -- _("Show information about the task's port sets.")); -+ cmd_list_element *port_rights_cmd = -+ add_info ("port-rights", info_port_rights_cmd, -+ _("Show information about the task's port rights.")); -+ cmd_list_element *port_sets_cmd = -+ add_info ("port-sets", info_port_sets_cmd, -+ _("Show information about the task's port sets.")); - add_info ("dead-names", info_dead_names_cmd, -- _("Show information about the task's dead names.")); -- add_info_alias ("ports", "port-rights", 1); -- add_info_alias ("port", "port-rights", 1); -- add_info_alias ("psets", "port-sets", 1); -+ _("Show information about the task's dead names.")); -+ add_info_alias ("ports", port_rights_cmd, 1); -+ add_info_alias ("port", port_rights_cmd, 1); -+ add_info_alias ("psets", port_sets_cmd, 1); - } - - -From e8df985cdd95e4808c390e226a0e852d23c502f9 Mon Sep 17 00:00:00 2001 -From: "Jan (janneke) Nieuwenhuizen" <janneke@gnu.org> -Date: Mon, 22 Nov 2021 08:22:15 +0100 -Subject: [PATCH 3/3] gdb: More compile fixes for gnu-nat.c. -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit -Content-Transfer-Encoding: 8bit -Content-Type: text/plain; charset=UTF-8 - -This fixes compile errors like - - ../../gdb-11.1/gdb/gnu-nat.c: In function ‘void add_task_commands()’: - ../../gdb-11.1/gdb/gnu-nat.c:3204:17: error: no matching function for call to ‘add_cmd(const char [8], command_class, cmd_list_element*&, char*, cmd_list_element**)’ - 3204 | &setlist); - | ^ - In file included from ../../gdb-11.1/gdb/completer.h:21, - from ../../gdb-11.1/gdb/symtab.h:36, - from ../../gdb-11.1/gdb/infrun.h:21, - from ../../gdb-11.1/gdb/target.h:42, - from ../../gdb-11.1/gdb/inf-child.h:23, - from ../../gdb-11.1/gdb/gnu-nat.h:38, - from ../../gdb-11.1/gdb/gnu-nat.c:24: - ../../gdb-11.1/gdb/command.h:160:33: note: candidate: ‘cmd_list_element* add_cmd(const char*, command_class, void (*)(const char*, int), const char*, cmd_list_element**)’ - 160 | extern struct cmd_list_element *add_cmd (const char *, enum command_class, - | ^~~~~~~ - ../../gdb-11.1/gdb/command.h:161:30: note: no known conversion for argument 3 from ‘cmd_list_element*’ to ‘void (*)(const char*, int)’ - 161 | cmd_const_cfunc_ftype *fun, - | ~~~~~~~~~~~~~~~~~~~~~~~^~~ - ../../gdb-11.1/gdb/command.h:167:33: note: candidate: ‘cmd_list_element* add_cmd(const char*, command_class, const char*, cmd_list_element**)’ - 167 | extern struct cmd_list_element *add_cmd (const char *, enum command_class, - | ^~~~~~~ - ../../gdb-11.1/gdb/command.h:167:33: note: candidate expects 4 arguments, 5 provided - ../../gdb-11.1/gdb/gnu-nat.c:3210:18: error: no matching function for call to ‘add_cmd(const char [8], command_class, cmd_list_element*&, char*, cmd_list_element**)’ - 3210 | &showlist); - | ^ - -* gdb/gnu-nat.c (add_task_commands): Use a fresh variable instead of -shadowing set_signals_cmd etc. -(add_thread_commands): Likewise. ---- - gdb/gnu-nat.c | 33 +++++++++++++++++---------------- - 1 file changed, 17 insertions(+), 16 deletions(-) - -diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c -index 8cd876b21d0..7aecc2295f8 100644 ---- a/gdb/gnu-nat.c -+++ b/gdb/gnu-nat.c -@@ -3197,31 +3197,31 @@ Show whether new threads are allowed to run (once gdb has noticed them)."), - _("Show the default detach-suspend-count value for new threads."), - &show_thread_default_cmd_list); - -- cmd_list_element *set_signals_cmd -+ cmd_list_element *set_signals_cmd_ - = add_cmd ("signals", class_run, set_signals_cmd, _("\ - Set whether the inferior process's signals will be intercepted.\n\ - Mach exceptions (such as breakpoint traps) are not affected."), - &setlist); -- add_alias_cmd ("sigs", set_signals_cmd, class_run, 1, &setlist); -+ add_alias_cmd ("sigs", set_signals_cmd_, class_run, 1, &setlist); - -- cmd_list_element *show_signals_cmd -+ cmd_list_element *show_signals_cmd_ - = add_cmd ("signals", no_class, show_signals_cmd, _("\ - Show whether the inferior process's signals will be intercepted."), - &showlist); -- add_alias_cmd ("sigs", show_signals_cmd, no_class, 1, &showlist); -+ add_alias_cmd ("sigs", show_signals_cmd_, no_class, 1, &showlist); - -- cmd_list_element *set_signal_thread_cmd -+ cmd_list_element *set_signal_thread_cmd_ - = add_cmd ("signal-thread", class_run, set_sig_thread_cmd, _("\ - Set the thread that gdb thinks is the libc signal thread.\n\ - This thread is run when delivering a signal to a non-stopped process."), - &setlist); -- add_alias_cmd ("sigthread", set_signal_thread_cmd, class_run, 1, &setlist); -+ add_alias_cmd ("sigthread", set_signal_thread_cmd_, class_run, 1, &setlist); - -- cmd_list_element *show_signal_thread_cmd -+ cmd_list_element *show_signal_thread_cmd_ - = add_cmd ("signal-thread", no_class, show_sig_thread_cmd, _("\ - Set the thread that gdb thinks is the libc signal thread."), - &showlist); -- add_alias_cmd ("sigthread", show_signal_thread_cmd, no_class, 1, &showlist); -+ add_alias_cmd ("sigthread", show_signal_thread_cmd_, no_class, 1, &showlist); - - add_cmd ("stopped", class_run, set_stopped_cmd, _("\ - Set whether gdb thinks the inferior process is stopped as with SIGSTOP.\n\ -@@ -3231,13 +3231,13 @@ Stopped process will be continued by sending them a signal."), - Show whether gdb thinks the inferior process is stopped as with SIGSTOP."), - &showlist); - -- cmd_list_element *set_exceptions_cmd -+ cmd_list_element *set_exceptions_cmd_ - = add_cmd ("exceptions", class_run, set_exceptions_cmd, _("\ - Set whether exceptions in the inferior process will be trapped.\n\ - When exceptions are turned off, neither breakpoints nor single-stepping\n\ - will work."), &setlist); - /* Allow `set exc' despite conflict with `set exception-port'. */ -- add_alias_cmd ("exc", set_exceptions_cmd, class_run, 1, &setlist); -+ add_alias_cmd ("exc", set_exceptions_cmd_, class_run, 1, &setlist); - - add_cmd ("exceptions", no_class, show_exceptions_cmd, _("\ - Show whether exceptions in the inferior process will be trapped."), -@@ -3269,14 +3269,14 @@ used to pause individual threads by default instead."), - "on the thread when detaching."), - &show_task_cmd_list); - -- cmd_list_element *set_task_exception_port_cmd -+ cmd_list_element *set_task_exception_port_cmd_ - = add_cmd ("exception-port", no_class, set_task_exc_port_cmd, _("\ - Set the task exception port to which we forward exceptions.\n\ - The argument should be the value of the send right in the task."), - &set_task_cmd_list); -- add_alias_cmd ("excp", set_task_exception_port_cmd, no_class, 1, -+ add_alias_cmd ("excp", set_task_exception_port_cmd_, no_class, 1, - &set_task_cmd_list); -- add_alias_cmd ("exc-port", set_task_exception_port_cmd, no_class, 1, -+ add_alias_cmd ("exc-port", set_task_exception_port_cmd_, no_class, 1, - &set_task_cmd_list); - - /* A convenient way of turning on all options require to noninvasively -@@ -3464,14 +3464,15 @@ Note that this is relative to suspend count when gdb noticed the thread;\n\ - use the `thread takeover-suspend-count' to force it to an absolute value."), - &show_thread_cmd_list); - -- add_cmd ("exception-port", no_class, set_thread_exc_port_cmd, _("\ -+ cmd_list_element *set_thread_exception_port_cmd_ -+ = add_cmd ("exception-port", no_class, set_thread_exc_port_cmd, _("\ - Set the thread exception port to which we forward exceptions.\n\ - This overrides the task exception port.\n\ - The argument should be the value of the send right in the task."), - &set_thread_cmd_list); -- add_alias_cmd ("excp", set_thread_exception_port_cmd, no_class, 1, -+ add_alias_cmd ("excp", set_thread_exception_port_cmd_, no_class, 1, - &set_thread_cmd_list); -- add_alias_cmd ("exc-port", set_thread_exception_port_cmd, no_class, 1, -+ add_alias_cmd ("exc-port", set_thread_exception_port_cmd_, no_class, 1, - &set_thread_cmd_list); - - add_cmd ("takeover-suspend-count", no_class, thread_takeover_sc_cmd, _("\ diff --git a/gnu/packages/patches/gettext-libunicode-update.patch b/gnu/packages/patches/gettext-libunicode-update.patch new file mode 100644 index 0000000000..2a67f4803a --- /dev/null +++ b/gnu/packages/patches/gettext-libunicode-update.patch @@ -0,0 +1,99 @@ +https://git.savannah.gnu.org/gitweb/?p=gettext.git;a=commit;h=56dc658db752c2894861ee574866d507f12a17f8 +Due to the encoding it needs to be retrieved from a git clone. + +commit 56dc658db752c2894861ee574866d507f12a17f8 +Author: Bruno Haible <bruno@clisp.org> +Date: Sun Jan 2 15:43:41 2022 +0100 + + Update after gnulib changed. + + * gettext-tools/tests/msgcat-17: Update test for changed libunistring line + breaking behaviour. + * gettext-tools/tests/msgfilter-sr-latin-1: Likewise. + * gettext-tools/tests/msgmerge-11: Likewise. + * gettext-tools/tests/xgettext-python-1: Likewise. + +diff --git a/gettext-tools/tests/msgcat-17 b/gettext-tools/tests/msgcat-17 +index 8fecc4039..c4aa220b9 100755 +--- a/gettext-tools/tests/msgcat-17 ++++ b/gettext-tools/tests/msgcat-17 +@@ -39,9 +39,9 @@ msgstr "" + #, c-format + msgid "write error of a big result on a too small disk% s% s" + msgstr "" +-"Fehler beim Schreiben eines großen Ergebnisses auf eine zu kleine Platte% s" +-"% smit der jederzeitigen Möglichkeit eines Fehlers in jedem Moment und an " +-"jeder Stelle" ++"Fehler beim Schreiben eines großen Ergebnisses auf eine zu kleine " ++"Platte% s% smit der jederzeitigen Möglichkeit eines Fehlers in jedem Moment " ++"und an jeder Stelle" + EOF + + : ${DIFF=diff} +diff --git a/gettext-tools/tests/msgfilter-sr-latin-1 b/gettext-tools/tests/msgfilter-sr-latin-1 +index c1cc97875..29e68c04f 100755 +--- a/gettext-tools/tests/msgfilter-sr-latin-1 ++++ b/gettext-tools/tests/msgfilter-sr-latin-1 +@@ -20,8 +20,8 @@ msgstr "" + "MIME-Version: 1.0\n" + "Content-Type: text/plain; charset=CP1251\n" + "Content-Transfer-Encoding: 8bit\n" +-"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : (n%10>=2 && n" +-"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" ++"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : (n%10>=2 && " ++"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" + + #: ../gettext-tools/lib/closeout.c:64 + msgid "write error" +@@ -332,8 +332,8 @@ msgstr "" + "MIME-Version: 1.0\n" + "Content-Type: text/plain; charset=UTF-8\n" + "Content-Transfer-Encoding: 8bit\n" +-"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : (n%10>=2 && n" +-"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" ++"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : (n%10>=2 && " ++"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" + + #: ../gettext-tools/lib/closeout.c:64 + msgid "write error" +diff --git a/gettext-tools/tests/msgmerge-11 b/gettext-tools/tests/msgmerge-11 +index ed49db95a..888855940 100755 +--- a/gettext-tools/tests/msgmerge-11 ++++ b/gettext-tools/tests/msgmerge-11 +@@ -19,8 +19,8 @@ msgstr "" + "MIME-Version: 1.0\n" + "Content-Type: text/plain; charset=ISO-8859-1\n" + "Content-Transfer-Encoding: 8bit\n" +-"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n" +-"%100==4 ? 2 : 3);\n" ++"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || " ++"n%100==4 ? 2 : 3);\n" + + #:foobar.c:29 + #, c-format +@@ -72,8 +72,8 @@ msgstr "" + "MIME-Version: 1.0\n" + "Content-Type: text/plain; charset=ISO-8859-1\n" + "Content-Transfer-Encoding: 8bit\n" +-"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n" +-"%100==4 ? 2 : 3);\n" ++"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || " ++"n%100==4 ? 2 : 3);\n" + + #: foobar.c:32 + #, fuzzy, c-format +diff --git a/gettext-tools/tests/xgettext-python-1 b/gettext-tools/tests/xgettext-python-1 +index 4901c71e3..9695abda4 100755 +--- a/gettext-tools/tests/xgettext-python-1 ++++ b/gettext-tools/tests/xgettext-python-1 +@@ -61,8 +61,8 @@ msgstr "" + #. interpret_ansic = false, interpret_unicode = false + msgid "" + "abc\\\n" +-"\\\\def\\'ghi\\\"jkl\\a\\b\\f\\n\\r\\t\\v x\\040x\\x7ey" +-"\\u0142\\U00010123\\N{LATIN SMALL LETTER Z}" ++"\\\\def\\'ghi\\\"jkl\\a\\b\\f\\n\\r\\t\\v " ++"x\\040x\\x7ey\\u0142\\U00010123\\N{LATIN SMALL LETTER Z}" + msgstr "" + + #. interpret_ansic = true, interpret_unicode = true diff --git a/gnu/packages/patches/ghc-9.2-grep-warnings.patch b/gnu/packages/patches/ghc-9.2-grep-warnings.patch new file mode 100644 index 0000000000..7a3d9c599e --- /dev/null +++ b/gnu/packages/patches/ghc-9.2-grep-warnings.patch @@ -0,0 +1,37 @@ +--- ghc-9.2.5/testsuite/tests/numeric/should_run/T7014.primops.orig 2023-03-12 14:42:11.338540492 +0100 ++++ ghc-9.2.5/testsuite/tests/numeric/should_run/T7014.primops 2023-03-12 14:42:13.735608896 +0100 +@@ -1,9 +1,9 @@ + and# + or# + uncheckedShift.*# +++# ++-# ++*# +-\+# +-\-# +-\*# + quotInt# + remInt# + plusFloat# +--- ghc-9.2.5/testsuite/tests/hsc2hs/Makefile.orig 2023-03-12 14:40:03.825939306 +0100 ++++ ghc-9.2.5/testsuite/tests/hsc2hs/Makefile 2023-03-12 14:40:07.961054835 +0100 +@@ -54,7 +54,7 @@ + ifeq "$(WINDOWS)" "YES" + grep '{-# LINE 1 \"T12504\\\\path\\\\to\\\\$@\.hsc\" #-}' T12504/path/to/$@.hs + else ++ grep '{-# LINE 1 "T12504/path/to/$@\.hsc" #-}' T12504/path/to/$@.hs +- grep '{-# LINE 1 \"T12504/path/to/$@\.hsc\" #-}' T12504/path/to/$@.hs + endif + + .PHONY: T15758 +--- ghc-9.2.5/testsuite/tests/simplCore/should_compile/Makefile.orig 2023-03-12 14:41:16.204974035 +0100 ++++ ghc-9.2.5/testsuite/tests/simplCore/should_compile/Makefile 2023-03-12 14:41:17.832020067 +0100 +@@ -253,7 +253,7 @@ + # g should have been collapsed into one defininition by CSE. + .PHONY: T13340 + T13340: ++ '$(TEST_HC)' $(TEST_HC_OPTS) -c -O T13340.hs -ddump-simpl -dsuppress-all | grep -c '+#' +- '$(TEST_HC)' $(TEST_HC_OPTS) -c -O T13340.hs -ddump-simpl -dsuppress-all | grep -c '\+#' + + + # We expect to see all dictionaries specialized away. diff --git a/gnu/packages/patches/ghc-testsuite-grep-compat.patch b/gnu/packages/patches/ghc-testsuite-grep-compat.patch new file mode 100644 index 0000000000..a2bd5fcec4 --- /dev/null +++ b/gnu/packages/patches/ghc-testsuite-grep-compat.patch @@ -0,0 +1,39 @@ +Remove stray escapes to avoid warnings from grep 3.8 which breaks +expected test output. + +diff --git a/testsuite/tests/hsc2hs/Makefile b/testsuite/tests/hsc2hs/Makefile +--- a/testsuite/tests/hsc2hs/Makefile ++++ b/testsuite/tests/hsc2hs/Makefile +@@ -47,5 +47,5 @@ T12504: + ifeq "$(WINDOWS)" "YES" + grep '{-# LINE 1 \"T12504\\\\path\\\\to\\\\$@\.hsc\" #-}' T12504/path/to/$@.hs + else +- grep '{-# LINE 1 \"T12504/path/to/$@\.hsc\" #-}' T12504/path/to/$@.hs ++ grep '{-# LINE 1 "T12504/path/to/$@\.hsc" #-}' T12504/path/to/$@.hs + endif +diff --git a/testsuite/tests/numeric/should_run/T7014.primops b/testsuite/tests/numeric/should_run/T7014.primops +--- a/testsuite/tests/numeric/should_run/T7014.primops ++++ b/testsuite/tests/numeric/should_run/T7014.primops +@@ -1,8 +1,8 @@ + and# + or# + uncheckedShift.*# +-\+# +-\-# +++# ++-# + \*# + quotInt# + remInt# +diff --git a/testsuite/tests/simplCore/should_compile/Makefile b/testsuite/tests/simplCore/should_compile/Makefile +--- a/testsuite/tests/simplCore/should_compile/Makefile ++++ b/testsuite/tests/simplCore/should_compile/Makefile +@@ -226,7 +226,7 @@ str-rules: + # g should have been collapsed into one defininition by CSE. + .PHONY: T13340 + T13340: +- '$(TEST_HC)' $(TEST_HC_OPTS) -c -O T13340.hs -ddump-simpl -dsuppress-all | grep -c '\+#' ++ '$(TEST_HC)' $(TEST_HC_OPTS) -c -O T13340.hs -ddump-simpl -dsuppress-all | grep -c '+#' + + + # We expect to see all dictionaries specialized away. diff --git a/gnu/packages/patches/ghostscript-no-header-creationdate.patch b/gnu/packages/patches/ghostscript-no-header-creationdate.patch index b19f3ab5d9..493693b78d 100644 --- a/gnu/packages/patches/ghostscript-no-header-creationdate.patch +++ b/gnu/packages/patches/ghostscript-no-header-creationdate.patch @@ -6,11 +6,11 @@ not write out the "/ID" field (if that's permissible). Upstream does not want to do this. See: https://bugs.ghostscript.com/show_bug.cgi?id=698208 -diff --git a/orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c b/bb/gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c -index 0fb067e..b342e2c 100644 ---- orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c -+++ gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c -@@ -305,6 +305,9 @@ pdf_initialize_ids(gx_device_pdf * pdev) +diff --git a/devices/vector/gdevpdf.c b/devices/vector/gdevpdf.c +index cb268f62e..c5abefde2 100644 +--- a/devices/vector/gdevpdf.c ++++ b/devices/vector/gdevpdf.c +@@ -425,6 +425,9 @@ pdf_initialize_ids(gx_device_pdf * pdev) * date and time, rather than (for example) %%CreationDate from the * PostScript file. We think this is wrong, but we do the same. */ @@ -20,9 +20,11 @@ index 0fb067e..b342e2c 100644 { struct tm tms; time_t t; ---- orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c -+++ gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c -@@ -692,6 +692,9 @@ +diff --git a/devices/vector/gdevpdfe.c b/devices/vector/gdevpdfe.c +index ec011d8ba..f083f1e93 100644 +--- a/devices/vector/gdevpdfe.c ++++ b/devices/vector/gdevpdfe.c +@@ -696,6 +696,9 @@ pdf_write_document_metadata(gx_device_pdf *pdev, const byte digest[6]) pdf_xml_attribute_name(s, "xmlns:xmp"); pdf_xml_attribute_value(s, "http://ns.adobe.com/xap/1.0/"); pdf_xml_tag_end(s); @@ -32,7 +34,7 @@ index 0fb067e..b342e2c 100644 { pdf_xml_tag_open_beg(s, "xmp:ModifyDate"); pdf_xml_tag_end(s); -@@ -700,6 +701,9 @@ +@@ -704,6 +707,9 @@ pdf_write_document_metadata(gx_device_pdf *pdev, const byte digest[6]) pdf_xml_tag_close(s, "xmp:ModifyDate"); pdf_xml_newline(s); } diff --git a/gnu/packages/patches/ghostscript-no-header-id.patch b/gnu/packages/patches/ghostscript-no-header-id.patch index 45fc95fd6e..ef518b0fb2 100644 --- a/gnu/packages/patches/ghostscript-no-header-id.patch +++ b/gnu/packages/patches/ghostscript-no-header-id.patch @@ -6,38 +6,39 @@ not write out the "/ID" field (if that's permissible). Upstream does not want to do this. See: https://bugs.ghostscript.com/show_bug.cgi?id=698208 -diff -ur orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c ---- orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c 2017-07-09 23:30:28.960479189 +0200 -+++ gnu-ghostscript-9.14.0/devices/vector/gdevpdf.c 2017-07-09 23:34:34.306524488 +0200 -@@ -1810,8 +1810,11 @@ +diff --git a/devices/vector/gdevpdf.c b/devices/vector/gdevpdf.c +index c5abefde2..3859fc088 100644 +--- a/devices/vector/gdevpdf.c ++++ b/devices/vector/gdevpdf.c +@@ -1909,8 +1909,11 @@ static int pdf_linearise(gx_device_pdf *pdev, pdf_linearisation_t *linear_params * +1 for the linearisation dict and +1 for the primary hint stream. */ linear_params->FirsttrailerOffset = gp_ftell(linear_params->Lin_File.file); -- gs_sprintf(LDict, "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R/ID[%s%s]/Prev %d>>\nstartxref\r\n0\n%%%%EOF\n \n", +- gs_snprintf(LDict, sizeof(LDict), "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R/ID[%s%s]/Prev %d>>\nstartxref\r\n0\n%%%%EOF\n \n", - linear_params->LastResource + 3, pdev->ResourceUsage[linear_params->Info_id].NewObjectNumber, pdev->ResourceUsage[linear_params->Catalog_id].NewObjectNumber, fileID, fileID, 0); -+ gs_sprintf(LDict, "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R", ++ gs_snprintf(LDict, sizeof(LDict), "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R", + linear_params->LastResource + 3, pdev->ResourceUsage[linear_params->Info_id].NewObjectNumber, pdev->ResourceUsage[linear_params->Catalog_id].NewObjectNumber); + if (pdev->OwnerPassword.size > 0 || !(!getenv("GS_GENERATE_UUIDS") || (strcasecmp(getenv("GS_GENERATE_UUIDS"), "0") != 0 && strcasecmp(getenv("GS_GENERATE_UUIDS"), "no") != 0))) /* ID is mandatory when encrypting */ -+ gs_sprintf(LDict, "/ID[%s%s]", fileID, fileID); -+ gs_sprintf(LDict, "/Prev %d>>\nstartxref\r\n0\n%%%%EOF\n \n", 0); ++ gs_snprintf(LDict, sizeof(LDict), "/ID[%s%s]", fileID, fileID); ++ gs_snprintf(LDict, sizeof(LDict), "/Prev %d>>\nstartxref\r\n0\n%%%%EOF\n \n", 0); gp_fwrite(LDict, strlen(LDict), 1, linear_params->Lin_File.file); /* Write document catalog (Part 4) */ -@@ -2346,8 +2349,11 @@ +@@ -2445,8 +2448,11 @@ static int pdf_linearise(gx_device_pdf *pdev, pdf_linearisation_t *linear_params if (code != 0) return_error(gs_error_ioerror); -- gs_sprintf(LDict, "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R/ID[%s%s]/Prev %"PRId64">>\nstartxref\r\n0\n%%%%EOF\n", +- gs_snprintf(LDict, sizeof(LDict), "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R/ID[%s%s]/Prev %"PRId64">>\nstartxref\r\n0\n%%%%EOF\n", - linear_params->LastResource + 3, pdev->ResourceUsage[linear_params->Info_id].NewObjectNumber, pdev->ResourceUsage[linear_params->Catalog_id].NewObjectNumber, fileID, fileID, mainxref); -+ gs_sprintf(LDict, "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R", ++ gs_snprintf(LDict, sizeof(LDict), "\ntrailer\n<</Size %ld/Info %d 0 R/Root %d 0 R", + linear_params->LastResource + 3, pdev->ResourceUsage[linear_params->Info_id].NewObjectNumber, pdev->ResourceUsage[linear_params->Catalog_id].NewObjectNumber); + if (pdev->OwnerPassword.size > 0 || !(!getenv("GS_GENERATE_UUIDS") || (strcasecmp(getenv("GS_GENERATE_UUIDS"), "0") != 0 || strcasecmp(getenv("GS_GENERATE_UUIDS"), "no") != 0))) /* ID is mandatory when encrypting */ -+ gs_sprintf(LDict, "/ID[%s%s]", fileID, fileID); -+ gs_sprintf(LDict, "/Prev %"PRId64">>\nstartxref\r\n0\n%%%%EOF\n", mainxref); ++ gs_snprintf(LDict, sizeof(LDict), "/ID[%s%s]", fileID, fileID); ++ gs_snprintf(LDict, sizeof(LDict), "/Prev %"PRId64">>\nstartxref\r\n0\n%%%%EOF\n", mainxref); gp_fwrite(LDict, strlen(LDict), 1, linear_params->sfile); code = gp_fseek(linear_params->sfile, pdev->ResourceUsage[HintStreamObj].LinearisedOffset, SEEK_SET); -@@ -3012,10 +3018,12 @@ +@@ -3139,10 +3145,12 @@ pdf_close(gx_device * dev) stream_puts(s, "trailer\n"); pprintld3(s, "<< /Size %ld /Root %ld 0 R /Info %ld 0 R\n", pdev->next_id, Catalog_id, Info_id); diff --git a/gnu/packages/patches/ghostscript-no-header-uuid.patch b/gnu/packages/patches/ghostscript-no-header-uuid.patch index f4b55764c8..b277a4bc2e 100644 --- a/gnu/packages/patches/ghostscript-no-header-uuid.patch +++ b/gnu/packages/patches/ghostscript-no-header-uuid.patch @@ -8,10 +8,11 @@ field value as "". Upstream does not want to do this. See: https://bugs.ghostscript.com/show_bug.cgi?id=698208 -diff -ur orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c aa/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c ---- orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c 2017-07-09 23:30:28.960479189 +0200 -+++ gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c 2017-07-10 01:04:12.252478276 +0200 -@@ -620,7 +620,7 @@ +diff --git a/devices/vector/gdevpdfe.c b/devices/vector/gdevpdfe.c +index f083f1e93..a19c64ac0 100644 +--- a/devices/vector/gdevpdfe.c ++++ b/devices/vector/gdevpdfe.c +@@ -624,7 +624,7 @@ pdf_write_document_metadata(gx_device_pdf *pdev, const byte digest[6]) return code; /* PDF/A XMP reference recommends setting UUID to empty. If not empty must be a URI */ @@ -20,7 +21,7 @@ diff -ur orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c aa/gnu-ghostscrip instance_uuid[0] = 0x00; cre_date_time_len = pdf_get_docinfo_item(pdev, "/CreationDate", cre_date_time, sizeof(cre_date_time)); -@@ -720,14 +720,17 @@ +@@ -730,14 +730,17 @@ pdf_write_document_metadata(gx_device_pdf *pdev, const byte digest[6]) pdf_xml_tag_close(s, "rdf:Description"); pdf_xml_newline(s); diff --git a/gnu/packages/patches/glib-networking-32-bit-time.patch b/gnu/packages/patches/glib-networking-32-bit-time.patch deleted file mode 100644 index a437310270..0000000000 --- a/gnu/packages/patches/glib-networking-32-bit-time.patch +++ /dev/null @@ -1,61 +0,0 @@ -Work around a year-2038 issue when building with a 32-bit 'time_t' -on 32-bit platforms: - - https://gitlab.gnome.org/GNOME/glib-networking/-/issues/172 - -From 4f8ca86a0e460794188c3355f0c7cc11fdbe4229 Mon Sep 17 00:00:00 2001 -From: Simon McVittie <simon.mcvittie@collabora.co.uk> -Date: Tue, 21 Sep 2021 17:07:44 +0000 -Subject: [PATCH] tests: Accept GNUTLS' workaround for limited size of time_t - ---- - tls/tests/certificate.c | 15 +++++++++++++++ - tls/tests/meson.build | 1 + - 2 files changed, 16 insertions(+) - -diff --git a/tls/tests/certificate.c b/tls/tests/certificate.c -index c0100d30..d216c710 100644 ---- a/tls/tests/certificate.c -+++ b/tls/tests/certificate.c -@@ -672,6 +672,12 @@ test_certificate_not_valid_before (void) - g_object_unref (cert); - } - -+/* On 32-bit, GNUTLS caps expiry times at 2037-12-31 23:23:23 to avoid -+ * overflowing time_t. Hopefully by 2037, either 32-bit will finally have -+ * died out, or GNUTLS will rethink its approach to -+ * https://gitlab.com/gnutls/gnutls/-/issues/370 */ -+#define GNUTLS_32_BIT_NOT_VALID_AFTER_MAX 2145914603 -+ - static void - test_certificate_not_valid_after (void) - { -@@ -686,7 +692,16 @@ test_certificate_not_valid_after (void) - actual = g_tls_certificate_get_not_valid_after (cert); - g_assert_nonnull (actual); - actual_str = g_date_time_format_iso8601 (actual); -+ -+#if SIZEOF_TIME_T <= 4 -+ if (g_date_time_to_unix (actual) == GNUTLS_32_BIT_NOT_VALID_AFTER_MAX) -+ g_test_incomplete ("not-valid-after date not representable on 32-bit"); -+ else -+ g_assert_cmpstr (actual_str, ==, EXPECTED_NOT_VALID_AFTER); -+#else - g_assert_cmpstr (actual_str, ==, EXPECTED_NOT_VALID_AFTER); -+#endif -+ - g_free (actual_str); - g_date_time_unref (actual); - g_object_unref (cert); -diff --git a/tls/tests/meson.build b/tls/tests/meson.build -index e9c7d8c6..7415f913 100644 ---- a/tls/tests/meson.build -+++ b/tls/tests/meson.build -@@ -69,6 +69,7 @@ foreach backend: backends - test_cflags = cflags + [ - '-DBACKEND="@0@"'.format(backend), - '-DBACKEND_IS_' + backend.to_upper(), -+ '-DSIZEOF_TIME_T=@0@'.format(cc.sizeof('time_t', prefix: '#include <time.h>')), - ] - - if backend == 'openssl' diff --git a/gnu/packages/patches/glibc-dl-cache.patch b/gnu/packages/patches/glibc-dl-cache.patch index 68c3a94846..647837b983 100644 --- a/gnu/packages/patches/glibc-dl-cache.patch +++ b/gnu/packages/patches/glibc-dl-cache.patch @@ -6,7 +6,7 @@ diff --git a/elf/dl-cache.c b/elf/dl-cache.c index 93d185e788..e0760a1f40 100644 --- a/elf/dl-cache.c +++ b/elf/dl-cache.c -@@ -171,6 +171,51 @@ _dl_cache_libcmp (const char *p1, const char *p2) +@@ -171,6 +171,52 @@ _dl_cache_libcmp (const char *p1, const char *p2) return *p1 - *p2; } @@ -27,7 +27,8 @@ index 93d185e788..e0760a1f40 100644 + const char *origin = _dl_get_origin (); + + /* Check whether ORIGIN is something like "/gnu/store/…-foo/bin". */ -+ if (strncmp (store, origin, strlen (store)) == 0 ++ if (origin != (char *) -1 /* _dl_get_origin reported failure */ ++ && strncmp (store, origin, strlen (store)) == 0 + && origin[sizeof store - 1] == '/') + { + char *store_item_end = strchr (origin + sizeof store, '/'); diff --git a/gnu/packages/patches/glibc-hurd-clock_gettime_monotonic.patch b/gnu/packages/patches/glibc-hurd-clock_gettime_monotonic.patch index e31f99a1ce..b02215550d 100644 --- a/gnu/packages/patches/glibc-hurd-clock_gettime_monotonic.patch +++ b/gnu/packages/patches/glibc-hurd-clock_gettime_monotonic.patch @@ -67,8 +67,8 @@ index fcd79fd554..1dd02aa449 100644 diff --git a/sysdeps/pthread/timer_create.c b/sysdeps/pthread/timer_create.c index 9d8a9ea8ae..3430582c09 100644 ---- a/sysdeps/pthread/timer_create.c -+++ b/sysdeps/pthread/timer_create.c +--- a/rt/timer_create.c ++++ b/rt/timer_create.c @@ -48,7 +48,7 @@ timer_create (clockid_t clock_id, struct sigevent *evp, timer_t *timerid) return -1; } diff --git a/gnu/packages/patches/glibc-static-nss.patch b/gnu/packages/patches/glibc-static-nss.patch deleted file mode 100644 index 1a9db616cc..0000000000 --- a/gnu/packages/patches/glibc-static-nss.patch +++ /dev/null @@ -1,1244 +0,0 @@ -This patch reinstates support for static NSS, which glibc 2.33 broke: - - https://sourceware.org/bugzilla/show_bug.cgi?id=27959 - -Patch obtained by running: - - git diff f0c28504a9877be5da3ed1215f2da2d5914bbb0b..f9c8b11ed7726b858cd7b7cea0d3d7c5233d78cf - git diff 5e1ce61e3e71fb7ffe53f58fe96e67cb15f94854{^,} - git diff 135425a1dd50cbe2b9db0628d6c2b36c7889f30b{^,} - -It corresponds to these changes: - - f9c8b11ed7 * nss: Access nss_files through direct references - 6212bb67f4 * nss_files: Move into libc - 36861a968a * nss_files: Add generic code for set*ent, end*ent and file open - f0c28504a9 * nss_files: Allocate nscd file registration data on the heap - 5e1ce61e3e * nss: Fix NSS_DECLARE_MODULE_FUNCTIONS handling of _nss_*_endnetgrent - 135425a1dd * nss: Fix build error with --disable-nscd - -... plus a manual fix in 'files-network.c' to address this compilation error: - - nss_files/files-network.c: In function ‘_nss_files_parse_netent’: - nss_files/files-network.c:72:20: error: implicit declaration of function ‘__inet_network’; did you mean ‘inet_network’? [-Werror=implicit-function-declaration] - 72 | result->n_net = __inet_network (addr); - | ^~~~~~~~~~~~~~ - nss_files/files-parse.c:106:3: note: in definition of macro ‘LINE_PARSER’ - 106 | BODY; \ - | ^~~~ - -diff --git a/include/libc-symbols.h b/include/libc-symbols.h -index 127ea656c2..d41ecf4384 100644 ---- a/include/libc-symbols.h -+++ b/include/libc-symbols.h -@@ -798,29 +798,6 @@ for linking") - # define libdl_hidden_data_ver(local, name) - #endif - --#if IS_IN (libnss_files) --# define libnss_files_hidden_proto(name, attrs...) hidden_proto (name, ##attrs) --# define libnss_files_hidden_tls_proto(name, attrs...) \ -- hidden_tls_proto (name, ##attrs) --# define libnss_files_hidden_def(name) hidden_def (name) --# define libnss_files_hidden_weak(name) hidden_weak (name) --# define libnss_files_hidden_ver(local, name) hidden_ver (local, name) --# define libnss_files_hidden_data_def(name) hidden_data_def (name) --# define libnss_files_hidden_tls_def(name) hidden_tls_def (name) --# define libnss_files_hidden_data_weak(name) hidden_data_weak (name) --# define libnss_files_hidden_data_ver(local, name) hidden_data_ver(local, name) --#else --# define libnss_files_hidden_proto(name, attrs...) --# define libnss_files_hidden_tls_proto(name, attrs...) --# define libnss_files_hidden_def(name) --# define libnss_files_hidden_weak(name) --# define libnss_files_hidden_ver(local, name) --# define libnss_files_hidden_data_def(name) --# define libnss_files_hidden_tls_def(name) --# define libnss_files_hidden_data_weak(name) --# define libnss_files_hidden_data_ver(local, name) --#endif -- - #if IS_IN (libnsl) - # define libnsl_hidden_proto(name, attrs...) hidden_proto (name, ##attrs) - # define libnsl_hidden_tls_proto(name, attrs...) \ -diff --git a/include/netdb.h b/include/netdb.h -index 82e102ff76..4dcdbb8cd4 100644 ---- a/include/netdb.h -+++ b/include/netdb.h -@@ -217,7 +217,7 @@ extern enum nss_status _nss_netgroup_parseline (char **cursor, - struct __netgrent *result, - char *buffer, size_t buflen, - int *errnop); --libnss_files_hidden_proto (_nss_netgroup_parseline) -+libc_hidden_proto (_nss_netgroup_parseline) - - #define DECLARE_NSS_PROTOTYPES(service) \ - extern enum nss_status _nss_ ## service ## _setprotoent (int); \ -diff --git a/include/nss_files.h b/include/nss_files.h -index 6a0dcdb85b..6190cac6be 100644 ---- a/include/nss_files.h -+++ b/include/nss_files.h -@@ -19,7 +19,11 @@ - #ifndef _NSS_FILES_H - #define _NSS_FILES_H - -+#include <nss.h> - #include <stdio.h> -+#if IS_IN (libc) -+#include <libc-lock.h> -+#endif - - /* Open PATH for reading, as a data source for nss_files. */ - FILE *__nss_files_fopen (const char *path); -@@ -47,6 +51,63 @@ int __nss_readline_seek (FILE *fp, off64_t offset) attribute_hidden; - int __nss_parse_line_result (FILE *fp, off64_t offset, int parse_line_result); - libc_hidden_proto (__nss_parse_line_result) - -+/* Per-file data. Used by the *ent functions that need to preserve -+ state across calls. */ -+struct nss_files_per_file_data -+{ -+ FILE *stream; -+#if IS_IN (libc) -+ /* The size of locks changes between libc and nss_files, so this -+ member must be last and is only available in libc. */ -+ __libc_lock_define (, lock); -+#endif -+}; -+ -+/* File index for __nss_files_data_get. */ -+enum nss_files_file -+ { -+ nss_file_aliasent, -+ nss_file_etherent, -+ nss_file_grent, -+ nss_file_hostent, -+ nss_file_netent, -+ nss_file_protoent, -+ nss_file_pwent, -+ nss_file_rpcent, -+ nss_file_servent, -+ nss_file_sgent, -+ nss_file_spent, -+ -+ nss_file_count -+ }; -+ -+/* Obtains a pointer to the per-file data for FILE, which is written -+ to *PDATA, and tries to open the file at PATH for it. On success, -+ returns NSS_STATUS_SUCCESS, and the caller must later call -+ __nss_files_data_put. On failure, NSS_STATUS_TRYAGAIN is returned, -+ and *ERRNOP and *HERRNOP are updated if these pointers are not -+ null. */ -+enum nss_status __nss_files_data_open (struct nss_files_per_file_data **pdata, -+ enum nss_files_file file, -+ const char *path, -+ int *errnop, int *herrnop); -+libc_hidden_proto (__nss_files_data_open) -+ -+/* Unlock the per-file data, previously obtained by -+ __nss_files_data_open. */ -+void __nss_files_data_put (struct nss_files_per_file_data *data); -+libc_hidden_proto (__nss_files_data_put) -+ -+/* Performs the set*ent operation for FILE. PATH is the file to -+ open. */ -+enum nss_status __nss_files_data_setent (enum nss_files_file file, -+ const char *path); -+libc_hidden_proto (__nss_files_data_setent) -+ -+/* Performs the end*ent operation for FILE. */ -+enum nss_status __nss_files_data_endent (enum nss_files_file file); -+libc_hidden_proto (__nss_files_data_endent) -+ - struct parser_data; - - /* Instances of the parse_line function from -@@ -64,16 +125,25 @@ extern nss_files_parse_line _nss_files_parse_servent; - extern nss_files_parse_line _nss_files_parse_sgent; - extern nss_files_parse_line _nss_files_parse_spent; - --libnss_files_hidden_proto (_nss_files_parse_etherent) -+libc_hidden_proto (_nss_files_parse_etherent) - libc_hidden_proto (_nss_files_parse_grent) --libnss_files_hidden_proto (_nss_files_parse_netent) --libnss_files_hidden_proto (_nss_files_parse_protoent) -+libc_hidden_proto (_nss_files_parse_netent) -+libc_hidden_proto (_nss_files_parse_protoent) - libc_hidden_proto (_nss_files_parse_pwent) --libnss_files_hidden_proto (_nss_files_parse_rpcent) --libnss_files_hidden_proto (_nss_files_parse_servent) -+libc_hidden_proto (_nss_files_parse_rpcent) -+libc_hidden_proto (_nss_files_parse_servent) - libc_hidden_proto (_nss_files_parse_sgent) - libc_hidden_proto (_nss_files_parse_spent) - -+NSS_DECLARE_MODULE_FUNCTIONS (files) -+#undef DEFINE_NSS_FUNCTION -+#define DEFINE_NSS_FUNCTION(x) libc_hidden_proto (_nss_files_##x) -+#include <nss/function.def> -+#undef DEFINE_NSS_FUNCTION -+ -+void _nss_files_init (void (*cb) (size_t, struct traced_file *)); -+libc_hidden_proto (_nss_files_init) -+ - /* Generic implementation of fget*ent_r. Reads lines from FP until - EOF or a successful parse into *RESULT using PARSER. Returns 0 on - success, ENOENT on EOF, ERANGE on too-small buffer. */ -diff --git a/nss/Makefile b/nss/Makefile -index 9682a31e20..63a386af18 100644 ---- a/nss/Makefile -+++ b/nss/Makefile -@@ -31,7 +31,8 @@ routines = nsswitch getnssent getnssent_r digits_dots \ - compat-lookup nss_hash nss_files_fopen \ - nss_readline nss_parse_line_result \ - nss_fgetent_r nss_module nss_action \ -- nss_action_parse nss_database -+ nss_action_parse nss_database nss_files_data \ -+ nss_files_functions - - # These are the databases that go through nss dispatch. - # Caution: if you add a database here, you must add its real name -@@ -98,9 +99,11 @@ subdir-dirs = $(services:%=nss_%) - vpath %.c $(subdir-dirs) ../locale/programs ../intl - - --libnss_files-routines := $(addprefix files-, \ -- $(filter-out key, $(databases))) \ -- files-initgroups files-init -+routines += \ -+ $(addprefix files-, $(filter-out key, $(databases))) \ -+ files-init \ -+ files-initgroups \ -+ # routines - - libnss_db-dbs := $(addprefix db-,\ - $(filter-out hosts network key alias,\ -@@ -116,12 +119,9 @@ libnss_compat-routines := $(addprefix compat-,grp pwd spwd initgroups) \ - install-others += $(inst_vardbdir)/Makefile - - # Build static module into libc if requested --libnss_files-inhibit-o = $(filter-out .os,$(object-suffixes)) - libnss_db-inhibit-o = $(filter-out .os,$(object-suffixes)) - libnss_compat-inhibit-o = $(filter-out .os,$(object-suffixes)) - ifeq ($(build-static-nss),yes) --routines += $(libnss_files-routines) --static-only-routines += $(libnss_files-routines) - tests-static += tst-nss-static - endif - extra-test-objs += nss_test1.os nss_test2.os -@@ -138,8 +138,6 @@ libnss-libc = $(common-objpfx)linkobj/libc.so - # for new links: - $(services:%=$(objpfx)libnss_%.so): libc-for-link = $(libnss-libc) - --$(objpfx)libnss_db.so: $(objpfx)libnss_files.so -- - $(libnss_db-dbs:%=$(objpfx)%.c): $(objpfx)db-%.c: nss_files/files-%.c - @rm -f $@.new - (echo '#define EXTERN_PARSER';\ -diff --git a/nss/Versions b/nss/Versions -index fdddea104c..e551524aa9 100644 ---- a/nss/Versions -+++ b/nss/Versions -@@ -19,11 +19,12 @@ libc { - __nss_services_lookup2; __nss_next2; __nss_lookup; - __nss_hash; __nss_database_get; - __nss_files_fopen; __nss_readline; __nss_parse_line_result; -- } --} -+ __nss_files_data_endent; -+ __nss_files_data_open; -+ __nss_files_data_put; -+ __nss_files_data_setent; - --libnss_files { -- GLIBC_PRIVATE { -+ # Routines formerly in libnss_files.so.2. - _nss_files_setaliasent; - _nss_files_endaliasent; - _nss_files_getaliasbyname_r; -@@ -109,6 +110,14 @@ libnss_files { - } - } - -+libnss_files { -+ GLIBC_PRIVATE { -+ # Keep a version node (with a synthesized local: * directive) so that -+ # __bss_* symbols are hidden on targets that need it. -+ __libnss_files_version_placeholder; -+ } -+} -+ - libnss_db { - GLIBC_PRIVATE { - _nss_db_setetherent; -diff --git a/nss/nss_files/files-XXX.c b/nss/nss_files/files-XXX.c -index b4b989d9bb..c158a891bd 100644 ---- a/nss/nss_files/files-XXX.c -+++ b/nss/nss_files/files-XXX.c -@@ -45,10 +45,12 @@ - # include <netdb.h> - # define H_ERRNO_PROTO , int *herrnop - # define H_ERRNO_ARG , herrnop -+# define H_ERRNO_ARG_OR_NULL herrnop - # define H_ERRNO_SET(val) (*herrnop = (val)) - #else - # define H_ERRNO_PROTO - # define H_ERRNO_ARG -+# define H_ERRNO_ARG_OR_NULL NULL - # define H_ERRNO_SET(val) ((void) 0) - #endif - -@@ -58,15 +60,11 @@ - # define EXTRA_ARGS_VALUE - #endif - --/* Locks the static variables in this file. */ --__libc_lock_define_initialized (static, lock) - - /* Maintenance of the stream open on the database file. For getXXent - operations the stream needs to be held open across calls, the other - getXXbyYY operations all use their own stream. */ - --static FILE *stream; -- - /* Open database file if not already opened. */ - static enum nss_status - internal_setent (FILE **stream) -@@ -91,42 +89,16 @@ internal_setent (FILE **stream) - enum nss_status - CONCAT(_nss_files_set,ENTNAME) (int stayopen) - { -- enum nss_status status; -- -- __libc_lock_lock (lock); -- -- status = internal_setent (&stream); -- -- __libc_lock_unlock (lock); -- -- return status; -+ return __nss_files_data_setent (CONCAT (nss_file_, ENTNAME), DATAFILE); - } -+libc_hidden_def (CONCAT (_nss_files_set,ENTNAME)) - -- --/* Close the database file. */ --static void --internal_endent (FILE **stream) --{ -- if (*stream != NULL) -- { -- fclose (*stream); -- *stream = NULL; -- } --} -- -- --/* Thread-safe, exported version of that. */ - enum nss_status - CONCAT(_nss_files_end,ENTNAME) (void) - { -- __libc_lock_lock (lock); -- -- internal_endent (&stream); -- -- __libc_lock_unlock (lock); -- -- return NSS_STATUS_SUCCESS; -+ return __nss_files_data_endent (CONCAT (nss_file_, ENTNAME)); - } -+libc_hidden_def (CONCAT (_nss_files_end,ENTNAME)) - - - /* Parsing the database file into `struct STRUCTURE' data structures. */ -@@ -194,28 +166,22 @@ CONCAT(_nss_files_get,ENTNAME_r) (struct STRUCTURE *result, char *buffer, - size_t buflen, int *errnop H_ERRNO_PROTO) - { - /* Return next entry in host file. */ -- enum nss_status status = NSS_STATUS_SUCCESS; -- -- __libc_lock_lock (lock); - -- /* Be prepared that the set*ent function was not called before. */ -- if (stream == NULL) -- { -- int save_errno = errno; -- -- status = internal_setent (&stream); -- -- __set_errno (save_errno); -- } -- -- if (status == NSS_STATUS_SUCCESS) -- status = internal_getent (stream, result, buffer, buflen, errnop -- H_ERRNO_ARG EXTRA_ARGS_VALUE); -+ struct nss_files_per_file_data *data; -+ enum nss_status status = __nss_files_data_open (&data, -+ CONCAT (nss_file_, ENTNAME), -+ DATAFILE, -+ errnop, H_ERRNO_ARG_OR_NULL); -+ if (status != NSS_STATUS_SUCCESS) -+ return status; - -- __libc_lock_unlock (lock); -+ status = internal_getent (data->stream, result, buffer, buflen, errnop -+ H_ERRNO_ARG EXTRA_ARGS_VALUE); - -+ __nss_files_data_put (data); - return status; - } -+libc_hidden_def (CONCAT (_nss_files_get,ENTNAME_r)) - - /* Macro for defining lookup functions for this file-based database. - -@@ -248,8 +214,9 @@ _nss_files_get##name##_r (proto, \ - == NSS_STATUS_SUCCESS) \ - { break_if_match } \ - \ -- internal_endent (&stream); \ -+ fclose (stream); \ - } \ - \ - return status; \ --} -+} \ -+libc_hidden_def (_nss_files_get##name##_r) -diff --git a/nss/nss_files/files-alias.c b/nss/nss_files/files-alias.c -index 30971bfe56..8c6e176ff6 100644 ---- a/nss/nss_files/files-alias.c -+++ b/nss/nss_files/files-alias.c -@@ -31,18 +31,11 @@ - #include "nsswitch.h" - #include <nss_files.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- --/* Locks the static variables in this file. */ --__libc_lock_define_initialized (static, lock) - - /* Maintenance of the stream open on the database file. For getXXent - operations the stream needs to be held open across calls, the other - getXXbyYY operations all use their own stream. */ - --static FILE *stream; -- -- - static enum nss_status - internal_setent (FILE **stream) - { -@@ -66,42 +59,16 @@ internal_setent (FILE **stream) - enum nss_status - _nss_files_setaliasent (void) - { -- enum nss_status status; -- -- __libc_lock_lock (lock); -- -- status = internal_setent (&stream); -- -- __libc_lock_unlock (lock); -- -- return status; -+ return __nss_files_data_setent (nss_file_aliasent, "/etc/aliases"); - } -+libc_hidden_def (_nss_files_setaliasent) - -- --/* Close the database file. */ --static void --internal_endent (FILE **stream) --{ -- if (*stream != NULL) -- { -- fclose (*stream); -- *stream = NULL; -- } --} -- -- --/* Thread-safe, exported version of that. */ - enum nss_status - _nss_files_endaliasent (void) - { -- __libc_lock_lock (lock); -- -- internal_endent (&stream); -- -- __libc_lock_unlock (lock); -- -- return NSS_STATUS_SUCCESS; -+ return __nss_files_data_endent (nss_file_aliasent); - } -+libc_hidden_def (_nss_files_endaliasent) - - /* Parsing the database file into `struct aliasent' data structures. */ - static enum nss_status -@@ -131,7 +98,7 @@ get_next_alias (FILE *stream, const char *match, struct aliasent *result, - /* Read the first line. It must contain the alias name and - possibly some alias names. */ - first_unused[room_left - 1] = '\xff'; -- line = fgets_unlocked (first_unused, room_left, stream); -+ line = __fgets_unlocked (first_unused, room_left, stream); - if (line == NULL) - /* Nothing to read. */ - break; -@@ -220,7 +187,7 @@ get_next_alias (FILE *stream, const char *match, struct aliasent *result, - /* If the file does not exist we simply ignore - the statement. */ - if (listfile != NULL -- && (old_line = strdup (line)) != NULL) -+ && (old_line = __strdup (line)) != NULL) - { - while (! feof_unlocked (listfile)) - { -@@ -232,8 +199,8 @@ get_next_alias (FILE *stream, const char *match, struct aliasent *result, - } - - first_unused[room_left - 1] = '\xff'; -- line = fgets_unlocked (first_unused, room_left, -- listfile); -+ line = __fgets_unlocked (first_unused, room_left, -+ listfile); - if (line == NULL) - break; - if (first_unused[room_left - 1] != '\xff') -@@ -335,7 +302,7 @@ get_next_alias (FILE *stream, const char *match, struct aliasent *result, - /* The just read character is a white space and so - can be ignored. */ - first_unused[room_left - 1] = '\xff'; -- line = fgets_unlocked (first_unused, room_left, stream); -+ line = __fgets_unlocked (first_unused, room_left, stream); - if (line == NULL) - { - /* Continuation line without any data and -@@ -369,29 +336,25 @@ _nss_files_getaliasent_r (struct aliasent *result, char *buffer, size_t buflen, - int *errnop) - { - /* Return next entry in host file. */ -- enum nss_status status = NSS_STATUS_SUCCESS; - -- __libc_lock_lock (lock); -- -- /* Be prepared that the set*ent function was not called before. */ -- if (stream == NULL) -- status = internal_setent (&stream); -- -- if (status == NSS_STATUS_SUCCESS) -- { -- result->alias_local = 1; -+ struct nss_files_per_file_data *data; -+ enum nss_status status = __nss_files_data_open (&data, nss_file_aliasent, -+ "/etc/aliases", errnop, NULL); -+ if (status != NSS_STATUS_SUCCESS) -+ return status; - -- /* Read lines until we get a definite result. */ -- do -- status = get_next_alias (stream, NULL, result, buffer, buflen, errnop); -- while (status == NSS_STATUS_RETURN); -- } -+ result->alias_local = 1; - -- __libc_lock_unlock (lock); -+ /* Read lines until we get a definite result. */ -+ do -+ status = get_next_alias (data->stream, NULL, result, buffer, buflen, -+ errnop); -+ while (status == NSS_STATUS_RETURN); - -+ __nss_files_data_put (data); - return status; - } -- -+libc_hidden_def (_nss_files_getaliasent_r) - - enum nss_status - _nss_files_getaliasbyname_r (const char *name, struct aliasent *result, -@@ -418,9 +381,10 @@ _nss_files_getaliasbyname_r (const char *name, struct aliasent *result, - do - status = get_next_alias (stream, name, result, buffer, buflen, errnop); - while (status == NSS_STATUS_RETURN); -- } - -- internal_endent (&stream); -+ fclose (stream); -+ } - - return status; - } -+libc_hidden_def (_nss_files_getaliasbyname_r) -diff --git a/nss/nss_files/files-ethers.c b/nss/nss_files/files-ethers.c -index 2fe7f81e4b..7c2c2b9833 100644 ---- a/nss/nss_files/files-ethers.c -+++ b/nss/nss_files/files-ethers.c -@@ -20,8 +20,6 @@ - #include <netinet/if_ether.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - struct etherent_data {}; - - #define ENTNAME etherent -diff --git a/nss/nss_files/files-grp.c b/nss/nss_files/files-grp.c -index 49be38e8b1..a716d948e2 100644 ---- a/nss/nss_files/files-grp.c -+++ b/nss/nss_files/files-grp.c -@@ -19,8 +19,6 @@ - #include <grp.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define STRUCTURE group - #define ENTNAME grent - #define DATABASE "group" -diff --git a/nss/nss_files/files-hosts.c b/nss/nss_files/files-hosts.c -index 2b47ec3e53..d54d91d038 100644 ---- a/nss/nss_files/files-hosts.c -+++ b/nss/nss_files/files-hosts.c -@@ -26,8 +26,6 @@ - #include <alloc_buffer.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - /* Get implementation for some internal functions. */ - #include "../resolv/res_hconf.h" - -@@ -57,12 +55,13 @@ LINE_PARSER - STRING_FIELD (addr, isspace, 1); - - /* Parse address. */ -- if (inet_pton (af == AF_UNSPEC ? AF_INET : af, addr, entdata->host_addr) -+ if (__inet_pton (af == AF_UNSPEC ? AF_INET : af, addr, entdata->host_addr) - > 0) - af = af == AF_UNSPEC ? AF_INET : af; - else - { -- if (af == AF_INET && inet_pton (AF_INET6, addr, entdata->host_addr) > 0) -+ if (af == AF_INET -+ && __inet_pton (AF_INET6, addr, entdata->host_addr) > 0) - { - if (IN6_IS_ADDR_V4MAPPED (entdata->host_addr)) - memcpy (entdata->host_addr, entdata->host_addr + 12, INADDRSZ); -@@ -76,7 +75,7 @@ LINE_PARSER - return 0; - } - else if (af == AF_UNSPEC -- && inet_pton (AF_INET6, addr, entdata->host_addr) > 0) -+ && __inet_pton (AF_INET6, addr, entdata->host_addr) > 0) - af = AF_INET6; - else - /* Illegal address: ignore line. */ -@@ -349,7 +348,7 @@ _nss_files_gethostbyname3_r (const char *name, int af, struct hostent *result, - status = gethostbyname3_multi - (stream, name, af, result, buffer, buflen, errnop, herrnop); - -- internal_endent (&stream); -+ fclose (stream); - } - - if (canonp && status == NSS_STATUS_SUCCESS) -@@ -357,6 +356,7 @@ _nss_files_gethostbyname3_r (const char *name, int af, struct hostent *result, - - return status; - } -+libc_hidden_def (_nss_files_gethostbyname3_r) - - enum nss_status - _nss_files_gethostbyname_r (const char *name, struct hostent *result, -@@ -366,6 +366,7 @@ _nss_files_gethostbyname_r (const char *name, struct hostent *result, - return _nss_files_gethostbyname3_r (name, AF_INET, result, buffer, buflen, - errnop, herrnop, NULL, NULL); - } -+libc_hidden_def (_nss_files_gethostbyname_r) - - enum nss_status - _nss_files_gethostbyname2_r (const char *name, int af, struct hostent *result, -@@ -375,6 +376,7 @@ _nss_files_gethostbyname2_r (const char *name, int af, struct hostent *result, - return _nss_files_gethostbyname3_r (name, af, result, buffer, buflen, - errnop, herrnop, NULL, NULL); - } -+libc_hidden_def (_nss_files_gethostbyname2_r) - - enum nss_status - _nss_files_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat, -@@ -475,7 +477,7 @@ _nss_files_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat, - status = NSS_STATUS_SUCCESS; - } - -- internal_endent (&stream); -+ fclose (stream); - } - else if (status == NSS_STATUS_TRYAGAIN) - { -@@ -490,3 +492,4 @@ _nss_files_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat, - - return status; - } -+libc_hidden_def (_nss_files_gethostbyname4_r) -diff --git a/nss/nss_files/files-init.c b/nss/nss_files/files-init.c -index 717c9fd334..18ed288d04 100644 ---- a/nss/nss_files/files-init.c -+++ b/nss/nss_files/files-init.c -@@ -21,8 +21,7 @@ - #include <string.h> - #include <nscd/nscd.h> - #include <nss.h> -- --NSS_DECLARE_MODULE_FUNCTIONS (files) -+#include <nss_files.h> - - static void - register_file (void (*cb) (size_t, struct traced_file *), -@@ -49,5 +48,6 @@ _nss_files_init (void (*cb) (size_t, struct traced_file *)) - register_file (cb, servdb, "/etc/services", 0); - register_file (cb, netgrdb, "/etc/netgroup", 0); - } -+libc_hidden_def (_nss_files_init) - - #endif -diff --git a/nss/nss_files/files-initgroups.c b/nss/nss_files/files-initgroups.c -index 6fcea40b55..b44211e50b 100644 ---- a/nss/nss_files/files-initgroups.c -+++ b/nss/nss_files/files-initgroups.c -@@ -28,8 +28,6 @@ - #include <nss.h> - #include <nss_files.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - enum nss_status - _nss_files_initgroups_dyn (const char *user, gid_t group, long int *start, - long int *size, gid_t **groupsp, long int limit, -@@ -129,3 +127,4 @@ _nss_files_initgroups_dyn (const char *user, gid_t group, long int *start, - - return status == NSS_STATUS_SUCCESS && !any ? NSS_STATUS_NOTFOUND : status; - } -+libc_hidden_def (_nss_files_initgroups_dyn) -diff --git a/nss/nss_files/files-netgrp.c b/nss/nss_files/files-netgrp.c -index f8c821c2f0..75bfbd9e44 100644 ---- a/nss/nss_files/files-netgrp.c -+++ b/nss/nss_files/files-netgrp.c -@@ -28,11 +28,9 @@ - #include "netgroup.h" - #include <nss_files.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define DATAFILE "/etc/netgroup" - --libnss_files_hidden_proto (_nss_files_endnetgrent) -+libc_hidden_proto (_nss_files_endnetgrent) - - #define EXPAND(needed) \ - do \ -@@ -152,7 +150,7 @@ _nss_files_setnetgrent (const char *group, struct __netgrent *result) - - return status; - } -- -+libc_hidden_def (_nss_files_setnetgrent) - - enum nss_status - _nss_files_endnetgrent (struct __netgrent *result) -@@ -164,7 +162,7 @@ _nss_files_endnetgrent (struct __netgrent *result) - result->cursor = NULL; - return NSS_STATUS_SUCCESS; - } --libnss_files_hidden_def (_nss_files_endnetgrent) -+libc_hidden_def (_nss_files_endnetgrent) - - static char * - strip_whitespace (char *str) -@@ -279,7 +277,7 @@ _nss_netgroup_parseline (char **cursor, struct __netgrent *result, - - return status; - } --libnss_files_hidden_def (_nss_netgroup_parseline) -+libc_hidden_def (_nss_netgroup_parseline) - - - enum nss_status -@@ -293,3 +291,4 @@ _nss_files_getnetgrent_r (struct __netgrent *result, char *buffer, - - return status; - } -+libc_hidden_def (_nss_files_getnetgrent_r) -diff --git a/nss/nss_files/files-network.c b/nss/nss_files/files-network.c -index 9cd7d7dc79..217ed78609 100644 ---- a/nss/nss_files/files-network.c -+++ b/nss/nss_files/files-network.c -@@ -22,8 +22,6 @@ - #include <stdint.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define ENTNAME netent - #define DATABASE "networks" - #define NEED_H_ERRNO -@@ -71,7 +69,7 @@ LINE_PARSER - *cp = '\0'; - addr = newp; - } -- result->n_net = inet_network (addr); -+ result->n_net = inet_network (addr); - result->n_addrtype = AF_INET; - - }) -diff --git a/nss/nss_files/files-parse.c b/nss/nss_files/files-parse.c -index 68c51c7cbf..997eac573a 100644 ---- a/nss/nss_files/files-parse.c -+++ b/nss/nss_files/files-parse.c -@@ -74,13 +74,7 @@ struct parser_data - /* Export the line parser function so it can be used in nss_db. */ - # define parser_stclass /* Global */ - # define parse_line CONCAT(_nss_files_parse_,ENTNAME) --# if IS_IN (libc) --/* We are defining one of the functions that actually lives in libc -- because it is used to implement fget*ent and suchlike. */ --# define nss_files_parse_hidden_def(name) libc_hidden_def (name) --# else --# define nss_files_parse_hidden_def(name) libnss_files_hidden_def (name) --# endif -+# define nss_files_parse_hidden_def(name) libc_hidden_def (name) - #endif - - -diff --git a/nss/nss_files/files-proto.c b/nss/nss_files/files-proto.c -index 98d082c642..13072692c1 100644 ---- a/nss/nss_files/files-proto.c -+++ b/nss/nss_files/files-proto.c -@@ -19,8 +19,6 @@ - #include <netdb.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define ENTNAME protoent - #define DATABASE "protocols" - -diff --git a/nss/nss_files/files-pwd.c b/nss/nss_files/files-pwd.c -index b04165ddde..5c74c6da9b 100644 ---- a/nss/nss_files/files-pwd.c -+++ b/nss/nss_files/files-pwd.c -@@ -19,8 +19,6 @@ - #include <pwd.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define STRUCTURE passwd - #define ENTNAME pwent - #define DATABASE "passwd" -diff --git a/nss/nss_files/files-rpc.c b/nss/nss_files/files-rpc.c -index eeb2725d2c..3dea8f18f2 100644 ---- a/nss/nss_files/files-rpc.c -+++ b/nss/nss_files/files-rpc.c -@@ -19,8 +19,6 @@ - #include <rpc/netdb.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define ENTNAME rpcent - #define DATABASE "rpc" - -diff --git a/nss/nss_files/files-service.c b/nss/nss_files/files-service.c -index f4f0985377..a8d83e094e 100644 ---- a/nss/nss_files/files-service.c -+++ b/nss/nss_files/files-service.c -@@ -20,8 +20,6 @@ - #include <netdb.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define ENTNAME servent - #define DATABASE "services" - -diff --git a/nss/nss_files/files-sgrp.c b/nss/nss_files/files-sgrp.c -index 6b1c9eac02..213a408e7b 100644 ---- a/nss/nss_files/files-sgrp.c -+++ b/nss/nss_files/files-sgrp.c -@@ -19,8 +19,6 @@ - #include <gshadow.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define STRUCTURE sgrp - #define ENTNAME sgent - #define DATABASE "gshadow" -diff --git a/nss/nss_files/files-spwd.c b/nss/nss_files/files-spwd.c -index 976deaf918..d031257a20 100644 ---- a/nss/nss_files/files-spwd.c -+++ b/nss/nss_files/files-spwd.c -@@ -19,8 +19,6 @@ - #include <shadow.h> - #include <nss.h> - --NSS_DECLARE_MODULE_FUNCTIONS (files) -- - #define STRUCTURE spwd - #define ENTNAME spent - #define DATABASE "shadow" -diff --git a/nss/nss_files_data.c b/nss/nss_files_data.c -new file mode 100644 -index 0000000000..80fbfe5fff ---- /dev/null -+++ b/nss/nss_files_data.c -@@ -0,0 +1,161 @@ -+/* Returns a pointer to the global nss_files data structure. -+ Copyright (C) 2021 Free Software Foundation, Inc. -+ This file is part of the GNU C Library. -+ -+ The GNU C Library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Lesser General Public -+ License as published by the Free Software Foundation; either -+ version 2.1 of the License, or (at your option) any later version. -+ -+ The GNU C Library is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ Lesser General Public License for more details. -+ -+ You should have received a copy of the GNU Lesser General Public -+ License along with the GNU C Library; if not, see -+ <https://www.gnu.org/licenses/>. */ -+ -+#include <nss_files.h> -+ -+#include <allocate_once.h> -+#include <errno.h> -+#include <netdb.h> -+#include <nss.h> -+#include <stdlib.h> -+ -+/* This collects all per file-data. */ -+struct nss_files_data -+{ -+ struct nss_files_per_file_data files[nss_file_count]; -+}; -+ -+/* For use with allocate_once. */ -+static void *nss_files_global; -+static void * -+nss_files_global_allocate (void *closure) -+{ -+ struct nss_files_data *result = malloc (sizeof (*result)); -+ if (result != NULL) -+ { -+ for (int i = 0; i < nss_file_count; ++i) -+ { -+ result->files[i].stream = NULL; -+ __libc_lock_init (result->files[i].lock); -+ } -+ } -+ return result; -+} -+/* Like __nss_files_data_open, but does not perform the open call. */ -+static enum nss_status -+__nss_files_data_get (struct nss_files_per_file_data **pdata, -+ enum nss_files_file file, int *errnop, int *herrnop) -+{ -+ struct nss_files_data *data = allocate_once (&nss_files_global, -+ nss_files_global_allocate, -+ NULL, NULL); -+ if (data == NULL) -+ { -+ if (errnop != NULL) -+ *errnop = errno; -+ if (herrnop != NULL) -+ { -+ __set_h_errno (NETDB_INTERNAL); -+ *herrnop = NETDB_INTERNAL; -+ } -+ return NSS_STATUS_TRYAGAIN; -+ } -+ -+ *pdata = &data->files[file]; -+ __libc_lock_lock ((*pdata)->lock); -+ return NSS_STATUS_SUCCESS; -+} -+ -+/* Helper function for opening the backing file at PATH. */ -+static enum nss_status -+__nss_files_data_internal_open (struct nss_files_per_file_data *data, -+ const char *path) -+{ -+ enum nss_status status = NSS_STATUS_SUCCESS; -+ -+ if (data->stream == NULL) -+ { -+ data->stream = __nss_files_fopen (path); -+ -+ if (data->stream == NULL) -+ status = errno == EAGAIN ? NSS_STATUS_TRYAGAIN : NSS_STATUS_UNAVAIL; -+ } -+ -+ return status; -+} -+ -+ -+enum nss_status -+__nss_files_data_open (struct nss_files_per_file_data **pdata, -+ enum nss_files_file file, const char *path, -+ int *errnop, int *herrnop) -+{ -+ enum nss_status status = __nss_files_data_get (pdata, file, errnop, herrnop); -+ if (status != NSS_STATUS_SUCCESS) -+ return status; -+ -+ /* Be prepared that the set*ent function was not called before. */ -+ if ((*pdata)->stream == NULL) -+ { -+ int saved_errno = errno; -+ status = __nss_files_data_internal_open (*pdata, path); -+ __set_errno (saved_errno); -+ if (status != NSS_STATUS_SUCCESS) -+ __nss_files_data_put (*pdata); -+ } -+ -+ return status; -+} -+ -+libc_hidden_def (__nss_files_data_open) -+ -+void -+__nss_files_data_put (struct nss_files_per_file_data *data) -+{ -+ __libc_lock_unlock (data->lock); -+} -+libc_hidden_def (__nss_files_data_put) -+ -+enum nss_status -+__nss_files_data_setent (enum nss_files_file file, const char *path) -+{ -+ struct nss_files_per_file_data *data; -+ enum nss_status status = __nss_files_data_get (&data, file, NULL, NULL); -+ if (status != NSS_STATUS_SUCCESS) -+ return status; -+ -+ if (data->stream == NULL) -+ status = __nss_files_data_internal_open (data, path); -+ else -+ rewind (data->stream); -+ -+ __nss_files_data_put (data); -+ return status; -+} -+libc_hidden_def (__nss_files_data_setent) -+ -+enum nss_status -+__nss_files_data_endent (enum nss_files_file file) -+{ -+ /* No cleanup is necessary if not initialized. */ -+ struct nss_files_data *data = atomic_load_acquire (&nss_files_global); -+ if (data == NULL) -+ return NSS_STATUS_SUCCESS; -+ -+ struct nss_files_per_file_data *fdata = &data->files[file]; -+ __libc_lock_lock (fdata->lock); -+ if (fdata->stream != NULL) -+ { -+ fclose (fdata->stream); -+ fdata->stream = NULL; -+ } -+ __libc_lock_unlock (fdata->lock); -+ -+ return NSS_STATUS_SUCCESS; -+} -+libc_hidden_def (__nss_files_data_endent) -diff --git a/nss/nss_files_functions.c b/nss/nss_files_functions.c -new file mode 100644 -index 0000000000..85720b4311 ---- /dev/null -+++ b/nss/nss_files_functions.c -@@ -0,0 +1,43 @@ -+/* Direct access for nss_files functions for NSS module loading. -+ Copyright (C) 2021 Free Software Foundation, Inc. -+ This file is part of the GNU C Library. -+ -+ The GNU C Library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Lesser General Public -+ License as published by the Free Software Foundation; either -+ version 2.1 of the License, or (at your option) any later version. -+ -+ The GNU C Library is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ Lesser General Public License for more details. -+ -+ You should have received a copy of the GNU Lesser General Public -+ License along with the GNU C Library; if not, see -+ <https://www.gnu.org/licenses/>. */ -+ -+#include <nss_module.h> -+#include <nss_files.h> -+ -+void -+__nss_files_functions (nss_module_functions_untyped pointers) -+{ -+ void **fptr = pointers; -+ -+ /* Functions which are not implemented. */ -+#define _nss_files_getcanonname_r NULL -+#define _nss_files_gethostbyaddr2_r NULL -+#define _nss_files_getpublickey NULL -+#define _nss_files_getsecretkey NULL -+#define _nss_files_netname2user NULL -+ -+#undef DEFINE_NSS_FUNCTION -+#define DEFINE_NSS_FUNCTION(x) *fptr++ = _nss_files_##x; -+#include "function.def" -+ -+#ifdef PTR_MANGLE -+ void **end = fptr; -+ for (fptr = pointers; fptr != end; ++fptr) -+ PTR_MANGLE (*fptr); -+#endif -+} -diff --git a/nss/nss_module.c b/nss/nss_module.c -index 60c070c851..7b42c585a4 100644 ---- a/nss/nss_module.c -+++ b/nss/nss_module.c -@@ -30,6 +30,7 @@ - #include <stdio.h> - #include <stdlib.h> - #include <string.h> -+#include <nss_files.h> - - /* Suffix after .so of NSS service modules. This is a bit of magic, - but we assume LIBNSS_FILES_SO looks like "libnss_files.so.2" and we -@@ -110,10 +111,45 @@ static const function_name nss_function_name_array[] = - #include "function.def" - }; - -+static bool -+module_load_nss_files (struct nss_module *module) -+{ -+ if (is_nscd) -+ { -+ void (*cb) (size_t, struct traced_file *) = nscd_init_cb; -+# ifdef PTR_DEMANGLE -+ PTR_DEMANGLE (cb); -+# endif -+ _nss_files_init (cb); -+ } -+ -+ /* Initialize the function pointers, following the double-checked -+ locking idiom. */ -+ __libc_lock_lock (nss_module_list_lock); -+ switch ((enum nss_module_state) atomic_load_acquire (&module->state)) -+ { -+ case nss_module_uninitialized: -+ case nss_module_failed: -+ __nss_files_functions (module->functions.untyped); -+ module->handle = NULL; -+ /* Synchronizes with unlocked __nss_module_load atomic_load_acquire. */ -+ atomic_store_release (&module->state, nss_module_loaded); -+ break; -+ case nss_module_loaded: -+ /* Nothing to clean up. */ -+ break; -+ } -+ __libc_lock_unlock (nss_module_list_lock); -+ return true; -+} -+ - /* Internal implementation of __nss_module_load. */ - static bool - module_load (struct nss_module *module) - { -+ if (strcmp (module->name, "files") == 0) -+ return module_load_nss_files (module); -+ - void *handle; - { - char *shlib_name; -@@ -360,7 +396,7 @@ __nss_module_freeres (void) - struct nss_module *current = nss_module_list; - while (current != NULL) - { -- if (current->state == nss_module_loaded) -+ if (current->state == nss_module_loaded && current->handle != NULL) - __libc_dlclose (current->handle); - - struct nss_module *next = current->next; -diff --git a/nss/nss_module.h b/nss/nss_module.h -index 05c4791d11..c1a1d90b60 100644 ---- a/nss/nss_module.h -+++ b/nss/nss_module.h -@@ -38,6 +38,10 @@ struct nss_module_functions - typedef void *nss_module_functions_untyped[sizeof (struct nss_module_functions) - / sizeof (void *)]; - -+/* Locate the nss_files functions, as if by dlopen/dlsym. */ -+void __nss_files_functions (nss_module_functions_untyped pointers) -+ attribute_hidden; -+ - /* Initialization state of a NSS module. */ - enum nss_module_state - { -diff --git a/nss/nss_readline.c b/nss/nss_readline.c -index 4b3ecbccc8..a2f397a11f 100644 ---- a/nss/nss_readline.c -+++ b/nss/nss_readline.c -@@ -40,7 +40,7 @@ __nss_readline (FILE *fp, char *buf, size_t len, off64_t *poffset) - *poffset = __ftello64 (fp); - - buf[len - 1] = '\xff'; /* Marker to recognize truncation. */ -- if (fgets_unlocked (buf, len, fp) == NULL) -+ if (__fgets_unlocked (buf, len, fp) == NULL) - { - if (feof_unlocked (fp)) - { -@@ -61,7 +61,7 @@ __nss_readline (FILE *fp, char *buf, size_t len, off64_t *poffset) - line on the next call. */ - return __nss_readline_seek (fp, *poffset); - -- /* fgets_unlocked succeeded. */ -+ /* __fgets_unlocked succeeded. */ - - /* Remove leading whitespace. */ - char *p = buf; -diff --git a/nss/nss.h b/nss/nss.h -index ae213f9a6c..c6d62adc0f 100644 ---- a/nss/nss.h -+++ b/nss/nss.h -@@ -196,7 +196,7 @@ typedef enum nss_status nss_setspent (int); - extern nss_endgrent _nss_##module##_endgrent; \ - extern nss_endhostent _nss_##module##_endhostent; \ - extern nss_endnetent _nss_##module##_endnetent; \ -- extern nss_endnetgrent _nss_##module##__endnetgrent; \ -+ extern nss_endnetgrent _nss_##module##_endnetgrent; \ - extern nss_endprotoent _nss_##module##_endprotoent; \ - extern nss_endpwent _nss_##module##_endpwent; \ - extern nss_endrpcent _nss_##module##_endrpcent; \ -diff --git a/nss/nss_module.c b/nss/nss_module.c -index 7b42c585a4..7ea5ad9887 100644 ---- a/nss/nss_module.c -+++ b/nss/nss_module.c -@@ -114,14 +114,16 @@ static const function_name nss_function_name_array[] = - static bool - module_load_nss_files (struct nss_module *module) - { -+#ifdef USE_NSCD - if (is_nscd) - { - void (*cb) (size_t, struct traced_file *) = nscd_init_cb; --# ifdef PTR_DEMANGLE -+# ifdef PTR_DEMANGLE - PTR_DEMANGLE (cb); --# endif -+# endif - _nss_files_init (cb); - } -+#endif - - /* Initialize the function pointers, following the double-checked - locking idiom. */ diff --git a/gnu/packages/patches/gnumach-add-missing-const_mach_port_name_array_t-type.patch b/gnu/packages/patches/gnumach-add-missing-const_mach_port_name_array_t-type.patch new file mode 100644 index 0000000000..73c99ade23 --- /dev/null +++ b/gnu/packages/patches/gnumach-add-missing-const_mach_port_name_array_t-type.patch @@ -0,0 +1,32 @@ +From 17335d49a3c9e866a81abc051420d73a59d669bf Mon Sep 17 00:00:00 2001 +Message-Id: <17335d49a3c9e866a81abc051420d73a59d669bf.1678745341.git.dev@jpoiret.xyz> +From: Josselin Poiret <dev@jpoiret.xyz> +Date: Sun, 28 Aug 2022 01:17:34 +0200 +Subject: [PATCH] Add missing const_mach_port_name_array_t type + +From: Samuel Thibault <samuel.thibault@ens-lyon.org> + +--- + include/mach/port.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/include/mach/port.h b/include/mach/port.h +index 3c226f6c..d25eb0b4 100644 +--- a/include/mach/port.h ++++ b/include/mach/port.h +@@ -43,6 +43,7 @@ + */ + typedef unsigned int mach_port_name_t; + typedef mach_port_name_t *mach_port_name_array_t; ++typedef const mach_port_name_t *const_mach_port_name_array_t; + + /* + * A port is represented + +base-commit: 3e1702a65fb3caf50c8d09a1b383b0056a5efc82 +prerequisite-patch-id: 4688654277aef235ccd1797a72dce27d52b04616 +prerequisite-patch-id: 8f1e7dd6429c15cc8ed1d411dba0a75b6e745236 +prerequisite-patch-id: 605553ee086473ad9bc24e59c91d49a12dbf8631 +-- +2.39.1 + diff --git a/gnu/packages/patches/gnupg-CVE-2022-34903.patch b/gnu/packages/patches/gnupg-CVE-2022-34903.patch deleted file mode 100644 index 19c055282a..0000000000 --- a/gnu/packages/patches/gnupg-CVE-2022-34903.patch +++ /dev/null @@ -1,54 +0,0 @@ -https://dev.gnupg.org/T6027 -https://www.openwall.com/lists/oss-security/2022/06/30/1 -https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=commit;h=34c649b3601383cd11dbc76221747ec16fd68e1b - -From 34c649b3601383cd11dbc76221747ec16fd68e1b Mon Sep 17 00:00:00 2001 -From: Werner Koch <wk@gnupg.org> -Date: Tue, 14 Jun 2022 11:33:27 +0200 -Subject: [PATCH] g10: Fix garbled status messages in NOTATION_DATA - -* g10/cpr.c (write_status_text_and_buffer): Fix off-by-one --- - -Depending on the escaping and line wrapping the computed remaining -buffer length could be wrong. Fixed by always using a break to -terminate the escape detection loop. Might have happened for all -status lines which may wrap. - -GnuPG-bug-id: T6027 ---- - g10/cpr.c | 13 ++++--------- - 1 file changed, 4 insertions(+), 9 deletions(-) - -diff --git a/g10/cpr.c b/g10/cpr.c -index 9bfdd3c34..fa8005d6f 100644 ---- a/g10/cpr.c -+++ b/g10/cpr.c -@@ -372,20 +372,15 @@ write_status_text_and_buffer (int no, const char *string, - } - first = 0; - } -- for (esc=0, s=buffer, n=len; n && !esc; s++, n--) -+ for (esc=0, s=buffer, n=len; n; s++, n--) - { - if (*s == '%' || *(const byte*)s <= lower_limit - || *(const byte*)s == 127 ) - esc = 1; - if (wrap && ++count > wrap) -- { -- dowrap=1; -- break; -- } -- } -- if (esc) -- { -- s--; n++; -+ dowrap=1; -+ if (esc || dowrap) -+ break; - } - if (s != buffer) - es_fwrite (buffer, s-buffer, 1, statusfp); --- -2.11.0 - diff --git a/gnu/packages/patches/gnutls-guile-eintr-eagain.patch b/gnu/packages/patches/gnutls-guile-eintr-eagain.patch deleted file mode 100644 index e04c945158..0000000000 --- a/gnu/packages/patches/gnutls-guile-eintr-eagain.patch +++ /dev/null @@ -1,56 +0,0 @@ -Fixes <https://issues.guix.gnu.org/47867>. - -This fix was merged upstream -in <https://gitlab.com/gnutls/gnutls/-/merge_requests/1417> and will -be in GnuTLS 3.7.3. Upstream commit: - -commit 110e2172dbef1fbdf7399dab1e80780847b61c0c -Author: Ludovic Courtès <ludo@gnu.org> -Date: Sat Apr 24 22:02:14 2021 +0200 - - guile: Writes to record ports handle EAGAIN/EINTR transparently. - -diff --git a/guile/src/core.c b/guile/src/core.c -index a13670fc7b..0926dc8a97 100644 ---- a/guile/src/core.c -+++ b/guile/src/core.c -@@ -985,7 +985,10 @@ write_to_session_record_port (SCM port, const void *data, size_t size) - c_result = gnutls_record_send (c_session, (char *) data + c_sent, - size - c_sent); - if (EXPECT_FALSE (c_result < 0)) -- scm_gnutls_error (c_result, FUNC_NAME); -+ { -+ if (c_result != GNUTLS_E_AGAIN && c_result != GNUTLS_E_INTERRUPTED) -+ scm_gnutls_error (c_result, FUNC_NAME); -+ } - else - c_sent += c_result; - } -@@ -1069,7 +1072,8 @@ read_from_session_record_port (SCM port, SCM dst, size_t start, size_t count) - #undef FUNC_NAME - - /* Return the file descriptor that backs PORT. This function is called upon a -- blocking read--i.e., 'read_from_session_record_port' returned -1. */ -+ blocking read--i.e., 'read_from_session_record_port' or -+ 'write_to_session_record_port' returned -1. */ - static int - session_record_port_fd (SCM port) - { -@@ -1097,7 +1101,16 @@ write_to_session_record_port (SCM port, SCM src, size_t start, size_t count) - c_session = scm_to_gnutls_session (session, 1, FUNC_NAME); - data = (char *) SCM_BYTEVECTOR_CONTENTS (src) + start; - -- result = gnutls_record_send (c_session, data, count); -+ do -+ result = gnutls_record_send (c_session, data, count); -+ while (result == GNUTLS_E_INTERRUPTED -+ || (result == GNUTLS_E_AGAIN -+ && !SCM_GNUTLS_SESSION_TRANSPORT_IS_FD (c_session))); -+ -+ if (result == GNUTLS_E_AGAIN -+ && SCM_GNUTLS_SESSION_TRANSPORT_IS_FD (c_session)) -+ /* Tell Guile that reading would block. */ -+ return (size_t) -1; - - if (EXPECT_FALSE (result < 0)) - scm_gnutls_error (result, FUNC_NAME); diff --git a/gnu/packages/patches/gobject-introspection-absolute-shlib-path.patch b/gnu/packages/patches/gobject-introspection-absolute-shlib-path.patch index 956fa617c3..8bb86467c0 100644 --- a/gnu/packages/patches/gobject-introspection-absolute-shlib-path.patch +++ b/gnu/packages/patches/gobject-introspection-absolute-shlib-path.patch @@ -1,11 +1,14 @@ -# Names of libraries included in typelib files are opened by dlopen. Here we -# add the full path. -# -# This patch was provided by Luca Bruno <lucabru@src.gnome.org> for -# 'gobject-introspection' 1.40.0 in Nix. -# -# It has since been updated to work with newer versions of -# gobject-introspection. +Names of libraries included in typelib files are opened by dlopen. +Here we add the full path. + +This patch was provided by Luca Bruno <lucabru@src.gnome.org>, +for 'gobject-introspection' 1.40.0 in Nix. + +It has since been updated to work with newer versions of +gobject-introspection. + +diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py +index 1d39ab84..e12ed24e 100644 --- a/giscanner/scannermain.py +++ b/giscanner/scannermain.py @@ -95,6 +95,39 @@ def get_windows_option_group(parser): @@ -48,10 +51,10 @@ def _get_option_parser(): parser = optparse.OptionParser('%prog [options] sources', version='%prog ' + giscanner.__version__) -@@ -205,6 +238,10 @@ match the namespace prefix.""") - parser.add_option("", "--filelist", - action="store", dest="filelist", default=[], - help="file containing headers and sources to be scanned") +@@ -220,6 +253,10 @@ match the namespace prefix.""") + parser.add_option("", "--compiler", + action="store", dest="compiler", default=None, + help="the C compiler to use internally") + parser.add_option("", "--fallback-library-path", + action="store", dest="fallback_libpath", + default=_get_default_fallback_libpath(), @@ -59,6 +62,8 @@ group = get_preprocessor_option_group(parser) parser.add_option_group(group) +diff --git a/giscanner/shlibs.py b/giscanner/shlibs.py +index 9f8ab5df..8aa37c99 100644 --- a/giscanner/shlibs.py +++ b/giscanner/shlibs.py @@ -57,6 +57,14 @@ def _ldd_library_pattern(library_name): @@ -76,7 +81,7 @@ # This is a what we do for non-la files. We assume that we are on an # ELF-like system where ldd exists and the soname extracted with ldd is # a filename that can be opened with dlopen(). -@@ -106,7 +112,8 @@ def _resolve_non_libtool(options, binary, libraries): +@@ -108,7 +116,8 @@ def _resolve_non_libtool(options, binary, libraries): output = output.decode("utf-8", "replace") shlibs = resolve_from_ldd_output(libraries, output) @@ -86,7 +91,7 @@ def sanitize_shlib_path(lib): -@@ -115,19 +122,18 @@ def sanitize_shlib_path(lib): +@@ -117,19 +126,18 @@ def sanitize_shlib_path(lib): # In case we get relative paths on macOS (like @rpath) then we fall # back to the basename as well: # https://gitlab.gnome.org/GNOME/gobject-introspection/issues/222 @@ -111,7 +116,7 @@ if len(patterns) == 0: return [] -@@ -139,8 +145,12 @@ def resolve_from_ldd_output(libraries, output): +@@ -141,8 +149,12 @@ def resolve_from_ldd_output(libraries, output): if line.endswith(':'): continue for word in line.split(): @@ -126,10 +131,11 @@ if m: del patterns[library] shlibs.append(m.group()) - +diff --git a/giscanner/utils.py b/giscanner/utils.py +index 31c7ea48..630002a8 100644 --- a/giscanner/utils.py +++ b/giscanner/utils.py -@@ -111,17 +111,11 @@ def extract_libtool_shlib(la_file): +@@ -114,16 +114,11 @@ def extract_libtool_shlib(la_file): if dlname is None: return None @@ -141,8 +147,7 @@ - if libdir is None: - return dlbasename - return libdir + '/' + dlbasename -- # From the comments in extract_libtool(), older libtools had -- # a path rather than the raw dlname +- # Older libtools had a path rather than the raw dlname - return os.path.basename(dlname) + dlbasename = os.path.basename(dlname) + libdir = _extract_libdir_field(la_file) @@ -151,10 +156,12 @@ + return libdir + '/' + dlbasename - def extract_libtool(la_file): + # Returns arguments for invoking libtool, if applicable, otherwise None +diff --git a/tests/scanner/test_shlibs.py b/tests/scanner/test_shlibs.py +index a8337c60..7f123103 100644 --- a/tests/scanner/test_shlibs.py +++ b/tests/scanner/test_shlibs.py -@@ -40,6 +64,7 @@ class TestLddParser(unittest.TestCase): +@@ -40,7 +40,8 @@ class TestLddParser(unittest.TestCase): self.assertEqual( sanitize_shlib_path('/foo/bar'), @@ -163,4 +170,4 @@ + '/foo/bar') def test_unresolved_library(self): -output = '' + output = '' diff --git a/gnu/packages/patches/gobject-introspection-cc.patch b/gnu/packages/patches/gobject-introspection-cc.patch index 6a86b56b44..d3b1df82af 100644 --- a/gnu/packages/patches/gobject-introspection-cc.patch +++ b/gnu/packages/patches/gobject-introspection-cc.patch @@ -1,12 +1,13 @@ Use gcc as the default C compiler if CC is not set. -diff -ru gobject-introspection-1.58.1.orig/giscanner/__init__.py gobject-introspection-1.58.1/giscanner/__init__.py ---- gobject-introspection-1.58.1.orig/giscanner/__init__.py 1970-01-01 01:00:00.000000000 +0100 -+++ gobject-introspection-1.58.1/giscanner/__init__.py 2018-12-03 13:33:28.788971299 +0100 -@@ -22,6 +22,8 @@ +diff --git a/giscanner/__init__.py b/giscanner/__init__.py +index 7c2f365a..607fe341 100644 +--- a/giscanner/__init__.py ++++ b/giscanner/__init__.py +@@ -21,6 +21,8 @@ import os builddir = os.environ.get('UNINSTALLED_INTROSPECTION_BUILDDIR') if builddir is not None: - __path__.append(os.path.join(builddir, 'giscanner')) + __path__.append(os.path.join(builddir, 'giscanner')) # type: ignore # mypy issue #1422 +if not 'CC' in os.environ: + os.environ['CC'] = 'gcc' try: diff --git a/gnu/packages/patches/guile-hurd-posix-spawn.patch b/gnu/packages/patches/guile-hurd-posix-spawn.patch new file mode 100644 index 0000000000..7cf600b4c2 --- /dev/null +++ b/gnu/packages/patches/guile-hurd-posix-spawn.patch @@ -0,0 +1,44 @@ +Fix <https://issues.guix.gnu.org/61095>, which affects GNU/Hurd. + +diff --git a/libguile/posix.c b/libguile/posix.c +index 3a8be94e4..f5fdc544c 100644 +--- a/libguile/posix.c ++++ b/libguile/posix.c +@@ -1326,7 +1326,14 @@ static void + close_inherited_fds_slow (posix_spawn_file_actions_t *actions, int max_fd) + { + while (--max_fd > 2) +- posix_spawn_file_actions_addclose (actions, max_fd); ++ { ++ /* Adding invalid file descriptors to an 'addclose' action leads ++ to 'posix_spawn' failures on some operating systems: ++ <https://bugs.gnu.org/61095>. Hence the extra check. */ ++ int flags = fcntl (max_fd, F_GETFD, NULL); ++ if ((flags >= 0) && ((flags & FD_CLOEXEC) == 0)) ++ posix_spawn_file_actions_addclose (actions, max_fd); ++ } + } + + static void + +Fix <https://issues.guix.gnu.org/62501>. + +diff --git a/test-suite/tests/posix.test b/test-suite/tests/posix.test +index f20e04453..d5cf47cda 100644 +--- a/test-suite/tests/posix.test ++++ b/test-suite/tests/posix.test +@@ -431,7 +431,13 @@ + (let ((str (get-string-all (car input+output)))) + (close-port (car input+output)) + (waitpid pid) +- str))) ++ ++ ;; On GNU/Hurd, the exec server prepends 'LD_ORIGIN_PATH' for ++ ;; every program: <https://bugs.gnu.org/62501>. Strip it. ++ (if (and (string=? "GNU" (utsname:sysname (uname))) ++ (string-prefix? "LD_ORIGIN_PATH=" str)) ++ (string-drop str (+ 1 (string-index str #\newline))) ++ str)))) + + (pass-if-equal "ls /proc/self/fd" + "0\n1\n2\n3\n" ;fourth FD is for /proc/self/fd diff --git a/gnu/packages/patches/hurd-add-without-rump-configure-option.patch b/gnu/packages/patches/hurd-add-without-rump-configure-option.patch new file mode 100644 index 0000000000..14cefdeac1 --- /dev/null +++ b/gnu/packages/patches/hurd-add-without-rump-configure-option.patch @@ -0,0 +1,82 @@ +From 80bc1678b7b859decae536e726a3e5870cbe84eb Mon Sep 17 00:00:00 2001 +Message-Id: <80bc1678b7b859decae536e726a3e5870cbe84eb.1678657122.git.dev@jpoiret.xyz> +In-Reply-To: <c9b816085272dd07ed762c5ae775a994fa77df56.1678657122.git.dev@jpoiret.xyz> +References: <c9b816085272dd07ed762c5ae775a994fa77df56.1678657122.git.dev@jpoiret.xyz> +From: Josselin Poiret <dev@jpoiret.xyz> +Date: Mon, 31 Oct 2022 13:39:28 +0100 +Subject: [PATCH 2/2] Add --without-rump configure option + +From: Samuel Thibault <samuel.thibault@ens-lyon.org> + +To allow cross-builds which cannot use AC_LINK_IFELSE at all. +--- + configure.ac | 47 ++++++++++++++++++++++++++--------------------- + 1 file changed, 26 insertions(+), 21 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 0c1bf9b2..849b5fad 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -234,33 +234,38 @@ AS_IF([test "x$with_libz" != xno], [ + ]) + AC_SUBST([HAVE_LIBZ]) + +-# Save +-oldLIBS="$LIBS" ++AC_ARG_WITH([rump], ++ [AS_HELP_STRING([--without-rump], [disable rump])], , [with_rump=yes]) + +-LIBS="$oldLIBS -lrump" +-AC_LINK_IFELSE( +- [AC_LANG_PROGRAM( +- [[#include <hurd.h> ++AS_IF([test "x$with_rump" != xno], [ ++ # Save ++ oldLIBS="$LIBS" ++ ++ LIBS="$oldLIBS -lrump" ++ AC_LINK_IFELSE( ++ [AC_LANG_PROGRAM( ++ [[#include <hurd.h> + #define _STANDALONE + #include <rump/rump.h>]], +- [])], +- [HAVE_LIBRUMP=yes], +- [HAVE_LIBRUMP=no]) +-AC_SUBST([HAVE_LIBRUMP]) +- +-LIBS="$oldLIBS -lrumpvfs_nofifofs_pic" +-AC_LINK_IFELSE( +- [AC_LANG_PROGRAM( +- [[#include <hurd.h> ++ [])], ++ [HAVE_LIBRUMP=yes], ++ [HAVE_LIBRUMP=no]) ++ AC_SUBST([HAVE_LIBRUMP]) ++ ++ LIBS="$oldLIBS -lrumpvfs_nofifofs_pic" ++ AC_LINK_IFELSE( ++ [AC_LANG_PROGRAM( ++ [[#include <hurd.h> + #define _STANDALONE + #include <rump/rump.h>]], +- [])], +- [HAVE_LIBRUMP_VFSNOFIFO=yes], +- [HAVE_LIBRUMP_VFSNOFIFO=no]) +-AC_SUBST([HAVE_LIBRUMP_VFSNOFIFO]) ++ [])], ++ [HAVE_LIBRUMP_VFSNOFIFO=yes], ++ [HAVE_LIBRUMP_VFSNOFIFO=no]) ++ AC_SUBST([HAVE_LIBRUMP_VFSNOFIFO]) + +-# Reset +-LIBS="$oldLIBS" ++ # Reset ++ LIBS="$oldLIBS" ++]) + + AC_ARG_ENABLE(boot-store-types, + [ --enable-boot-store-types=TYPES... +-- +2.39.1 + diff --git a/gnu/packages/patches/hurd-cross.patch b/gnu/packages/patches/hurd-cross.patch deleted file mode 100644 index cc95dddccc..0000000000 --- a/gnu/packages/patches/hurd-cross.patch +++ /dev/null @@ -1,33 +0,0 @@ -This fixes linking libfstest/test-fcntl (and others). - -As discussed with upstream: https://lists.gnu.org/archive/html/bug-hurd/2020-03/msg00018.html - -From 96a9f67a8685e713f25259c18306797d54cc27a5 Mon Sep 17 00:00:00 2001 -From: Jan Nieuwenhuizen <janneke@gnu.org> -Date: Sat, 14 Mar 2020 11:28:31 +0100 -Subject: [PATCH] build: Fix cross build on Guix. - -As discussed in https://lists.gnu.org/archive/html/bug-hurd/2020-03/msg00018.html. - -* Makeconf (lpath): Add -Wl,-rpath-link=<dir> next to -L<dir>. ---- - Makeconf | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/Makeconf b/Makeconf -index 67f7ab1c..f68ff6e3 100644 ---- a/Makeconf -+++ b/Makeconf -@@ -325,7 +325,8 @@ _libsubst=${libsubst$(patsubst %,-override,${libsubst-override})} - - # Direct the linker where to find shared objects specified in the - # dependencies of other shared objects it encounters. --lpath := -L. $(patsubst %,-L%,$(dir $(wildcard ../lib*/lib*.so))) -+lib_dirs := $(dir $(wildcard ../lib*/lib*.so)) -+lpath := -L. $(lib_dirs:%=-L%) $(lib_dirs:%=-Wl,-rpath-link=%) - - # Main rule to link executables - # --- -2.24.0 - diff --git a/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods-2.patch b/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods-2.patch new file mode 100644 index 0000000000..dda95fb3d5 --- /dev/null +++ b/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods-2.patch @@ -0,0 +1,155 @@ +From eb1b2057d839249c955189c2cba8bc37c66d4151 Mon Sep 17 00:00:00 2001 +Message-Id: <eb1b2057d839249c955189c2cba8bc37c66d4151.1678793830.git.dev@jpoiret.xyz> +In-Reply-To: <f0cacda83293e4d792b8d12665fcb795dc11d6fc.1678793830.git.dev@jpoiret.xyz> +References: <f0cacda83293e4d792b8d12665fcb795dc11d6fc.1678793830.git.dev@jpoiret.xyz> +From: Josselin Poiret <dev@jpoiret.xyz> +Date: Tue, 30 Aug 2022 00:59:59 +0200 +Subject: [PATCH 2/2] Fix types of read write and readables methods + +From: Samuel Thibault <samuel.thibault@ens-lyon.org> + +This completes 5adb4b834b1e +--- + hurd/pci.defs | 2 +- + lwip/io-ops.c | 6 +++--- + lwip/port/netif/hurdtunif.c | 6 +++--- + lwip/socket-ops.c | 4 ++-- + pci-arbiter/pci-ops.c | 4 ++-- + storeio/open.c | 2 +- + 6 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/hurd/pci.defs b/hurd/pci.defs +index 23c90334..e258f5ce 100644 +--- a/hurd/pci.defs ++++ b/hurd/pci.defs +@@ -51,7 +51,7 @@ routine pci_conf_write( + */ + routine pci_get_ndevs( + master: pci_t; +- out ndevs: vm_size_t ++ out ndevs: mach_msg_type_number_t + ); + + /* +diff --git a/lwip/io-ops.c b/lwip/io-ops.c +index 5461d695..6cc724ce 100644 +--- a/lwip/io-ops.c ++++ b/lwip/io-ops.c +@@ -36,7 +36,7 @@ error_t + lwip_S_io_write (struct sock_user *user, + const_data_t data, + size_t datalen, +- off_t offset, mach_msg_type_number_t * amount) ++ off_t offset, vm_size_t * amount) + { + int sent; + int sockflags; +@@ -59,7 +59,7 @@ lwip_S_io_write (struct sock_user *user, + error_t + lwip_S_io_read (struct sock_user * user, + data_t *data, +- size_t * datalen, off_t offset, mach_msg_type_number_t amount) ++ size_t * datalen, off_t offset, vm_size_t amount) + { + error_t err; + int alloced = 0; +@@ -112,7 +112,7 @@ lwip_S_io_seek (struct sock_user * user, + } + + error_t +-lwip_S_io_readable (struct sock_user * user, mach_msg_type_number_t * amount) ++lwip_S_io_readable (struct sock_user * user, vm_size_t * amount) + { + error_t err; + if (!user) +diff --git a/lwip/port/netif/hurdtunif.c b/lwip/port/netif/hurdtunif.c +index 79a082cf..c976703f 100644 +--- a/lwip/port/netif/hurdtunif.c ++++ b/lwip/port/netif/hurdtunif.c +@@ -348,7 +348,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t * data_len, +- loff_t offs, size_t amount) ++ loff_t offs, vm_size_t amount) + { + struct hurdtunif *tunif; + struct pbuf *p; +@@ -423,7 +423,7 @@ trivfs_S_io_write (struct trivfs_protid * cred, + mach_msg_type_name_t replytype, + const_data_t data, + mach_msg_type_number_t datalen, +- off_t offset, mach_msg_type_number_t * amount) ++ off_t offset, vm_size_t * amount) + { + struct netif *netif; + struct pbuf *p, *q; +@@ -482,7 +482,7 @@ trivfs_S_io_write (struct trivfs_protid * cred, + kern_return_t + trivfs_S_io_readable (struct trivfs_protid * cred, + mach_port_t reply, mach_msg_type_name_t replytype, +- mach_msg_type_number_t * amount) ++ vm_size_t * amount) + { + struct hurdtunif *tunif; + +diff --git a/lwip/socket-ops.c b/lwip/socket-ops.c +index 5b50f58c..d5e3cb07 100644 +--- a/lwip/socket-ops.c ++++ b/lwip/socket-ops.c +@@ -342,7 +342,7 @@ lwip_S_socket_send (struct sock_user * user, + const mach_port_t * ports, + size_t nports, + const char *control, +- size_t controllen, mach_msg_type_number_t * amount) ++ size_t controllen, vm_size_t * amount) + { + int sent; + int sockflags; +@@ -392,7 +392,7 @@ lwip_S_socket_recv (struct sock_user * user, + size_t * nports, + char **control, + size_t * controllen, +- int *outflags, mach_msg_type_number_t amount) ++ int *outflags, vm_size_t amount) + { + error_t err; + union { struct sockaddr_storage storage; struct sockaddr sa; } addr; +diff --git a/pci-arbiter/pci-ops.c b/pci-arbiter/pci-ops.c +index ef27a3cd..d721f368 100644 +--- a/pci-arbiter/pci-ops.c ++++ b/pci-arbiter/pci-ops.c +@@ -80,7 +80,7 @@ calculate_ndevs (struct iouser *user) + */ + error_t + S_pci_conf_read (struct protid * master, int reg, char **data, +- size_t * datalen, mach_msg_type_number_t amount) ++ size_t * datalen, vm_size_t amount) + { + error_t err; + pthread_mutex_t *lock; +@@ -129,7 +129,7 @@ S_pci_conf_read (struct protid * master, int reg, char **data, + /* Write `datalen' bytes from `data'. `amount' is updated. */ + error_t + S_pci_conf_write (struct protid * master, int reg, const char *data, size_t datalen, +- mach_msg_type_number_t * amount) ++ vm_size_t * amount) + { + error_t err; + pthread_mutex_t *lock; +diff --git a/storeio/open.c b/storeio/open.c +index f8eb6ce0..74902520 100644 +--- a/storeio/open.c ++++ b/storeio/open.c +@@ -75,7 +75,7 @@ open_write (struct open *open, off_t offs, const void *buf, size_t len, + otherwise the error code is returned. */ + error_t + open_read (struct open *open, off_t offs, vm_size_t amount, +- void **buf, size_t *len) ++ void **buf, vm_size_t *len) + { + error_t err; + if (offs < 0) +-- +2.39.1 + diff --git a/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods.patch b/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods.patch new file mode 100644 index 0000000000..aebe8d6847 --- /dev/null +++ b/gnu/packages/patches/hurd-fix-types-of-read-write-and-readables-methods.patch @@ -0,0 +1,891 @@ +From 5adb4b834b1eba82b7f3eca6324bed0355cae0af Mon Sep 17 00:00:00 2001 +Message-Id: <5adb4b834b1eba82b7f3eca6324bed0355cae0af.1678815112.git.dev@jpoiret.xyz> +From: Josselin Poiret <dev@jpoiret.xyz> +Date: Mon, 29 Aug 2022 21:36:17 +0200 +Subject: [PATCH] Fix types of read write and readables methods + +From: Etienne Brateau <etienne.brateau@gmail.com> + +Message-Id: <20220829193617.13481-1-etienne.brateau@gmail.com> +--- + boot/boot.c | 6 +++--- + console-client/trans.c | 4 ++-- + libdiskfs/io-read.c | 2 +- + libdiskfs/io-readable.c | 2 +- + libdiskfs/io-write.c | 2 +- + libnetfs/io-read.c | 2 +- + libnetfs/io-readable.c | 2 +- + libnetfs/io-write.c | 2 +- + libpager/data-return.c | 2 +- + libstore/nbd.c | 6 +++--- + libstore/rdwr.c | 4 ++-- + libtrivfs/io-read.c | 2 +- + libtrivfs/io-readable.c | 2 +- + libtrivfs/io-write.c | 2 +- + mach-defpager/default_pager.c | 4 ++-- + pfinet/io-ops.c | 10 +++++----- + pfinet/socket-ops.c | 16 ++++++++-------- + pfinet/tunnel.c | 6 +++--- + pflocal/io.c | 6 +++--- + pflocal/socket.c | 14 +++++++------- + storeio/io.c | 8 ++++---- + storeio/open.c | 4 ++-- + storeio/open.h | 6 +++--- + term/ptyio.c | 4 ++-- + term/term.h | 4 ++-- + term/users.c | 14 +++++++------- + trans/fifo.c | 10 +++++----- + trans/firmlink.c | 4 ++-- + trans/hello-mt.c | 2 +- + trans/hello.c | 2 +- + trans/mtab.c | 4 ++-- + trans/new-fifo.c | 10 +++++----- + trans/null.c | 8 ++++---- + trans/proxy-defpager.c | 6 +++--- + trans/random.c | 6 +++--- + trans/streamio.c | 6 +++--- + 36 files changed, 97 insertions(+), 97 deletions(-) + +diff --git a/boot/boot.c b/boot/boot.c +index 1b10c86b..f326e5b2 100644 +--- a/boot/boot.c ++++ b/boot/boot.c +@@ -1412,7 +1412,7 @@ S_io_write (mach_port_t object, + const_data_t data, + mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amtwritten) ++ vm_size_t *amtwritten) + { + if (object != pseudo_console) + return EOPNOTSUPP; +@@ -1437,7 +1437,7 @@ S_io_read (mach_port_t object, + data_t *data, + mach_msg_type_number_t *datalen, + off_t offset, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + mach_msg_type_number_t avail; + +@@ -1489,7 +1489,7 @@ kern_return_t + S_io_readable (mach_port_t object, + mach_port_t reply_port, + mach_msg_type_name_t reply_type, +- mach_msg_type_number_t *amt) ++ vm_size_t *amt) + { + if (object != pseudo_console) + return EOPNOTSUPP; +diff --git a/console-client/trans.c b/console-client/trans.c +index fe4b9ca4..49e30a61 100644 +--- a/console-client/trans.c ++++ b/console-client/trans.c +@@ -578,7 +578,7 @@ netfs_S_io_read (struct protid *user, + data_t *data, + mach_msg_type_number_t *datalen, + off_t offset, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + struct node *np; + +@@ -597,7 +597,7 @@ netfs_S_io_write (struct protid *user, + const_data_t data, + mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + struct node *np; + +diff --git a/libdiskfs/io-read.c b/libdiskfs/io-read.c +index 71803517..a706d677 100644 +--- a/libdiskfs/io-read.c ++++ b/libdiskfs/io-read.c +@@ -25,7 +25,7 @@ diskfs_S_io_read (struct protid *cred, + data_t *data, + mach_msg_type_number_t *datalen, + off_t offset, +- mach_msg_type_number_t maxread) ++ vm_size_t maxread) + { + struct node *np; + int err; +diff --git a/libdiskfs/io-readable.c b/libdiskfs/io-readable.c +index c3debac3..03218bf3 100644 +--- a/libdiskfs/io-readable.c ++++ b/libdiskfs/io-readable.c +@@ -22,7 +22,7 @@ + /* Implement io_readable as described in <hurd/io.defs>. */ + kern_return_t + diskfs_S_io_readable (struct protid *cred, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + struct node *np; + +diff --git a/libdiskfs/io-write.c b/libdiskfs/io-write.c +index 154bc887..9efed88f 100644 +--- a/libdiskfs/io-write.c ++++ b/libdiskfs/io-write.c +@@ -25,7 +25,7 @@ diskfs_S_io_write (struct protid *cred, + const_data_t data, + mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amt) ++ vm_size_t *amt) + { + struct node *np; + error_t err; +diff --git a/libnetfs/io-read.c b/libnetfs/io-read.c +index 2427ce6c..688da1f6 100644 +--- a/libnetfs/io-read.c ++++ b/libnetfs/io-read.c +@@ -28,7 +28,7 @@ netfs_S_io_read (struct protid *user, + data_t *data, + mach_msg_type_number_t *datalen, + off_t offset, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + error_t err; + off_t start; +diff --git a/libnetfs/io-readable.c b/libnetfs/io-readable.c +index 07becf66..7c365484 100644 +--- a/libnetfs/io-readable.c ++++ b/libnetfs/io-readable.c +@@ -25,7 +25,7 @@ + + error_t + netfs_S_io_readable (struct protid *user, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + error_t err; + +diff --git a/libnetfs/io-write.c b/libnetfs/io-write.c +index 482b45fc..2306d1f0 100644 +--- a/libnetfs/io-write.c ++++ b/libnetfs/io-write.c +@@ -27,7 +27,7 @@ netfs_S_io_write (struct protid *user, + const_data_t data, + mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + error_t err; + off_t off = offset; +diff --git a/libpager/data-return.c b/libpager/data-return.c +index c0f5aaf7..4c4affe8 100644 +--- a/libpager/data-return.c ++++ b/libpager/data-return.c +@@ -258,7 +258,7 @@ _pager_S_memory_object_data_return (struct pager *p, + mach_port_t control, + vm_offset_t offset, + pointer_t data, +- vm_size_t length, ++ mach_msg_type_number_t length, + int dirty, + int kcopy) + { +diff --git a/libstore/nbd.c b/libstore/nbd.c +index 3138af01..8e0892e3 100644 +--- a/libstore/nbd.c ++++ b/libstore/nbd.c +@@ -119,7 +119,7 @@ nbd_write (struct store *store, + type: htonl (1), /* WRITE */ + }; + error_t err; +- mach_msg_type_number_t cc; ++ vm_size_t cc; + + addr <<= store->log2_block_size; + *amount = 0; +@@ -178,7 +178,7 @@ nbd_read (struct store *store, + requested can be found in CHUNK. */ + inline error_t request_chunk (char **buf, size_t *len) + { +- mach_msg_type_number_t cc; ++ vm_size_t cc; + + chunk = (amount - ofs) < NBD_IO_MAX ? (amount - ofs) : NBD_IO_MAX; + +@@ -435,7 +435,7 @@ nbdclose (struct store *store) + magic: NBD_REQUEST_MAGIC, + type: htonl (2), /* disconnect */ + }; +- mach_msg_type_number_t cc; ++ vm_size_t cc; + (void) io_write (store->port, (char *) &req, sizeof req, -1, &cc); + + /* Close the socket. */ +diff --git a/libstore/rdwr.c b/libstore/rdwr.c +index 9737c515..f443ad9f 100644 +--- a/libstore/rdwr.c ++++ b/libstore/rdwr.c +@@ -120,7 +120,7 @@ store_write (struct store *store, + else + /* ARGH, we've got to split up the write ... */ + { +- mach_msg_type_number_t try, written; ++ vm_size_t try, written; + + /* Write the initial bit in the first run. Errors here are returned. */ + try = (run->length - addr) << block_shift; +@@ -138,7 +138,7 @@ store_write (struct store *store, + && run->start >= 0) /* Check for holes. */ + /* Ok, we can write in this run, at least a bit. */ + { +- mach_msg_type_number_t seg_written; ++ vm_size_t seg_written; + + if ((len >> block_shift) <= run->length) + try = len; +diff --git a/libtrivfs/io-read.c b/libtrivfs/io-read.c +index a911f778..4d3302e4 100644 +--- a/libtrivfs/io-read.c ++++ b/libtrivfs/io-read.c +@@ -26,7 +26,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + data_t *data, + mach_msg_type_number_t *datalen, + off_t off, +- mach_msg_type_number_t amt) ++ vm_size_t amt) + { + assert_backtrace (!trivfs_support_read); + return EOPNOTSUPP; +diff --git a/libtrivfs/io-readable.c b/libtrivfs/io-readable.c +index de4d32b8..acb3fa52 100644 +--- a/libtrivfs/io-readable.c ++++ b/libtrivfs/io-readable.c +@@ -23,7 +23,7 @@ kern_return_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, + mach_msg_type_name_t replytype, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + assert_backtrace (!trivfs_support_read); + return EOPNOTSUPP; +diff --git a/libtrivfs/io-write.c b/libtrivfs/io-write.c +index 74cbb32b..787b2544 100644 +--- a/libtrivfs/io-write.c ++++ b/libtrivfs/io-write.c +@@ -27,7 +27,7 @@ trivfs_S_io_write (struct trivfs_protid *cred, + const_data_t data, + mach_msg_type_number_t datalen, + off_t off, +- mach_msg_type_number_t *amt) ++ vm_size_t *amt) + { + if (!(trivfs_allow_open & O_WRITE)) + return EBADF; +diff --git a/mach-defpager/default_pager.c b/mach-defpager/default_pager.c +index fd3a7b22..5c1352f4 100644 +--- a/mach-defpager/default_pager.c ++++ b/mach-defpager/default_pager.c +@@ -2572,7 +2572,7 @@ seqnos_memory_object_data_initialize(ds, seqno, pager_request, + vm_offset_t offset; + register + pointer_t addr; +- vm_size_t data_cnt; ++ mach_msg_type_number_t data_cnt; + { + vm_offset_t amount_sent; + static char here[] = "%sdata_initialize"; +@@ -2631,7 +2631,7 @@ seqnos_memory_object_data_return(ds, seqno, pager_request, + mach_port_t pager_request; + vm_offset_t offset; + pointer_t addr; +- vm_size_t data_cnt; ++ mach_msg_type_number_t data_cnt; + boolean_t dirty; + boolean_t kernel_copy; + { +diff --git a/pfinet/io-ops.c b/pfinet/io-ops.c +index fa6350c3..6269743d 100644 +--- a/pfinet/io-ops.c ++++ b/pfinet/io-ops.c +@@ -37,9 +37,9 @@ + error_t + S_io_write (struct sock_user *user, + const_data_t data, +- size_t datalen, ++ mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + error_t err; + struct iovec iov = { (void*) data, datalen }; +@@ -70,9 +70,9 @@ S_io_write (struct sock_user *user, + error_t + S_io_read (struct sock_user *user, + data_t *data, +- size_t *datalen, ++ mach_msg_type_number_t *datalen, + off_t offset, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + error_t err; + int alloced = 0; +@@ -135,7 +135,7 @@ S_io_seek (struct sock_user *user, + + error_t + S_io_readable (struct sock_user *user, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + struct sock *sk; + error_t err; +diff --git a/pfinet/socket-ops.c b/pfinet/socket-ops.c +index db1b92cd..8d27c383 100644 +--- a/pfinet/socket-ops.c ++++ b/pfinet/socket-ops.c +@@ -431,12 +431,12 @@ S_socket_send (struct sock_user *user, + struct sock_addr *addr, + int flags, + const_data_t data, +- size_t datalen, ++ mach_msg_type_number_t datalen, + const mach_port_t *ports, +- size_t nports, ++ mach_msg_type_number_t nports, + const_data_t control, +- size_t controllen, +- mach_msg_type_number_t *amount) ++ mach_msg_type_number_t controllen, ++ vm_size_t *amount) + { + int sent; + struct iovec iov = { (void*) data, datalen }; +@@ -478,14 +478,14 @@ S_socket_recv (struct sock_user *user, + mach_msg_type_name_t *addrporttype, + int flags, + data_t *data, +- size_t *datalen, ++ mach_msg_type_number_t *datalen, + mach_port_t **ports, + mach_msg_type_name_t *portstype, +- size_t *nports, ++ mach_msg_type_number_t *nports, + data_t *control, +- size_t *controllen, ++ mach_msg_type_number_t *controllen, + int *outflags, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + error_t err; + union { struct sockaddr_storage storage; struct sockaddr sa; } addr; +diff --git a/pfinet/tunnel.c b/pfinet/tunnel.c +index 1082404e..e11ab670 100644 +--- a/pfinet/tunnel.c ++++ b/pfinet/tunnel.c +@@ -291,7 +291,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, size_t amount) ++ off_t offs, vm_size_t amount) + { + struct tunnel_device *tdev; + struct sk_buff *skb; +@@ -372,7 +372,7 @@ trivfs_S_io_write (struct trivfs_protid *cred, + const_data_t data, + mach_msg_type_number_t datalen, + off_t offset, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + struct tunnel_device *tdev; + struct sk_buff *skb; +@@ -415,7 +415,7 @@ trivfs_S_io_write (struct trivfs_protid *cred, + kern_return_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + struct tunnel_device *tdev; + struct sk_buff *skb; +diff --git a/pflocal/io.c b/pflocal/io.c +index 96b2fc48..06749756 100644 +--- a/pflocal/io.c ++++ b/pflocal/io.c +@@ -44,7 +44,7 @@ + error_t + S_io_read (struct sock_user *user, + data_t *data, mach_msg_type_number_t *data_len, +- off_t offset, mach_msg_type_number_t amount) ++ off_t offset, vm_size_t amount) + { + error_t err; + struct pipe *pipe; +@@ -80,7 +80,7 @@ S_io_read (struct sock_user *user, + error_t + S_io_write (struct sock_user *user, + const_data_t data, mach_msg_type_number_t data_len, +- off_t offset, mach_msg_type_number_t *amount) ++ off_t offset, vm_size_t *amount) + { + error_t err; + struct pipe *pipe; +@@ -119,7 +119,7 @@ S_io_write (struct sock_user *user, + a "long time" (this should be the same meaning of "long time" used + by the nonblocking flag. */ + error_t +-S_io_readable (struct sock_user *user, mach_msg_type_number_t *amount) ++S_io_readable (struct sock_user *user, vm_size_t *amount) + { + error_t err; + struct pipe *pipe; +diff --git a/pflocal/socket.c b/pflocal/socket.c +index 8c1ee3e9..8c240e09 100644 +--- a/pflocal/socket.c ++++ b/pflocal/socket.c +@@ -287,10 +287,10 @@ S_socket_peername (struct sock_user *user, + /* Send data over a socket, possibly including Mach ports. */ + error_t + S_socket_send (struct sock_user *user, struct addr *dest_addr, int flags, +- const_data_t data, size_t data_len, +- const mach_port_t *ports, size_t num_ports, +- const_data_t control, size_t control_len, +- size_t *amount) ++ const_data_t data, mach_msg_type_number_t data_len, ++ const mach_port_t *ports, mach_msg_type_number_t num_ports, ++ const_data_t control, mach_msg_type_number_t control_len, ++ vm_size_t *amount) + { + error_t err = 0; + int noblock; +@@ -378,11 +378,11 @@ error_t + S_socket_recv (struct sock_user *user, + mach_port_t *addr, mach_msg_type_name_t *addr_type, + int in_flags, +- data_t *data, size_t *data_len, ++ data_t *data, mach_msg_type_name_t *data_len, + mach_port_t **ports, mach_msg_type_name_t *ports_type, + size_t *num_ports, +- data_t *control, size_t *control_len, +- int *out_flags, size_t amount) ++ data_t *control, mach_msg_type_name_t *control_len, ++ int *out_flags, vm_size_t amount) + { + error_t err; + unsigned flags; +diff --git a/storeio/io.c b/storeio/io.c +index 634185f7..3c4cb9ff 100644 +--- a/storeio/io.c ++++ b/storeio/io.c +@@ -83,8 +83,8 @@ trivfs_S_io_map (struct trivfs_protid *cred, + error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ data_t *data, mach_msg_type_name_t *data_len, ++ off_t offs, vm_size_t amount) + { + if (! cred) + return EOPNOTSUPP; +@@ -101,7 +101,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + if (! cred) + return EOPNOTSUPP; +@@ -126,7 +126,7 @@ error_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + const_data_t data, mach_msg_type_number_t data_len, +- loff_t offs, mach_msg_type_number_t *amount) ++ off_t offs, vm_size_t *amount) + { + if (! cred) + return EOPNOTSUPP; +diff --git a/storeio/open.c b/storeio/open.c +index 4c2870c6..f8eb6ce0 100644 +--- a/storeio/open.c ++++ b/storeio/open.c +@@ -74,8 +74,8 @@ open_write (struct open *open, off_t offs, const void *buf, size_t len, + standard mach out-array convention. If no error occurs, zero is returned, + otherwise the error code is returned. */ + error_t +-open_read (struct open *open, off_t offs, size_t amount, +- void **buf, vm_size_t *len) ++open_read (struct open *open, off_t offs, vm_size_t amount, ++ void **buf, size_t *len) + { + error_t err; + if (offs < 0) +diff --git a/storeio/open.h b/storeio/open.h +index 6be930a6..ad2678ff 100644 +--- a/storeio/open.h ++++ b/storeio/open.h +@@ -51,13 +51,13 @@ void open_free (struct open *open); + and returns the number of bytes written in AMOUNT. If no error occurs, + zero is returned, otherwise the error code is returned. */ + error_t open_write (struct open *open, off_t offs, const void *buf, size_t len, +- size_t *amount); ++ vm_size_t *amount); + + /* Reads up to AMOUNT bytes from the device into BUF and BUF_LEN using the + standard mach out-array convention. If no error occurs, zero is returned, + otherwise the error code is returned. */ +-error_t open_read (struct open *open, off_t offs, size_t amount, +- void **buf, size_t *buf_len); ++error_t open_read (struct open *open, off_t offs, vm_size_t amount, ++ void **buf, vm_size_t *buf_len); + + /* Set OPEN's location to OFFS, interpreted according to WHENCE as by seek. + The new absolute location is returned in NEW_OFFS (and may not be the same +diff --git a/term/ptyio.c b/term/ptyio.c +index 928ae0ac..acd1015a 100644 +--- a/term/ptyio.c ++++ b/term/ptyio.c +@@ -302,7 +302,7 @@ error_t + pty_io_read (struct trivfs_protid *cred, + data_t *data, + mach_msg_type_number_t *datalen, +- mach_msg_type_number_t amount) ++ vm_size_t amount) + { + int size; + +@@ -386,7 +386,7 @@ error_t + pty_io_write (struct trivfs_protid *cred, + const_data_t data, + mach_msg_type_number_t datalen, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + int i, flush; + int cancel = 0; +diff --git a/term/term.h b/term/term.h +index efe27ffa..1e6be5f2 100644 +--- a/term/term.h ++++ b/term/term.h +@@ -387,9 +387,9 @@ extern dev_t rdev; + /* kludge--these are pty versions of trivfs_S_io_* functions called by + the real functions in users.c to do work for ptys. */ + error_t pty_io_write (struct trivfs_protid *, const char *, +- mach_msg_type_number_t, mach_msg_type_number_t *); ++ mach_msg_type_number_t, vm_size_t *); + error_t pty_io_read (struct trivfs_protid *, char **, +- mach_msg_type_number_t *, mach_msg_type_number_t); ++ mach_msg_type_number_t *, vm_size_t); + error_t pty_io_readable (size_t *); + error_t pty_io_select (struct trivfs_protid *, mach_port_t, + struct timespec *, int *); +diff --git a/term/users.c b/term/users.c +index 72f5507d..59f02b66 100644 +--- a/term/users.c ++++ b/term/users.c +@@ -562,9 +562,9 @@ trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, + mach_msg_type_name_t replytype, + const_data_t data, +- size_t datalen, +- loff_t offset, +- size_t *amt) ++ mach_msg_type_name_t datalen, ++ off_t offset, ++ vm_size_t *amt) + { + int i; + int cancel; +@@ -640,9 +640,9 @@ trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, + mach_msg_type_name_t replytype, + data_t *data, +- size_t *datalen, +- loff_t offset, +- size_t amount) ++ mach_msg_type_name_t *datalen, ++ off_t offset, ++ vm_size_t amount) + { + int cancel; + int i, max; +@@ -820,7 +820,7 @@ error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, + mach_msg_type_name_t replytype, +- size_t *amt) ++ vm_size_t *amt) + { + if (!cred) + return EOPNOTSUPP; +diff --git a/trans/fifo.c b/trans/fifo.c +index ce7c7729..894565f6 100644 +--- a/trans/fifo.c ++++ b/trans/fifo.c +@@ -339,8 +339,8 @@ trivfs_S_io_map (struct trivfs_protid *cred, + error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- data_t *data, size_t *data_len, +- off_t offs, size_t amount) ++ data_t *data, mach_msg_type_name_t *data_len, ++ off_t offs, vm_size_t amount) + { + error_t err; + +@@ -368,7 +368,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- size_t *amount) ++ vm_size_t *amount) + { + error_t err; + +@@ -502,8 +502,8 @@ trivfs_S_io_select_timeout (struct trivfs_protid *cred, + error_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- const_data_t data, size_t data_len, +- off_t offs, size_t *amount) ++ const_data_t data, mach_msg_type_name_t data_len, ++ off_t offs, vm_size_t *amount) + { + error_t err; + +diff --git a/trans/firmlink.c b/trans/firmlink.c +index 8a5d01a8..e216146a 100644 +--- a/trans/firmlink.c ++++ b/trans/firmlink.c +@@ -207,7 +207,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + error_t err = 0; + +@@ -244,7 +244,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + if (! cred) + return EOPNOTSUPP; +diff --git a/trans/hello-mt.c b/trans/hello-mt.c +index 92f814d6..e99ba754 100644 +--- a/trans/hello-mt.c ++++ b/trans/hello-mt.c +@@ -125,7 +125,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + struct open *op; + +diff --git a/trans/hello.c b/trans/hello.c +index f8f9e7ab..0405fad3 100644 +--- a/trans/hello.c ++++ b/trans/hello.c +@@ -116,7 +116,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + struct open *op; + +diff --git a/trans/mtab.c b/trans/mtab.c +index caff3385..a2feee7d 100644 +--- a/trans/mtab.c ++++ b/trans/mtab.c +@@ -657,7 +657,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + error_t err = 0; + struct mtab *op; +@@ -774,7 +774,7 @@ void (*trivfs_peropen_destroy_hook) (struct trivfs_peropen *) = close_hook; + kern_return_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + error_t err = 0; + if (!cred) +diff --git a/trans/new-fifo.c b/trans/new-fifo.c +index 9a959a39..3e9a886c 100644 +--- a/trans/new-fifo.c ++++ b/trans/new-fifo.c +@@ -524,8 +524,8 @@ trivfs_S_io_map (struct trivfs_protid *cred, + error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- data_t *data, size_t *data_len, +- off_t offs, size_t amount) ++ data_t *data, mach_msg_type_name_t *data_len, ++ off_t offs, vm_size_t amount) + { + error_t err; + +@@ -554,7 +554,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- size_t *amount) ++ vm_size_t *amount) + { + error_t err; + +@@ -689,8 +689,8 @@ trivfs_S_io_select_timeout (struct trivfs_protid *cred, + error_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- const_data_t data, size_t data_len, +- off_t offs, size_t *amount) ++ const_data_t data, mach_msg_type_name_t data_len, ++ off_t offs, vm_size_t *amount) + { + error_t err; + +diff --git a/trans/null.c b/trans/null.c +index 034bb103..f4ba5582 100644 +--- a/trans/null.c ++++ b/trans/null.c +@@ -149,8 +149,8 @@ trivfs_S_io_read(struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, + data_t *data, + mach_msg_type_number_t *datalen, +- loff_t offs, +- mach_msg_type_number_t amt) ++ off_t offs, ++ vm_size_t amt) + { + if (!cred) + return EOPNOTSUPP; +@@ -169,7 +169,7 @@ trivfs_S_io_read(struct trivfs_protid *cred, + kern_return_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + if (!cred) + return EOPNOTSUPP; +@@ -228,7 +228,7 @@ kern_return_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, + const_data_t data, mach_msg_type_number_t datalen, +- loff_t offs, mach_msg_type_number_t *amt) ++ off_t offs, vm_size_t *amt) + { + if (!cred) + return EOPNOTSUPP; +diff --git a/trans/proxy-defpager.c b/trans/proxy-defpager.c +index 8ca25b72..bfeda063 100644 +--- a/trans/proxy-defpager.c ++++ b/trans/proxy-defpager.c +@@ -169,8 +169,8 @@ trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, + data_t *data, + mach_msg_type_number_t *datalen, +- loff_t offs, +- mach_msg_type_number_t amt) ++ off_t offs, ++ vm_size_t amt) + { + if (!cred) + return EOPNOTSUPP; +@@ -181,7 +181,7 @@ kern_return_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t replytype, + const_data_t data, mach_msg_type_number_t datalen, +- loff_t offs, mach_msg_type_number_t *amt) ++ loff_t offs, vm_size_t *amt) + { + if (!cred) + return EOPNOTSUPP; +diff --git a/trans/random.c b/trans/random.c +index c230280a..297253e4 100644 +--- a/trans/random.c ++++ b/trans/random.c +@@ -318,7 +318,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + error_t err; + void *buf = NULL; +@@ -377,8 +377,8 @@ trivfs_S_io_write (struct trivfs_protid *cred, + mach_msg_type_name_t replytype, + const_data_t data, + mach_msg_type_number_t datalen, +- loff_t offset, +- mach_msg_type_number_t *amount) ++ off_t offset, ++ vm_size_t *amount) + { + /* Deny access if they have bad credentials. */ + if (! cred) +diff --git a/trans/streamio.c b/trans/streamio.c +index 30b8b20e..acd5d674 100644 +--- a/trans/streamio.c ++++ b/trans/streamio.c +@@ -482,7 +482,7 @@ error_t + trivfs_S_io_read (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + data_t *data, mach_msg_type_number_t *data_len, +- loff_t offs, mach_msg_type_number_t amount) ++ off_t offs, vm_size_t amount) + { + error_t err; + +@@ -501,7 +501,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, + error_t + trivfs_S_io_readable (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, +- mach_msg_type_number_t *amount) ++ vm_size_t *amount) + { + error_t err; + +@@ -521,7 +521,7 @@ error_t + trivfs_S_io_write (struct trivfs_protid *cred, + mach_port_t reply, mach_msg_type_name_t reply_type, + const_data_t data, mach_msg_type_number_t data_len, +- loff_t offs, mach_msg_type_number_t *amount) ++ off_t offs, vm_size_t *amount) + { + error_t err; + + +base-commit: b6509385bb1dd2a6d47401465bfb98b6339c5c2b +prerequisite-patch-id: 33c640aa0fcf19d49fff88cc58cecd3be8f7892d +prerequisite-patch-id: 411256b31780cf9ea0b24efe9f2b20f82c6ce9c1 +prerequisite-patch-id: 830470d11762c6c5e09488a2b834dff0f4f6e434 +prerequisite-patch-id: 1a1293bebf97550d54d9dba3a1817f20a3ef6a2a +prerequisite-patch-id: f12e5842dea12ed7b0ff4ae3fa2afe78f3647288 +prerequisite-patch-id: 4436fa0181c5e21580e6656634e35febf251dc5b +prerequisite-patch-id: a938f788841d96151e9e4cc134114dc7652e4f27 +prerequisite-patch-id: bfc7264e11d3ca2dbc520f221cf8bf13857d4732 +prerequisite-patch-id: 50393cc222a3e9de9cfab0762f5acf10e394c9f0 +-- +2.39.1 + diff --git a/gnu/packages/patches/hurd-xattr.patch b/gnu/packages/patches/hurd-xattr.patch deleted file mode 100644 index 0a922c91b5..0000000000 --- a/gnu/packages/patches/hurd-xattr.patch +++ /dev/null @@ -1,53 +0,0 @@ -From 75cb948c575fca3962c4cce115d31dd178bc389f Mon Sep 17 00:00:00 2001 -From: "Jan (janneke) Nieuwenhuizen" <janneke@gnu.org> -Date: Tue, 12 May 2020 07:39:59 +0200 -Subject: [PATCH] ext2fs: Update to upstream Hurd-reserved xattr index for - "gnu.*". - -See - https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=3980bd3b406addb327d858aebd19e229ea340b9a - -This supports setting (and reading) of passive trasnlators from -GNU/Linux, e.g. - - dd if=/dev/zero of=file bs=1k count=1000 - losetup /dev/loop0 file - mke2fs -t ext2 -o hurd -O ext_attr /dev/loop0 - mount -t ext2 -o x-xattr-translator-records /dev/loop0 /mnt - mkdir -p /mnt/servers/socket - touch /mnt/servers/socket/1 - setfattr --name=gnu.translator --value='/hurd/pflocal\0' /mnt/servers/socket/1 - getfattr --name=gnu.translator /mnt/servers/socket/1 - # file: 1 - gnu.translator="/hurd/pflocal" - -* ext2fs/xattr.c (struct _xattr_prefix): For "gnu.*", use index for -the Hurd (10). ---- - ext2fs/xattr.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/ext2fs/xattr.c b/ext2fs/xattr.c -index f6ea0f39..78458214 100644 ---- a/ext2fs/xattr.c -+++ b/ext2fs/xattr.c -@@ -1,6 +1,6 @@ - /* Ext2 support for extended attributes - -- Copyright (C) 2006, 2016 Free Software Foundation, Inc. -+ Copyright (C) 2006, 2016, 2020 Free Software Foundation, Inc. - - Written by Thadeu Lima de Souza Cascardo <cascardo@dcc.ufmg.br> - and Shengyu Zhang <lastavengers@outlook.com> -@@ -39,7 +39,7 @@ xattr_prefixes[] = - { - 1, "user.", sizeof "user." - 1}, - { -- 7, "gnu.", sizeof "gnu." - 1}, -+ 10, "gnu.", sizeof "gnu." - 1}, - { - 0, NULL, 0} - }; --- -2.26.0 - diff --git a/gnu/packages/patches/icedtea-7-hotspot-pointer-comparison.patch b/gnu/packages/patches/icedtea-7-hotspot-pointer-comparison.patch new file mode 100644 index 0000000000..deb305bd96 --- /dev/null +++ b/gnu/packages/patches/icedtea-7-hotspot-pointer-comparison.patch @@ -0,0 +1,36 @@ +Avoid ordered comparison of pointer with integer to prevent compile error +with GCC 11. + +diff --git a/src/share/vm/opto/lcm.cpp b/src/share/vm/opto/lcm.cpp +--- a/src/share/vm/opto/lcm.cpp ++++ b/src/share/vm/opto/lcm.cpp +@@ -60,7 +60,7 @@ + // Check whether val is not-null-decoded compressed oop, + // i.e. will grab into the base of the heap if it represents NULL. + static bool accesses_heap_base_zone(Node *val) { +- if (Universe::narrow_oop_base() > 0) { // Implies UseCompressedOops. ++ if (Universe::narrow_oop_base() != NULL) { // Implies UseCompressedOops. + if (val && val->is_Mach()) { + if (val->as_Mach()->ideal_Opcode() == Op_DecodeN) { + // This assumes all Decodes with TypePtr::NotNull are matched to nodes that +diff --git a/src/share/vm/runtime/virtualspace.cpp b/src/share/vm/runtime/virtualspace.cpp +--- a/src/share/vm/runtime/virtualspace.cpp ++++ b/src/share/vm/runtime/virtualspace.cpp +@@ -527,7 +527,7 @@ ReservedHeapSpace::ReservedHeapSpace(size_t size, size_t alignment, + (UseCompressedOops && (Universe::narrow_oop_base() != NULL) && + Universe::narrow_oop_use_implicit_null_checks()) ? + lcm(os::vm_page_size(), alignment) : 0) { +- if (base() > 0) { ++ if (base() != NULL) { + MemTracker::record_virtual_memory_type((address)base(), mtJavaHeap); + } + +@@ -546,7 +546,7 @@ ReservedHeapSpace::ReservedHeapSpace(const size_t prefix_size, + (UseCompressedOops && (Universe::narrow_oop_base() != NULL) && + Universe::narrow_oop_use_implicit_null_checks()) ? + lcm(os::vm_page_size(), prefix_align) : 0) { +- if (base() > 0) { ++ if (base() != NULL) { + MemTracker::record_virtual_memory_type((address)base(), mtJavaHeap); + } + diff --git a/gnu/packages/patches/inkscape-poppler-compat.patch b/gnu/packages/patches/inkscape-poppler-compat.patch new file mode 100644 index 0000000000..cb7d1c8eb3 --- /dev/null +++ b/gnu/packages/patches/inkscape-poppler-compat.patch @@ -0,0 +1,45 @@ +Fix build with Poppler 22.9.0. + +Taken from upstream: + + https://gitlab.com/inkscape/inkscape/-/commit/fb00794923d19cfbb2ca4adca3ae8971553a06be + +diff --git a/src/extension/internal/pdfinput/pdf-parser.cpp b/src/extension/internal/pdfinput/pdf-parser.cpp +index cca1e840966c7940a1af472025535042b07e3e0f..80d64c9b866d5d3dd095636a9a02571b89061af1 100644 +--- a/src/extension/internal/pdfinput/pdf-parser.cpp ++++ b/src/extension/internal/pdfinput/pdf-parser.cpp +@@ -697,7 +697,11 @@ void PdfParser::opSetDash(Object args[], int /*numArgs*/) + _POPPLER_FREE(obj); + } + } ++#if POPPLER_CHECK_VERSION(22, 9, 0) ++ state->setLineDash(std::vector<double> (dash, dash + length), args[1].getNum()); ++#else + state->setLineDash(dash, length, args[1].getNum()); ++#endif + builder->updateStyle(state); + } + +diff --git a/src/extension/internal/pdfinput/svg-builder.cpp b/src/extension/internal/pdfinput/svg-builder.cpp +index 12f71dd9214b95dbad6fdf7642a96cdd57f2c64a..9fc56fe63c2feee986ad1ff5018e679a0bacb665 100644 +--- a/src/extension/internal/pdfinput/svg-builder.cpp ++++ b/src/extension/internal/pdfinput/svg-builder.cpp +@@ -389,10 +389,17 @@ void SvgBuilder::_setStrokeStyle(SPCSSAttr *css, GfxState *state) { + sp_repr_css_set_property(css, "stroke-miterlimit", os_ml.str().c_str()); + + // Line dash +- double *dash_pattern; + int dash_length; + double dash_start; ++#if POPPLER_CHECK_VERSION(22, 9, 0) ++ const double *dash_pattern; ++ const std::vector<double> &dash = state->getLineDash(&dash_start); ++ dash_pattern = dash.data(); ++ dash_length = dash.size(); ++#else ++ double *dash_pattern; + state->getLineDash(&dash_pattern, &dash_length, &dash_start); ++#endif + if ( dash_length > 0 ) { + Inkscape::CSSOStringStream os_array; + for ( int i = 0 ; i < dash_length ; i++ ) { diff --git a/gnu/packages/patches/jsoncpp-pkg-config-version.patch b/gnu/packages/patches/jsoncpp-pkg-config-version.patch deleted file mode 100644 index 3983cc300c..0000000000 --- a/gnu/packages/patches/jsoncpp-pkg-config-version.patch +++ /dev/null @@ -1,24 +0,0 @@ -Taken from upstream: https://github.com/open-source-parsers/jsoncpp/issues/1235. - -From ac2870298ed5b5a96a688d9df07461b31f83e906 Mon Sep 17 00:00:00 2001 -From: Derick Vigne <derickvigne@me.com> -Date: Tue, 26 Jan 2021 14:59:12 -0500 -Subject: [PATCH] Fixed pkg-config Version - ---- - pkg-config/jsoncpp.pc.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/pkg-config/jsoncpp.pc.in b/pkg-config/jsoncpp.pc.in -index 632a377f5..2a2221069 100644 ---- a/pkg-config/jsoncpp.pc.in -+++ b/pkg-config/jsoncpp.pc.in -@@ -5,7 +5,7 @@ includedir=@includedir_for_pc_file@ - - Name: jsoncpp - Description: A C++ library for interacting with JSON --Version: @JSONCPP_VERSION@ -+Version: @PROJECT_VERSION@ - URL: https://github.com/open-source-parsers/jsoncpp - Libs: -L${libdir} -ljsoncpp - Cflags: -I${includedir} diff --git a/gnu/packages/patches/julia-Use-MPFR-4.2.patch b/gnu/packages/patches/julia-Use-MPFR-4.2.patch new file mode 100644 index 0000000000..73a395c89e --- /dev/null +++ b/gnu/packages/patches/julia-Use-MPFR-4.2.patch @@ -0,0 +1,228 @@ +This patch backports part of Julia upstream commit: + + 1e5fdb29f8858f3244f6aff116ee12e4c8247f3a + Author: Simon Byrne <simon.byrne@gmail.com> + AuthorDate: Tue Jan 10 14:52:36 2023 -0800 + Commit: GitHub <noreply@github.com> + CommitDate: Tue Jan 10 17:52:36 2023 -0500 + + update MPFR to 4.2.0 (#48165) + + Co-authored-by: Mosè Giordano <giordano@users.noreply.github.com> + + 6 files changed, 112 insertions(+), 79 deletions(-) + base/mpfr.jl | 34 ++++++++++++++-- + deps/checksums/mpfr | 68 ++++++++++++++++---------------- + deps/mpfr.version | 2 +- + stdlib/MPFR_jll/Project.toml | 2 +- + stdlib/MPFR_jll/test/runtests.jl | 2 +- + test/math.jl | 83 +++++++++++++++++++++------------------- + + +diff -ur julia-1.8.3-orig/base/mpfr.jl julia-1.8.3-patch/base/mpfr.jl +--- julia-1.8.3-orig/base/mpfr.jl 2023-04-13 17:50:58.394891391 +0200 ++++ julia-1.8.3-patch/base/mpfr.jl 2023-04-13 20:42:52.551833467 +0200 +@@ -16,7 +16,8 @@ + cosh, sinh, tanh, sech, csch, coth, acosh, asinh, atanh, lerpi, + cbrt, typemax, typemin, unsafe_trunc, floatmin, floatmax, rounding, + setrounding, maxintfloat, widen, significand, frexp, tryparse, iszero, +- isone, big, _string_n, decompose ++ isone, big, _string_n, decompose, minmax, ++ sinpi, cospi, sincospi, sind, cosd, tand, asind, acosd, atand + + import ..Rounding: rounding_raw, setrounding_raw + +@@ -745,7 +746,7 @@ + end + + # Functions for which NaN results are converted to DomainError, following Base +-for f in (:sin, :cos, :tan, :sec, :csc, :acos, :asin, :atan, :acosh, :asinh, :atanh) ++for f in (:sin, :cos, :tan, :sec, :csc, :acos, :asin, :atan, :acosh, :asinh, :atanh, :sinpi, :cospi) + @eval begin + function ($f)(x::BigFloat) + isnan(x) && return x +@@ -756,6 +757,7 @@ + end + end + end ++sincospi(x::BigFloat) = (sinpi(x), cospi(x)) + + function atan(y::BigFloat, x::BigFloat) + z = BigFloat() +@@ -763,6 +765,32 @@ + return z + end + ++# degree functions ++for f in (:sin, :cos, :tan) ++ @eval begin ++ function ($(Symbol(f,:d)))(x::BigFloat) ++ isnan(x) && return x ++ z = BigFloat() ++ ccall(($(string(:mpfr_,f,:u)), :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}, Culong, MPFRRoundingMode), z, x, 360, ROUNDING_MODE[]) ++ isnan(z) && throw(DomainError(x, "NaN result for non-NaN input.")) ++ return z ++ end ++ function ($(Symbol(:a,f,:d)))(x::BigFloat) ++ isnan(x) && return x ++ z = BigFloat() ++ ccall(($(string(:mpfr_a,f,:u)), :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}, Culong, MPFRRoundingMode), z, x, 360, ROUNDING_MODE[]) ++ isnan(z) && throw(DomainError(x, "NaN result for non-NaN input.")) ++ return z ++ end ++ end ++end ++function atand(y::BigFloat, x::BigFloat) ++ z = BigFloat() ++ ccall((:mpfr_atan2u, :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}, Ref{BigFloat}, Culong, MPFRRoundingMode), z, y, x, 360, ROUNDING_MODE[]) ++ return z ++end ++ ++ + # Utility functions + ==(x::BigFloat, y::BigFloat) = ccall((:mpfr_equal_p, :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}), x, y) != 0 + <=(x::BigFloat, y::BigFloat) = ccall((:mpfr_lessequal_p, :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}), x, y) != 0 +@@ -1018,7 +1046,7 @@ + isfinite(x) || return string(Float64(x)) + _prettify_bigfloat(string_mpfr(x, fmt)) + end +-_string(x::BigFloat) = _string(x, "%.Re") ++_string(x::BigFloat) = _string(x, "%Re") + _string(x::BigFloat, k::Integer) = _string(x, "%.$(k)Re") + + string(b::BigFloat) = _string(b) +diff -ur julia-1.8.3-orig/test/math.jl julia-1.8.3-patch/test/math.jl +--- julia-1.8.3-orig/test/math.jl 2023-04-13 17:50:58.382891276 +0200 ++++ julia-1.8.3-patch/test/math.jl 2023-04-13 21:13:55.377279761 +0200 +@@ -411,47 +411,51 @@ + @test rad2deg(pi + (pi/3)*im) ≈ 180 + 60im + end + ++# ensure zeros are signed the same ++⩲(x,y) = typeof(x) == typeof(y) && x == y && signbit(x) == signbit(y) ++⩲(x::Tuple, y::Tuple) = length(x) == length(y) && all(map(⩲,x,y)) ++ + @testset "degree-based trig functions" begin +- @testset "$T" for T = (Float32,Float64,Rational{Int}) ++ @testset "$T" for T = (Float32,Float64,Rational{Int},BigFloat) + fT = typeof(float(one(T))) + fTsc = typeof( (float(one(T)), float(one(T))) ) + for x = -400:40:400 +- @test sind(convert(T,x))::fT ≈ convert(fT,sin(pi/180*x)) atol=eps(deg2rad(convert(fT,x))) +- @test cosd(convert(T,x))::fT ≈ convert(fT,cos(pi/180*x)) atol=eps(deg2rad(convert(fT,x))) ++ @test sind(convert(T,x))::fT ≈ sin(pi*convert(fT,x)/180) atol=eps(deg2rad(convert(fT,x))) ++ @test cosd(convert(T,x))::fT ≈ cos(pi*convert(fT,x)/180) atol=eps(deg2rad(convert(fT,x))) + + s,c = sincosd(convert(T,x)) +- @test s::fT ≈ convert(fT,sin(pi/180*x)) atol=eps(deg2rad(convert(fT,x))) +- @test c::fT ≈ convert(fT,cos(pi/180*x)) atol=eps(deg2rad(convert(fT,x))) ++ @test s::fT ≈ sin(pi*convert(fT,x)/180) atol=eps(deg2rad(convert(fT,x))) ++ @test c::fT ≈ cos(pi*convert(fT,x)/180) atol=eps(deg2rad(convert(fT,x))) + end + @testset "sind" begin +- @test sind(convert(T,0.0))::fT === zero(fT) +- @test sind(convert(T,180.0))::fT === zero(fT) +- @test sind(convert(T,360.0))::fT === zero(fT) +- T != Rational{Int} && @test sind(convert(T,-0.0))::fT === -zero(fT) +- @test sind(convert(T,-180.0))::fT === -zero(fT) +- @test sind(convert(T,-360.0))::fT === -zero(fT) ++ @test sind(convert(T,0.0))::fT ⩲ zero(fT) ++ @test sind(convert(T,180.0))::fT ⩲ zero(fT) ++ @test sind(convert(T,360.0))::fT ⩲ zero(fT) ++ T != Rational{Int} && @test sind(convert(T,-0.0))::fT ⩲ -zero(fT) ++ @test sind(convert(T,-180.0))::fT ⩲ -zero(fT) ++ @test sind(convert(T,-360.0))::fT ⩲ -zero(fT) + if T <: AbstractFloat + @test isnan(sind(T(NaN))) + end + end + @testset "cosd" begin +- @test cosd(convert(T,90))::fT === zero(fT) +- @test cosd(convert(T,270))::fT === zero(fT) +- @test cosd(convert(T,-90))::fT === zero(fT) +- @test cosd(convert(T,-270))::fT === zero(fT) ++ @test cosd(convert(T,90))::fT ⩲ zero(fT) ++ @test cosd(convert(T,270))::fT ⩲ zero(fT) ++ @test cosd(convert(T,-90))::fT ⩲ zero(fT) ++ @test cosd(convert(T,-270))::fT ⩲ zero(fT) + if T <: AbstractFloat + @test isnan(cosd(T(NaN))) + end + end + @testset "sincosd" begin +- @test sincosd(convert(T,-360))::fTsc === ( -zero(fT), one(fT) ) +- @test sincosd(convert(T,-270))::fTsc === ( one(fT), zero(fT) ) +- @test sincosd(convert(T,-180))::fTsc === ( -zero(fT), -one(fT) ) +- @test sincosd(convert(T, -90))::fTsc === ( -one(fT), zero(fT) ) +- @test sincosd(convert(T, 0))::fTsc === ( zero(fT), one(fT) ) +- @test sincosd(convert(T, 90))::fTsc === ( one(fT), zero(fT) ) +- @test sincosd(convert(T, 180))::fTsc === ( zero(fT), -one(fT) ) +- @test sincosd(convert(T, 270))::fTsc === ( -one(fT), zero(fT) ) ++ @test sincosd(convert(T,-360))::fTsc ⩲ ( -zero(fT), one(fT) ) ++ @test sincosd(convert(T,-270))::fTsc ⩲ ( one(fT), zero(fT) ) ++ @test sincosd(convert(T,-180))::fTsc ⩲ ( -zero(fT), -one(fT) ) ++ @test sincosd(convert(T, -90))::fTsc ⩲ ( -one(fT), zero(fT) ) ++ @test sincosd(convert(T, 0))::fTsc ⩲ ( zero(fT), one(fT) ) ++ @test sincosd(convert(T, 90))::fTsc ⩲ ( one(fT), zero(fT) ) ++ @test sincosd(convert(T, 180))::fTsc ⩲ ( zero(fT), -one(fT) ) ++ @test sincosd(convert(T, 270))::fTsc ⩲ ( -one(fT), zero(fT) ) + if T <: AbstractFloat + @test_throws DomainError sincosd(T(Inf)) + @test all(isnan.(sincosd(T(NaN)))) +@@ -463,22 +467,22 @@ + "sincospi" => (x->sincospi(x)[1], x->sincospi(x)[2]) + ) + @testset "pi * $x" for x = -3:0.3:3 +- @test sinpi(convert(T,x))::fT ≈ convert(fT,sin(pi*x)) atol=eps(pi*convert(fT,x)) +- @test cospi(convert(T,x))::fT ≈ convert(fT,cos(pi*x)) atol=eps(pi*convert(fT,x)) ++ @test sinpi(convert(T,x))::fT ≈ sin(pi*convert(fT,x)) atol=eps(pi*convert(fT,x)) ++ @test cospi(convert(T,x))::fT ≈ cos(pi*convert(fT,x)) atol=eps(pi*convert(fT,x)) + end + +- @test sinpi(convert(T,0.0))::fT === zero(fT) +- @test sinpi(convert(T,1.0))::fT === zero(fT) +- @test sinpi(convert(T,2.0))::fT === zero(fT) +- T != Rational{Int} && @test sinpi(convert(T,-0.0))::fT === -zero(fT) +- @test sinpi(convert(T,-1.0))::fT === -zero(fT) +- @test sinpi(convert(T,-2.0))::fT === -zero(fT) ++ @test sinpi(convert(T,0.0))::fT ⩲ zero(fT) ++ @test sinpi(convert(T,1.0))::fT ⩲ zero(fT) ++ @test sinpi(convert(T,2.0))::fT ⩲ zero(fT) ++ T != Rational{Int} && @test sinpi(convert(T,-0.0))::fT ⩲ -zero(fT) ++ @test sinpi(convert(T,-1.0))::fT ⩲ -zero(fT) ++ @test sinpi(convert(T,-2.0))::fT ⩲ -zero(fT) + @test_throws DomainError sinpi(convert(T,Inf)) + +- @test cospi(convert(T,0.5))::fT === zero(fT) +- @test cospi(convert(T,1.5))::fT === zero(fT) +- @test cospi(convert(T,-0.5))::fT === zero(fT) +- @test cospi(convert(T,-1.5))::fT === zero(fT) ++ @test cospi(convert(T,0.5))::fT ⩲ zero(fT) ++ @test cospi(convert(T,1.5))::fT ⩲ zero(fT) ++ @test cospi(convert(T,-0.5))::fT ⩲ zero(fT) ++ @test cospi(convert(T,-1.5))::fT ⩲ zero(fT) + @test_throws DomainError cospi(convert(T,Inf)) + end + @testset "Check exact values" begin +@@ -489,8 +493,8 @@ + @test sincospi(one(T)/convert(T,6))[1] == 0.5 + @test_throws DomainError sind(convert(T,Inf)) + @test_throws DomainError cosd(convert(T,Inf)) +- T != Float32 && @test cospi(one(T)/convert(T,3)) == 0.5 +- T != Float32 && @test sincospi(one(T)/convert(T,3))[2] == 0.5 ++ fT == Float64 && @test isapprox(cospi(one(T)/convert(T,3)), 0.5) ++ fT == Float64 && @test isapprox(sincospi(one(T)/convert(T,3))[2], 0.5) + T == Rational{Int} && @test sinpi(5//6) == 0.5 + T == Rational{Int} && @test sincospi(5//6)[1] == 0.5 + end +@@ -538,8 +542,8 @@ + end + end + end +- @test @inferred(sinc(0//1)) === 1.0 +- @test @inferred(cosc(0//1)) === -0.0 ++ @test @inferred(sinc(0//1)) ⩲ 1.0 ++ @test @inferred(cosc(0//1)) ⩲ -0.0 + + # test right before/after thresholds of Taylor series + @test sinc(0.001) ≈ 0.999998355066745 rtol=1e-15 diff --git a/gnu/packages/patches/libaio-32bit-test.patch b/gnu/packages/patches/libaio-32bit-test.patch new file mode 100644 index 0000000000..0da8e25c69 --- /dev/null +++ b/gnu/packages/patches/libaio-32bit-test.patch @@ -0,0 +1,26 @@ +This fix comes from an upstream pull request, see +https://pagure.io/libaio/pull-request/22#commit_list + +diff --git a/harness/cases/23.t b/harness/cases/23.t +index cc5a8a1..9bbb05c 100644 +--- a/harness/cases/23.t ++++ b/harness/cases/23.t +@@ -72,7 +72,7 @@ static void fail_errno(const char *format, ...) + static void *thrproc2(void *arg) + { + for (;;) { +- off_t offset = 0; ++ off64_t offset = 0; + + pthread_barrier_wait(&barrier); + if (exiting) +@@ -92,7 +92,7 @@ static void *thrproc3(void *arg) + { + for (;;) { + char c; +- off_t offset = 0; ++ off64_t offset = 0; + + pthread_barrier_wait(&barrier); + if (exiting) + diff --git a/gnu/packages/patches/libffi-3.3-powerpc-fixes.patch b/gnu/packages/patches/libffi-3.3-powerpc-fixes.patch deleted file mode 100644 index 971ed26180..0000000000 --- a/gnu/packages/patches/libffi-3.3-powerpc-fixes.patch +++ /dev/null @@ -1,138 +0,0 @@ -This is a combination of the following 4 commits: -https://github.com/libffi/libffi/commit/01a75ed76ea7e57f1b7a5c183e2b1e890e6aa0fd.patch -https://github.com/libffi/libffi/commit/6663047f56c2932a6b10a790f4ac6666dd181326.patch -https://github.com/libffi/libffi/commit/e50b9ef8b910fa642ef158f6642e60d54d7ad740.patch -https://github.com/libffi/libffi/commit/4d6d2866ae43e55325e8ee96561221804602cd7a.patch - -From 2dbfa92a95e3bacabca431b89d2a5925e48a0e40 Mon Sep 17 00:00:00 2001 -From: Sergei Trofimovich <slyfox@gentoo.org> -Date: Thu, 28 Nov 2019 12:42:41 +0000 - -powerpc: fix build failure on power7 and older (#532) - -Build failure looks as: -``` -libtool: compile: powerpc-unknown-linux-gnu-gcc \ - -O2 -mcpu=powerpc -mtune=powerpc -pipe ... -c src/powerpc/ffi.c ... -In file included from src/powerpc/ffi.c:33: -src/powerpc/ffi_powerpc.h:65:9: error: '__int128' is not supported on this target - 65 | typedef __int128 float128; - | ^~~~~~~~ -``` - -The fix avoids using __int128 in favour of aligned char[16]. - -Closes: https://github.com/libffi/libffi/issues/531 -Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> - -Address platforms with no __int128. - -powerpc64: Use memcpy to help platforms with no __int128. (#534) - -Signed-off-by: Khem Raj <raj.khem@gmail.com> - -Update powerpc sysv assembly for ffi_powerpc.h changes (#541) - -Some of the flag bits were moved when adding powerpc64 vector support. - -Fixes #536 ---- - src/powerpc/ffi_linux64.c | 12 ++++++------ - src/powerpc/ffi_powerpc.h | 2 +- - src/powerpc/sysv.S | 12 +++++------- - 3 files changed, 12 insertions(+), 14 deletions(-) - -diff --git a/src/powerpc/ffi_linux64.c b/src/powerpc/ffi_linux64.c -index de0d033..4d50878 100644 ---- a/src/powerpc/ffi_linux64.c -+++ b/src/powerpc/ffi_linux64.c -@@ -547,9 +547,9 @@ ffi_prep_args64 (extended_cif *ecif, unsigned long *const stack) - if (next_arg.ul == gpr_end.ul) - next_arg.ul = rest.ul; - if (vecarg_count < NUM_VEC_ARG_REGISTERS64 && i < nfixedargs) -- *vec_base.f128++ = **p_argv.f128; -+ memcpy (vec_base.f128++, *p_argv.f128, sizeof (float128)); - else -- *next_arg.f128 = **p_argv.f128; -+ memcpy (next_arg.f128, *p_argv.f128, sizeof (float128)); - if (++next_arg.f128 == gpr_end.f128) - next_arg.f128 = rest.f128; - vecarg_count++; -@@ -680,9 +680,9 @@ ffi_prep_args64 (extended_cif *ecif, unsigned long *const stack) - { - if (vecarg_count < NUM_VEC_ARG_REGISTERS64 - && i < nfixedargs) -- *vec_base.f128++ = *arg.f128++; -+ memcpy (vec_base.f128++, arg.f128, sizeof (float128)); - else -- *next_arg.f128 = *arg.f128++; -+ memcpy (next_arg.f128, arg.f128++, sizeof (float128)); - if (++next_arg.f128 == gpr_end.f128) - next_arg.f128 = rest.f128; - vecarg_count++; -@@ -986,9 +986,9 @@ ffi_closure_helper_LINUX64 (ffi_cif *cif, - do - { - if (pvec < end_pvec && i < nfixedargs) -- *to.f128 = *pvec++; -+ memcpy (to.f128, pvec++, sizeof (float128)); - else -- *to.f128 = *from.f128; -+ memcpy (to.f128, from.f128, sizeof (float128)); - to.f128++; - from.f128++; - } -diff --git a/src/powerpc/ffi_powerpc.h b/src/powerpc/ffi_powerpc.h -index 5ee2a70..8e2f2f0 100644 ---- a/src/powerpc/ffi_powerpc.h -+++ b/src/powerpc/ffi_powerpc.h -@@ -62,7 +62,7 @@ typedef _Float128 float128; - #elif defined(__FLOAT128__) - typedef __float128 float128; - #else --typedef __int128 float128; -+typedef char float128[16] __attribute__((aligned(16))); - #endif - - void FFI_HIDDEN ffi_closure_SYSV (void); -diff --git a/src/powerpc/sysv.S b/src/powerpc/sysv.S -index 1474ce7..df97734 100644 ---- a/src/powerpc/sysv.S -+++ b/src/powerpc/sysv.S -@@ -104,17 +104,16 @@ ENTRY(ffi_call_SYSV) - bctrl - - /* Now, deal with the return value. */ -- mtcrf 0x01,%r31 /* cr7 */ -+ mtcrf 0x03,%r31 /* cr6-cr7 */ - bt- 31,L(small_struct_return_value) - bt- 30,L(done_return_value) - #ifndef __NO_FPRS__ - bt- 29,L(fp_return_value) - #endif - stw %r3,0(%r30) -- bf+ 28,L(done_return_value) -+ bf+ 27,L(done_return_value) - stw %r4,4(%r30) -- mtcrf 0x02,%r31 /* cr6 */ -- bf 27,L(done_return_value) -+ bf 26,L(done_return_value) - stw %r5,8(%r30) - stw %r6,12(%r30) - /* Fall through... */ -@@ -145,10 +144,9 @@ L(done_return_value): - #ifndef __NO_FPRS__ - L(fp_return_value): - .cfi_restore_state -- bf 28,L(float_return_value) -+ bf 27,L(float_return_value) - stfd %f1,0(%r30) -- mtcrf 0x02,%r31 /* cr6 */ -- bf 27,L(done_return_value) -+ bf 26,L(done_return_value) - stfd %f2,8(%r30) - b L(done_return_value) - L(float_return_value): --- -2.26.0 - diff --git a/gnu/packages/patches/libffi-float128-powerpc64le.patch b/gnu/packages/patches/libffi-float128-powerpc64le.patch deleted file mode 100644 index 4fd32b0102..0000000000 --- a/gnu/packages/patches/libffi-float128-powerpc64le.patch +++ /dev/null @@ -1,58 +0,0 @@ -From de93adfb6f48100946bba2c3abad2a77a0cfde0b Mon Sep 17 00:00:00 2001 -From: Fabrice Fontaine <fontaine.fabrice@gmail.com> -Date: Sun, 24 Nov 2019 09:52:01 +0100 -Subject: [PATCH] ffi_powerpc.h: fix build failure with powerpc7 - -This is a patch pulled down from the following: -https://github.com/buildroot/buildroot/blob/78926f610b1411b03464152472fd430012deb9ac/package/libffi/0004-ffi_powerpc.h-fix-build-failure-with-powerpc7.patch - -This issue is being hit on OpenBMC code when pulling the latest -libffi tag and building on a P8 ppc64le machine. I verified this -patch fixes the issue we are seeing. - -Below is the original commit message: - -Sicne commit 73dd43afc8a447ba98ea02e9aad4c6898dc77fb0, build on powerpc7 -fails on: - -In file included from ../src/powerpc/ffi.c:33:0: -../src/powerpc/ffi_powerpc.h:61:9: error: '_Float128' is not supported on this target - typedef _Float128 float128; - ^~~~~~~~~ - -Fix this build failure by checking for __HAVE_FLOAT128 before using -_Float128, as _Float128 is enabled only on specific conditions, see -output/host/powerpc64-buildroot-linux-gnu/sysroot/usr/include/bits/floatn.h: - - /* Defined to 1 if the current compiler invocation provides a - floating-point type with the IEEE 754 binary128 format, and this glibc - includes corresponding *f128 interfaces for it. */ - #if defined _ARCH_PWR8 && defined __LITTLE_ENDIAN__ && (_CALL_ELF == 2) \ - && defined __FLOAT128__ && !defined __NO_LONG_DOUBLE_MATH - # define __HAVE_FLOAT128 1 - #else - # define __HAVE_FLOAT128 0 - #endif - -Fixes: - - http://autobuild.buildroot.org/results/5c9dd8fb3b6a128882b6250f197c80232d8a3b53 - -Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> -Signed-off-by: Andrew Geissler <geissonator@yahoo.com> ---- - src/powerpc/ffi_powerpc.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/powerpc/ffi_powerpc.h b/src/powerpc/ffi_powerpc.h -index 8e2f2f0e..960a5c42 100644 ---- a/src/powerpc/ffi_powerpc.h -+++ b/src/powerpc/ffi_powerpc.h -@@ -57,7 +57,7 @@ typedef union - double d; - } ffi_dblfl; - --#if defined(__FLOAT128_TYPE__) -+#if defined(__FLOAT128_TYPE__) && defined(__HAVE_FLOAT128) - typedef _Float128 float128; - #elif defined(__FLOAT128__) - typedef __float128 float128; diff --git a/gnu/packages/patches/libssh2-CVE-2019-17498.patch b/gnu/packages/patches/libssh2-CVE-2019-17498.patch deleted file mode 100644 index 6f69e562e2..0000000000 --- a/gnu/packages/patches/libssh2-CVE-2019-17498.patch +++ /dev/null @@ -1,126 +0,0 @@ -https://github.com/libssh2/libssh2/commit/dedcbd106f8e52d5586b0205bc7677e4c9868f9c.patch - -From dedcbd106f8e52d5586b0205bc7677e4c9868f9c Mon Sep 17 00:00:00 2001 -From: Will Cosgrove <will@panic.com> -Date: Fri, 30 Aug 2019 09:57:38 -0700 -Subject: [PATCH] packet.c: improve message parsing (#402) - -* packet.c: improve parsing of packets - -file: packet.c - -notes: -Use _libssh2_get_string API in SSH_MSG_DEBUG/SSH_MSG_DISCONNECT. Additional uint32 bounds check in SSH_MSG_GLOBAL_REQUEST. ---- - src/packet.c | 68 ++++++++++++++++++++++------------------------------ - 1 file changed, 29 insertions(+), 39 deletions(-) - -diff --git a/src/packet.c b/src/packet.c -index 38ab62944..2e01bfc5d 100644 ---- a/src/packet.c -+++ b/src/packet.c -@@ -419,8 +419,8 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned char *data, - size_t datalen, int macstate) - { - int rc = 0; -- char *message = NULL; -- char *language = NULL; -+ unsigned char *message = NULL; -+ unsigned char *language = NULL; - size_t message_len = 0; - size_t language_len = 0; - LIBSSH2_CHANNEL *channelp = NULL; -@@ -472,33 +472,23 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned char *data, - - case SSH_MSG_DISCONNECT: - if(datalen >= 5) { -- size_t reason = _libssh2_ntohu32(data + 1); -+ uint32_t reason = 0; -+ struct string_buf buf; -+ buf.data = (unsigned char *)data; -+ buf.dataptr = buf.data; -+ buf.len = datalen; -+ buf.dataptr++; /* advance past type */ - -- if(datalen >= 9) { -- message_len = _libssh2_ntohu32(data + 5); -+ _libssh2_get_u32(&buf, &reason); -+ _libssh2_get_string(&buf, &message, &message_len); -+ _libssh2_get_string(&buf, &language, &language_len); - -- if(message_len < datalen-13) { -- /* 9 = packet_type(1) + reason(4) + message_len(4) */ -- message = (char *) data + 9; -- -- language_len = -- _libssh2_ntohu32(data + 9 + message_len); -- language = (char *) data + 9 + message_len + 4; -- -- if(language_len > (datalen-13-message_len)) { -- /* bad input, clear info */ -- language = message = NULL; -- language_len = message_len = 0; -- } -- } -- else -- /* bad size, clear it */ -- message_len = 0; -- } - if(session->ssh_msg_disconnect) { -- LIBSSH2_DISCONNECT(session, reason, message, -- message_len, language, language_len); -+ LIBSSH2_DISCONNECT(session, reason, (const char *)message, -+ message_len, (const char *)language, -+ language_len); - } -+ - _libssh2_debug(session, LIBSSH2_TRACE_TRANS, - "Disconnect(%d): %s(%s)", reason, - message, language); -@@ -539,24 +529,24 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned char *data, - int always_display = data[1]; - - if(datalen >= 6) { -- message_len = _libssh2_ntohu32(data + 2); -- -- if(message_len <= (datalen - 10)) { -- /* 6 = packet_type(1) + display(1) + message_len(4) */ -- message = (char *) data + 6; -- language_len = _libssh2_ntohu32(data + 6 + -- message_len); -- -- if(language_len <= (datalen - 10 - message_len)) -- language = (char *) data + 10 + message_len; -- } -+ struct string_buf buf; -+ buf.data = (unsigned char *)data; -+ buf.dataptr = buf.data; -+ buf.len = datalen; -+ buf.dataptr += 2; /* advance past type & always display */ -+ -+ _libssh2_get_string(&buf, &message, &message_len); -+ _libssh2_get_string(&buf, &language, &language_len); - } - - if(session->ssh_msg_debug) { -- LIBSSH2_DEBUG(session, always_display, message, -- message_len, language, language_len); -+ LIBSSH2_DEBUG(session, always_display, -+ (const char *)message, -+ message_len, (const char *)language, -+ language_len); - } - } -+ - /* - * _libssh2_debug will actually truncate this for us so - * that it's not an inordinate about of data -@@ -579,7 +569,7 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned char *data, - uint32_t len = 0; - unsigned char want_reply = 0; - len = _libssh2_ntohu32(data + 1); -- if(datalen >= (6 + len)) { -+ if((len <= (UINT_MAX - 6)) && (datalen >= (6 + len))) { - want_reply = data[5 + len]; - _libssh2_debug(session, - LIBSSH2_TRACE_CONN, diff --git a/gnu/packages/patches/libtiff-CVE-2022-34526.patch b/gnu/packages/patches/libtiff-CVE-2022-34526.patch new file mode 100644 index 0000000000..a5ad9d79a5 --- /dev/null +++ b/gnu/packages/patches/libtiff-CVE-2022-34526.patch @@ -0,0 +1,22 @@ +Fix CVE-2022-34526: + + https://nvd.nist.gov/vuln/detail/CVE-2022-34526 + https://gitlab.com/libtiff/libtiff/-/issues/433 + +Patch taken from upstream source repository: + + https://gitlab.com/libtiff/libtiff/-/commit/275735d0354e39c0ac1dc3c0db2120d6f31d1990 + +diff --git a/libtiff/tif_dirinfo.c b/libtiff/tif_dirinfo.c +--- a/libtiff/tif_dirinfo.c ++++ b/libtiff/tif_dirinfo.c +@@ -1191,6 +1191,9 @@ _TIFFCheckFieldIsValidForCodec(TIFF *tif, ttag_t tag) + default: + return 1; + } ++ if( !TIFFIsCODECConfigured(tif->tif_dir.td_compression) ) { ++ return 0; ++ } + /* Check if codec specific tags are allowed for the current + * compression scheme (codec) */ + switch (tif->tif_dir.td_compression) { diff --git a/gnu/packages/patches/libtool-grep-compat.patch b/gnu/packages/patches/libtool-grep-compat.patch new file mode 100644 index 0000000000..46e5c6873d --- /dev/null +++ b/gnu/packages/patches/libtool-grep-compat.patch @@ -0,0 +1,51 @@ +Don't escape forward slashes to prevent a warning from grep 3.8. + +diff --git a/tests/link-order.at b/tests/link-order.at +--- a/tests/link-order.at ++++ b/tests/link-order.at +@@ -99,12 +99,12 @@ aix* | interix*) ;; # These systems have different path syntax + case $hardcode_direct$hardcode_direct_absolute in + yesno) + AT_CHECK([if $EGREP relinking stderr; then +- $EGREP " .*\/new\/lib/libb$shared_ext .*\/old\/lib/libcee$shared_ext" stdout ++ $EGREP " .*/new/lib/libb$shared_ext .*/old/lib/libcee$shared_ext" stdout + else :; fi], [0], [ignore], [], [echo "wrong link order"]) + ;; + *) + AT_CHECK([if $EGREP relinking stderr; then +- $EGREP " -L.*\/new\/lib -lb -L.*\/old\/lib -lcee" stdout ++ $EGREP " -L.*/new/lib -lb -L.*/old/lib -lcee" stdout + else :; fi], [0], [ignore], [], [echo "wrong link order"]) + ;; + esac +diff --git a/tests/testsuite b/tests/testsuite +--- a/tests/testsuite ++++ b/tests/testsuite +@@ -20611,11 +20611,11 @@ aix* | interix*) ;; # These systems have different path syntax + yesno) + { set +x + $as_echo "$at_srcdir/link-order.at:101: if \$EGREP relinking stderr; then +- \$EGREP \" .*\\/new\\/lib/libb\$shared_ext .*\\/old\\/lib/libcee\$shared_ext\" stdout ++ \$EGREP \" .*/new/lib/libb\$shared_ext .*/old/lib/libcee\$shared_ext\" stdout + else :; fi" + at_fn_check_prepare_notrace 'an embedded newline' "link-order.at:101" + ( $at_check_trace; if $EGREP relinking stderr; then +- $EGREP " .*\/new\/lib/libb$shared_ext .*\/old\/lib/libcee$shared_ext" stdout ++ $EGREP " .*/new/lib/libb$shared_ext .*/old/lib/libcee$shared_ext" stdout + else :; fi + ) >>"$at_stdout" 2>>"$at_stderr" 5>&- + at_status=$? at_failed=false +@@ -20633,11 +20633,11 @@ $at_traceon; } + *) + { set +x + $as_echo "$at_srcdir/link-order.at:106: if \$EGREP relinking stderr; then +- \$EGREP \" -L.*\\/new\\/lib -lb -L.*\\/old\\/lib -lcee\" stdout ++ \$EGREP \" -L.*/new\\/lib -lb -L.*/old/lib -lcee\" stdout + else :; fi" + at_fn_check_prepare_notrace 'an embedded newline' "link-order.at:106" + ( $at_check_trace; if $EGREP relinking stderr; then +- $EGREP " -L.*\/new\/lib -lb -L.*\/old\/lib -lcee" stdout ++ $EGREP " -L.*/new/lib -lb -L.*/old/lib -lcee" stdout + else :; fi + ) >>"$at_stdout" 2>>"$at_stderr" 5>&- + at_status=$? at_failed=false diff --git a/gnu/packages/patches/libtool-skip-tests2.patch b/gnu/packages/patches/libtool-skip-tests2.patch index 3f86191b4f..91beaa903e 100644 --- a/gnu/packages/patches/libtool-skip-tests2.patch +++ b/gnu/packages/patches/libtool-skip-tests2.patch @@ -16,7 +16,7 @@ Skip the nopic test on ARM, MIPS and RISC-V systems. @@ -8741,7 +8741,7 @@ { set +x - $as_echo "$at_srcdir/demo.at:535: case \$host in + $as_echo "$at_srcdir/demo.at:513: case \$host in -hppa*|x86_64*|s390*) +hppa*|x86_64*|s390*|arm*|mips*|riscv*) # These hosts cannot use non-PIC shared libs @@ -24,7 +24,7 @@ Skip the nopic test on ARM, MIPS and RISC-V systems. *-solaris*|*-sunos*) @@ -8766,7 +8766,7 @@ " - at_fn_check_prepare_notrace 'a `...` command substitution' "demo.at:535" + at_fn_check_prepare_notrace 'a `...` command substitution' "demo.at:513" ( $at_check_trace; case $host in -hppa*|x86_64*|s390*) +hppa*|x86_64*|s390*|arm*|mips*|riscv*) diff --git a/gnu/packages/patches/libwpd-gcc-compat.patch b/gnu/packages/patches/libwpd-gcc-compat.patch new file mode 100644 index 0000000000..ee206beafe --- /dev/null +++ b/gnu/packages/patches/libwpd-gcc-compat.patch @@ -0,0 +1,17 @@ +Fix build with newer GCC. + +Taken from upstream: + + https://sourceforge.net/p/libwpd/code/ci/333c8a26f231bea26ec3d56245315041bbf5577f/ + +--- a/src/lib/WPXTable.h ++++ b/src/lib/WPXTable.h +@@ -53,7 +53,7 @@ + ~WPXTable(); + void insertRow(); + void insertCell(unsigned char colSpan, unsigned char rowSpan, unsigned char borderBits); +- const WPXTableCell *getCell(size_t i, size_t j) ++ const WPXTableCell *getCell(std::size_t i, std::size_t j) + { + return &(m_tableRows[i])[j]; + } diff --git a/gnu/packages/patches/libxml2-parent-pointers.patch b/gnu/packages/patches/libxml2-parent-pointers.patch deleted file mode 100644 index 1f0615c512..0000000000 --- a/gnu/packages/patches/libxml2-parent-pointers.patch +++ /dev/null @@ -1,228 +0,0 @@ -Fix a regression in 2.9.12 where some corrupt XML structures were handled -incorrectly: - - https://gitlab.gnome.org/GNOME/libxml2/-/issues/255 - -This is an amalgamation of these upstream commits: - - https://gitlab.gnome.org/GNOME/libxml2/-/commit/85b1792e37b131e7a51af98a37f92472e8de5f3f - https://gitlab.gnome.org/GNOME/libxml2/-/commit/13ad8736d294536da4cbcd70a96b0a2fbf47070c - -diff --git a/HTMLtree.c b/HTMLtree.c ---- a/HTMLtree.c -+++ b/HTMLtree.c -@@ -744,7 +744,7 @@ void - htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - xmlNodePtr cur, const char *encoding ATTRIBUTE_UNUSED, - int format) { -- xmlNodePtr root; -+ xmlNodePtr root, parent; - xmlAttrPtr attr; - const htmlElemDesc * info; - -@@ -755,6 +755,7 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - } - - root = cur; -+ parent = cur->parent; - while (1) { - switch (cur->type) { - case XML_HTML_DOCUMENT_NODE: -@@ -762,13 +763,25 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - if (((xmlDocPtr) cur)->intSubset != NULL) { - htmlDtdDumpOutput(buf, (xmlDocPtr) cur, NULL); - } -- if (cur->children != NULL) { -+ /* Always validate cur->parent when descending. */ -+ if ((cur->parent == parent) && (cur->children != NULL)) { -+ parent = cur; - cur = cur->children; - continue; - } - break; - - case XML_ELEMENT_NODE: -+ /* -+ * Some users like lxml are known to pass nodes with a corrupted -+ * tree structure. Fall back to a recursive call to handle this -+ * case. -+ */ -+ if ((cur->parent != parent) && (cur->children != NULL)) { -+ htmlNodeDumpFormatOutput(buf, doc, cur, encoding, format); -+ break; -+ } -+ - /* - * Get specific HTML info for that node. - */ -@@ -817,6 +830,7 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - (cur->name != NULL) && - (cur->name[0] != 'p')) /* p, pre, param */ - xmlOutputBufferWriteString(buf, "\n"); -+ parent = cur; - cur = cur->children; - continue; - } -@@ -825,9 +839,9 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - (info != NULL) && (!info->isinline)) { - if ((cur->next->type != HTML_TEXT_NODE) && - (cur->next->type != HTML_ENTITY_REF_NODE) && -- (cur->parent != NULL) && -- (cur->parent->name != NULL) && -- (cur->parent->name[0] != 'p')) /* p, pre, param */ -+ (parent != NULL) && -+ (parent->name != NULL) && -+ (parent->name[0] != 'p')) /* p, pre, param */ - xmlOutputBufferWriteString(buf, "\n"); - } - -@@ -842,9 +856,9 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - break; - if (((cur->name == (const xmlChar *)xmlStringText) || - (cur->name != (const xmlChar *)xmlStringTextNoenc)) && -- ((cur->parent == NULL) || -- ((xmlStrcasecmp(cur->parent->name, BAD_CAST "script")) && -- (xmlStrcasecmp(cur->parent->name, BAD_CAST "style"))))) { -+ ((parent == NULL) || -+ ((xmlStrcasecmp(parent->name, BAD_CAST "script")) && -+ (xmlStrcasecmp(parent->name, BAD_CAST "style"))))) { - xmlChar *buffer; - - buffer = xmlEncodeEntitiesReentrant(doc, cur->content); -@@ -902,13 +916,9 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - break; - } - -- /* -- * The parent should never be NULL here but we want to handle -- * corrupted documents gracefully. -- */ -- if (cur->parent == NULL) -- return; -- cur = cur->parent; -+ cur = parent; -+ /* cur->parent was validated when descending. */ -+ parent = cur->parent; - - if ((cur->type == XML_HTML_DOCUMENT_NODE) || - (cur->type == XML_DOCUMENT_NODE)) { -@@ -939,9 +949,9 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - (cur->next != NULL)) { - if ((cur->next->type != HTML_TEXT_NODE) && - (cur->next->type != HTML_ENTITY_REF_NODE) && -- (cur->parent != NULL) && -- (cur->parent->name != NULL) && -- (cur->parent->name[0] != 'p')) /* p, pre, param */ -+ (parent != NULL) && -+ (parent->name != NULL) && -+ (parent->name[0] != 'p')) /* p, pre, param */ - xmlOutputBufferWriteString(buf, "\n"); - } - } -diff --git a/xmlsave.c b/xmlsave.c ---- a/xmlsave.c -+++ b/xmlsave.c -@@ -847,7 +847,7 @@ htmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - static void - xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - int format = ctxt->format; -- xmlNodePtr tmp, root, unformattedNode = NULL; -+ xmlNodePtr tmp, root, unformattedNode = NULL, parent; - xmlAttrPtr attr; - xmlChar *start, *end; - xmlOutputBufferPtr buf; -@@ -856,6 +856,7 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - buf = ctxt->buf; - - root = cur; -+ parent = cur->parent; - while (1) { - switch (cur->type) { - case XML_DOCUMENT_NODE: -@@ -868,7 +869,9 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - break; - - case XML_DOCUMENT_FRAG_NODE: -- if (cur->children != NULL) { -+ /* Always validate cur->parent when descending. */ -+ if ((cur->parent == parent) && (cur->children != NULL)) { -+ parent = cur; - cur = cur->children; - continue; - } -@@ -887,7 +890,18 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - break; - - case XML_ELEMENT_NODE: -- if ((cur != root) && (ctxt->format == 1) && (xmlIndentTreeOutput)) -+ /* -+ * Some users like lxml are known to pass nodes with a corrupted -+ * tree structure. Fall back to a recursive call to handle this -+ * case. -+ */ -+ if ((cur->parent != parent) && (cur->children != NULL)) { -+ xmlNodeDumpOutputInternal(ctxt, cur); -+ break; -+ } -+ -+ if ((ctxt->level > 0) && (ctxt->format == 1) && -+ (xmlIndentTreeOutput)) - xmlOutputBufferWrite(buf, ctxt->indent_size * - (ctxt->level > ctxt->indent_nr ? - ctxt->indent_nr : ctxt->level), -@@ -942,6 +956,7 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - xmlOutputBufferWrite(buf, 1, ">"); - if (ctxt->format == 1) xmlOutputBufferWrite(buf, 1, "\n"); - if (ctxt->level >= 0) ctxt->level++; -+ parent = cur; - cur = cur->children; - continue; - } -@@ -1058,13 +1073,9 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - break; - } - -- /* -- * The parent should never be NULL here but we want to handle -- * corrupted documents gracefully. -- */ -- if (cur->parent == NULL) -- return; -- cur = cur->parent; -+ cur = parent; -+ /* cur->parent was validated when descending. */ -+ parent = cur->parent; - - if (cur->type == XML_ELEMENT_NODE) { - if (ctxt->level > 0) ctxt->level--; -diff --git a/xmlsave.c b/xmlsave.c ---- a/xmlsave.c -+++ b/xmlsave.c -@@ -890,6 +890,13 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - break; - - case XML_ELEMENT_NODE: -+ if ((cur != root) && (ctxt->format == 1) && -+ (xmlIndentTreeOutput)) -+ xmlOutputBufferWrite(buf, ctxt->indent_size * -+ (ctxt->level > ctxt->indent_nr ? -+ ctxt->indent_nr : ctxt->level), -+ ctxt->indent); -+ - /* - * Some users like lxml are known to pass nodes with a corrupted - * tree structure. Fall back to a recursive call to handle this -@@ -900,13 +907,6 @@ xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { - break; - } - -- if ((ctxt->level > 0) && (ctxt->format == 1) && -- (xmlIndentTreeOutput)) -- xmlOutputBufferWrite(buf, ctxt->indent_size * -- (ctxt->level > ctxt->indent_nr ? -- ctxt->indent_nr : ctxt->level), -- ctxt->indent); -- - xmlOutputBufferWrite(buf, 1, "<"); - if ((cur->ns != NULL) && (cur->ns->prefix != NULL)) { - xmlOutputBufferWriteString(buf, (const char *)cur->ns->prefix); diff --git a/gnu/packages/patches/libxml2-terminating-newline.patch b/gnu/packages/patches/libxml2-terminating-newline.patch deleted file mode 100644 index 3f5c88dd4e..0000000000 --- a/gnu/packages/patches/libxml2-terminating-newline.patch +++ /dev/null @@ -1,33 +0,0 @@ -Fix a regression in 2.9.12 where serializing empty HTML documents would -not add a terminating newline. - - https://gitlab.gnome.org/GNOME/libxml2/-/issues/266 - -Taken from upstream: - - https://gitlab.gnome.org/GNOME/libxml2/-/commit/92d9ab4c28842a09ca2b76d3ff2f933e01b6cd6f - -diff --git a/HTMLtree.c b/HTMLtree.c ---- a/HTMLtree.c -+++ b/HTMLtree.c -@@ -763,11 +763,15 @@ htmlNodeDumpFormatOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, - if (((xmlDocPtr) cur)->intSubset != NULL) { - htmlDtdDumpOutput(buf, (xmlDocPtr) cur, NULL); - } -- /* Always validate cur->parent when descending. */ -- if ((cur->parent == parent) && (cur->children != NULL)) { -- parent = cur; -- cur = cur->children; -- continue; -+ if (cur->children != NULL) { -+ /* Always validate cur->parent when descending. */ -+ if (cur->parent == parent) { -+ parent = cur; -+ cur = cur->children; -+ continue; -+ } -+ } else { -+ xmlOutputBufferWriteString(buf, "\n"); - } - break; - diff --git a/gnu/packages/patches/libxml2-xpath-recursion-limit.patch b/gnu/packages/patches/libxml2-xpath-recursion-limit.patch deleted file mode 100644 index 051196c635..0000000000 --- a/gnu/packages/patches/libxml2-xpath-recursion-limit.patch +++ /dev/null @@ -1,20 +0,0 @@ -Fix recursion accounting in XPath expressions: - - https://gitlab.gnome.org/GNOME/libxml2/-/issues/264 - -Taken from upstream: - - https://gitlab.gnome.org/GNOME/libxml2/-/commit/3e1aad4fe584747fd7d17cc7b2863a78e2d21a77 - -diff --git a/xpath.c b/xpath.c ---- a/xpath.c -+++ b/xpath.c -@@ -10983,7 +10983,7 @@ xmlXPathCompileExpr(xmlXPathParserContextPtr ctxt, int sort) { - } - - if (xpctxt != NULL) -- xpctxt->depth -= 1; -+ xpctxt->depth -= 10; - } - - /** diff --git a/gnu/packages/patches/linphone-desktop-without-sdk.patch b/gnu/packages/patches/linphone-desktop-without-sdk.patch index 63e9808bf4..ef61b86707 100644 --- a/gnu/packages/patches/linphone-desktop-without-sdk.patch +++ b/gnu/packages/patches/linphone-desktop-without-sdk.patch @@ -13,13 +13,12 @@ Subject: [PATCH] [PATCH]: Fix building from git. 6 files changed, 6 insertions(+), 121 deletions(-) create mode 100644 linphone-app/linphoneqt_version.cmake -diff --git a/CMakeLists.txt b/CMakeLists.txt -index f7eb05f2..3e853bdd 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -48,16 +48,6 @@ project(linphoneqt) - include(GNUInstallDirs) - include(CheckCXXCompilerFlag) +diff -ru a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt 1970-01-01 01:00:01.000000000 +0100 ++++ b/CMakeLists.txt 2023-04-08 16:00:45.487927870 +0200 +@@ -51,23 +51,6 @@ + + set(CMAKE_CXX_STANDARD 11) -# Prepare gobal CMAKE configuration specific to the current project -set(SDK_BUILD_DIR "${CMAKE_BINARY_DIR}/WORK") # SDK build in WORK. Keep all in it. @@ -27,30 +26,43 @@ index f7eb05f2..3e853bdd 100644 - -set(APPLICATION_OUTPUT_DIR "${CMAKE_BINARY_DIR}/OUTPUT") - --set(CMAKE_PREFIX_PATH "${LINPHONE_OUTPUT_DIR};${APPLICATION_OUTPUT_DIR}${PREFIX_PATH}") +-set(CMAKE_PREFIX_PATH "${LINPHONE_OUTPUT_DIR};${APPLICATION_OUTPUT_DIR};${APPLICATION_OUTPUT_DIR}/include${PREFIX_PATH}") +-if(WIN32) +- set( CMAKE_PREFIX_PATH "${CMAKE_PREFIX_PATH};${APPLICATION_OUTPUT_DIR}/${CMAKE_INSTALL_BINDIR}") +-elseif(APPLE) +- set( CMAKE_PREFIX_PATH "${CMAKE_PREFIX_PATH};${APPLICATION_NAME}.app/Contents/Frameworks") +-else() +- set( CMAKE_PREFIX_PATH "${CMAKE_PREFIX_PATH};${APPLICATION_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}") +-endif() -string(REPLACE ";" "|" PREFIX_PATH "${CMAKE_PREFIX_PATH}") -#set(PREFIX_PATH "${LINPHONE_OUTPUT_DIR}|${APPLICATION_OUTPUT_DIR}${PREFIX_PATH}") - # Avoid cmake warning if CMP0071 is not set. if (POLICY CMP0071) cmake_policy(SET CMP0071 NEW) -@@ -116,9 +106,6 @@ if(ENABLE_V4L) +@@ -177,10 +160,8 @@ endif() list(APPEND APP_OPTIONS "-DENABLE_RELATIVE_PREFIX=${ENABLE_RELATIVE_PREFIX}") -list(APPEND APP_OPTIONS "-DLINPHONE_OUTPUT_DIR=${LINPHONE_OUTPUT_DIR}") -- + list(APPEND APP_OPTIONS "-DENABLE_QT_GL=${ENABLE_VIDEO}")#Activate on video + -include(ExternalProject) set(PROJECT_BUILD_COMMAND "") if(CMAKE_BUILD_PARALLEL_LEVEL) list(APPEND APP_OPTIONS "-DCMAKE_BUILD_PARALLEL_LEVEL=${CMAKE_BUILD_PARALLEL_LEVEL}") -@@ -133,32 +120,10 @@ if(CMAKE_VERBOSE_MAKEFILE) +@@ -195,7 +176,6 @@ endif() endif() if(UNIX AND NOT APPLE) - set(CMAKE_INSTALL_RPATH "$ORIGIN:$ORIGIN/lib64:$ORIGIN/../lib64:$ORIGIN/lib:$ORIGIN/../lib:${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}") list(APPEND APP_OPTIONS "-DCMAKE_INSTALL_RPATH=${CMAKE_INSTALL_RPATH}") - endif() + elseif(APPLE) + list(APPEND APP_OPTIONS "-DENABLE_FAT_BINARY=ON") #Disable XCFrameworks as it is not supported. +@@ -222,28 +202,9 @@ + + + if(NOT LINPHONE_QT_ONLY) -ExternalProject_Add(sdk PREFIX "${CMAKE_BINARY_DIR}/sdk" - SOURCE_DIR "${CMAKE_SOURCE_DIR}/linphone-sdk" - INSTALL_DIR "${LINPHONE_OUTPUT_DIR}" @@ -61,7 +73,7 @@ index f7eb05f2..3e853bdd 100644 - INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "Install step is already done at build time." - LIST_SEPARATOR | # Use the alternate list separator - CMAKE_ARGS ${APP_OPTIONS} ${USER_ARGS} -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR> -DCMAKE_PREFIX_PATH=${PREFIX_PATH} -- #BUILD_ALWAYS NO #${DO_BUILD} +- BUILD_ALWAYS NO #${DO_BUILD} -) -ExternalProject_Add_Step(sdk force_build - COMMENT "Forcing build for 'desktop'" @@ -69,18 +81,17 @@ index f7eb05f2..3e853bdd 100644 - DEPENDERS build - ALWAYS 1 -) + endif() include(FindPkgConfig) -set(APP_DEPENDS sdk) -- -- - find_package(Qt5 5.12 COMPONENTS Core REQUIRED) + find_package(Qt5 5.10 COMPONENTS Core REQUIRED) if ( NOT Qt5_FOUND ) -@@ -173,39 +138,5 @@ find_package(Mediastreamer2 CONFIG QUIET) +@@ -257,62 +218,5 @@ + find_package(Mediastreamer2 CONFIG QUIET) find_package(ortp CONFIG QUIET) - -if(NOT (LinphoneCxx_FOUND) OR NOT (Linphone_FOUND) OR NOT (bctoolbox_FOUND) OR NOT (belcard_FOUND) OR NOT (Mediastreamer2_FOUND) OR NOT (ortp_FOUND) OR FORCE_APP_EXTERNAL_PROJECTS) - message("Projects are set as External projects. You can start building them by using for example : cmake --build . --target install") - ExternalProject_Add(linphone-qt PREFIX "${CMAKE_BINARY_DIR}/linphone-app" @@ -89,22 +100,45 @@ index f7eb05f2..3e853bdd 100644 - BINARY_DIR "${CMAKE_BINARY_DIR}/linphone-app" - DEPENDS ${APP_DEPENDS} - BUILD_COMMAND ${CMAKE_COMMAND} --build <BINARY_DIR> --config $<CONFIG> ${PROJECT_BUILD_COMMAND} -- INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "Install step will not be done by external project" +- INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "Install step is already done at build time." - LIST_SEPARATOR | # Use the alternate list separator - CMAKE_ARGS ${APP_OPTIONS} ${USER_ARGS} -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR> -DCMAKE_PREFIX_PATH=${PREFIX_PATH} - # ${APP_OPTIONS} - BUILD_ALWAYS ON - ) +- if( ENABLE_BUILD_APP_PLUGINS) +- ExternalProject_Add(app-plugins PREFIX "${CMAKE_BINARY_DIR}/plugins-app" +- SOURCE_DIR "${CMAKE_SOURCE_DIR}/plugins" +- INSTALL_DIR "${APPLICATION_OUTPUT_DIR}" +- BINARY_DIR "${CMAKE_BINARY_DIR}/plugins-app" +- DEPENDS linphone-qt +- BUILD_COMMAND ${CMAKE_COMMAND} --build <BINARY_DIR> --config $<CONFIG> ${PROJECT_BUILD_COMMAND} +- INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "Install step is already done at build time." +- LIST_SEPARATOR | # Use the alternate list separator +- CMAKE_ARGS ${APP_OPTIONS} ${USER_ARGS} -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR> -DCMAKE_PREFIX_PATH=${PREFIX_PATH} +- ) +- endif() - install(CODE "message(STATUS Running install)") - set(AUTO_REGENERATION auto_regeneration) -- add_custom_target(${AUTO_REGENERATION} ALL -- COMMAND ${CMAKE_COMMAND} ${CMAKE_CURRENT_SOURCE_DIR} -- DEPENDS linphone-qt) +- if( ENABLE_BUILD_APP_PLUGINS) +- add_custom_target(${AUTO_REGENERATION} ALL +- COMMAND ${CMAKE_COMMAND} ${CMAKE_CURRENT_SOURCE_DIR} +- DEPENDS app-plugins) +- else() +- add_custom_target(${AUTO_REGENERATION} ALL +- COMMAND ${CMAKE_COMMAND} ${CMAKE_CURRENT_SOURCE_DIR} +- DEPENDS linphone-qt) +- endif() -else() - message("Adding Linphone Desktop in an IDE-friendly state") - set(CMAKE_INSTALL_PREFIX "${APPLICATION_OUTPUT_DIR}") - add_subdirectory(${CMAKE_SOURCE_DIR}/linphone-app) -- add_dependencies(app-library ${APP_DEPENDS}) +- if(NOT LINPHONE_QT_ONLY) +- add_dependencies(app-library ${APP_DEPENDS}) +- endif() +- if( ENABLE_BUILD_APP_PLUGINS) +- add_subdirectory(${CMAKE_SOURCE_DIR}/plugins "plugins-app") +- endif() -endif() -ExternalProject_Add(linphone-qt-only PREFIX "${CMAKE_BINARY_DIR}/linphone-app" - SOURCE_DIR "${CMAKE_SOURCE_DIR}/linphone-app" @@ -115,14 +149,25 @@ index f7eb05f2..3e853bdd 100644 - LIST_SEPARATOR | # Use the alternate list separator - CMAKE_ARGS ${APP_OPTIONS} ${USER_ARGS} -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR> -DCMAKE_PREFIX_PATH=${PREFIX_PATH} - EXCLUDE_FROM_ALL ON -- BUILD_ALWAYS ON +- #BUILD_ALWAYS ON -) +message("Adding Linphone Desktop in an IDE-friendly state") +add_subdirectory(${CMAKE_SOURCE_DIR}/linphone-app) -diff --git a/linphone-app/CMakeLists.txt b/linphone-app/CMakeLists.txt -index 3bc9420a..5267cd4a 100644 ---- a/linphone-app/CMakeLists.txt -+++ b/linphone-app/CMakeLists.txt +diff -ru a/linphone-app/cmake_builder/additional_steps.cmake ./linphone-app/cmake_builder/additional_steps.cmake +--- a/linphone-app/cmake_builder/additional_steps.cmake 1970-01-01 01:00:01.000000000 +0100 ++++ ./linphone-app/cmake_builder/additional_steps.cmake 2023-04-08 16:02:33.005843116 +0200 +@@ -61,7 +61,7 @@ + SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/linphone_package" + DOWNLOAD_COMMAND "" + CMAKE_GENERATOR ${CMAKE_GENERATOR} +- CMAKE_ARGS ${LINPHONE_BUILDER_EP_ARGS} -DCMAKE_INSTALL_PREFIX=${LINPHONE_BUILDER_WORK_DIR}/PACKAGE -DTOOLS_DIR=${CMAKE_BINARY_DIR}/programs -DLINPHONE_OUTPUT_DIR=${CMAKE_INSTALL_PREFIX} -DLINPHONE_DESKTOP_DIR=${CMAKE_CURRENT_LIST_DIR}/.. -DLINPHONE_SOURCE_DIR=${EP_linphone_SOURCE_DIR} ${ENABLE_VARIABLES} -DLINPHONE_BUILDER_SIGNING_IDENTITY=${LINPHONE_BUILDER_SIGNING_IDENTITY} ++ CMAKE_ARGS ${LINPHONE_BUILDER_EP_ARGS} -DCMAKE_INSTALL_PREFIX=${LINPHONE_BUILDER_WORK_DIR}/PACKAGE -DTOOLS_DIR=${CMAKE_BINARY_DIR}/programs -DLINPHONE_DESKTOP_DIR=${CMAKE_CURRENT_LIST_DIR}/.. -DLINPHONE_SOURCE_DIR=${EP_linphone_SOURCE_DIR} ${ENABLE_VARIABLES} -DLINPHONE_BUILDER_SIGNING_IDENTITY=${LINPHONE_BUILDER_SIGNING_IDENTITY} + ) + endif () + endif () +diff -ru a/linphone-app/CMakeLists.txt ./linphone-app/CMakeLists.txt +--- a/linphone-app/CMakeLists.txt 1970-01-01 01:00:01.000000000 +0100 ++++ ./linphone-app/CMakeLists.txt 2023-04-08 16:01:32.699012115 +0200 @@ -21,17 +21,8 @@ ################################################################################ cmake_minimum_required(VERSION 3.1) @@ -140,96 +185,30 @@ index 3bc9420a..5267cd4a 100644 - -project(linphoneqt VERSION "${version_major}.${version_minor}.${version_patch}") + if(ENABLE_BUILD_VERBOSE) - #message("CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH}") -@@ -49,7 +40,6 @@ if(UNIX AND NOT APPLE) - set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) +@@ -51,7 +42,6 @@ + set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) endif() list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../cmake") -list(APPEND CMAKE_MODULE_PATH "${LINPHONE_OUTPUT_DIR}/cmake") set(APP_LIBRARY app-library) - include(application_info.cmake) -diff --git a/linphone-app/cmake_builder/additional_steps.cmake b/linphone-app/cmake_builder/additional_steps.cmake -index 7f7fd573..48e3c716 100644 ---- a/linphone-app/cmake_builder/additional_steps.cmake -+++ b/linphone-app/cmake_builder/additional_steps.cmake -@@ -61,7 +61,7 @@ if (ENABLE_PACKAGING) - SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/linphone_package" - DOWNLOAD_COMMAND "" - CMAKE_GENERATOR ${CMAKE_GENERATOR} -- CMAKE_ARGS ${LINPHONE_BUILDER_EP_ARGS} -DCMAKE_INSTALL_PREFIX=${LINPHONE_BUILDER_WORK_DIR}/PACKAGE -DTOOLS_DIR=${CMAKE_BINARY_DIR}/programs -DLINPHONE_OUTPUT_DIR=${CMAKE_INSTALL_PREFIX} -DLINPHONE_DESKTOP_DIR=${CMAKE_CURRENT_LIST_DIR}/.. -DLINPHONE_SOURCE_DIR=${EP_linphone_SOURCE_DIR} ${ENABLE_VARIABLES} -DLINPHONE_BUILDER_SIGNING_IDENTITY=${LINPHONE_BUILDER_SIGNING_IDENTITY} -+ CMAKE_ARGS ${LINPHONE_BUILDER_EP_ARGS} -DCMAKE_INSTALL_PREFIX=${LINPHONE_BUILDER_WORK_DIR}/PACKAGE -DTOOLS_DIR=${CMAKE_BINARY_DIR}/programs -DLINPHONE_DESKTOP_DIR=${CMAKE_CURRENT_LIST_DIR}/.. -DLINPHONE_SOURCE_DIR=${EP_linphone_SOURCE_DIR} ${ENABLE_VARIABLES} -DLINPHONE_BUILDER_SIGNING_IDENTITY=${LINPHONE_BUILDER_SIGNING_IDENTITY} - ) - endif () - endif () -diff --git a/linphone-app/cmake_builder/linphone_package/CMakeLists.txt b/linphone-app/cmake_builder/linphone_package/CMakeLists.txt -index baea03cf..d06dcb74 100644 ---- a/linphone-app/cmake_builder/linphone_package/CMakeLists.txt -+++ b/linphone-app/cmake_builder/linphone_package/CMakeLists.txt -@@ -200,44 +200,6 @@ elseif (APPLE) - endif () - # install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${APPLICATION_NAME}.app" DESTINATION "." USE_SOURCE_PERMISSIONS) - else()# Not Windows and Apple -- foreach (LIBRARY ${SHARED_LIBRARIES}) -- get_filename_component(LIBRARY_FILENAME ${LIBRARY} NAME) -- message("Changing RPATH of ${LIBRARY_FILENAME} from '${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}' to '$ORIGIN/../${CMAKE_INSTALL_LIBDIR}'") -- execute_process(COMMAND install_name_tool -rpath "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}" "$ORIGIN/../lib" "${LIBRARY}") -- execute_process(COMMAND install_name_tool -addrpath "$ORIGIN/../lib64" "${LIBRARY}") -- endforeach () -- install(DIRECTORY "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_BINDIR}/" DESTINATION "${CMAKE_INSTALL_BINDIR}" USE_SOURCE_PERMISSIONS) --#Just in case. This is useless because we have to use CMAKE_INSTALL_LIBDIR -- if( EXISTS "${LINPHONE_OUTPUT_DIR}/lib/") -- file(GLOB SHARED_LIBRARIES "${LINPHONE_OUTPUT_DIR}/lib/*.so*") -- if( ENABLE_OPENH264 )# Remove openH264 lib from the installation. this codec will be download by user -- foreach(item ${SHARED_LIBRARIES}) -- get_filename_component(LIBRARY_FILENAME ${item} NAME) -- if("${LIBRARY_FILENAME}" MATCHES "^libopenh264.*$") -- list(REMOVE_ITEM SHARED_LIBRARIES ${item}) -- endif() -- endforeach(item) -- endif() -- install(FILES ${SHARED_LIBRARIES} DESTINATION "lib") -- endif() -- if( EXISTS "${LINPHONE_OUTPUT_DIR}/lib64/") -- file(GLOB SHARED_LIBRARIES "${LINPHONE_OUTPUT_DIR}/lib64/*.so*") -- if( ENABLE_OPENH264 )# Remove openH264 lib from the installation. this codec will be download by user -- foreach(item ${SHARED_LIBRARIES}) -- get_filename_component(LIBRARY_FILENAME ${item} NAME) -- if("${LIBRARY_FILENAME}" MATCHES "^libopenh264.*$") -- list(REMOVE_ITEM SHARED_LIBRARIES ${item}) -- endif() -- endforeach(item) -- endif() -- install(FILES ${SHARED_LIBRARIES} DESTINATION "lib64") -- endif() -- install(DIRECTORY "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_DATAROOTDIR}/" DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}" USE_SOURCE_PERMISSIONS) -- if(ENABLE_BUILD_VERBOSE) -- message("INSTALLATION : ${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_DATAROOTDIR}/" ) -- endif() -- file(GLOB PLUGINS_FILES "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}/mediastreamer/plugins/*") -- install(FILES ${PLUGINS_FILES} DESTINATION "plugins/mediastreamer/" ) - # Install desktop/icon files. - configure_file("${CMAKE_CURRENT_SOURCE_DIR}/../../assets/linphone.desktop.cmake" "${CMAKE_CURRENT_BINARY_DIR}/../../${EXECUTABLE_NAME}.desktop" @ONLY) - install(FILES "${CMAKE_CURRENT_BINARY_DIR}/../../${EXECUTABLE_NAME}.desktop" DESTINATION "${CMAKE_INSTALL_DATADIR}/applications") + set(APP_PLUGIN app-plugin) diff --git a/linphone-app/linphoneqt_version.cmake b/linphone-app/linphoneqt_version.cmake new file mode 100644 index 00000000..a85d3455 --- /dev/null +++ b/linphone-app/linphoneqt_version.cmake -@@ -0,0 +1 @@ +@@ -0,0 +1,1 @@ +project(linphoneqt VERSION ${GUIX-SET-VERSION}) \ No newline at end of file -diff --git a/linphone-app/src/config.h.cmake b/linphone-app/src/config.h.cmake -index 093539e0..5a238c70 100644 ---- a/linphone-app/src/config.h.cmake -+++ b/linphone-app/src/config.h.cmake -@@ -28,3 +28,4 @@ - #cmakedefine ENABLE_UPDATE_CHECK 1 +diff -ru a/linphone-app/src/config.h.cmake b/linphone-app/src/config.h.cmake +--- a/linphone-app/src/config.h.cmake 1970-01-01 01:00:01.000000000 +0100 ++++ b/linphone-app/src/config.h.cmake 2023-04-08 16:05:33.458349986 +0200 +@@ -32,3 +32,4 @@ #cmakedefine EXECUTABLE_NAME "${EXECUTABLE_NAME}" #cmakedefine MSPLUGINS_DIR "${MSPLUGINS_DIR}" + #cmakedefine ENABLE_APP_WEBVIEW "${ENABLE_APP_WEBVIEW}" +#define LINPHONE_QT_GIT_VERSION "${PROJECT_VERSION}" \ No newline at end of file --- -2.31.0 - diff --git a/gnu/packages/patches/linux-pam-unix_chkpwd.patch b/gnu/packages/patches/linux-pam-unix_chkpwd.patch new file mode 100644 index 0000000000..0e865ff18c --- /dev/null +++ b/gnu/packages/patches/linux-pam-unix_chkpwd.patch @@ -0,0 +1,9 @@ +unix_chkpwd is designed to have a suid bit, but it's not possible to set it +for files in the store. This patch tells unix_pam.so to look for +unix_chkpwd in setuid program directory on Guix System. + +--- a/modules/pam_unix/Makefile.in ++++ b/modules/pam_unix/Makefile.in +@@ -651,1 +651,1 @@ +- -DCHKPWD_HELPER=\"$(sbindir)/unix_chkpwd\" \ ++ -DCHKPWD_HELPER=\"/run/setuid-programs/unix_chkpwd\" \ diff --git a/gnu/packages/patches/llvm-8-missing-include.patch b/gnu/packages/patches/llvm-8-missing-include.patch new file mode 100644 index 0000000000..4d7ca6d332 --- /dev/null +++ b/gnu/packages/patches/llvm-8-missing-include.patch @@ -0,0 +1,17 @@ +Add missing include statement for compatibility with libstdc++ 11. + +Taken from upstream: + + https://github.com/llvm/llvm-project/commit/b498303066a63a203d24f739b2d2e0e56dca70d1 + +diff --git a/utils/benchmark/src/benchmark_register.h b/utils/benchmark/src/benchmark_register.h +--- a/utils/benchmark/src/benchmark_register.h ++++ b/utils/benchmark/src/benchmark_register.h +@@ -1,6 +1,7 @@ + #ifndef BENCHMARK_REGISTER_H + #define BENCHMARK_REGISTER_H + ++#include <limits> + #include <vector> + + #include "check.h" diff --git a/gnu/packages/patches/lxqt-session-procps-4.patch b/gnu/packages/patches/lxqt-session-procps-4.patch new file mode 100644 index 0000000000..d10e310723 --- /dev/null +++ b/gnu/packages/patches/lxqt-session-procps-4.patch @@ -0,0 +1,82 @@ +From d1db1c791195f3c0cf148e2be8bd46c5a51ca535 Mon Sep 17 00:00:00 2001 +From: Palo Kisa <palo.kisa@gmail.com> +Date: Tue, 7 Mar 2023 14:21:40 +0100 +Subject: [PATCH 978/978] reaper: Build/Run on systems with procps-ng >= 4.0.0 + (#456) + +On Linux, make it possible to use libproc2 or libprocps whichever is +available. +--- + CMakeLists.txt | 6 +++++- + lxqt-session/src/procreaper.cpp | 24 +++++++++++++++++++++++- + 2 files changed, 28 insertions(+), 2 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a3c5e0d..f208600 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -35,7 +35,11 @@ find_package(X11 REQUIRED) + message(STATUS "Building with Qt${Qt5Core_VERSION}") + find_package(PkgConfig REQUIRED) + if (CMAKE_SYSTEM_NAME STREQUAL "Linux") +- pkg_search_module(PROCPS REQUIRED libprocps) ++ pkg_search_module(PROCPS REQUIRED libproc2 libprocps) ++ message(STATUS "Using PROCPS -> ${PROCPS_MODULE_NAME} v${PROCPS_VERSION}") ++ if (PROCPS_VERSION VERSION_GREATER_EQUAL 4.0.0) ++ add_definitions("-DUSING_LIBPROC2") ++ endif() + endif() + + # Please don't move, must be after lxqt +diff --git a/lxqt-session/src/procreaper.cpp b/lxqt-session/src/procreaper.cpp +index 2acd030..1ea4bdc 100644 +--- a/lxqt-session/src/procreaper.cpp ++++ b/lxqt-session/src/procreaper.cpp +@@ -29,7 +29,11 @@ + #include "log.h" + #if defined(Q_OS_LINUX) + #include <sys/prctl.h> +-#include <proc/readproc.h> ++# if defined(USING_LIBPROC2) ++# include <libproc2/pids.h> ++# else ++# include <proc/readproc.h> ++# endif + #elif defined(Q_OS_FREEBSD) + #include <sys/procctl.h> + #include <libutil.h> +@@ -109,6 +113,23 @@ void ProcReaper::stop(const std::set<int64_t> & excludedPids) + const pid_t my_pid = ::getpid(); + std::vector<pid_t> children; + #if defined(Q_OS_LINUX) ++# if defined(USING_LIBPROC2) ++ constexpr pids_item items[] = { PIDS_ID_PPID, PIDS_ID_TGID }; ++ enum rel_items { rel_ppid, rel_tgid }; ++ pids_info * info = nullptr; ++ procps_pids_new(&info, const_cast<pids_item *>(items), sizeof(items) / sizeof(pids_item)); ++ pids_stack * stack = nullptr; ++ while ((stack = procps_pids_get(info, PIDS_FETCH_TASKS_ONLY))) ++ { ++ const int ppid = PIDS_VAL(rel_ppid, s_int, stack, info); ++ if (ppid == my_pid) ++ { ++ const int tgid = PIDS_VAL(rel_tgid, s_int, stack, info); ++ children.push_back(tgid); ++ } ++ } ++ procps_pids_unref(&info); ++# else + PROCTAB * proc_dir = ::openproc(PROC_FILLSTAT); + while (proc_t * proc = ::readproc(proc_dir, nullptr)) + { +@@ -119,6 +140,7 @@ void ProcReaper::stop(const std::set<int64_t> & excludedPids) + ::freeproc(proc); + } + ::closeproc(proc_dir); ++# endif + #elif defined(Q_OS_FREEBSD) + int cnt = 0; + if (kinfo_proc *proc_info = kinfo_getallproc(&cnt)) +-- +2.39.2 + diff --git a/gnu/packages/patches/m4-gnulib-libio.patch b/gnu/packages/patches/m4-gnulib-libio.patch deleted file mode 100644 index a26622ccf3..0000000000 --- a/gnu/packages/patches/m4-gnulib-libio.patch +++ /dev/null @@ -1,128 +0,0 @@ -Adjust the bundled gnulib to cope with removal of libio interface in -glibc 2.28. - -Based on this upstream patch, without hunks that do not apply to m4: -https://git.savannah.gnu.org/cgit/gnulib.git/commit/?id=4af4a4a71827c0bc5e0ec67af23edef4f15cee8e - -diff --git a/lib/fflush.c b/lib/fflush.c -index 983ade0..a6edfa1 100644 ---- a/lib/fflush.c -+++ b/lib/fflush.c -@@ -33,7 +33,7 @@ - #undef fflush - - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - - /* Clear the stream's ungetc buffer, preserving the value of ftello (fp). */ - static void -@@ -72,7 +72,7 @@ clear_ungetc_buffer (FILE *fp) - - #endif - --#if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */) -+#if ! (defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */) - - # if (defined __sferror || defined __DragonFly__ || defined __ANDROID__) && defined __SNPT - /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Minix 3, Android */ -@@ -148,7 +148,7 @@ rpl_fflush (FILE *stream) - if (stream == NULL || ! freading (stream)) - return fflush (stream); - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - - clear_ungetc_buffer_preserving_position (stream); - -diff --git a/lib/fpending.c b/lib/fpending.c -index c84e3a5..789f50e 100644 ---- a/lib/fpending.c -+++ b/lib/fpending.c -@@ -32,7 +32,7 @@ __fpending (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - <stdio.h>, because they need it for implementing getc() and putc() as - fast macros. */ --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - return fp->_IO_write_ptr - fp->_IO_write_base; - #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__ - /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Minix 3, Android */ -diff --git a/lib/fpurge.c b/lib/fpurge.c -index b1d417c..3aedcc3 100644 ---- a/lib/fpurge.c -+++ b/lib/fpurge.c -@@ -62,7 +62,7 @@ fpurge (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - <stdio.h>, because they need it for implementing getc() and putc() as - fast macros. */ --# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - fp->_IO_read_end = fp->_IO_read_ptr; - fp->_IO_write_ptr = fp->_IO_write_base; - /* Avoid memory leak when there is an active ungetc buffer. */ -diff --git a/lib/freadahead.c b/lib/freadahead.c -index c2ecb5b..23ec76e 100644 ---- a/lib/freadahead.c -+++ b/lib/freadahead.c -@@ -30,7 +30,7 @@ extern size_t __sreadahead (FILE *); - size_t - freadahead (FILE *fp) - { --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - if (fp->_IO_write_ptr > fp->_IO_write_base) - return 0; - return (fp->_IO_read_end - fp->_IO_read_ptr) -diff --git a/lib/freading.c b/lib/freading.c -index 73c28ac..c24d0c8 100644 ---- a/lib/freading.c -+++ b/lib/freading.c -@@ -31,7 +31,7 @@ freading (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - <stdio.h>, because they need it for implementing getc() and putc() as - fast macros. */ --# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - return ((fp->_flags & _IO_NO_WRITES) != 0 - || ((fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING)) == 0 - && fp->_IO_read_base != NULL)); -diff --git a/lib/fseeko.c b/lib/fseeko.c -index 0101ab5..193f4e8 100644 ---- a/lib/fseeko.c -+++ b/lib/fseeko.c -@@ -47,7 +47,7 @@ fseeko (FILE *fp, off_t offset, int whence) - #endif - - /* These tests are based on fpurge.c. */ --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - if (fp->_IO_read_end == fp->_IO_read_ptr - && fp->_IO_write_ptr == fp->_IO_write_base - && fp->_IO_save_base == NULL) -@@ -123,7 +123,7 @@ fseeko (FILE *fp, off_t offset, int whence) - return -1; - } - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - fp->_flags &= ~_IO_EOF_SEEN; - fp->_offset = pos; - #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__ -diff --git a/lib/stdio-impl.h b/lib/stdio-impl.h -index 78d896e..05c5752 100644 ---- a/lib/stdio-impl.h -+++ b/lib/stdio-impl.h -@@ -18,6 +18,12 @@ - the same implementation of stdio extension API, except that some fields - have different naming conventions, or their access requires some casts. */ - -+/* Glibc 2.28 made _IO_IN_BACKUP private. For now, work around this -+ problem by defining it ourselves. FIXME: Do not rely on glibc -+ internals. */ -+#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN -+# define _IO_IN_BACKUP 0x100 -+#endif - - /* BSD stdio derived implementations. */ - diff --git a/gnu/packages/patches/mesa-fix-sporadic-test-failures.patch b/gnu/packages/patches/mesa-fix-sporadic-test-failures.patch new file mode 100644 index 0000000000..50ac5530a2 --- /dev/null +++ b/gnu/packages/patches/mesa-fix-sporadic-test-failures.patch @@ -0,0 +1,27 @@ +commit 7749599d737d205a88bbb6fa755ba095d9b581fa +Author: Gert Wollny <gert.wollny@collabora.com> +Date: Mon Aug 15 17:15:43 2022 +0200 + + r600/sfn: Initialize out buffer when printing op + + 79ca456b4837b3bc21cf9ef3c03c505c4b4909f6 + r600/sfn: rewrite NIR backend + + Closes: #7021 + + Signed-off-by: Gert Wollny <gert.wollny@collabora.com> + Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18130> + +diff --git a/src/gallium/drivers/r600/sfn/sfn_instr_export.cpp b/src/gallium/drivers/r600/sfn/sfn_instr_export.cpp +index 3d40ea1796a..00826ed6457 100644 +--- a/src/gallium/drivers/r600/sfn/sfn_instr_export.cpp ++++ b/src/gallium/drivers/r600/sfn/sfn_instr_export.cpp +@@ -206,7 +206,7 @@ bool WriteScratchInstr::do_ready() const + + void WriteScratchInstr::do_print(std::ostream& os) const + { +- char buf[6]; ++ char buf[6] = {0}; + + os << "WRITE_SCRATCH "; + if (m_address) diff --git a/gnu/packages/patches/mesa-skip-tests.patch b/gnu/packages/patches/mesa-skip-tests.patch deleted file mode 100644 index 7ff571dcf5..0000000000 --- a/gnu/packages/patches/mesa-skip-tests.patch +++ /dev/null @@ -1,19 +0,0 @@ -This test fails on i686-linux. I couldn't come up with a regex that -could be used to disable it just on i686-linux, so we disable it -completely with this patch: - -https://gitlab.freedesktop.org/mesa/mesa/-/issues/4091 - -diff --git a/src/util/meson.build b/src/util/meson.build -index 319b22d9bf7..93790c72675 100644 ---- a/src/util/meson.build -+++ b/src/util/meson.build -@@ -344,7 +344,7 @@ if with_tests - ) - endif - -- foreach t: ['bitset', 'register_allocate', 'u_debug_stack', 'u_qsort'] -+ foreach t: ['bitset', 'register_allocate', 'u_qsort'] - test( - t, - executable( diff --git a/gnu/packages/patches/meson-allow-dirs-outside-of-prefix.patch b/gnu/packages/patches/meson-allow-dirs-outside-of-prefix.patch deleted file mode 100644 index f16daa8009..0000000000 --- a/gnu/packages/patches/meson-allow-dirs-outside-of-prefix.patch +++ /dev/null @@ -1,20 +0,0 @@ -Source: https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/development/tools/build-managers/meson/allow-dirs-outside-of-prefix.patch ---- a/mesonbuild/coredata.py -+++ b/mesonbuild/coredata.py -@@ -506,7 +506,6 @@ class CoreData: - return value - if option.name.endswith('dir') and value.is_absolute() and \ - option not in BULITIN_DIR_NOPREFIX_OPTIONS: -- # Value must be a subdir of the prefix - # commonpath will always return a path in the native format, so we - # must use pathlib.PurePath to do the same conversion before - # comparing. -@@ -518,7 +517,7 @@ class CoreData: - try: - value = value.relative_to(prefix) - except ValueError: -- raise MesonException(msg.format(option, value, prefix)) -+ pass - if '..' in str(value): - raise MesonException(msg.format(option, value, prefix)) - return value.as_posix() diff --git a/gnu/packages/patches/mig-cpu.h-generation.patch b/gnu/packages/patches/mig-cpu.h-generation.patch new file mode 100644 index 0000000000..3030eaeaa6 --- /dev/null +++ b/gnu/packages/patches/mig-cpu.h-generation.patch @@ -0,0 +1,16 @@ +Backport MiG commit 73fbf2504ae606dda81372701a67dad6fee0865e: + + From: Flavio Cruz <flaviocruz@gmail.com> + Subject: Generate cpu.h with -ffreestanding + +--- a/Makefile.in 2023-03-26 23:02:51.384318331 +0200 ++++ b/Makefile.in 2023-03-26 23:03:03.300329369 +0200 +@@ -1051,7 +1051,7 @@ uninstall-am: uninstall-binSCRIPTS unins + .sym.symc: + $(AWK_V) $(AWK) -f $(srcdir)/gensym.awk $< > $@ + .symc.symo: +- $(AM_V_CC) $(TARGET_CC) -S $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) -x c -o $@ $< ++ $(AM_V_CC) $(TARGET_CC) -S $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) -ffreestanding -x c -o $@ $< + .symo.h: + $(AM_V_GEN) sed -e '/^[^*].*$$/d' -e 's/^[*]/#define/' -e 's/mAgIc[^-0-9]*//' \ + $< > $@ diff --git a/gnu/packages/patches/mm-common-reproducible-tarball.patch b/gnu/packages/patches/mm-common-reproducible-tarball.patch new file mode 100644 index 0000000000..f0890aaf57 --- /dev/null +++ b/gnu/packages/patches/mm-common-reproducible-tarball.patch @@ -0,0 +1,40 @@ +From 024c121c844a4ec920133eb3f7e6b6ee8044c0b6 Mon Sep 17 00:00:00 2001 +From: Vagrant Cascadian <vagrant@reproducible-builds.org> +Date: Sat, 12 Dec 2020 04:05:56 +0000 +Original-Patch: https://bugs.debian.org/977177 +Subject: [PATCH] Set uid, username, gid, and group name on files in + generated tarball. + +The user and group may otherwise vary between builds on different systems. + +--- + util/meson_aux/skeletonmm-tarball.py | 16 +++++++++++++++- + 1 file changed, 15 insertions(+), 1 deletion(-) + +diff --git a/util/meson_aux/skeletonmm-tarball.py b/util/meson_aux/skeletonmm-tarball.py +index db9e650..89049b6 100755 +--- a/util/meson_aux/skeletonmm-tarball.py ++++ b/util/meson_aux/skeletonmm-tarball.py +@@ -39,10 +39,18 @@ elif output_file.endswith('.gz'): + else: + mode = 'w' + ++def reproducible(tarinfo): ++ # Set consistent user and group on files in the tar archive ++ tarinfo.uid = 0 ++ tarinfo.uname = 'root' ++ tarinfo.gid = 0 ++ tarinfo.gname = 'root' ++ return tarinfo ++ + with tarfile.open(output_file, mode=mode) as tar_file: + os.chdir(source_dir) # Input filenames are relative to source_dir. + for file in sys.argv[3:]: +- tar_file.add(file) ++ tar_file.add(file, filter=reproducible) + # Errors raise exceptions. If an exception is raised, Meson+ninja will notice + # that the command failed, despite exit(0). + sys.exit(0) +-- +2.29.2 + diff --git a/gnu/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch b/gnu/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch new file mode 100644 index 0000000000..a8144b85e6 --- /dev/null +++ b/gnu/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch @@ -0,0 +1,52 @@ +From 5a224b981ee32d7cf59aaa9e2c101af65a275edc Mon Sep 17 00:00:00 2001 +From: Julien Lepiller <julien@lepiller.eu> +Date: Mon, 20 Feb 2023 19:14:12 +0100 +Subject: [PATCH] Dynamically allocate the alternate signal stack. + +This patch is a backport of https://github.com/ocaml/ocaml/pull/10266. +--- + asmrun/signals_asm.c | 19 +++++++++++-------- + 1 file changed, 11 insertions(+), 8 deletions(-) + +diff --git a/asmrun/signals_asm.c b/asmrun/signals_asm.c +index 3895d75..7e2abe8 100644 +--- a/asmrun/signals_asm.c ++++ b/asmrun/signals_asm.c +@@ -182,7 +182,6 @@ DECLARE_SIGNAL_HANDLER(trap_handler) + #ifdef HAS_STACK_OVERFLOW_DETECTION + + static char * system_stack_top; +-static char sig_alt_stack[SIGSTKSZ]; + + #if defined(SYS_linux) + /* PR#4746: recent Linux kernels with support for stack randomization +@@ -274,15 +273,19 @@ void caml_init_signals(void) + #ifdef HAS_STACK_OVERFLOW_DETECTION + { + stack_t stk; +- struct sigaction act; +- stk.ss_sp = sig_alt_stack; ++ stk.ss_sp = malloc(SIGSTKSZ); + stk.ss_size = SIGSTKSZ; + stk.ss_flags = 0; +- SET_SIGACT(act, segv_handler); +- act.sa_flags |= SA_ONSTACK | SA_NODEFER; +- sigemptyset(&act.sa_mask); +- system_stack_top = (char *) &act; +- if (sigaltstack(&stk, NULL) == 0) { sigaction(SIGSEGV, &act, NULL); } ++ if (stk.ss_sp != NULL) { ++ if (sigaltstack(&stk, NULL) != -1) { ++ struct sigaction act; ++ SET_SIGACT(act, segv_handler); ++ act.sa_flags |= SA_ONSTACK | SA_NODEFER; ++ sigemptyset(&act.sa_mask); ++ system_stack_top = (char *) &act; ++ sigaction(SIGSEGV, &act, NULL); ++ } ++ } + } + #endif + } +-- +2.38.1 + diff --git a/gnu/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch b/gnu/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch new file mode 100644 index 0000000000..2af1582976 --- /dev/null +++ b/gnu/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch @@ -0,0 +1,52 @@ +From 95f5016955e519c392c746e38e0c9460f2c1aa0c Mon Sep 17 00:00:00 2001 +From: Julien Lepiller <julien@lepiller.eu> +Date: Sun, 19 Feb 2023 09:58:57 +0100 +Subject: [PATCH] Dynamically allocate the alternate signal stack. + +This patch is a backport of https://github.com/ocaml/ocaml/pull/10266. +--- + runtime/signals_nat.c | 19 +++++++++++-------- + 1 file changed, 11 insertions(+), 8 deletions(-) + +diff --git a/runtime/signals_nat.c b/runtime/signals_nat.c +index 29a5f49..a193fc2 100644 +--- a/runtime/signals_nat.c ++++ b/runtime/signals_nat.c +@@ -182,7 +182,6 @@ DECLARE_SIGNAL_HANDLER(trap_handler) + #ifdef HAS_STACK_OVERFLOW_DETECTION + + static char * system_stack_top; +-static char sig_alt_stack[SIGSTKSZ]; + + #if defined(SYS_linux) + /* PR#4746: recent Linux kernels with support for stack randomization +@@ -274,15 +273,19 @@ void caml_init_signals(void) + #ifdef HAS_STACK_OVERFLOW_DETECTION + { + stack_t stk; +- struct sigaction act; +- stk.ss_sp = sig_alt_stack; ++ stk.ss_sp = malloc(SIGSTKSZ); + stk.ss_size = SIGSTKSZ; + stk.ss_flags = 0; +- SET_SIGACT(act, segv_handler); +- act.sa_flags |= SA_ONSTACK | SA_NODEFER; +- sigemptyset(&act.sa_mask); +- system_stack_top = (char *) &act; +- if (sigaltstack(&stk, NULL) == 0) { sigaction(SIGSEGV, &act, NULL); } ++ if (stk.ss_sp != NULL) { ++ if (sigaltstack(&stk, NULL) != -1) { ++ struct sigaction act; ++ SET_SIGACT(act, segv_handler); ++ act.sa_flags |= SA_ONSTACK | SA_NODEFER; ++ sigemptyset(&act.sa_mask); ++ system_stack_top = (char *) &act; ++ sigaction(SIGSEGV, &act, NULL); ++ } ++ } + } + #endif + } +-- +2.38.1 + diff --git a/gnu/packages/patches/openjdk-10-pointer-comparison.patch b/gnu/packages/patches/openjdk-10-pointer-comparison.patch new file mode 100644 index 0000000000..9c09f8e391 --- /dev/null +++ b/gnu/packages/patches/openjdk-10-pointer-comparison.patch @@ -0,0 +1,14 @@ +Patch inspired by file comparison with openjdk@19. + +diff -u -r openjdk-10.alt/src/hotspot/os/linux/os_linux.cpp openjdk-10/src/hotspot/os/linux/os_linux.cpp +--- openjdk-10.alt/src/hotspot/os/linux/os_linux.cpp 2023-04-05 15:02:56.994779480 +0200 ++++ openjdk-10/src/hotspot/os/linux/os_linux.cpp 2023-04-05 15:07:47.267537301 +0200 +@@ -2155,7 +2155,7 @@ + } + + p = OSContainer::cpu_cpuset_memory_nodes(); +- if (p < 0) ++ if (p == NULL) + st->print("cpu_memory_nodes() failed\n"); + else { + st->print("cpu_memory_nodes: %s\n", p); diff --git a/gnu/packages/patches/openjdk-10-setsignalhandler.patch b/gnu/packages/patches/openjdk-10-setsignalhandler.patch new file mode 100644 index 0000000000..c91ae6b318 --- /dev/null +++ b/gnu/packages/patches/openjdk-10-setsignalhandler.patch @@ -0,0 +1,25 @@ +Patch inspired by file comparison with openjdk@19. + +diff -u -r openjdk-10.alt/test/hotspot/jtreg/runtime/StackGuardPages/exeinvoke.c openjdk-10/test/hotspot/jtreg/runtime/StackGuardPages/exeinvoke.c +--- openjdk-10.alt/test/hotspot/jtreg/runtime/StackGuardPages/exeinvoke.c 2023-04-05 15:03:00.070787628 +0200 ++++ openjdk-10/test/hotspot/jtreg/runtime/StackGuardPages/exeinvoke.c 2023-04-05 15:29:51.379824348 +0200 +@@ -67,8 +67,17 @@ + longjmp(context, 1); + } + +-void set_signal_handler() { +- static char altstack[SIGSTKSZ]; ++static char* altstack = NULL; ++ ++ void set_signal_handler() { ++ if (altstack == NULL) { ++ // Dynamically allocated in case SIGSTKSZ is not constant ++ altstack = (char*)malloc(SIGSTKSZ); ++ if (altstack == NULL) { ++ fprintf(stderr, "Test ERROR. Unable to malloc altstack space\n"); ++ exit(7); ++ } ++ } + + stack_t ss = { + .ss_size = SIGSTKSZ, diff --git a/gnu/packages/patches/openjdk-9-pointer-comparison.patch b/gnu/packages/patches/openjdk-9-pointer-comparison.patch new file mode 100644 index 0000000000..dd443ae817 --- /dev/null +++ b/gnu/packages/patches/openjdk-9-pointer-comparison.patch @@ -0,0 +1,27 @@ +The following patch prevents build failures due to comparisons between +a pointer and an integer. It has been adapted from openjdk@10. + +diff -u -r openjdk-9.alt/hotspot/src/share/vm/memory/virtualspace.cpp openjdk-9/hotspot/src/share/vm/memory/virtualspace.cpp +--- openjdk-9.alt/hotspot/src/share/vm/memory/virtualspace.cpp 2023-04-05 13:46:58.841965513 +0200 ++++ openjdk-9/hotspot/src/share/vm/memory/virtualspace.cpp 2023-04-05 13:48:43.902387837 +0200 +@@ -581,7 +581,7 @@ + assert(markOopDesc::encode_pointer_as_mark(&_base[size])->decode_pointer() == &_base[size], + "area must be distinguishable from marks for mark-sweep"); + +- if (base() > 0) { ++ if (base() != NULL) { + MemTracker::record_virtual_memory_type((address)base(), mtJavaHeap); + } + } +diff -u -r openjdk-9.alt/hotspot/src/share/vm/opto/lcm.cpp openjdk-9/hotspot/src/share/vm/opto/lcm.cpp +--- openjdk-9.alt/hotspot/src/share/vm/opto/lcm.cpp 2023-04-05 13:46:58.849965545 +0200 ++++ openjdk-9/hotspot/src/share/vm/opto/lcm.cpp 2023-04-05 13:47:53.566187260 +0200 +@@ -39,7 +39,7 @@ + // Check whether val is not-null-decoded compressed oop, + // i.e. will grab into the base of the heap if it represents NULL. + static bool accesses_heap_base_zone(Node *val) { +- if (Universe::narrow_oop_base() > 0) { // Implies UseCompressedOops. ++ if (Universe::narrow_oop_base() != NULL) { // Implies UseCompressedOops. + if (val && val->is_Mach()) { + if (val->as_Mach()->ideal_Opcode() == Op_DecodeN) { + // This assumes all Decodes with TypePtr::NotNull are matched to nodes that diff --git a/gnu/packages/patches/openjdk-9-setsignalhandler.patch b/gnu/packages/patches/openjdk-9-setsignalhandler.patch new file mode 100644 index 0000000000..500bf2360b --- /dev/null +++ b/gnu/packages/patches/openjdk-9-setsignalhandler.patch @@ -0,0 +1,24 @@ +Patch taken from file comparison with openjdk@19. + +diff -u -r openjdk-9.alt/hotspot/test/runtime/StackGuardPages/exeinvoke.c openjdk-9/hotspot/test/runtime/StackGuardPages/exeinvoke.c +--- openjdk-9.alt/hotspot/test/runtime/StackGuardPages/exeinvoke.c 2023-04-05 13:46:58.689964892 +0200 ++++ openjdk-9/hotspot/test/runtime/StackGuardPages/exeinvoke.c 2023-04-05 14:15:52.435613325 +0200 +@@ -67,8 +67,17 @@ + longjmp(context, 1); + } + ++static char* altstack = NULL; ++ + void set_signal_handler() { +- static char altstack[SIGSTKSZ]; ++ if (altstack == NULL) { ++ // Dynamically allocated in case SIGSTKSZ is not constant ++ altstack = (char*)malloc(SIGSTKSZ); ++ if (altstack == NULL) { ++ fprintf(stderr, "Test ERROR. Unable to malloc altstack space\n"); ++ exit(7); ++ } ++ } + + stack_t ss = { + .ss_size = SIGSTKSZ, diff --git a/gnu/packages/patches/p7zip-fix-build-with-gcc-11.patch b/gnu/packages/patches/p7zip-fix-build-with-gcc-11.patch new file mode 100644 index 0000000000..20a40488d8 --- /dev/null +++ b/gnu/packages/patches/p7zip-fix-build-with-gcc-11.patch @@ -0,0 +1,49 @@ +Building p7zip with GCC 11 or newer normally fails with error messages like + + ../../../../CPP/7zip/Archive/Wim/WimHandler.cpp:308:11: error: use of an + operand of type ‘bool’ in ‘operator++’ is forbidden in C++17 + 308 | numMethods++; + | ^~~~~~~~~~ + +This patch causes GCC to interpret the code using the GNU dialect of the C++14 +standard, as GCC 10 did by default, and reduces these errors to warnings. + +diff --git a/makefile.linux_amd64_asm b/makefile.linux_amd64_asm +index 075c6a8..b7d73ee 100644 +--- a/makefile.linux_amd64_asm ++++ b/makefile.linux_amd64_asm +@@ -11,6 +11,8 @@ ALLFLAGS=-m64 ${OPTFLAGS} -pipe \ + -D_7ZIP_ASM \ + $(LOCAL_FLAGS) + ++ALLFLAGS_CPP=-std=gnu++14 ++ + CXX=g++ + CC=gcc + CC_SHARED=-fPIC +diff --git a/makefile.linux_any_cpu_gcc_4.X b/makefile.linux_any_cpu_gcc_4.X +index be093b5..c0f3120 100644 +--- a/makefile.linux_any_cpu_gcc_4.X ++++ b/makefile.linux_any_cpu_gcc_4.X +@@ -10,7 +10,7 @@ ALLFLAGS=${OPTFLAGS} -pipe \ + -D_7ZIP_LARGE_PAGES \ + $(LOCAL_FLAGS) + +-ALLFLAGS_CPP=-DENV_HAVE_GCCVISIBILITYPATCH -fvisibility=hidden -fvisibility-inlines-hidden ++ALLFLAGS_CPP=-DENV_HAVE_GCCVISIBILITYPATCH -std=gnu++14 -fvisibility=hidden -fvisibility-inlines-hidden + + CXX=g++ + CC=gcc +diff --git a/makefile.linux_x86_asm_gcc_4.X b/makefile.linux_x86_asm_gcc_4.X +index 1ac339b..6e736d9 100644 +--- a/makefile.linux_x86_asm_gcc_4.X ++++ b/makefile.linux_x86_asm_gcc_4.X +@@ -12,7 +12,7 @@ ALLFLAGS=${OPTFLAGS} -pipe -m32 \ + -D_7ZIP_ASM \ + $(LOCAL_FLAGS) + +-ALLFLAGS_CPP=-DENV_HAVE_GCCVISIBILITYPATCH -fvisibility=hidden -fvisibility-inlines-hidden ++ALLFLAGS_CPP=-DENV_HAVE_GCCVISIBILITYPATCH -std=gnu++14 -fvisibility=hidden -fvisibility-inlines-hidden + + CXX=g++ + CC=gcc diff --git a/gnu/packages/patches/pciutils-hurd-configure.patch b/gnu/packages/patches/pciutils-hurd-configure.patch deleted file mode 100644 index 226891a995..0000000000 --- a/gnu/packages/patches/pciutils-hurd-configure.patch +++ /dev/null @@ -1,35 +0,0 @@ -Add ability to detect GNU/Hurd when configuring. - -Adapted from https://git.hadrons.org/cgit/debian/pkgs/pciutils.git/tree/debian/patches/00-configure-hurd.patch - -From e39a3af22501234a91cf28e8c57b45f9379f9101 Mon Sep 17 00:00:00 2001 -From: Damien Zammit <damien@zamaudio.com> -Date: Fri, 26 Oct 2018 09:24:04 -0400 -Subject: [PATCH 2/2] Add ability to detect GNU/Hurd when configuring - ---- - lib/configure | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - ---- a/lib/configure -+++ b/lib/configure -@@ -25,7 +25,7 @@ if [ -z "$HOST" ] ; then - proc=`/usr/sbin/lsdev -C -c processor -S available -F name | head -1` - cpu=`/usr/sbin/lsattr -F value -l $proc -a type | sed 's/_.*//'` - else -- cpu=`uname -m | sed 's/^i.86$/i386/;s/^sun4u$/sparc64/;s/^i86pc$/i386/;s/^BePC$/i386/;s/^BeMac$/powerpc/;s/^BeBox$/powerpc/'` -+ cpu=`uname -m | sed 's/^i.86-AT386/i386/;s/^i.86$/i386/;s/^sun4u$/sparc64/;s/^i86pc$/i386/;s/^BePC$/i386/;s/^BeMac$/powerpc/;s/^BeBox$/powerpc/'` - fi - if [ "$sys" = "DragonFly" ] - then -@@ -39,6 +39,10 @@ if [ -z "$HOST" ] ; then - then - sys=cygwin - fi -+ if [ "$sys" = "GNU" ] -+ then -+ sys=gnu -+ fi - HOST=${3:-$cpu-$sys} - fi - [ -n "$RELEASE" ] && rel="${RELEASE}" diff --git a/gnu/packages/patches/pciutils-hurd-fix.patch b/gnu/packages/patches/pciutils-hurd-fix.patch deleted file mode 100644 index f1979d4352..0000000000 --- a/gnu/packages/patches/pciutils-hurd-fix.patch +++ /dev/null @@ -1,23 +0,0 @@ -Fix a build error on GNU/Hurd for pciutils 3.7.0. - -commit 053cf6c8b2acafadf828912828336d90fe9b8696 -Author: Martin Mares <mj@ucw.cz> -Date: Sun May 31 11:53:28 2020 +0200 - - HURD backend should compile again - - Fixes a bug introduced by commit 82c06b47dea5a38075ce9d56f743360bc47b4c78. - -diff --git a/lib/hurd.c b/lib/hurd.c -index 7b3b2ae..ccd92f6 100644 ---- a/lib/hurd.c -+++ b/lib/hurd.c -@@ -307,7 +307,6 @@ hurd_fill_regions(struct pci_dev *d) - d->base_addr[i] |= regions[i].is_64 << 2; - d->base_addr[i] |= regions[i].is_prefetchable << 3; - -- if (flags & PCI_FILL_SIZES) -- d->size[i] = regions[i].size; -+ d->size[i] = regions[i].size; - } - } diff --git a/gnu/packages/patches/procps-strtod-test.patch b/gnu/packages/patches/procps-strtod-test.patch new file mode 100644 index 0000000000..db1cee320e --- /dev/null +++ b/gnu/packages/patches/procps-strtod-test.patch @@ -0,0 +1,36 @@ +See https://gitlab.com/procps-ng/procps/-/issues/271 + +diff -u -r procps-ng-4.0.3.alt/src/tests/test_strtod_nol.c procps-ng-4.0.3/src/tests/test_strtod_nol.c +--- procps-ng-4.0.3.alt/src/tests/test_strtod_nol.c 2022-12-18 23:44:18.383960834 +0100 ++++ procps-ng-4.0.3/src/tests/test_strtod_nol.c 2023-03-20 16:52:26.680032658 +0100 +@@ -1,6 +1,7 @@ + + #include <stdio.h> + #include <stdlib.h> ++#include <math.h> + #include "strutils.h" + + struct strtod_tests { +@@ -25,6 +26,11 @@ + {NULL, 0.0} + }; + ++#define EPSILON 1.0 // Really not trying for precision here ++int dequal(const double d1, const double d2) ++{ ++ return fabs(d1-d2) < EPSILON; ++} + + + int main(int argc, char *argv[]) +@@ -33,8 +39,8 @@ + double val; + + for(i=0; tests[i].string != NULL; i++) { +- if(strtod_nol_or_err(tests[i].string, "Cannot parse number") != +- tests[i].result) { ++ if(!dequal (strtod_nol_or_err(tests[i].string, "Cannot parse number"), ++ tests[i].result)) { + fprintf(stderr, "FAIL: strtod_nol_or_err(\"%s\") != %f\n", + tests[i].string, tests[i].result); + return EXIT_FAILURE; diff --git a/gnu/packages/patches/prusa-slicer-boost-fixes.patch b/gnu/packages/patches/prusa-slicer-boost-fixes.patch new file mode 100644 index 0000000000..5bca271625 --- /dev/null +++ b/gnu/packages/patches/prusa-slicer-boost-fixes.patch @@ -0,0 +1,97 @@ +Fixes for Boost compatibility. +This patch comes from Gentoo: + portage/media-gfx/prusaslicer/files/prusaslicer-2.5.0_alpha2-boost-fixes.patch + +--- a/src/hints/HintsToPot.cpp ++++ b/src/hints/HintsToPot.cpp +@@ -1,6 +1,7 @@ + #include <iostream> + #include <vector> + #include <string> ++#include <boost/nowide/fstream.hpp> + #include <boost/filesystem.hpp> + #include <boost/dll.hpp> + #include <boost/property_tree/ini_parser.hpp> +@@ -9,7 +10,7 @@ + + bool write_to_pot(boost::filesystem::path path, const std::vector<std::pair<std::string, std::string>>& data) + { +- boost::filesystem::ofstream file(std::move(path), std::ios_base::app); ++ boost::nowide::ofstream file(std::move(path), std::ios_base::app); + for (const auto& element : data) + { + //Example of .pot element +--- a/src/libslic3r/Preset.cpp ++++ b/src/libslic3r/Preset.cpp +@@ -25,6 +25,7 @@ + #include <stdexcept> + #include <unordered_map> + #include <boost/format.hpp> ++#include <boost/nowide/fstream.hpp> + #include <boost/filesystem.hpp> + #include <boost/filesystem/fstream.hpp> + #include <boost/algorithm/string.hpp> +@@ -84,7 +85,7 @@ ConfigFileType guess_config_file_type(const ptree &tree) + VendorProfile VendorProfile::from_ini(const boost::filesystem::path &path, bool load_all) + { + ptree tree; +- boost::filesystem::ifstream ifs(path); ++ boost::nowide::ifstream ifs(path); + boost::property_tree::read_ini(ifs, tree); + return VendorProfile::from_ini(tree, path, load_all); + } +--- a/src/slic3r/GUI/DesktopIntegrationDialog.cpp ++++ b/src/slic3r/GUI/DesktopIntegrationDialog.cpp +@@ -10,6 +10,7 @@ + #include "libslic3r/Platform.hpp" + #include "libslic3r/Config.hpp" + ++#include <boost/nowide/fstream.hpp> + #include <boost/filesystem.hpp> + #include <boost/log/trivial.hpp> + #include <boost/dll/runtime_symbol_info.hpp> +@@ -503,4 +504,4 @@ DesktopIntegrationDialog::~DesktopIntegrationDialog() + + } // namespace GUI + } // namespace Slic3r +-#endif // __linux__ +\ No newline at end of file ++#endif // __linux__ +--- a/src/slic3r/GUI/GUI_App.cpp ++++ b/src/slic3r/GUI/GUI_App.cpp +@@ -13,6 +13,7 @@ + #include <cstdlib> + #include <regex> + #include <string_view> ++#include <boost/nowide/fstream.hpp> + #include <boost/algorithm/string/predicate.hpp> + #include <boost/algorithm/string.hpp> + #include <boost/format.hpp> +--- a/src/slic3r/GUI/HintNotification.cpp ++++ b/src/slic3r/GUI/HintNotification.cpp +@@ -15,6 +15,7 @@ + #include "libslic3r/PrintConfig.hpp" + + #include <boost/algorithm/string/replace.hpp> ++#include <boost/nowide/fstream.hpp> + #include <boost/filesystem.hpp> + #include <boost/nowide/fstream.hpp> + #include <boost/log/trivial.hpp> +@@ -65,7 +66,7 @@ inline void push_style_color(ImGuiCol idx, const ImVec4& col, bool fading_out, f + + void write_used_binary(const std::vector<std::string>& ids) + { +- boost::filesystem::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal"), std::ios::binary); ++ boost::nowide::ofstream file((boost::filesystem::path(data_dir()) / "cache" / "hints.cereal"), std::ios::binary); + cereal::BinaryOutputArchive archive(file); + HintsCerealData cd { ids }; + try +@@ -84,7 +85,7 @@ void read_used_binary(std::vector<std::string>& ids) + BOOST_LOG_TRIVIAL(warning) << "Failed to load to hints.cereal. File does not exists. " << path.string(); + return; + } +- boost::filesystem::ifstream file(path); ++ boost::nowide::ifstream file(path); + cereal::BinaryInputArchive archive(file); + HintsCerealData cd; + try diff --git a/gnu/packages/patches/prusa-slicer-fix-tests.patch b/gnu/packages/patches/prusa-slicer-fix-tests.patch new file mode 100644 index 0000000000..da9a5307f9 --- /dev/null +++ b/gnu/packages/patches/prusa-slicer-fix-tests.patch @@ -0,0 +1,17 @@ +This patch comes from Gentoo: + portage/media-gfx/prusaslicer/files/prusaslicer-2.5.0_rc1-fix-tests.patch + +--- a/tests/fff_print/test_data.cpp ++++ b/tests/fff_print/test_data.cpp +@@ -4,10 +4,9 @@ + #include "libslic3r/GCodeReader.hpp" + #include "libslic3r/Config.hpp" + #include "libslic3r/Print.hpp" +-#include "libslic3r/Format/OBJ.hpp" +-#include "libslic3r/Format/STL.hpp" + + #include <cstdlib> ++#include <fstream> + #include <string> + + #include <boost/nowide/cstdio.hpp> diff --git a/gnu/packages/patches/prusa-slicer-with-cereal-1.3.1.patch b/gnu/packages/patches/prusa-slicer-with-cereal-1.3.1.patch new file mode 100644 index 0000000000..affa506b1c --- /dev/null +++ b/gnu/packages/patches/prusa-slicer-with-cereal-1.3.1.patch @@ -0,0 +1,52 @@ +Fix for building with cereal>=1.3.1. +This patch comes from Gentoo: + portage/media-gfx/prusaslicer/files/prusaslicer-2.5.0_rc1-cereal-1.3.1.patch + +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -127,7 +127,7 @@ + set_target_properties(PrusaSlicer PROPERTIES OUTPUT_NAME "prusa-slicer") + endif () + +-target_link_libraries(PrusaSlicer libslic3r cereal) ++target_link_libraries(PrusaSlicer libslic3r libcereal) + + if (APPLE) + # add_compile_options(-stdlib=libc++) +--- a/src/slic3r/CMakeLists.txt ++++ b/src/slic3r/CMakeLists.txt +@@ -260,7 +260,7 @@ + + encoding_check(libslic3r_gui) + +-target_link_libraries(libslic3r_gui libslic3r avrdude cereal imgui GLEW::GLEW OpenGL::GL hidapi libcurl ${wxWidgets_LIBRARIES}) ++target_link_libraries(libslic3r_gui libslic3r avrdude libcereal imgui GLEW::GLEW OpenGL::GL hidapi libcurl ${wxWidgets_LIBRARIES}) + + if (MSVC) + target_link_libraries(libslic3r_gui Setupapi.lib) +--- a/src/libslic3r/CMakeLists.txt ++++ b/src/libslic3r/CMakeLists.txt +@@ -395,7 +395,7 @@ + target_link_libraries(libslic3r + libnest2d + admesh +- cereal ++ libcereal + libigl + miniz + boost_libs +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -446,6 +446,12 @@ + + # Find the Cereal serialization library + find_package(cereal REQUIRED) ++add_library(libcereal INTERFACE) ++if (NOT TARGET cereal::cereal) ++ target_link_libraries(libcereal INTERFACE cereal) ++else() ++ target_link_libraries(libcereal INTERFACE cereal::cereal) ++endif() + + # l10n + set(L10N_DIR "${SLIC3R_RESOURCES_DIR}/localization") diff --git a/gnu/packages/patches/pytest-fix-unstrable-exception-test.patch b/gnu/packages/patches/pytest-fix-unstrable-exception-test.patch new file mode 100644 index 0000000000..4d77786b77 --- /dev/null +++ b/gnu/packages/patches/pytest-fix-unstrable-exception-test.patch @@ -0,0 +1,34 @@ +From b55e264a675f7621b8351e227b93742f19e01c7d Mon Sep 17 00:00:00 2001 +From: Daniel Valenzuela <dsvalenzuela@uc.cl> +Date: Wed, 9 Nov 2022 19:43:10 -0300 +Subject: [PATCH] Fix test_raising_repr test + +Closes #10473 + +Python <3.11 versions depend on `exceptiongroup>=1.0.0rc8`, and they released version `1.0.1` +6 days ago (2022/11/03) that as a side-effect changed the output of exceptions. +--- + testing/test_assertion.py | 10 +--------- + 1 file changed, 1 insertion(+), 9 deletions(-) + +diff --git a/testing/test_assertion.py b/testing/test_assertion.py +index d8844f2e41..7574592210 100644 +--- a/testing/test_assertion.py ++++ b/testing/test_assertion.py +@@ -1664,15 +1664,7 @@ def test_raising_repr(): + """ + ) + result = pytester.runpytest() +- if sys.version_info >= (3, 11): +- # python 3.11 has native support for un-str-able exceptions +- result.stdout.fnmatch_lines( +- ["E AssertionError: <exception str() failed>"] +- ) +- else: +- result.stdout.fnmatch_lines( +- ["E AssertionError: <unprintable AssertionError object>"] +- ) ++ result.stdout.fnmatch_lines(["E AssertionError: <exception str() failed>"]) + + + def test_issue_1944(pytester: Pytester) -> None: diff --git a/gnu/packages/patches/python-2.7-expat-compat.patch b/gnu/packages/patches/python-2.7-expat-compat.patch new file mode 100644 index 0000000000..9cbdf8bd6a --- /dev/null +++ b/gnu/packages/patches/python-2.7-expat-compat.patch @@ -0,0 +1,59 @@ +Fix test failure with newer Expat: + + https://bugs.python.org/issue46811 + +This is a backport of this upstream commit: + + https://github.com/python/cpython/commit/2cae93832f46b245847bdc252456ddf7742ef45e + +diff --git a/Lib/test/test_minidom.py b/Lib/test/test_minidom.py +index 2eb642395b..1793f9365d 100644 +--- a/Lib/test/test_minidom.py ++++ b/Lib/test/test_minidom.py +@@ -6,12 +6,14 @@ from StringIO import StringIO + from test import support + import unittest + ++import pyexpat + import xml.dom + import xml.dom.minidom + import xml.parsers.expat + + from xml.dom.minidom import parse, Node, Document, parseString + from xml.dom.minidom import getDOMImplementation ++from xml.parsers.expat import ExpatError + + + tstfile = support.findfile("test.xml", subdir="xmltestdata") +@@ -1051,7 +1053,13 @@ class MinidomTest(unittest.TestCase): + + # Verify that character decoding errors raise exceptions instead + # of crashing +- self.assertRaises(UnicodeDecodeError, parseString, ++ if pyexpat.version_info >= (2, 4, 5): ++ self.assertRaises(ExpatError, parseString, ++ b'<fran\xe7ais></fran\xe7ais>') ++ self.assertRaises(ExpatError, parseString, ++ b'<franais>Comment \xe7a va ? Tr\xe8s bien ?</franais>') ++ else: ++ self.assertRaises(UnicodeDecodeError, parseString, + '<fran\xe7ais>Comment \xe7a va ? Tr\xe8s bien ?</fran\xe7ais>') + + doc.unlink() +diff --git a/Lib/test/test_xml_etree.py b/Lib/test/test_xml_etree.py +index c75d55f05c..0855bc07ca 100644 +--- a/Lib/test/test_xml_etree.py ++++ b/Lib/test/test_xml_etree.py +@@ -1482,12 +1482,6 @@ class BugsTest(unittest.TestCase): + b"<?xml version='1.0' encoding='ascii'?>\n" + b'<body>tãg</body>') + +- def test_issue3151(self): +- e = ET.XML('<prefix:localname xmlns:prefix="${stuff}"/>') +- self.assertEqual(e.tag, '{${stuff}}localname') +- t = ET.ElementTree(e) +- self.assertEqual(ET.tostring(e), b'<ns0:localname xmlns:ns0="${stuff}" />') +- + def test_issue6565(self): + elem = ET.XML("<body><tag/></body>") + self.assertEqual(summarize_list(elem), ['tag']) diff --git a/gnu/packages/patches/python-3-fix-tests.patch b/gnu/packages/patches/python-3-fix-tests.patch index b44e743c71..d31af35630 100644 --- a/gnu/packages/patches/python-3-fix-tests.patch +++ b/gnu/packages/patches/python-3-fix-tests.patch @@ -6,34 +6,12 @@ Subject: [PATCH] Skip problematic Python 3 tests in Guix. A subset of the hunks in this patch is tracked upstream at https://bugs.python.org/issue38845, which was contributed by Tanguy Le Carrour <tanguy@bioneland.org>. ---- - Lib/ctypes/test/test_callbacks.py | 3 +++ - Lib/ctypes/test/test_find.py | 1 + - Lib/ctypes/test/test_libc.py | 3 +++ - Lib/distutils/tests/test_archive_util.py | 2 ++ - Lib/distutils/tests/test_sdist.py | 1 + - Lib/test/_test_multiprocessing.py | 2 ++ - Lib/test/test_asyncio/test_base_events.py | 2 ++ - Lib/test/test_generators.py | 1 + - Lib/test/test_pathlib.py | 3 +-- - Lib/test/test_pdb.py | 4 ++-- - Lib/test/test_regrtest.py | 2 ++ - Lib/test/test_resource.py | 1 + - Lib/test/test_shutil.py | 2 ++ - Lib/test/test_signal.py | 4 ++++ - Lib/test/test_socket.py | 8 ++++++++ - Lib/test/test_spwd.py | 6 ++---- - Lib/test/test_tarfile.py | 9 ++++++--- - Lib/test/test_threading.py | 3 +++ - Lib/test/test_unicodedata.py | 1 + - Tools/scripts/run_tests.py | 2 +- - 20 files changed, 48 insertions(+), 12 deletions(-) diff --git a/Lib/ctypes/test/test_callbacks.py b/Lib/ctypes/test/test_callbacks.py index d8e9c5a760..94fc5929c9 100644 --- a/Lib/ctypes/test/test_callbacks.py +++ b/Lib/ctypes/test/test_callbacks.py -@@ -5,6 +5,7 @@ from test import support +@@ -5,6 +5,7 @@ from ctypes import * from ctypes.test import need_symbol import _ctypes_test @@ -41,7 +19,7 @@ index d8e9c5a760..94fc5929c9 100644 class Callbacks(unittest.TestCase): functype = CFUNCTYPE -@@ -178,6 +179,8 @@ class SampleCallbacksTestCase(unittest.TestCase): +@@ -178,6 +179,8 @@ def func(x): self.assertLess(diff, 0.01, "%s not less than 0.01" % diff) @@ -51,10 +29,10 @@ index d8e9c5a760..94fc5929c9 100644 from ctypes.util import find_library libc_path = find_library("c") diff --git a/Lib/ctypes/test/test_find.py b/Lib/ctypes/test/test_find.py -index 92ac1840ad..c8eb75dedd 100644 +index 1ff9d019b1..5194954914 100644 --- a/Lib/ctypes/test/test_find.py +++ b/Lib/ctypes/test/test_find.py -@@ -116,6 +116,7 @@ class FindLibraryLinux(unittest.TestCase): +@@ -117,6 +117,7 @@ def test_find_library_with_gcc(self): with unittest.mock.patch("ctypes.util._findSoname_ldconfig", lambda *args: None): self.assertNotEqual(find_library('c'), None) @@ -66,7 +44,7 @@ diff --git a/Lib/ctypes/test/test_libc.py b/Lib/ctypes/test/test_libc.py index 56285b5ff8..c088ab3db8 100644 --- a/Lib/ctypes/test/test_libc.py +++ b/Lib/ctypes/test/test_libc.py -@@ -2,6 +2,7 @@ import unittest +@@ -2,6 +2,7 @@ from ctypes import * import _ctypes_test @@ -74,7 +52,7 @@ index 56285b5ff8..c088ab3db8 100644 lib = CDLL(_ctypes_test.__file__) -@@ -17,6 +18,8 @@ class LibTest(unittest.TestCase): +@@ -17,6 +18,8 @@ def test_sqrt(self): import math self.assertEqual(lib.my_sqrt(2.0), math.sqrt(2.0)) @@ -84,10 +62,10 @@ index 56285b5ff8..c088ab3db8 100644 comparefunc = CFUNCTYPE(c_int, POINTER(c_char), POINTER(c_char)) lib.my_qsort.argtypes = c_void_p, c_size_t, c_size_t, comparefunc diff --git a/Lib/distutils/tests/test_archive_util.py b/Lib/distutils/tests/test_archive_util.py -index e9aad0e40f..8bbaa51ee5 100644 +index edcec2513e..a716150763 100644 --- a/Lib/distutils/tests/test_archive_util.py +++ b/Lib/distutils/tests/test_archive_util.py -@@ -333,6 +333,7 @@ class ArchiveUtilTestCase(support.TempdirManager, +@@ -335,6 +335,7 @@ def test_make_archive_xztar(self): self.assertEqual(os.path.basename(res), 'archive.tar.xz') self.assertEqual(self._tarinfo(res), self._created_files) @@ -95,7 +73,7 @@ index e9aad0e40f..8bbaa51ee5 100644 def test_make_archive_owner_group(self): # testing make_archive with owner and group, with various combinations # this works even if there's not gid/uid support -@@ -362,6 +363,7 @@ class ArchiveUtilTestCase(support.TempdirManager, +@@ -364,6 +365,7 @@ def test_make_archive_owner_group(self): @unittest.skipUnless(ZLIB_SUPPORT, "Requires zlib") @unittest.skipUnless(UID_GID_SUPPORT, "Requires grp and pwd support") @@ -104,10 +82,10 @@ index e9aad0e40f..8bbaa51ee5 100644 tmpdir = self._create_files() base_name = os.path.join(self.mkdtemp(), 'archive') diff --git a/Lib/distutils/tests/test_sdist.py b/Lib/distutils/tests/test_sdist.py -index 23db126959..6e2329df7d 100644 +index 752e9db5ba..c66b6323e4 100644 --- a/Lib/distutils/tests/test_sdist.py +++ b/Lib/distutils/tests/test_sdist.py -@@ -443,6 +443,7 @@ class SDistTestCase(BasePyPIRCCommandTestCase): +@@ -444,6 +444,7 @@ def test_manual_manifest(self): "The tar command is not found") @unittest.skipIf(find_executable('gzip') is None, "The gzip command is not found") @@ -116,10 +94,10 @@ index 23db126959..6e2329df7d 100644 # now building a sdist dist, cmd = self.get_cmd() diff --git a/Lib/test/_test_multiprocessing.py b/Lib/test/_test_multiprocessing.py -index e47905c863..31a5a9c308 100644 +index 8dced90c53..59947e3023 100644 --- a/Lib/test/_test_multiprocessing.py +++ b/Lib/test/_test_multiprocessing.py -@@ -1577,6 +1577,7 @@ class _TestCondition(BaseTestCase): +@@ -1589,6 +1589,7 @@ def _test_wait_result(cls, c, pid): if pid is not None: os.kill(pid, signal.SIGINT) @@ -127,7 +105,7 @@ index e47905c863..31a5a9c308 100644 def test_wait_result(self): if isinstance(self, ProcessesMixin) and sys.platform != 'win32': pid = os.getpid() -@@ -3905,6 +3906,7 @@ class _TestSharedMemory(BaseTestCase): +@@ -4008,6 +4009,7 @@ def test_shared_memory_across_processes(self): sms.close() @unittest.skipIf(os.name != "posix", "not feasible in non-posix platforms") @@ -136,10 +114,10 @@ index e47905c863..31a5a9c308 100644 # bpo-36368: protect SharedMemoryManager server process from # KeyboardInterrupt signals. diff --git a/Lib/test/test_asyncio/test_base_events.py b/Lib/test/test_asyncio/test_base_events.py -index 533d5cc7f5..c4f860cc3b 100644 +index d77bf95a7b..79912c8230 100644 --- a/Lib/test/test_asyncio/test_base_events.py +++ b/Lib/test/test_asyncio/test_base_events.py -@@ -1341,6 +1341,8 @@ class BaseEventLoopWithSelectorTests(test_utils.TestCase): +@@ -1359,6 +1359,8 @@ def test_create_connection_no_inet_pton(self, m_socket): self._test_create_connection_ip_addr(m_socket, False) @patch_socket @@ -149,10 +127,10 @@ index 533d5cc7f5..c4f860cc3b 100644 m_socket.getaddrinfo = socket.getaddrinfo sock = m_socket.socket.return_value diff --git a/Lib/test/test_generators.py b/Lib/test/test_generators.py -index 3bf1522808..04bac8a7db 100644 +index 3bf5f3b743..23368c8d8b 100644 --- a/Lib/test/test_generators.py +++ b/Lib/test/test_generators.py -@@ -33,6 +33,7 @@ class SignalAndYieldFromTest(unittest.TestCase): +@@ -33,6 +33,7 @@ def generator2(self): else: return "FAILED" @@ -161,42 +139,40 @@ index 3bf1522808..04bac8a7db 100644 gen = self.generator1() gen.send(None) diff --git a/Lib/test/test_pathlib.py b/Lib/test/test_pathlib.py -index 3da35710b9..5404f9193d 100644 +index bf3fc5fb24..21015403f3 100644 --- a/Lib/test/test_pathlib.py +++ b/Lib/test/test_pathlib.py -@@ -2408,8 +2408,7 @@ class PosixPathTest(_BasePathTest, unittest.TestCase): - self.assertEqual(given, expect) - self.assertEqual(set(p.rglob("FILEd*")), set()) - -- @unittest.skipUnless(hasattr(pwd, 'getpwall'), -- 'pwd module does not expose getpwall()') +@@ -2546,6 +2546,7 @@ def test_rglob(self): + 'pwd module does not expose getpwall()') + @unittest.skipIf(sys.platform == "vxworks", + "no home directory on VxWorks") + @unittest.skipIf(True, "Guix builder home is '/' which causes trouble for these tests") def test_expanduser(self): P = self.cls - support.import_module('pwd') + import_helper.import_module('pwd') diff --git a/Lib/test/test_pdb.py b/Lib/test/test_pdb.py -index 8016f81e5a..10190486b4 100644 +index 6ac1a4a3c3..4f58cf9b40 100644 --- a/Lib/test/test_pdb.py +++ b/Lib/test/test_pdb.py -@@ -1219,11 +1219,11 @@ def test_pdb_issue_20766(): +@@ -1315,11 +1315,11 @@ def test_pdb_issue_20766(): > <doctest test.test_pdb.test_pdb_issue_20766[0]>(6)test_function() -> print('pdb %d: %s' % (i, sess._previous_sigint_handler)) (Pdb) continue - pdb 1: <built-in function default_int_handler> + pdb 1: Handlers.SIG_IGN - > <doctest test.test_pdb.test_pdb_issue_20766[0]>(5)test_function() - -> sess.set_trace(sys._getframe()) + > <doctest test.test_pdb.test_pdb_issue_20766[0]>(6)test_function() + -> print('pdb %d: %s' % (i, sess._previous_sigint_handler)) (Pdb) continue - pdb 2: <built-in function default_int_handler> + pdb 2: Handlers.SIG_IGN """ - + def test_pdb_issue_43318(): diff --git a/Lib/test/test_regrtest.py b/Lib/test/test_regrtest.py -index a77638b10a..2069b349a8 100644 +index 62e6c28280..7ffee56635 100644 --- a/Lib/test/test_regrtest.py +++ b/Lib/test/test_regrtest.py -@@ -811,6 +811,7 @@ class ArgsTestCase(BaseTestCase): +@@ -810,6 +810,7 @@ def test_fromfile(self): output = self.run_tests('--fromfile', filename) self.check_executed_tests(output, tests) @@ -204,7 +180,7 @@ index a77638b10a..2069b349a8 100644 def test_interrupted(self): code = TEST_INTERRUPTED test = self.create_test('sigint', code=code) -@@ -828,6 +829,7 @@ class ArgsTestCase(BaseTestCase): +@@ -827,6 +828,7 @@ def test_slowest(self): % (self.TESTNAME_REGEX, len(tests))) self.check_line(output, regex) @@ -213,10 +189,10 @@ index a77638b10a..2069b349a8 100644 # Issue #25373: test --slowest with an interrupted test code = TEST_INTERRUPTED diff --git a/Lib/test/test_resource.py b/Lib/test/test_resource.py -index e5ece5284c..5299e54507 100644 +index f2642c6ba1..4358a20dae 100644 --- a/Lib/test/test_resource.py +++ b/Lib/test/test_resource.py -@@ -148,6 +148,7 @@ class ResourceTest(unittest.TestCase): +@@ -150,6 +150,7 @@ def test_freebsd_contants(self): @unittest.skipUnless(hasattr(resource, 'prlimit'), 'no prlimit') @support.requires_linux_version(2, 6, 36) @@ -225,10 +201,10 @@ index e5ece5284c..5299e54507 100644 self.assertRaises(TypeError, resource.prlimit) self.assertRaises(ProcessLookupError, resource.prlimit, diff --git a/Lib/test/test_shutil.py b/Lib/test/test_shutil.py -index e19af64be0..1b893df6fa 100644 +index 62e9180375..3eda176fa3 100644 --- a/Lib/test/test_shutil.py +++ b/Lib/test/test_shutil.py -@@ -1427,6 +1427,7 @@ class TestArchives(BaseTest, unittest.TestCase): +@@ -1497,6 +1497,7 @@ def test_make_archive(self): base_name = os.path.join(tmpdir, 'archive') self.assertRaises(ValueError, make_archive, base_name, 'xxx') @@ -236,7 +212,7 @@ index e19af64be0..1b893df6fa 100644 @support.requires_zlib() def test_make_archive_owner_group(self): # testing make_archive with owner and group, with various combinations -@@ -1455,6 +1456,7 @@ class TestArchives(BaseTest, unittest.TestCase): +@@ -1525,6 +1526,7 @@ def test_make_archive_owner_group(self): self.assertTrue(os.path.isfile(res)) @@ -245,10 +221,10 @@ index e19af64be0..1b893df6fa 100644 @unittest.skipUnless(UID_GID_SUPPORT, "Requires grp and pwd support") def test_tarfile_root_owner(self): diff --git a/Lib/test/test_signal.py b/Lib/test/test_signal.py -index 45553a6a42..55623f01a3 100644 +index c2b5861fc3..3c7a9c42cb 100644 --- a/Lib/test/test_signal.py +++ b/Lib/test/test_signal.py -@@ -78,6 +78,7 @@ class PosixTests(unittest.TestCase): +@@ -89,6 +89,7 @@ def test_valid_signals(self): self.assertLess(len(s), signal.NSIG) @unittest.skipUnless(sys.executable, "sys.executable required.") @@ -256,7 +232,7 @@ index 45553a6a42..55623f01a3 100644 def test_keyboard_interrupt_exit_code(self): """KeyboardInterrupt triggers exit via SIGINT.""" process = subprocess.run( -@@ -128,6 +129,7 @@ class WindowsSignalTests(unittest.TestCase): +@@ -139,6 +140,7 @@ def test_issue9324(self): signal.signal(7, handler) @unittest.skipUnless(sys.executable, "sys.executable required.") @@ -264,7 +240,7 @@ index 45553a6a42..55623f01a3 100644 def test_keyboard_interrupt_exit_code(self): """KeyboardInterrupt triggers an exit using STATUS_CONTROL_C_EXIT.""" # We don't test via os.kill(os.getpid(), signal.CTRL_C_EVENT) here -@@ -1245,6 +1247,7 @@ class StressTest(unittest.TestCase): +@@ -1322,6 +1324,7 @@ def cycle_handlers(): class RaiseSignalTest(unittest.TestCase): @@ -272,7 +248,7 @@ index 45553a6a42..55623f01a3 100644 def test_sigint(self): with self.assertRaises(KeyboardInterrupt): signal.raise_signal(signal.SIGINT) -@@ -1275,6 +1278,7 @@ class RaiseSignalTest(unittest.TestCase): +@@ -1352,6 +1355,7 @@ def handler(a, b): class PidfdSignalTest(unittest.TestCase): @@ -281,10 +257,10 @@ index 45553a6a42..55623f01a3 100644 hasattr(signal, "pidfd_send_signal"), "pidfd support not built in", diff --git a/Lib/test/test_socket.py b/Lib/test/test_socket.py -index aefba4f397..6c89f558d5 100755 +index 9c5f6d3dc9..ef74fc5694 100644 --- a/Lib/test/test_socket.py +++ b/Lib/test/test_socket.py -@@ -1009,6 +1009,8 @@ class GeneralModuleTests(unittest.TestCase): +@@ -1006,6 +1006,8 @@ def testHostnameRes(self): if not fqhn in all_host_names: self.fail("Error testing host resolution mechanisms. (fqdn: %s, all: %s)" % (fqhn, repr(all_host_names))) @@ -293,16 +269,16 @@ index aefba4f397..6c89f558d5 100755 def test_host_resolution(self): for addr in [socket_helper.HOSTv4, '10.0.0.1', '255.255.255.255']: self.assertEqual(socket.gethostbyname(addr), addr) -@@ -1140,6 +1142,8 @@ class GeneralModuleTests(unittest.TestCase): - self.assertWarns(DeprecationWarning, socket.ntohs, k) - self.assertWarns(DeprecationWarning, socket.htons, k) +@@ -1136,6 +1138,8 @@ def testNtoHErrors(self): + self.assertRaises(OverflowError, socket.ntohl, k) + self.assertRaises(OverflowError, socket.htonl, k) + @unittest.skipUnless(os.path.exists("/etc/services"), + "getservbyname uses /etc/services, which is not in the chroot") def testGetServBy(self): eq = self.assertEqual # Find one service that exists, then check all the related interfaces. -@@ -1489,6 +1493,8 @@ class GeneralModuleTests(unittest.TestCase): +@@ -1485,6 +1489,8 @@ def test_sio_loopback_fast_path(self): raise self.assertRaises(TypeError, s.ioctl, socket.SIO_LOOPBACK_FAST_PATH, None) @@ -311,7 +287,7 @@ index aefba4f397..6c89f558d5 100755 def testGetaddrinfo(self): try: socket.getaddrinfo('localhost', 80) -@@ -1571,6 +1577,8 @@ class GeneralModuleTests(unittest.TestCase): +@@ -1567,6 +1573,8 @@ def test_getnameinfo(self): # only IP addresses are allowed self.assertRaises(OSError, socket.getnameinfo, ('mail.python.org',0), 0) @@ -321,11 +297,11 @@ index aefba4f397..6c89f558d5 100755 'network is not enabled') def test_idna(self): diff --git a/Lib/test/test_spwd.py b/Lib/test/test_spwd.py -index 07793c84c8..fec672bcbe 100644 +index a143acc659..f7207887c0 100644 --- a/Lib/test/test_spwd.py +++ b/Lib/test/test_spwd.py -@@ -5,8 +5,7 @@ from test import support - spwd = support.import_module('spwd') +@@ -6,8 +6,7 @@ + spwd = import_helper.import_module('spwd') -@unittest.skipUnless(hasattr(os, 'geteuid') and os.geteuid() == 0, @@ -334,7 +310,7 @@ index 07793c84c8..fec672bcbe 100644 class TestSpwdRoot(unittest.TestCase): def test_getspall(self): -@@ -56,8 +55,7 @@ class TestSpwdRoot(unittest.TestCase): +@@ -57,8 +56,7 @@ def test_getspnam(self): self.assertRaises(TypeError, spwd.getspnam, bytes_name) @@ -345,10 +321,10 @@ index 07793c84c8..fec672bcbe 100644 def test_getspnam_exception(self): diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py -index 29cde91bf7..8d0f20e8bf 100644 +index c658cca7a7..b7188e411e 100644 --- a/Lib/test/test_tarfile.py +++ b/Lib/test/test_tarfile.py -@@ -2607,9 +2607,12 @@ def root_is_uid_gid_0(): +@@ -2737,9 +2737,12 @@ def root_is_uid_gid_0(): import pwd, grp except ImportError: return False @@ -365,18 +341,18 @@ index 29cde91bf7..8d0f20e8bf 100644 return True diff --git a/Lib/test/test_threading.py b/Lib/test/test_threading.py -index c21cdf8eb7..6c9d575032 100644 +index c54806e594..d9bbca4e6a 100644 --- a/Lib/test/test_threading.py +++ b/Lib/test/test_threading.py -@@ -1398,6 +1398,7 @@ class MiscTestCase(unittest.TestCase): - +@@ -1620,6 +1620,7 @@ def check_interrupt_main_noerror(self, signum): + # Restore original handler + signal.signal(signum, handler) - class InterruptMainTests(unittest.TestCase): + @unittest.skipIf(True, 'Keyboard interrupts do not work in the Guix build container.') def test_interrupt_main_subthread(self): # Calling start_new_thread with a function that executes interrupt_main # should raise KeyboardInterrupt upon completion. -@@ -1409,6 +1410,8 @@ class InterruptMainTests(unittest.TestCase): +@@ -1631,6 +1632,8 @@ def call_interrupt(): t.join() t.join() @@ -386,10 +362,10 @@ index c21cdf8eb7..6c9d575032 100644 # Make sure that if interrupt_main is called in main thread that # KeyboardInterrupt is raised instantly. diff --git a/Lib/test/test_unicodedata.py b/Lib/test/test_unicodedata.py -index b552d2bd17..28b1144e15 100644 +index 213b3cf252..a5edd4a119 100644 --- a/Lib/test/test_unicodedata.py +++ b/Lib/test/test_unicodedata.py -@@ -309,6 +309,7 @@ class UnicodeMiscTest(UnicodeDatabaseTest): +@@ -315,6 +315,7 @@ def test_linebreak_7643(self): self.assertEqual(len(lines), 1, r"\u%.4x should not be a linebreak" % i) @@ -398,10 +374,10 @@ index b552d2bd17..28b1144e15 100644 @staticmethod def check_version(testfile): diff --git a/Tools/scripts/run_tests.py b/Tools/scripts/run_tests.py -index bcfa5e943b..1f2484971b 100644 +index 48feb3f778..e82cafc88a 100644 --- a/Tools/scripts/run_tests.py +++ b/Tools/scripts/run_tests.py -@@ -41,7 +41,7 @@ def main(regrtest_args): +@@ -40,7 +40,7 @@ def main(regrtest_args): if not any(is_multiprocess_flag(arg) for arg in regrtest_args): args.extend(['-j', '0']) # Use all CPU cores if not any(is_resource_use_flag(arg) for arg in regrtest_args): @@ -410,6 +386,3 @@ index bcfa5e943b..1f2484971b 100644 args.extend(regrtest_args) print(' '.join(args)) if sys.platform == 'win32': --- -2.29.2 - diff --git a/gnu/packages/patches/python-3-no-static-lib.patch b/gnu/packages/patches/python-3-no-static-lib.patch deleted file mode 100644 index b44dbc976c..0000000000 --- a/gnu/packages/patches/python-3-no-static-lib.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: David Malcolm <dmalcolm@redhat.com> -Date: Mon, 18 Jan 2010 17:59:07 +0000 -Subject: [PATCH] 00111: Don't try to build a libpythonMAJOR.MINOR.a -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Downstream only: not appropriate for upstream. - -See https://bugzilla.redhat.com/show_bug.cgi?id=556092 - -Co-authored-by: David Malcolm <dmalcolm@redhat.com> -Co-authored-by: Bohuslav Kabrda <bkabrda@redhat.com> -Co-authored-by: Matej Stuchlik <mstuchli@redhat.com> -Co-authored-by: Robert Kuska <rkuska@redhat.com> -Co-authored-by: Charalampos Stratakis <cstratak@redhat.com> -Co-authored-by: Miro Hrončok <miro@hroncok.cz> ---- - Makefile.pre.in | 21 ++------------------- - 1 file changed, 2 insertions(+), 19 deletions(-) - -diff --git a/Makefile.pre.in b/Makefile.pre.in -index 0c3981c132..5587422ec7 100644 ---- a/Makefile.pre.in -+++ b/Makefile.pre.in -@@ -589,7 +589,7 @@ clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c - $(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py --make --srcdir $(srcdir) - - # Build the interpreter --$(BUILDPYTHON): Programs/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY) $(EXPORTSYMS) -+$(BUILDPYTHON): Programs/python.o $(LDLIBRARY) $(PY3LIBRARY) $(EXPORTSYMS) - $(LINKCC) $(PY_CORE_LDFLAGS) $(LINKFORSHARED) -o $@ Programs/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) - - platform: $(BUILDPYTHON) pybuilddir.txt -@@ -637,12 +637,6 @@ sharedmods: $(BUILDPYTHON) pybuilddir.txt Modules/_math.o - _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \ - $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build - -- --# Build static library --$(LIBRARY): $(LIBRARY_OBJS) -- -rm -f $@ -- $(AR) $(ARFLAGS) $@ $(LIBRARY_OBJS) -- - libpython$(LDVERSION).so: $(LIBRARY_OBJS) $(DTRACE_OBJS) - if test $(INSTSONAME) != $(LDLIBRARY); then \ - $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM); \ -@@ -724,7 +718,7 @@ Makefile Modules/config.c: Makefile.pre \ - @echo "The Makefile was updated, you may need to re-run make." - - --Programs/_testembed: Programs/_testembed.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY) $(EXPORTSYMS) -+Programs/_testembed: Programs/_testembed.o $(LDLIBRARY) $(PY3LIBRARY) $(EXPORTSYMS) - $(LINKCC) $(PY_CORE_LDFLAGS) $(LINKFORSHARED) -o $@ Programs/_testembed.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) - - ############################################################################ -@@ -1652,17 +1646,6 @@ libainstall: @DEF_MAKE_RULE@ python-config - else true; \ - fi; \ - done -- @if test -d $(LIBRARY); then :; else \ -- if test "$(PYTHONFRAMEWORKDIR)" = no-framework; then \ -- if test "$(SHLIB_SUFFIX)" = .dll; then \ -- $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \ -- else \ -- $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \ -- fi; \ -- else \ -- echo Skip install of $(LIBRARY) - use make frameworkinstall; \ -- fi; \ -- fi - $(INSTALL_DATA) Modules/config.c $(DESTDIR)$(LIBPL)/config.c - $(INSTALL_DATA) Programs/python.o $(DESTDIR)$(LIBPL)/python.o - $(INSTALL_DATA) $(srcdir)/Modules/config.c.in $(DESTDIR)$(LIBPL)/config.c.in diff --git a/gnu/packages/patches/python-execnet-read-only-fix.patch b/gnu/packages/patches/python-execnet-read-only-fix.patch deleted file mode 100644 index 58a4b129a7..0000000000 --- a/gnu/packages/patches/python-execnet-read-only-fix.patch +++ /dev/null @@ -1,77 +0,0 @@ -From 0d6562a20b0610c5a83d1c66ac879223b84a2746 Mon Sep 17 00:00:00 2001 -From: Maxim Cournoyer <maxim.cournoyer@gmail.com> -Date: Thu, 26 Aug 2021 00:43:26 -0400 -Subject: [PATCH] rsync_remote: Fix a problem when receiving read-only - directories. - -Before this change, when the source directories hierarchy was -read-only, the read-only mode would be preserved at the destination, -preventing child directories to be recreated by a normal user (a -permission denied error, EACCES would be raised). - -* execnet/rsync_remote.py (serve_rsync.receive_directory_structure): -Bitwise OR to ensure the write bit is set on received directories. -* testing/test_rsync.py (TestRSync) -<test_read_only_directories>: New test. ---- - execnet/rsync_remote.py | 8 ++++++-- - testing/test_rsync.py | 17 +++++++++++++++++ - 2 files changed, 23 insertions(+), 2 deletions(-) - -diff --git a/execnet/rsync_remote.py b/execnet/rsync_remote.py -index cd5e765..55d154c 100644 ---- a/execnet/rsync_remote.py -+++ b/execnet/rsync_remote.py -@@ -35,7 +35,11 @@ def serve_rsync(channel): - os.makedirs(path) - mode = msg.pop(0) - if mode: -- os.chmod(path, mode) -+ # Ensure directories are writable, otherwise a -+ # permission denied error (EACCES) would be raised -+ # when attempting to receive read-only directory -+ # structures. -+ os.chmod(path, mode | 0o700) - entrynames = {} - for entryname in msg: - destpath = os.path.join(path, entryname) -@@ -59,7 +63,7 @@ def serve_rsync(channel): - checksum = md5(f.read()).digest() - f.close() - elif msg_mode and msg_mode != st.st_mode: -- os.chmod(path, msg_mode) -+ os.chmod(path, msg_mode | 0o700) - return - else: - return # already fine -diff --git a/testing/test_rsync.py b/testing/test_rsync.py -index 995f229..1d6c30c 100644 ---- a/testing/test_rsync.py -+++ b/testing/test_rsync.py -@@ -157,6 +157,23 @@ class TestRSync: - mode = destdir.stat().mode - assert mode & 511 == 504 - -+ @py.test.mark.skipif("sys.platform == 'win32' or getattr(os, '_name', '') == 'nt'") -+ def test_read_only_directories(self, dirs, gw1): -+ source = dirs.source -+ dest = dirs.dest1 -+ source.ensure("sub", "subsub", dir=True) -+ source.join("sub").chmod(0o500) -+ source.join("sub", "subsub").chmod(0o500) -+ -+ # The destination directories should be created with the write -+ # permission forced, to avoid raising an EACCES error. -+ rsync = RSync(source) -+ rsync.add_target(gw1, dest) -+ rsync.send() -+ -+ assert dest.join("sub").stat().mode & 0o700 -+ assert dest.join("sub").join("subsub").stat().mode & 0o700 -+ - @needssymlink - def test_symlink_rsync(self, dirs, gw1): - source = dirs.source --- -2.32.0 - diff --git a/gnu/packages/patches/python-feedparser-missing-import.patch b/gnu/packages/patches/python-feedparser-missing-import.patch new file mode 100644 index 0000000000..6ed504c1d2 --- /dev/null +++ b/gnu/packages/patches/python-feedparser-missing-import.patch @@ -0,0 +1,34 @@ +Since feedparser messes with Python’s internals by assigning +to __code__ it needs to import SGMLParseError too. It also +expects SGMLParseError, which was turned into AssertionError by +https://github.com/python/cpython/commit/e34bbfd61f405eef89e8aa50672b0b25022de320 + +--- feedparser-6.0.10/feedparser/sgml.py.orig 2023-03-18 09:24:50.976316932 +0100 ++++ feedparser-6.0.10/feedparser/sgml.py 2023-03-18 09:26:32.971928811 +0100 +@@ -28,6 +28,7 @@ + import re + + import sgmllib ++from sgmllib import SGMLParseError + + __all__ = [ + 'sgmllib', +@@ -41,6 +42,7 @@ + 'shorttagopen', + 'starttagopen', + 'endbracket', ++ 'SGMLParseError', + ] + + # sgmllib defines a number of module-level regular expressions that are +--- feedparser-6.0.10/feedparser/html.py.orig 2023-03-18 09:32:03.647114745 +0100 ++++ feedparser-6.0.10/feedparser/html.py 2023-03-18 09:46:05.021142671 +0100 +@@ -349,7 +349,7 @@ + + try: + return sgmllib.SGMLParser.parse_declaration(self, i) +- except sgmllib.SGMLParseError: ++ except AssertionError: + # Escape the doctype declaration and continue parsing. + self.handle_data('<') + return i+1 diff --git a/gnu/packages/patches/python-parso-unit-tests-in-3.10.patch b/gnu/packages/patches/python-parso-unit-tests-in-3.10.patch new file mode 100644 index 0000000000..1fc7fb701b --- /dev/null +++ b/gnu/packages/patches/python-parso-unit-tests-in-3.10.patch @@ -0,0 +1,186 @@ +Patch from python-parso upstream. + +From cf5969d7a109798adbf9538d70e92138f077d700 Mon Sep 17 00:00:00 2001 +From: Jochen Sprickerhof <git@jochen.sprickerhof.de> +Date: Sun, 4 Dec 2022 13:29:25 +0100 +Subject: [PATCH 1/7] Fix unit tests in Python 3.10 (Closes: #192) + +--- + parso/python/errors.py | 51 ++++++++++++++++++++++++++++++-------- + test/test_python_errors.py | 23 +++++++++++++++++ + 2 files changed, 64 insertions(+), 10 deletions(-) + +diff --git a/parso/python/errors.py b/parso/python/errors.py +index 5da046a..09c5047 100644 +--- a/parso/python/errors.py ++++ b/parso/python/errors.py +@@ -1,5 +1,6 @@ + # -*- coding: utf-8 -*- + import codecs ++import sys + import warnings + import re + from contextlib import contextmanager +@@ -33,7 +34,10 @@ def _get_rhs_name(node, version): + return "literal" + else: + if second.children[1] == ":" or second.children[0] == "**": +- return "dict display" ++ if version < (3, 10): ++ return "dict display" ++ else: ++ return "dict literal" + else: + return "set display" + elif ( +@@ -47,7 +51,10 @@ def _get_rhs_name(node, version): + elif first == "[": + return "list" + elif first == "{" and second == "}": +- return "dict display" ++ if version < (3, 10): ++ return "dict display" ++ else: ++ return "dict literal" + elif first == "{" and len(node.children) > 2: + return "set display" + elif type_ == "keyword": +@@ -58,7 +65,10 @@ def _get_rhs_name(node, version): + else: + return str(node.value) + elif type_ == "operator" and node.value == "...": +- return "Ellipsis" ++ if version < (3, 10): ++ return "Ellipsis" ++ else: ++ return "ellipsis" + elif type_ == "comparison": + return "comparison" + elif type_ in ("string", "number", "strings"): +@@ -83,7 +93,10 @@ def _get_rhs_name(node, version): + or "_test" in type_ + or type_ in ("term", "factor") + ): +- return "operator" ++ if version < (3, 10): ++ return "operator" ++ else: ++ return "expression" + elif type_ == "star_expr": + return "starred" + elif type_ == "testlist_star_expr": +@@ -610,7 +623,10 @@ class _NameChecks(SyntaxRule): + + @ErrorFinder.register_rule(type='string') + class _StringChecks(SyntaxRule): +- message = "bytes can only contain ASCII literal characters." ++ if sys.version_info < (3, 10): ++ message = "bytes can only contain ASCII literal characters." ++ else: ++ message = "bytes can only contain ASCII literal characters" + + def is_issue(self, leaf): + string_prefix = leaf.string_prefix.lower() +@@ -1043,14 +1059,20 @@ class _CheckAssignmentRule(SyntaxRule): + error = 'literal' + else: + if second.children[1] == ':': +- error = 'dict display' ++ if self._normalizer.version < (3, 10): ++ error = 'dict display' ++ else: ++ error = 'dict literal' + else: + error = 'set display' + elif first == "{" and second == "}": + if self._normalizer.version < (3, 8): + error = 'literal' + else: +- error = "dict display" ++ if self._normalizer.version < (3, 10): ++ error = "dict display" ++ else: ++ error = "dict literal" + elif first == "{" and len(node.children) > 2: + if self._normalizer.version < (3, 8): + error = 'literal' +@@ -1083,7 +1105,10 @@ class _CheckAssignmentRule(SyntaxRule): + error = str(node.value) + elif type_ == 'operator': + if node.value == '...': +- error = 'Ellipsis' ++ if self._normalizer.version < (3, 10): ++ error = 'Ellipsis' ++ else: ++ error = 'ellipsis' + elif type_ == 'comparison': + error = 'comparison' + elif type_ in ('string', 'number', 'strings'): +@@ -1098,7 +1123,10 @@ class _CheckAssignmentRule(SyntaxRule): + if node.children[0] == 'await': + error = 'await expression' + elif node.children[-2] == '**': +- error = 'operator' ++ if self._normalizer.version < (3, 10): ++ error = 'operator' ++ else: ++ error = 'expression' + else: + # Has a trailer + trailer = node.children[-1] +@@ -1120,7 +1148,10 @@ class _CheckAssignmentRule(SyntaxRule): + elif ('expr' in type_ and type_ != 'star_expr' # is a substring + or '_test' in type_ + or type_ in ('term', 'factor')): +- error = 'operator' ++ if self._normalizer.version < (3, 10): ++ error = 'operator' ++ else: ++ error = 'expression' + elif type_ == "star_expr": + if is_deletion: + if self._normalizer.version >= (3, 9): +diff --git a/test/test_python_errors.py b/test/test_python_errors.py +index adf5f06..9686d14 100644 +--- a/test/test_python_errors.py ++++ b/test/test_python_errors.py +@@ -1,6 +1,7 @@ + """ + Testing if parso finds syntax errors and indentation errors. + """ ++import re + import sys + import warnings + +@@ -136,6 +137,28 @@ def _get_actual_exception(code): + wanted = 'SyntaxError: invalid syntax' + elif wanted == "SyntaxError: f-string: single '}' is not allowed": + wanted = 'SyntaxError: invalid syntax' ++ elif "Maybe you meant '==' instead of '='?" in wanted: ++ wanted = wanted.removesuffix(" here. Maybe you meant '==' instead of '='?") ++ elif re.match( ++ r"SyntaxError: unterminated string literal \(detected at line \d+\)", wanted ++ ): ++ wanted = "SyntaxError: EOL while scanning string literal" ++ elif re.match( ++ r"SyntaxError: unterminated triple-quoted string literal \(detected at line \d+\)", ++ wanted, ++ ): ++ wanted = 'SyntaxError: EOF while scanning triple-quoted string literal' ++ elif wanted == 'SyntaxError: cannot use starred expression here': ++ wanted = "SyntaxError: can't use starred expression here" ++ elif wanted == 'SyntaxError: f-string: cannot use starred expression here': ++ wanted = "SyntaxError: f-string: can't use starred expression here" ++ elif re.match( ++ r"IndentationError: expected an indented block after '[^']*' statement on line \d", ++ wanted, ++ ): ++ wanted = 'IndentationError: expected an indented block' ++ elif wanted == 'SyntaxError: unterminated string literal': ++ wanted = 'SyntaxError: EOL while scanning string literal' + return [wanted], line_nr + + +-- +2.39.1 + diff --git a/gnu/packages/patches/python-sgmllib3k-assertions.patch b/gnu/packages/patches/python-sgmllib3k-assertions.patch new file mode 100644 index 0000000000..872f1c62c9 --- /dev/null +++ b/gnu/packages/patches/python-sgmllib3k-assertions.patch @@ -0,0 +1,221 @@ +Restores compatibility with Python >=3.9, +which removed the custom .error() method in +https://github.com/python/cpython/commit/e34bbfd61f405eef89e8aa50672b0b25022de320 + +Despite the big diff, only a try…except clause is added. + +--- source/sgmllib.py 2023-03-18 08:57:58.726240606 +0100 ++++ source/sgmllib.py 2023-03-18 09:02:01.667568916 +0100 +@@ -101,113 +101,116 @@ + """Handle the remaining data.""" + self.goahead(1) + +- def error(self, message): +- raise SGMLParseError(message) +- + # Internal -- handle data as far as reasonable. May leave state + # and data to be processed by a subsequent call. If 'end' is + # true, force handling all data as if followed by EOF marker. + def goahead(self, end): +- rawdata = self.rawdata +- i = 0 +- n = len(rawdata) +- while i < n: +- if self.nomoretags: +- self.handle_data(rawdata[i:n]) +- i = n +- break +- match = interesting.search(rawdata, i) +- if match: j = match.start() +- else: j = n +- if i < j: +- self.handle_data(rawdata[i:j]) +- i = j +- if i == n: break +- if rawdata[i] == '<': +- if starttagopen.match(rawdata, i): ++ try: ++ rawdata = self.rawdata ++ i = 0 ++ n = len(rawdata) ++ while i < n: ++ if self.nomoretags: ++ self.handle_data(rawdata[i:n]) ++ i = n ++ break ++ match = interesting.search(rawdata, i) ++ if match: j = match.start() ++ else: j = n ++ if i < j: ++ self.handle_data(rawdata[i:j]) ++ i = j ++ if i == n: break ++ if rawdata[i] == '<': ++ if starttagopen.match(rawdata, i): ++ if self.literal: ++ self.handle_data(rawdata[i]) ++ i = i+1 ++ continue ++ k = self.parse_starttag(i) ++ if k < 0: break ++ i = k ++ continue ++ if rawdata.startswith("</", i): ++ k = self.parse_endtag(i) ++ if k < 0: break ++ i = k ++ self.literal = 0 ++ continue ++ if self.literal: ++ if n > (i + 1): ++ self.handle_data("<") ++ i = i+1 ++ else: ++ # incomplete ++ break ++ continue ++ if rawdata.startswith("<!--", i): ++ # Strictly speaking, a comment is --.*-- ++ # within a declaration tag <!...>. ++ # This should be removed, ++ # and comments handled only in parse_declaration. ++ k = self.parse_comment(i) ++ if k < 0: break ++ i = k ++ continue ++ if rawdata.startswith("<?", i): ++ k = self.parse_pi(i) ++ if k < 0: break ++ i = i+k ++ continue ++ if rawdata.startswith("<!", i): ++ # This is some sort of declaration; in "HTML as ++ # deployed," this should only be the document type ++ # declaration ("<!DOCTYPE html...>"). ++ k = self.parse_declaration(i) ++ if k < 0: break ++ i = k ++ continue ++ elif rawdata[i] == '&': + if self.literal: + self.handle_data(rawdata[i]) + i = i+1 + continue +- k = self.parse_starttag(i) +- if k < 0: break +- i = k +- continue +- if rawdata.startswith("</", i): +- k = self.parse_endtag(i) +- if k < 0: break +- i = k +- self.literal = 0 +- continue +- if self.literal: +- if n > (i + 1): +- self.handle_data("<") +- i = i+1 +- else: +- # incomplete +- break +- continue +- if rawdata.startswith("<!--", i): +- # Strictly speaking, a comment is --.*-- +- # within a declaration tag <!...>. +- # This should be removed, +- # and comments handled only in parse_declaration. +- k = self.parse_comment(i) +- if k < 0: break +- i = k +- continue +- if rawdata.startswith("<?", i): +- k = self.parse_pi(i) +- if k < 0: break +- i = i+k +- continue +- if rawdata.startswith("<!", i): +- # This is some sort of declaration; in "HTML as +- # deployed," this should only be the document type +- # declaration ("<!DOCTYPE html...>"). +- k = self.parse_declaration(i) +- if k < 0: break +- i = k +- continue +- elif rawdata[i] == '&': +- if self.literal: ++ match = charref.match(rawdata, i) ++ if match: ++ name = match.group(1) ++ self.handle_charref(name) ++ i = match.end(0) ++ if rawdata[i-1] != ';': i = i-1 ++ continue ++ match = entityref.match(rawdata, i) ++ if match: ++ name = match.group(1) ++ self.handle_entityref(name) ++ i = match.end(0) ++ if rawdata[i-1] != ';': i = i-1 ++ continue ++ else: ++ self.error('neither < nor & ??') ++ # We get here only if incomplete matches but ++ # nothing else ++ match = incomplete.match(rawdata, i) ++ if not match: + self.handle_data(rawdata[i]) + i = i+1 + continue +- match = charref.match(rawdata, i) +- if match: +- name = match.group(1) +- self.handle_charref(name) +- i = match.end(0) +- if rawdata[i-1] != ';': i = i-1 +- continue +- match = entityref.match(rawdata, i) +- if match: +- name = match.group(1) +- self.handle_entityref(name) +- i = match.end(0) +- if rawdata[i-1] != ';': i = i-1 +- continue +- else: +- self.error('neither < nor & ??') +- # We get here only if incomplete matches but +- # nothing else +- match = incomplete.match(rawdata, i) +- if not match: +- self.handle_data(rawdata[i]) +- i = i+1 +- continue +- j = match.end(0) +- if j == n: +- break # Really incomplete +- self.handle_data(rawdata[i:j]) +- i = j +- # end while +- if end and i < n: +- self.handle_data(rawdata[i:n]) +- i = n +- self.rawdata = rawdata[i:] +- # XXX if end: check for empty stack ++ j = match.end(0) ++ if j == n: ++ break # Really incomplete ++ self.handle_data(rawdata[i:j]) ++ i = j ++ # end while ++ if end and i < n: ++ self.handle_data(rawdata[i:n]) ++ i = n ++ self.rawdata = rawdata[i:] ++ # XXX if end: check for empty stack ++ except AssertionError as e: ++ # The .error() method, which threw the custom SGMLParseError was removed ++ # by https://github.com/python/cpython/issues/76025. So we have to catch ++ # _markupbase’s AssertionError and translate it into the old one. ++ raise SGMLParseError (e.args[0]) from e + + # Extensions for the DOCTYPE scanner: + _decl_otherchars = '=' diff --git a/gnu/packages/patches/python-shiboken-2-compat.patch b/gnu/packages/patches/python-shiboken-2-compat.patch new file mode 100644 index 0000000000..0c7de64395 --- /dev/null +++ b/gnu/packages/patches/python-shiboken-2-compat.patch @@ -0,0 +1,16 @@ +Provide a declaration that's missing in Python 3.10. + +--- pyside-setup-opensource-src-5.15.8/sources/shiboken2/libshiboken/sbkpython.h 2023-04-19 23:14:11.415337435 +0200 ++++ pyside-setup-opensource-src-5.15.8/sources/shiboken2/libshiboken/sbkpython.h 2023-04-19 23:18:09.055605606 +0200 +@@ -108,6 +108,11 @@ extern "C" { + #if PY_MAJOR_VERSION >= 3 + #define IS_PY3K + ++extern "C" { ++ /* In Python 3.10 this declaration is not provided by <Python.h>. */ ++ extern PyObject* _Py_Mangle(PyObject *p, PyObject *name); ++} ++ + #define PyInt_Type PyLong_Type + #define PyInt_Check PyLong_Check + #define PyInt_CheckExact PyLong_CheckExact diff --git a/gnu/packages/patches/python-sip-include-dirs.patch b/gnu/packages/patches/python-sip-include-dirs.patch new file mode 100644 index 0000000000..f2ef8fc1b2 --- /dev/null +++ b/gnu/packages/patches/python-sip-include-dirs.patch @@ -0,0 +1,20 @@ +Add an environment variable to python-sip that extends its search +directories for .sip files. + +It seems that we cannot easily change the destination folder of these +files though, so this variable must be set on a per-package basis (and +non through search-path). + +--- sip/sipbuild/builder.py 2023-03-22 09:06:37.588792878 +0100 ++++ sip/sipbuild/builder.py 2023-03-22 09:10:35.830181134 +0100 +@@ -254,6 +254,10 @@ + os.path.join(project.target_dir, + project.get_bindings_dir())) + ++ # Add extra bindings from environment for GNU Guix. ++ if 'SIP_INCLUDE_DIRS' in os.environ: ++ sip_include_dirs.extend(os.environ['SIP_INCLUDE_DIRS'].split(os.pathsep)) ++ + # Generate the sip.h file for the shared sip module. + copy_sip_h(abi_major_version, project.build_dir, + project.sip_module, version_info=project.version_info) diff --git a/gnu/packages/patches/python-typeguard-python3.10.patch b/gnu/packages/patches/python-typeguard-python3.10.patch new file mode 100644 index 0000000000..29321d8918 --- /dev/null +++ b/gnu/packages/patches/python-typeguard-python3.10.patch @@ -0,0 +1,47 @@ +Taken from Gentoo, which adapted +https://github.com/agronholm/typeguard/commit/e0db07a777d5a481eaba6162354adf32286ce21b + +diff --git a/src/typeguard/__init__.py b/src/typeguard/__init__.py +index 5684d63..27fa30b 100644 +--- a/src/typeguard/__init__.py ++++ b/src/typeguard/__init__.py +@@ -61,22 +61,25 @@ except ImportError: + from typing import _ForwardRef as ForwardRef + evaluate_forwardref = ForwardRef._eval_type + +-if sys.version_info >= (3, 10): +- from typing import is_typeddict +-else: +- _typed_dict_meta_types = () +- if sys.version_info >= (3, 8): +- from typing import _TypedDictMeta +- _typed_dict_meta_types += (_TypedDictMeta,) ++try: ++ from typing_extensions import is_typeddict ++except ImportError: ++ if sys.version_info >= (3, 10): ++ from typing import is_typeddict ++ else: ++ _typed_dict_meta_types = () ++ if sys.version_info >= (3, 8): ++ from typing import _TypedDictMeta ++ _typed_dict_meta_types += (_TypedDictMeta,) + +- try: +- from typing_extensions import _TypedDictMeta +- _typed_dict_meta_types += (_TypedDictMeta,) +- except ImportError: +- pass ++ try: ++ from typing_extensions import _TypedDictMeta ++ _typed_dict_meta_types += (_TypedDictMeta,) ++ except ImportError: ++ pass + +- def is_typeddict(tp) -> bool: +- return isinstance(tp, _typed_dict_meta_types) ++ def is_typeddict(tp) -> bool: ++ return isinstance(tp, _typed_dict_meta_types) + + + if TYPE_CHECKING: diff --git a/gnu/packages/patches/python-unittest2-python3-compat.patch b/gnu/packages/patches/python-unittest2-python3-compat.patch index fe0afe559a..68fbccacd0 100644 --- a/gnu/packages/patches/python-unittest2-python3-compat.patch +++ b/gnu/packages/patches/python-unittest2-python3-compat.patch @@ -32,3 +32,15 @@ index 683f662..347eea5 100644 def test_loadTestsFromNames__relative_malformed_name(self): loader = unittest.TestLoader() +diff --git a/unittest2/compatibility.py b/unittest2/compatibility.py +index 9e5f1a5..2d20c19 100644 +--- a/unittest2/compatibility.py ++++ b/unittest2/compatibility.py +@@ -140,6 +140,6 @@ except ImportError: + ### ChainMap (helper for configparser and string.Template) + ######################################################################## + +-class ChainMap(collections.MutableMapping): ++class ChainMap(collections.abc.MutableMapping): + ''' A ChainMap groups multiple dicts (or other mappings) together + to create a single, updateable view. diff --git a/gnu/packages/patches/softhsm-fix-openssl3-tests.patch b/gnu/packages/patches/softhsm-fix-openssl3-tests.patch new file mode 100644 index 0000000000..f2d9ce3f5d --- /dev/null +++ b/gnu/packages/patches/softhsm-fix-openssl3-tests.patch @@ -0,0 +1,1107 @@ +Copied from Debian: + +https://sources.debian.org/patches/softhsm2/2.6.1-2.1/0003-fix-ftbfs-with-opensslv3.patch/ + +From 643f061e6fbe04552a2c49bd00528e61a9a77064 Mon Sep 17 00:00:00 2001 +From: Alexander Bokovoy <abokovoy@redhat.com> +Date: Wed, 26 May 2021 20:03:25 +0300 +Subject: [PATCH 1/4] openssl 3.0: Run DES tests only if OpenSSL allows it + +OpenSSL 3.0 moves DES into a legacy provider which has to be loaded +explicitly. By default, it will not be loaded and DES methods in tests +will fail. Nest test blocks under successful initialization. + +Signed-off-by: Alexander Bokovoy <abokovoy@redhat.com> +--- + src/lib/crypto/test/DESTests.cpp | 350 ++++++++++++++++--------------- + 1 file changed, 182 insertions(+), 168 deletions(-) + +Index: softhsm2-2.6.1/src/lib/crypto/test/DESTests.cpp +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/crypto/test/DESTests.cpp ++++ softhsm2-2.6.1/src/lib/crypto/test/DESTests.cpp +@@ -259,54 +259,58 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey56, SymMode::CBC, IV)); ++ if (des->encryptInit(&desKey56, SymMode::CBC, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::CBC, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::CBC, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ ++ } + + // Test 112-bit key + cipherText = ByteString(testResult[i][j][1]); + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey112, SymMode::CBC, IV)); ++ if (des->encryptInit(&desKey112, SymMode::CBC, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::CBC, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::CBC, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; ++ ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + +- CPPUNIT_ASSERT(shsmPlainText == plainText); + #endif + + // Test 168-bit key +@@ -314,27 +318,28 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey168, SymMode::CBC, IV)); ++ if (des->encryptInit(&desKey168, SymMode::CBC, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::CBC, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::CBC, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + } + } + } +@@ -534,54 +539,56 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey56, SymMode::ECB, IV)); ++ if (des->encryptInit(&desKey56, SymMode::ECB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::ECB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::ECB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + + // Test 112-bit key + cipherText = ByteString(testResult[i][j][1]); + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey112, SymMode::ECB, IV)); ++ if (des->encryptInit(&desKey112, SymMode::ECB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::ECB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::ECB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + #endif + + // Test 168-bit key +@@ -589,27 +596,28 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey168, SymMode::ECB, IV)); ++ if (des->encryptInit(&desKey168, SymMode::ECB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::ECB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::ECB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + } + } + } +@@ -809,54 +817,56 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey56, SymMode::OFB, IV)); ++ if (des->encryptInit(&desKey56, SymMode::OFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::OFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::OFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + + // Test 112-bit key + cipherText = ByteString(testResult[i][j][1]); + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey112, SymMode::OFB, IV)); ++ if (des->encryptInit(&desKey112, SymMode::OFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::OFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::OFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + #endif + + // Test 168-bit key +@@ -864,27 +874,28 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey168, SymMode::OFB, IV)); ++ if (des->encryptInit(&desKey168, SymMode::OFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::OFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::OFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + } + } + } +@@ -1083,54 +1094,56 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey56, SymMode::CFB, IV)); ++ if (des->encryptInit(&desKey56, SymMode::CFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::CFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey56, SymMode::CFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + + // Test 112-bit key + cipherText = ByteString(testResult[i][j][1]); + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey112, SymMode::CFB, IV)); ++ if (des->encryptInit(&desKey112, SymMode::CFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::CFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey112, SymMode::CFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + #endif + + // Test 168-bit key +@@ -1138,27 +1151,28 @@ + + // Now, do the same thing using our DES implementation + shsmCipherText.wipe(); +- CPPUNIT_ASSERT(des->encryptInit(&desKey168, SymMode::CFB, IV)); ++ if (des->encryptInit(&desKey168, SymMode::CFB, IV)) { + +- CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptUpdate(plainText, OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(des->encryptFinal(OB)); +- shsmCipherText += OB; ++ CPPUNIT_ASSERT(des->encryptFinal(OB)); ++ shsmCipherText += OB; + +- CPPUNIT_ASSERT(shsmCipherText == cipherText); ++ CPPUNIT_ASSERT(shsmCipherText == cipherText); + +- // Check that we can get the plain text +- shsmPlainText.wipe(); +- CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::CFB, IV)); ++ // Check that we can get the plain text ++ shsmPlainText.wipe(); ++ CPPUNIT_ASSERT(des->decryptInit(&desKey168, SymMode::CFB, IV)); + +- CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptUpdate(shsmCipherText, OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(des->decryptFinal(OB)); +- shsmPlainText += OB; ++ CPPUNIT_ASSERT(des->decryptFinal(OB)); ++ shsmPlainText += OB; + +- CPPUNIT_ASSERT(shsmPlainText == plainText); ++ CPPUNIT_ASSERT(shsmPlainText == plainText); ++ } + } + } + } +Index: softhsm2-2.6.1/src/lib/crypto/test/RSATests.cpp +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/crypto/test/RSATests.cpp ++++ softhsm2-2.6.1/src/lib/crypto/test/RSATests.cpp +@@ -78,7 +78,6 @@ + + // Key sizes to test + std::vector<size_t> keySizes; +- keySizes.push_back(1024); + #ifndef WITH_FIPS + keySizes.push_back(1025); + #endif +@@ -93,30 +92,31 @@ + p.setE(*e); + p.setBitLength(*k); + +- // Generate key-pair +- CPPUNIT_ASSERT(rsa->generateKeyPair(&kp, &p)); ++ // Generate key-pair but skip test if key size is unsupported in OpenSSL 3.0.0 ++ if (rsa->generateKeyPair(&kp, &p)) { + +- RSAPublicKey* pub = (RSAPublicKey*) kp->getPublicKey(); +- RSAPrivateKey* priv = (RSAPrivateKey*) kp->getPrivateKey(); ++ RSAPublicKey* pub = (RSAPublicKey*) kp->getPublicKey(); ++ RSAPrivateKey* priv = (RSAPrivateKey*) kp->getPrivateKey(); + +- CPPUNIT_ASSERT(pub->getBitLength() == *k); +- CPPUNIT_ASSERT(priv->getBitLength() == *k); +- CPPUNIT_ASSERT(pub->getE() == *e); +- CPPUNIT_ASSERT(priv->getE() == *e); ++ CPPUNIT_ASSERT(pub->getBitLength() == *k); ++ CPPUNIT_ASSERT(priv->getBitLength() == *k); ++ CPPUNIT_ASSERT(pub->getE() == *e); ++ CPPUNIT_ASSERT(priv->getE() == *e); + +- rsa->recycleKeyPair(kp); ++ rsa->recycleKeyPair(kp); ++ } + } + } + } + + void RSATests::testSerialisation() + { +- // Generate a 1024-bit key-pair for testing ++ // Generate a 2048-bit key-pair for testing + AsymmetricKeyPair* kp; + RSAParameters p; + + p.setE("010001"); +- p.setBitLength(1024); ++ p.setBitLength(2048); + + CPPUNIT_ASSERT(rsa->generateKeyPair(&kp, &p)); + CPPUNIT_ASSERT(kp != NULL); +@@ -204,12 +204,12 @@ + + void RSATests::testPKCS8() + { +- // Generate a 1024-bit key-pair for testing ++ // Generate a 2048-bit key-pair for testing + AsymmetricKeyPair* kp; + RSAParameters p; + + p.setE("010001"); +- p.setBitLength(1024); ++ p.setBitLength(2048); + + CPPUNIT_ASSERT(rsa->generateKeyPair(&kp, &p)); + CPPUNIT_ASSERT(kp != NULL); +@@ -253,7 +253,6 @@ + + // Key sizes to test + std::vector<size_t> keySizes; +- keySizes.push_back(1024); + keySizes.push_back(1280); + keySizes.push_back(2048); + //keySizes.push_back(4096); +@@ -293,8 +292,10 @@ + p.setE(*e); + p.setBitLength(*k); + +- // Generate key-pair +- CPPUNIT_ASSERT(rsa->generateKeyPair(&kp, &p)); ++ // Generate key-pair but skip those that unsupported in OpenSSL 3.0.0 ++ if (!rsa->generateKeyPair(&kp, &p)) { ++ continue; ++ } + + // Generate some data to sign + ByteString dataToSign; +@@ -611,7 +612,6 @@ + + // Key sizes to test + std::vector<size_t> keySizes; +- keySizes.push_back(1024); + keySizes.push_back(1280); + keySizes.push_back(2048); + //keySizes.push_back(4096); +@@ -629,8 +629,10 @@ + p.setE(*e); + p.setBitLength(*k); + +- // Generate key-pair +- CPPUNIT_ASSERT(rsa->generateKeyPair(&kp, &p)); ++ // Generate key-pair but skip those that unsupported in OpenSSL 3.0.0 ++ if (!rsa->generateKeyPair(&kp, &p)) { ++ continue; ++ } + + RNG* rng = CryptoFactory::i()->getRNG(); + +Index: softhsm2-2.6.1/src/lib/test/DeriveTests.cpp +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/DeriveTests.cpp ++++ softhsm2-2.6.1/src/lib/test/DeriveTests.cpp +@@ -642,11 +642,14 @@ + 0x25, 0x26, 0x27, 0x28, 0x29, 0x30, 0x31, 0x32 + }; + CK_ULONG secLen = 0; ++ CK_BBOOL oldMechs = CK_FALSE; + + switch (mechType) + { + case CKM_DES_ECB_ENCRYPT_DATA: + case CKM_DES3_ECB_ENCRYPT_DATA: ++ oldMechs = CK_TRUE; ++ /* fall-through */ + case CKM_AES_ECB_ENCRYPT_DATA: + param1.pData = &data[0]; + param1.ulLen = sizeof(data); +@@ -655,6 +658,7 @@ + break; + case CKM_DES_CBC_ENCRYPT_DATA: + case CKM_DES3_CBC_ENCRYPT_DATA: ++ oldMechs = CK_TRUE; + memcpy(param2.iv, "12345678", 8); + param2.pData = &data[0]; + param2.length = sizeof(data); +@@ -679,10 +683,12 @@ + break; + case CKK_DES: + mechEncrypt.mechanism = CKM_DES_ECB; ++ oldMechs = CK_TRUE; + break; + case CKK_DES2: + case CKK_DES3: + mechEncrypt.mechanism = CKM_DES3_ECB; ++ oldMechs = CK_TRUE; + break; + case CKK_AES: + mechEncrypt.mechanism = CKM_AES_ECB; +@@ -719,7 +725,11 @@ + keyAttribs, sizeof(keyAttribs)/sizeof(CK_ATTRIBUTE) - 1, + &hDerive) ); + } +- CPPUNIT_ASSERT(rv == CKR_OK); ++ if (rv != CKR_OK && oldMechs == CK_TRUE) { ++ // Skip old mechanisms, they don't work under this crypto library ++ return; ++ } ++ CPPUNIT_ASSERT(rv==CKR_OK); + + // Check that KCV has been set + CK_ATTRIBUTE checkAttribs[] = { +@@ -740,6 +750,10 @@ + CK_ULONG ulRecoveredTextLen; + + rv = CRYPTOKI_F_PTR( C_EncryptInit(hSession,&mechEncrypt,hDerive) ); ++ if (rv != CKR_OK && oldMechs == CK_TRUE) { ++ // Skip old mechanisms, they don't work under this crypto library ++ return; ++ } + CPPUNIT_ASSERT(rv==CKR_OK); + + ulCipherTextLen = sizeof(cipherText); +Index: softhsm2-2.6.1/src/lib/test/ObjectTests.cpp +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/ObjectTests.cpp ++++ softhsm2-2.6.1/src/lib/test/ObjectTests.cpp +@@ -2370,8 +2370,10 @@ + CPPUNIT_ASSERT(rv == CKR_OK); + rv = CRYPTOKI_F_PTR( C_GetAttributeValue(hSession, hObject, attribKCV, 1) ); + CPPUNIT_ASSERT(rv == CKR_OK); +- CPPUNIT_ASSERT(attribKCV[0].ulValueLen == 3); +- CPPUNIT_ASSERT(memcmp(pCheckValue, desKCV, 3) == 0); ++ // If DES key is not supported, skip it ++ if (attribKCV[0].ulValueLen == 3) { ++ CPPUNIT_ASSERT(memcmp(pCheckValue, desKCV, 3) == 0); ++ } + rv = CRYPTOKI_F_PTR( C_DestroyObject(hSession,hObject) ); + CPPUNIT_ASSERT(rv == CKR_OK); + +@@ -2381,9 +2383,12 @@ + rv = CRYPTOKI_F_PTR( C_CreateObject(hSession, attribs, sizeof(attribs)/sizeof(CK_ATTRIBUTE), &hObject) ); + CPPUNIT_ASSERT(rv == CKR_OK); + rv = CRYPTOKI_F_PTR( C_GetAttributeValue(hSession, hObject, attribKCV, 1) ); +- CPPUNIT_ASSERT(rv == CKR_OK); +- CPPUNIT_ASSERT(attribKCV[0].ulValueLen == 3); +- CPPUNIT_ASSERT(memcmp(pCheckValue, des2KCV, 3) == 0); ++ // If DES2 key is not supported, skip it ++ if (rv == CKR_OK) { ++ if (attribKCV[0].ulValueLen == 3) { ++ CPPUNIT_ASSERT(memcmp(pCheckValue, des2KCV, 3) == 0); ++ } ++ } + rv = CRYPTOKI_F_PTR( C_DestroyObject(hSession,hObject) ); + CPPUNIT_ASSERT(rv == CKR_OK); + +@@ -2394,8 +2399,10 @@ + CPPUNIT_ASSERT(rv == CKR_OK); + rv = CRYPTOKI_F_PTR( C_GetAttributeValue(hSession, hObject, attribKCV, 1) ); + CPPUNIT_ASSERT(rv == CKR_OK); +- CPPUNIT_ASSERT(attribKCV[0].ulValueLen == 3); +- CPPUNIT_ASSERT(memcmp(pCheckValue, des3KCV, 3) == 0); ++ // If DES3 key is not supported, skip it ++ if (attribKCV[0].ulValueLen == 3) { ++ CPPUNIT_ASSERT(memcmp(pCheckValue, des3KCV, 3) == 0); ++ } + rv = CRYPTOKI_F_PTR( C_DestroyObject(hSession,hObject) ); + CPPUNIT_ASSERT(rv == CKR_OK); + } +Index: softhsm2-2.6.1/src/lib/test/SymmetricAlgorithmTests.cpp +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/SymmetricAlgorithmTests.cpp ++++ softhsm2-2.6.1/src/lib/test/SymmetricAlgorithmTests.cpp +@@ -195,6 +195,8 @@ + std::vector<CK_BYTE> vEncryptedData; + std::vector<CK_BYTE> vEncryptedDataParted; + PartSize partSize(blockSize, &vData); ++ CK_BBOOL oldMechs = CK_FALSE; ++ CK_RV rv = CKR_OK; + + CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_GenerateRandom(hSession, (CK_BYTE_PTR)&vData.front(), messageSize) ) ); + +@@ -233,6 +235,8 @@ + case CKM_DES_CBC_PAD: + case CKM_DES3_CBC: + case CKM_DES3_CBC_PAD: ++ oldMechs = CK_TRUE; ++ /* fall-through */ + case CKM_AES_CBC: + case CKM_AES_CBC_PAD: + pMechanism->pParameter = (CK_VOID_PTR)&vData.front(); +@@ -246,12 +250,18 @@ + pMechanism->pParameter = &gcmParams; + pMechanism->ulParameterLen = sizeof(gcmParams); + break; ++ case CKM_DES_ECB: ++ case CKM_DES3_ECB: ++ oldMechs = CK_TRUE; ++ break; + default: + break; + } + + // Single-part encryption +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptInit(hSession,pMechanism,hKey) ) ); ++ rv = CRYPTOKI_F_PTR( C_EncryptInit(hSession,pMechanism,hKey) ); ++ CPPUNIT_ASSERT_EQUAL( (CK_BBOOL) CK_FALSE, (CK_BBOOL) ((rv != CKR_OK) && (oldMechs == CK_FALSE)) ); ++ if (oldMechs == CK_FALSE) + { + CK_ULONG ulEncryptedDataLen; + const CK_RV rv( CRYPTOKI_F_PTR( C_Encrypt(hSession,(CK_BYTE_PTR)&vData.front(),messageSize,NULL_PTR,&ulEncryptedDataLen) ) ); +@@ -267,40 +277,42 @@ + } + + // Multi-part encryption +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptInit(hSession,pMechanism,hKey) ) ); +- +- for ( std::vector<CK_BYTE>::const_iterator i(vData.begin()); i<vData.end(); i+=partSize.getCurrent() ) { +- const CK_ULONG lPartLen( i+partSize.getNext()<vData.end() ? partSize.getCurrent() : vData.end()-i ); +- CK_ULONG ulEncryptedPartLen; +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptUpdate(hSession,(CK_BYTE_PTR)&(*i),lPartLen,NULL_PTR,&ulEncryptedPartLen) ) ); +- const size_t oldSize( vEncryptedDataParted.size() ); +- vEncryptedDataParted.resize(oldSize+ulEncryptedPartLen); +- CK_BYTE dummy; +- const CK_BYTE_PTR pEncryptedPart( ulEncryptedPartLen>0 ? &vEncryptedDataParted.at(oldSize) : &dummy ); +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptUpdate(hSession,(CK_BYTE_PTR)&(*i),lPartLen,pEncryptedPart,&ulEncryptedPartLen) ) ); +- vEncryptedDataParted.resize(oldSize+ulEncryptedPartLen); +- } +- { +- CK_ULONG ulLastEncryptedPartLen; +- const CK_RV rv( CRYPTOKI_F_PTR( C_EncryptFinal(hSession,NULL_PTR,&ulLastEncryptedPartLen) ) ); +- if ( isSizeOK ) { +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, rv ); ++ rv = CRYPTOKI_F_PTR( C_EncryptInit(hSession,pMechanism,hKey) ); ++ CPPUNIT_ASSERT_EQUAL( (CK_BBOOL) CK_FALSE, (CK_BBOOL) ((rv != CKR_OK) && (oldMechs == CK_FALSE)) ); ++ if (oldMechs == CK_FALSE) { ++ for ( std::vector<CK_BYTE>::const_iterator i(vData.begin()); i<vData.end(); i+=partSize.getCurrent() ) { ++ const CK_ULONG lPartLen( i+partSize.getNext()<vData.end() ? partSize.getCurrent() : vData.end()-i ); ++ CK_ULONG ulEncryptedPartLen; ++ CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptUpdate(hSession,(CK_BYTE_PTR)&(*i),lPartLen,NULL_PTR,&ulEncryptedPartLen) ) ); + const size_t oldSize( vEncryptedDataParted.size() ); ++ vEncryptedDataParted.resize(oldSize+ulEncryptedPartLen); + CK_BYTE dummy; +- vEncryptedDataParted.resize(oldSize+ulLastEncryptedPartLen); +- const CK_BYTE_PTR pLastEncryptedPart( ulLastEncryptedPartLen>0 ? &vEncryptedDataParted.at(oldSize) : &dummy ); +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptFinal(hSession,pLastEncryptedPart,&ulLastEncryptedPartLen) ) ); +- vEncryptedDataParted.resize(oldSize+ulLastEncryptedPartLen); +- } else { +- CPPUNIT_ASSERT_EQUAL_MESSAGE("C_EncryptFinal should fail with C_CKR_DATA_LEN_RANGE", (CK_RV)CKR_DATA_LEN_RANGE, rv); +- vEncryptedDataParted = vData; ++ const CK_BYTE_PTR pEncryptedPart( ulEncryptedPartLen>0 ? &vEncryptedDataParted.at(oldSize) : &dummy ); ++ CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptUpdate(hSession,(CK_BYTE_PTR)&(*i),lPartLen,pEncryptedPart,&ulEncryptedPartLen) ) ); ++ vEncryptedDataParted.resize(oldSize+ulEncryptedPartLen); ++ } ++ { ++ CK_ULONG ulLastEncryptedPartLen; ++ const CK_RV rv( CRYPTOKI_F_PTR( C_EncryptFinal(hSession,NULL_PTR,&ulLastEncryptedPartLen) ) ); ++ if ( isSizeOK ) { ++ CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, rv ); ++ const size_t oldSize( vEncryptedDataParted.size() ); ++ CK_BYTE dummy; ++ vEncryptedDataParted.resize(oldSize+ulLastEncryptedPartLen); ++ const CK_BYTE_PTR pLastEncryptedPart( ulLastEncryptedPartLen>0 ? &vEncryptedDataParted.at(oldSize) : &dummy ); ++ CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_EncryptFinal(hSession,pLastEncryptedPart,&ulLastEncryptedPartLen) ) ); ++ vEncryptedDataParted.resize(oldSize+ulLastEncryptedPartLen); ++ } else { ++ CPPUNIT_ASSERT_EQUAL_MESSAGE("C_EncryptFinal should fail with C_CKR_DATA_LEN_RANGE", (CK_RV)CKR_DATA_LEN_RANGE, rv); ++ vEncryptedDataParted = vData; ++ } + } + } + + // Single-part decryption +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_DecryptInit(hSession,pMechanism,hKey) ) ); +- +- { ++ rv = CRYPTOKI_F_PTR( C_DecryptInit(hSession,pMechanism,hKey) ); ++ CPPUNIT_ASSERT_EQUAL( (CK_BBOOL) CK_FALSE, (CK_BBOOL) ((rv != CKR_OK) && (oldMechs == CK_FALSE)) ); ++ if (oldMechs == CK_FALSE) { + CK_ULONG ulDataLen; + const CK_RV rv( CRYPTOKI_F_PTR( C_Decrypt(hSession,&vEncryptedData.front(),vEncryptedData.size(),NULL_PTR,&ulDataLen) ) ); + if ( isSizeOK ) { +@@ -315,8 +327,9 @@ + } + + // Multi-part decryption +- CPPUNIT_ASSERT_EQUAL( (CK_RV)CKR_OK, CRYPTOKI_F_PTR( C_DecryptInit(hSession,pMechanism,hKey) ) ); +- { ++ rv = CRYPTOKI_F_PTR( C_DecryptInit(hSession,pMechanism,hKey) ); ++ CPPUNIT_ASSERT_EQUAL( (CK_BBOOL) CK_FALSE, (CK_BBOOL) ((rv != CKR_OK) && (oldMechs == CK_FALSE)) ); ++ if (oldMechs == CK_FALSE) { + std::vector<CK_BYTE> vDecryptedData; + CK_BYTE dummy; + for ( std::vector<CK_BYTE>::iterator i(vEncryptedDataParted.begin()); i<vEncryptedDataParted.end(); i+=partSize.getCurrent()) { +@@ -836,44 +849,44 @@ + + // Generate all combinations of session/token keys. + rv = generateDesKey(hSessionRW,IN_SESSION,IS_PUBLIC,hKey); +- CPPUNIT_ASSERT(rv == CKR_OK); +- +- encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST-1); +- encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1); +- encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES_CBC,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES_CBC,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); +- encryptDecrypt(CKM_DES_ECB,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES_ECB,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ if (rv == CKR_OK) { ++ encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST-1); ++ encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1); ++ encryptDecrypt(CKM_DES_CBC_PAD,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES_CBC,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES_CBC,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ encryptDecrypt(CKM_DES_ECB,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES_ECB,blockSize,hSessionRO,hKey,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ } + + CK_OBJECT_HANDLE hKey2 = CK_INVALID_HANDLE; + + // Generate all combinations of session/token keys. + rv = generateDes2Key(hSessionRW,IN_SESSION,IS_PUBLIC,hKey2); +- CPPUNIT_ASSERT(rv == CKR_OK); +- +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST-1); +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1); +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); +- encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ if (rv == CKR_OK) { ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST-1); ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1); ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey2,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ } + #endif + + CK_OBJECT_HANDLE hKey3 = CK_INVALID_HANDLE; + + // Generate all combinations of session/token keys. + rv = generateDes3Key(hSessionRW,IN_SESSION,IS_PUBLIC,hKey3); +- CPPUNIT_ASSERT(rv == CKR_OK); +- +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST-1); +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1); +- encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); +- encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); +- encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ if (rv == CKR_OK) { ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST-1); ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1); ++ encryptDecrypt(CKM_DES3_CBC_PAD,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_CBC,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST); ++ encryptDecrypt(CKM_DES3_ECB,blockSize,hSessionRO,hKey3,blockSize*NR_OF_BLOCKS_IN_TEST+1, false); ++ } + } + + void SymmetricAlgorithmTests::testNullTemplate() +Index: softhsm2-2.6.1/src/lib/test/InfoTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/InfoTests.h ++++ softhsm2-2.6.1/src/lib/test/InfoTests.h +@@ -42,13 +42,13 @@ + CPPUNIT_TEST_SUITE(InfoTests); + CPPUNIT_TEST(testGetInfo); + CPPUNIT_TEST(testGetFunctionList); +- CPPUNIT_TEST(testGetSlotList); +- CPPUNIT_TEST(testGetSlotInfo); +- CPPUNIT_TEST(testGetTokenInfo); +- CPPUNIT_TEST(testGetMechanismList); +- CPPUNIT_TEST(testGetMechanismInfo); +- CPPUNIT_TEST(testGetSlotInfoAlt); +- CPPUNIT_TEST(testGetMechanismListConfig); ++ //CPPUNIT_TEST(testGetSlotList); ++ //CPPUNIT_TEST(testGetSlotInfo); ++ //CPPUNIT_TEST(testGetTokenInfo); ++ //CPPUNIT_TEST(testGetMechanismList); ++ //CPPUNIT_TEST(testGetMechanismInfo); ++ //CPPUNIT_TEST(testGetSlotInfoAlt); ++ //CPPUNIT_TEST(testGetMechanismListConfig); + CPPUNIT_TEST(testWaitForSlotEvent); + CPPUNIT_TEST_SUITE_END(); + +Index: softhsm2-2.6.1/src/lib/test/ObjectTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/ObjectTests.h ++++ softhsm2-2.6.1/src/lib/test/ObjectTests.h +@@ -41,7 +41,7 @@ + class ObjectTests : public TestsBase + { + CPPUNIT_TEST_SUITE(ObjectTests); +- CPPUNIT_TEST(testCreateObject); ++ /*CPPUNIT_TEST(testCreateObject); + CPPUNIT_TEST(testCopyObject); + CPPUNIT_TEST(testDestroyObject); + CPPUNIT_TEST(testGetObjectSize); +@@ -60,7 +60,7 @@ + CPPUNIT_TEST(testAllowedMechanisms); + CPPUNIT_TEST(testReAuthentication); + CPPUNIT_TEST(testTemplateAttribute); +- CPPUNIT_TEST(testCreateSecretKey); ++ CPPUNIT_TEST(testCreateSecretKey);*/ + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/UserTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/UserTests.h ++++ softhsm2-2.6.1/src/lib/test/UserTests.h +@@ -39,10 +39,10 @@ + class UserTests : public TestsNoPINInitBase + { + CPPUNIT_TEST_SUITE(UserTests); +- CPPUNIT_TEST(testInitPIN); ++ /*CPPUNIT_TEST(testInitPIN); + CPPUNIT_TEST(testLogin); + CPPUNIT_TEST(testLogout); +- CPPUNIT_TEST(testSetPIN); ++ CPPUNIT_TEST(testSetPIN);*/ + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/SignVerifyTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/SignVerifyTests.h ++++ softhsm2-2.6.1/src/lib/test/SignVerifyTests.h +@@ -41,14 +41,14 @@ + class SignVerifyTests : public TestsBase + { + CPPUNIT_TEST_SUITE(SignVerifyTests); +- CPPUNIT_TEST(testRsaSignVerify); ++ /*CPPUNIT_TEST(testRsaSignVerify); + #ifdef WITH_ECC + CPPUNIT_TEST(testEcSignVerify); + #endif + #ifdef WITH_EDDSA + CPPUNIT_TEST_PARAMETERIZED(testEdSignVerify, {"Ed25519", "Ed448"}); + #endif +- CPPUNIT_TEST(testMacSignVerify); ++ CPPUNIT_TEST(testMacSignVerify);*/ + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/SymmetricAlgorithmTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/SymmetricAlgorithmTests.h ++++ softhsm2-2.6.1/src/lib/test/SymmetricAlgorithmTests.h +@@ -39,7 +39,7 @@ + class SymmetricAlgorithmTests : public TestsBase + { + CPPUNIT_TEST_SUITE(SymmetricAlgorithmTests); +- CPPUNIT_TEST(testAesEncryptDecrypt); ++ /*CPPUNIT_TEST(testAesEncryptDecrypt); + CPPUNIT_TEST(testDesEncryptDecrypt); + #ifdef HAVE_AES_KEY_WRAP + CPPUNIT_TEST(testAesWrapUnwrap); +@@ -49,7 +49,7 @@ + CPPUNIT_TEST(testCheckValue); + CPPUNIT_TEST(testAesCtrOverflow); + CPPUNIT_TEST(testGenericKey); +- CPPUNIT_TEST(testEncDecFinalNULLValidation); ++ CPPUNIT_TEST(testEncDecFinalNULLValidation);*/ + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/RandomTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/RandomTests.h ++++ softhsm2-2.6.1/src/lib/test/RandomTests.h +@@ -39,8 +39,8 @@ + class RandomTests : public TestsNoPINInitBase + { + CPPUNIT_TEST_SUITE(RandomTests); +- CPPUNIT_TEST(testSeedRandom); +- CPPUNIT_TEST(testGenerateRandom); ++ //CPPUNIT_TEST(testSeedRandom); ++ //CPPUNIT_TEST(testGenerateRandom); + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/SessionTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/SessionTests.h ++++ softhsm2-2.6.1/src/lib/test/SessionTests.h +@@ -40,10 +40,10 @@ + class SessionTests : public TestsNoPINInitBase + { + CPPUNIT_TEST_SUITE(SessionTests); +- CPPUNIT_TEST(testOpenSession); ++ /*CPPUNIT_TEST(testOpenSession); + CPPUNIT_TEST(testCloseSession); + CPPUNIT_TEST(testCloseAllSessions); +- CPPUNIT_TEST(testGetSessionInfo); ++ CPPUNIT_TEST(testGetSessionInfo);*/ + CPPUNIT_TEST_SUITE_END(); + + public: +Index: softhsm2-2.6.1/src/lib/test/TokenTests.h +=================================================================== +--- softhsm2-2.6.1.orig/src/lib/test/TokenTests.h ++++ softhsm2-2.6.1/src/lib/test/TokenTests.h +@@ -39,7 +39,7 @@ + class TokenTests : public TestsNoPINInitBase + { + CPPUNIT_TEST_SUITE(TokenTests); +- CPPUNIT_TEST(testInitToken); ++ //CPPUNIT_TEST(testInitToken); + CPPUNIT_TEST_SUITE_END(); + + public: diff --git a/gnu/packages/patches/source-highlight-gcc-compat.patch b/gnu/packages/patches/source-highlight-gcc-compat.patch new file mode 100644 index 0000000000..7b543dcf32 --- /dev/null +++ b/gnu/packages/patches/source-highlight-gcc-compat.patch @@ -0,0 +1,74 @@ +Fix various compatibility problems with newer GCC. + +This is an amalgamation of these upstream commits: + + https://git.savannah.gnu.org/cgit/src-highlite.git/commit/?id=904949c9026cb772dc93fbe0947a252ef47127f4 + https://git.savannah.gnu.org/cgit/src-highlite.git/commit/?id=ab9fe5cb9b85c5afab94f2a7f4b6d7d473c14ee9 + +diff --git a/lib/srchilite/fileutil.cc b/lib/srchilite/fileutil.cc +index 59a6d64..963178c 100644 +--- a/lib/srchilite/fileutil.cc ++++ b/lib/srchilite/fileutil.cc +@@ -48,7 +48,7 @@ void set_file_util_verbose(bool b) { + // FIXME avoid using a global variable + std::string start_path; + +-string readFile(const string &fileName) throw (IOException) { ++string readFile(const string &fileName) { + ifstream file(fileName.c_str()); + + if (!file.is_open()) { +diff --git a/lib/srchilite/fileutil.h b/lib/srchilite/fileutil.h +index 7335a9b..042eb56 100644 +--- a/lib/srchilite/fileutil.h ++++ b/lib/srchilite/fileutil.h +@@ -27,7 +27,7 @@ extern std::string start_path; + * @return the contents of the file + * @throw IOException + */ +-string readFile(const string &fileName) throw (IOException); ++string readFile(const string &fileName); + + //char *read_file(const string &fileName); + +diff --git a/lib/tests/stdboosterror.h b/lib/tests/stdboosterror.h +index 568545b..d59bfa6 100644 +--- a/lib/tests/stdboosterror.h ++++ b/lib/tests/stdboosterror.h +@@ -4,7 +4,7 @@ + #include <boost/regex/pattern_except.hpp> + + static boost::regex_error +- std_boost_exception(boost::regex_error(boost::regex_constants::error_bad_pattern)); ++ std_boost_exception = boost::regex_error(boost::regex_constants::error_bad_pattern); + + /** + * returns the string representing a standard exception (which +diff --git a/lib/tests/test_wordtokenizer_main.cpp b/lib/tests/test_wordtokenizer_main.cpp +index 40e23b1..11ba389 100644 +--- a/lib/tests/test_wordtokenizer_main.cpp ++++ b/lib/tests/test_wordtokenizer_main.cpp +@@ -11,6 +11,14 @@ + using namespace std; + using namespace srchilite; + ++/* ++ * We have to use 'std' namespaces because 'WordTokenizer::WordTokenizerResults::value_type' ++ * is an std::pair<std::string, std::string> in disguise. We have to place 'operator<<()' ++ * into the same namespace for ADL to work. Otherwise gcc-12 or clang-13 can't find the ++ * overload. ++ */ ++namespace std { ++ + static ostream &operator <<(ostream &os, const WordTokenizer::WordTokenizerResults::value_type &); + + ostream &operator <<(ostream &os, const WordTokenizer::WordTokenizerResults::value_type &token) { +@@ -23,6 +31,8 @@ ostream &operator <<(ostream &os, const WordTokenizer::WordTokenizerResults::val + return os; + } + ++} ++ + int main() { + WordTokenizer::WordTokenizerResults tokens; + \ No newline at end of file diff --git a/gnu/packages/patches/swig-support-gcc-12.patch b/gnu/packages/patches/swig-support-gcc-12.patch new file mode 100644 index 0000000000..ece7928aa2 --- /dev/null +++ b/gnu/packages/patches/swig-support-gcc-12.patch @@ -0,0 +1,16 @@ +Fix for https://github.com/swig/swig/issues/2145 made in unreleased upstream commit +https://github.com/swig/swig/commit/76d5a9ec270a763c892ae28070e391cf99e0b7cd + +diff --git a/Examples/test-suite/nested_class.i b/Examples/test-suite/nested_class.i +index b10c339493e..c778a12cf7c 100644 +--- a/Examples/test-suite/nested_class.i ++++ b/Examples/test-suite/nested_class.i +@@ -201,7 +201,7 @@ struct Outer { + Integer xx; + } MultipleInstanceAnonDerived1, MultipleInstanceAnonDerived2, *MultipleInstanceAnonDerived3, MultipleInstanceAnonDerived4[2]; + +-#if defined(__GNUC__) || defined(_MSC_VER) || defined(SWIG) ++#if (defined(__GNUC__) && __GNUC__ < 12) || defined(_MSC_VER) || defined(SWIG) + /* some compilers do not accept these */ + struct : public InnerMultiple { + Integer xx; diff --git a/gnu/packages/patches/texinfo-headings-single.patch b/gnu/packages/patches/texinfo-headings-single.patch new file mode 100644 index 0000000000..5147449ddc --- /dev/null +++ b/gnu/packages/patches/texinfo-headings-single.patch @@ -0,0 +1,21 @@ +Fix a regression in 6.8 where the 'single' headings option was not recognized. + +Taken from upstream: + + https://git.savannah.gnu.org/cgit/texinfo.git/commit/?id=13a8894fe2faa45b04033d7122a8fe7939ce6aa2 + +diff --git a/tp/Texinfo/XS/parsetexi/end_line.c b/tp/Texinfo/XS/parsetexi/end_line.c +index 4556780052..3fc2065616 100644 +--- a/tp/Texinfo/XS/parsetexi/end_line.c ++++ b/tp/Texinfo/XS/parsetexi/end_line.c +@@ -778,8 +778,8 @@ kdbinputstyle_invalid: + case CM_headings: + { + if (!strcmp (line, "off") || !strcmp (line, "on") +- || !strcmp (line, "double") || !strcmp (line, "singleafter") +- || !strcmp (line, "doubleafter")) ++ || !strcmp (line, "single") || !strcmp (line, "double") ++ || !strcmp (line, "singleafter") || !strcmp (line, "doubleafter")) + { + ADD_ARG(line); + } diff --git a/gnu/packages/patches/u-boot-fix-build-python-3.10.patch b/gnu/packages/patches/u-boot-fix-build-python-3.10.patch new file mode 100644 index 0000000000..7e5d6ba656 --- /dev/null +++ b/gnu/packages/patches/u-boot-fix-build-python-3.10.patch @@ -0,0 +1,37 @@ +This patch is backported from U-Boot 2023.01; remove when updating. + +From 7d01bb1c5a1daef0187c9ea276bde19a8d0e7fde Mon Sep 17 00:00:00 2001 +From: Michal Suchanek <msuchanek@suse.de> +Date: Thu, 13 Oct 2022 22:43:41 +0200 +Subject: [PATCH] libfdt: Fix build with python 3.10 + +Python 3.10 requires defining PY_SSIZE_T_CLEAN. This will be fixed in +swig 4.10 but it is not clear when it will be released. There was a +warning since python 3.8. + +Link: https://github.com/swig/swig/pull/2277 + +Signed-off-by: Michal Suchanek <msuchanek@suse.de> +Reviewed-by: Simon Glass <sjg@chromium.org> +--- + scripts/dtc/pylibfdt/libfdt.i_shipped | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/scripts/dtc/pylibfdt/libfdt.i_shipped b/scripts/dtc/pylibfdt/libfdt.i_shipped +index 27c29ea260..56cc5d48f4 100644 +--- a/scripts/dtc/pylibfdt/libfdt.i_shipped ++++ b/scripts/dtc/pylibfdt/libfdt.i_shipped +@@ -7,6 +7,10 @@ + + %module libfdt + ++%begin %{ ++#define PY_SSIZE_T_CLEAN ++%} ++ + %include <stdint.i> + + %{ +-- +GitLab + diff --git a/gnu/packages/patches/ucx-tcp-iface-ioctl.patch b/gnu/packages/patches/ucx-tcp-iface-ioctl.patch index 56f06fc920..c441a0861a 100644 --- a/gnu/packages/patches/ucx-tcp-iface-ioctl.patch +++ b/gnu/packages/patches/ucx-tcp-iface-ioctl.patch @@ -54,7 +54,7 @@ index cad4a2709..7c1d2c9de 100644 + for (i = 0; i < conf.ifc_len / sizeof(struct ifreq); i++) { + const char *name = reqs[i].ifr_name; + -+ if (!ucs_netif_is_active(name)) { ++ if (!ucs_netif_is_active(name, AF_INET)) { + continue; + } + @@ -87,9 +87,9 @@ index cad4a2709..7c1d2c9de 100644 unsigned *num_devices_p) @@ -599,9 +663,9 @@ ucs_status_t uct_tcp_query_devices(uct_md_h md, - dir = opendir(netdev_dir); + dir = opendir(UCT_TCP_IFACE_NETDEV_DIR); if (dir == NULL) { -- ucs_error("opendir(%s) failed: %m", netdev_dir); +- ucs_error("opendir(%s) failed: %m", UCT_TCP_IFACE_NETDEV_DIR); - status = UCS_ERR_IO_ERROR; - goto out; + /* When /sys is unavailable, as can be the case in a container, diff --git a/gnu/packages/patches/util-linux-CVE-2021-3995.patch b/gnu/packages/patches/util-linux-CVE-2021-3995.patch deleted file mode 100644 index 7faea83801..0000000000 --- a/gnu/packages/patches/util-linux-CVE-2021-3995.patch +++ /dev/null @@ -1,146 +0,0 @@ -Fix CVE-2021-3995: - -https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3995 -https://seclists.org/oss-sec/2022/q1/66 - -Patch copied from upstream source repository: - -https://github.com/util-linux/util-linux/commit/f3db9bd609494099f0c1b95231c5dfe383346929 - -From f3db9bd609494099f0c1b95231c5dfe383346929 Mon Sep 17 00:00:00 2001 -From: Karel Zak <kzak@redhat.com> -Date: Wed, 24 Nov 2021 13:53:25 +0100 -Subject: [PATCH] libmount: fix UID check for FUSE umount [CVE-2021-3995] - -Improper UID check allows an unprivileged user to unmount FUSE -filesystems of users with similar UID. - -Signed-off-by: Karel Zak <kzak@redhat.com> ---- - include/strutils.h | 2 +- - libmount/src/context_umount.c | 14 +++--------- - libmount/src/mountP.h | 1 + - libmount/src/optstr.c | 42 +++++++++++++++++++++++++++++++++++ - 4 files changed, 47 insertions(+), 12 deletions(-) - -diff --git a/include/strutils.h b/include/strutils.h -index 6e95707ea..a84d29594 100644 ---- a/include/strutils.h -+++ b/include/strutils.h -@@ -106,8 +106,8 @@ static inline char *mem2strcpy(char *dest, const void *src, size_t n, size_t nma - if (n + 1 > nmax) - n = nmax - 1; - -+ memset(dest, '\0', nmax); - memcpy(dest, src, n); -- dest[nmax-1] = '\0'; - return dest; - } - -diff --git a/libmount/src/context_umount.c b/libmount/src/context_umount.c -index 173637a15..8773c65ff 100644 ---- a/libmount/src/context_umount.c -+++ b/libmount/src/context_umount.c -@@ -453,10 +453,7 @@ static int is_fuse_usermount(struct libmnt_context *cxt, int *errsv) - struct libmnt_ns *ns_old; - const char *type = mnt_fs_get_fstype(cxt->fs); - const char *optstr; -- char *user_id = NULL; -- size_t sz; -- uid_t uid; -- char uidstr[sizeof(stringify_value(ULONG_MAX))]; -+ uid_t uid, entry_uid; - - *errsv = 0; - -@@ -473,11 +470,7 @@ static int is_fuse_usermount(struct libmnt_context *cxt, int *errsv) - optstr = mnt_fs_get_fs_options(cxt->fs); - if (!optstr) - return 0; -- -- if (mnt_optstr_get_option(optstr, "user_id", &user_id, &sz) != 0) -- return 0; -- -- if (sz == 0 || user_id == NULL) -+ if (mnt_optstr_get_uid(optstr, "user_id", &entry_uid) != 0) - return 0; - - /* get current user */ -@@ -494,8 +487,7 @@ static int is_fuse_usermount(struct libmnt_context *cxt, int *errsv) - return 0; - } - -- snprintf(uidstr, sizeof(uidstr), "%lu", (unsigned long) uid); -- return strncmp(user_id, uidstr, sz) == 0; -+ return uid == entry_uid; - } - - /* -diff --git a/libmount/src/mountP.h b/libmount/src/mountP.h -index d43a83541..22442ec55 100644 ---- a/libmount/src/mountP.h -+++ b/libmount/src/mountP.h -@@ -399,6 +399,7 @@ extern const struct libmnt_optmap *mnt_optmap_get_entry( - const struct libmnt_optmap **mapent); - - /* optstr.c */ -+extern int mnt_optstr_get_uid(const char *optstr, const char *name, uid_t *uid); - extern int mnt_optstr_remove_option_at(char **optstr, char *begin, char *end); - extern int mnt_optstr_fix_gid(char **optstr, char *value, size_t valsz, char **next); - extern int mnt_optstr_fix_uid(char **optstr, char *value, size_t valsz, char **next); -diff --git a/libmount/src/optstr.c b/libmount/src/optstr.c -index 921b9318e..16800f571 100644 ---- a/libmount/src/optstr.c -+++ b/libmount/src/optstr.c -@@ -1076,6 +1076,48 @@ int mnt_optstr_fix_user(char **optstr) - return rc; - } - -+/* -+ * Converts value from @optstr addressed by @name to uid. -+ * -+ * Returns: 0 on success, 1 if not found, <0 on error -+ */ -+int mnt_optstr_get_uid(const char *optstr, const char *name, uid_t *uid) -+{ -+ char *value = NULL; -+ size_t valsz = 0; -+ char buf[sizeof(stringify_value(UINT64_MAX))]; -+ int rc; -+ uint64_t num; -+ -+ assert(optstr); -+ assert(name); -+ assert(uid); -+ -+ rc = mnt_optstr_get_option(optstr, name, &value, &valsz); -+ if (rc != 0) -+ goto fail; -+ -+ if (valsz > sizeof(buf) - 1) { -+ rc = -ERANGE; -+ goto fail; -+ } -+ mem2strcpy(buf, value, valsz, sizeof(buf)); -+ -+ rc = ul_strtou64(buf, &num, 10); -+ if (rc != 0) -+ goto fail; -+ if (num > ULONG_MAX || (uid_t) num != num) { -+ rc = -ERANGE; -+ goto fail; -+ } -+ *uid = (uid_t) num; -+ -+ return 0; -+fail: -+ DBG(UTILS, ul_debug("failed to convert '%s'= to number [rc=%d]", name, rc)); -+ return rc; -+} -+ - /** - * mnt_match_options: - * @optstr: options string --- -2.34.0 - diff --git a/gnu/packages/patches/util-linux-CVE-2021-3996.patch b/gnu/packages/patches/util-linux-CVE-2021-3996.patch deleted file mode 100644 index 59edf5c7cf..0000000000 --- a/gnu/packages/patches/util-linux-CVE-2021-3996.patch +++ /dev/null @@ -1,233 +0,0 @@ -Fix CVE-2021-3996: - -https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3996 -https://seclists.org/oss-sec/2022/q1/66 - -Patch copied from upstream source repository: - -https://github.com/util-linux/util-linux/commit/018a10907fa9885093f6d87401556932c2d8bd2b - -From 018a10907fa9885093f6d87401556932c2d8bd2b Mon Sep 17 00:00:00 2001 -From: Karel Zak <kzak@redhat.com> -Date: Tue, 4 Jan 2022 10:54:20 +0100 -Subject: [PATCH] libmount: fix (deleted) suffix issue [CVE-2021-3996] - -This issue is related to parsing the /proc/self/mountinfo file allows an -unprivileged user to unmount other user's filesystems that are either -world-writable themselves or mounted in a world-writable directory. - -The support for "(deleted)" is no more necessary as the Linux kernel does -not use it in /proc/self/mountinfo and /proc/self/mount files anymore. - -Signed-off-by: Karel Zak <kzak@redhat.com> ---- - libmount/src/tab_parse.c | 5 ----- - tests/expected/findmnt/filter-options | 1 - - tests/expected/findmnt/filter-options-nameval-neg | 3 +-- - tests/expected/findmnt/filter-types-neg | 1 - - tests/expected/findmnt/outputs-default | 3 +-- - tests/expected/findmnt/outputs-force-tree | 3 +-- - tests/expected/findmnt/outputs-kernel | 3 +-- - tests/expected/libmount/tabdiff-mount | 1 - - tests/expected/libmount/tabdiff-move | 1 - - tests/expected/libmount/tabdiff-remount | 1 - - tests/expected/libmount/tabdiff-umount | 1 - - tests/expected/libmount/tabfiles-parse-mountinfo | 11 ----------- - tests/expected/libmount/tabfiles-py-parse-mountinfo | 11 ----------- - tests/ts/findmnt/files/mountinfo | 1 - - tests/ts/findmnt/files/mountinfo-nonroot | 1 - - tests/ts/libmount/files/mountinfo | 1 - - 16 files changed, 4 insertions(+), 44 deletions(-) - -diff --git a/libmount/src/tab_parse.c b/libmount/src/tab_parse.c -index 917779ab6..4407f9c9c 100644 ---- a/libmount/src/tab_parse.c -+++ b/libmount/src/tab_parse.c -@@ -227,11 +227,6 @@ static int mnt_parse_mountinfo_line(struct libmnt_fs *fs, const char *s) - goto fail; - } - -- /* remove "\040(deleted)" suffix */ -- p = (char *) endswith(fs->target, PATH_DELETED_SUFFIX); -- if (p && *p) -- *p = '\0'; -- - s = skip_separator(s); - - /* (6) vfs options (fs-independent) */ -diff --git a/tests/expected/findmnt/filter-options b/tests/expected/findmnt/filter-options -index 2606bce76..97b0ead0a 100644 ---- a/tests/expected/findmnt/filter-options -+++ b/tests/expected/findmnt/filter-options -@@ -28,5 +28,4 @@ TARGET SOURCE FSTYPE OPTIONS - /home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - /var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime - /mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --/mnt/foo /fooooo bar rw,relatime - rc=0 -diff --git a/tests/expected/findmnt/filter-options-nameval-neg b/tests/expected/findmnt/filter-options-nameval-neg -index 5471d65af..f0467ef75 100644 ---- a/tests/expected/findmnt/filter-options-nameval-neg -+++ b/tests/expected/findmnt/filter-options-nameval-neg -@@ -29,6 +29,5 @@ TARGET SOURCE FSTYPE OPTIO - |-/home/kzak /dev/mapper/kzak-home ext4 rw,noatime,barrier=1,data=ordered - | `-/home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - |-/var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime --|-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --`-/mnt/foo /fooooo bar rw,relatime -+`-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 - rc=0 -diff --git a/tests/expected/findmnt/filter-types-neg b/tests/expected/findmnt/filter-types-neg -index 2606bce76..97b0ead0a 100644 ---- a/tests/expected/findmnt/filter-types-neg -+++ b/tests/expected/findmnt/filter-types-neg -@@ -28,5 +28,4 @@ TARGET SOURCE FSTYPE OPTIONS - /home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - /var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime - /mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --/mnt/foo /fooooo bar rw,relatime - rc=0 -diff --git a/tests/expected/findmnt/outputs-default b/tests/expected/findmnt/outputs-default -index 59495797b..01599355e 100644 ---- a/tests/expected/findmnt/outputs-default -+++ b/tests/expected/findmnt/outputs-default -@@ -30,6 +30,5 @@ TARGET SOURCE FSTYPE OPTIO - |-/home/kzak /dev/mapper/kzak-home ext4 rw,noatime,barrier=1,data=ordered - | `-/home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - |-/var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime --|-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --`-/mnt/foo /fooooo bar rw,relatime -+`-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 - rc=0 -diff --git a/tests/expected/findmnt/outputs-force-tree b/tests/expected/findmnt/outputs-force-tree -index 59495797b..01599355e 100644 ---- a/tests/expected/findmnt/outputs-force-tree -+++ b/tests/expected/findmnt/outputs-force-tree -@@ -30,6 +30,5 @@ TARGET SOURCE FSTYPE OPTIO - |-/home/kzak /dev/mapper/kzak-home ext4 rw,noatime,barrier=1,data=ordered - | `-/home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - |-/var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime --|-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --`-/mnt/foo /fooooo bar rw,relatime -+`-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 - rc=0 -diff --git a/tests/expected/findmnt/outputs-kernel b/tests/expected/findmnt/outputs-kernel -index 59495797b..01599355e 100644 ---- a/tests/expected/findmnt/outputs-kernel -+++ b/tests/expected/findmnt/outputs-kernel -@@ -30,6 +30,5 @@ TARGET SOURCE FSTYPE OPTIO - |-/home/kzak /dev/mapper/kzak-home ext4 rw,noatime,barrier=1,data=ordered - | `-/home/kzak/.gvfs gvfs-fuse-daemon fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=500,group_id=500 - |-/var/lib/nfs/rpc_pipefs sunrpc rpc_pipefs rw,relatime --|-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --`-/mnt/foo /fooooo bar rw,relatime -+`-/mnt/sounds //foo.home/bar/ cifs rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 - rc=0 -diff --git a/tests/expected/libmount/tabdiff-mount b/tests/expected/libmount/tabdiff-mount -index 420aeacd5..3c18f8dc4 100644 ---- a/tests/expected/libmount/tabdiff-mount -+++ b/tests/expected/libmount/tabdiff-mount -@@ -1,3 +1,2 @@ - /dev/mapper/kzak-home on /home/kzak: MOUNTED --/fooooo on /mnt/foo: MOUNTED - tmpfs on /mnt/test/foo bar: MOUNTED -diff --git a/tests/expected/libmount/tabdiff-move b/tests/expected/libmount/tabdiff-move -index 24f9bc791..95820d93e 100644 ---- a/tests/expected/libmount/tabdiff-move -+++ b/tests/expected/libmount/tabdiff-move -@@ -1,3 +1,2 @@ - //foo.home/bar/ on /mnt/music: MOVED to /mnt/music --/fooooo on /mnt/foo: UMOUNTED - tmpfs on /mnt/test/foo bar: UMOUNTED -diff --git a/tests/expected/libmount/tabdiff-remount b/tests/expected/libmount/tabdiff-remount -index 82ebeab39..876bfd953 100644 ---- a/tests/expected/libmount/tabdiff-remount -+++ b/tests/expected/libmount/tabdiff-remount -@@ -1,4 +1,3 @@ - /dev/mapper/kzak-home on /home/kzak: REMOUNTED from 'rw,noatime,barrier=1,data=ordered' to 'ro,noatime,barrier=1,data=ordered' - //foo.home/bar/ on /mnt/sounds: REMOUNTED from 'rw,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344' to 'ro,relatime,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344' --/fooooo on /mnt/foo: UMOUNTED - tmpfs on /mnt/test/foo bar: UMOUNTED -diff --git a/tests/expected/libmount/tabdiff-umount b/tests/expected/libmount/tabdiff-umount -index a3e0fe48a..c7be725b9 100644 ---- a/tests/expected/libmount/tabdiff-umount -+++ b/tests/expected/libmount/tabdiff-umount -@@ -1,3 +1,2 @@ - /dev/mapper/kzak-home on /home/kzak: UMOUNTED --/fooooo on /mnt/foo: UMOUNTED - tmpfs on /mnt/test/foo bar: UMOUNTED -diff --git a/tests/expected/libmount/tabfiles-parse-mountinfo b/tests/expected/libmount/tabfiles-parse-mountinfo -index 47eb77006..d5ba5248e 100644 ---- a/tests/expected/libmount/tabfiles-parse-mountinfo -+++ b/tests/expected/libmount/tabfiles-parse-mountinfo -@@ -351,17 +351,6 @@ id: 47 - parent: 20 - devno: 0:38 - ------ fs: --source: /fooooo --target: /mnt/foo --fstype: bar --optstr: rw,relatime --VFS-optstr: rw,relatime --FS-opstr: rw --root: / --id: 48 --parent: 20 --devno: 0:39 -------- fs: - source: tmpfs - target: /mnt/test/foo bar - fstype: tmpfs -diff --git a/tests/expected/libmount/tabfiles-py-parse-mountinfo b/tests/expected/libmount/tabfiles-py-parse-mountinfo -index 47eb77006..d5ba5248e 100644 ---- a/tests/expected/libmount/tabfiles-py-parse-mountinfo -+++ b/tests/expected/libmount/tabfiles-py-parse-mountinfo -@@ -351,17 +351,6 @@ id: 47 - parent: 20 - devno: 0:38 - ------ fs: --source: /fooooo --target: /mnt/foo --fstype: bar --optstr: rw,relatime --VFS-optstr: rw,relatime --FS-opstr: rw --root: / --id: 48 --parent: 20 --devno: 0:39 -------- fs: - source: tmpfs - target: /mnt/test/foo bar - fstype: tmpfs -diff --git a/tests/ts/findmnt/files/mountinfo b/tests/ts/findmnt/files/mountinfo -index 475ea1a33..ff1e664a8 100644 ---- a/tests/ts/findmnt/files/mountinfo -+++ b/tests/ts/findmnt/files/mountinfo -@@ -30,4 +30,3 @@ - 44 41 0:36 / /home/kzak/.gvfs rw,nosuid,nodev,relatime - fuse.gvfs-fuse-daemon gvfs-fuse-daemon rw,user_id=500,group_id=500 - 45 20 0:37 / /var/lib/nfs/rpc_pipefs rw,relatime - rpc_pipefs sunrpc rw - 47 20 0:38 / /mnt/sounds rw,relatime - cifs //foo.home/bar/ rw,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --48 20 0:39 / /mnt/foo\040(deleted) rw,relatime - bar /fooooo rw -diff --git a/tests/ts/findmnt/files/mountinfo-nonroot b/tests/ts/findmnt/files/mountinfo-nonroot -index e15b46701..87b421d2e 100644 ---- a/tests/ts/findmnt/files/mountinfo-nonroot -+++ b/tests/ts/findmnt/files/mountinfo-nonroot -@@ -29,4 +29,3 @@ - 44 41 0:36 / /home/kzak/.gvfs rw,nosuid,nodev,relatime - fuse.gvfs-fuse-daemon gvfs-fuse-daemon rw,user_id=500,group_id=500 - 45 20 0:37 / /var/lib/nfs/rpc_pipefs rw,relatime - rpc_pipefs sunrpc rw - 47 20 0:38 / /mnt/sounds rw,relatime - cifs //foo.home/bar/ rw,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --48 20 0:39 / /mnt/foo\040(deleted) rw,relatime - bar /fooooo rw -diff --git a/tests/ts/libmount/files/mountinfo b/tests/ts/libmount/files/mountinfo -index c06307183..2b0174048 100644 ---- a/tests/ts/libmount/files/mountinfo -+++ b/tests/ts/libmount/files/mountinfo -@@ -30,5 +30,4 @@ - 44 41 0:36 / /home/kzak/.gvfs rw,nosuid,nodev,relatime - fuse.gvfs-fuse-daemon gvfs-fuse-daemon rw,user_id=500,group_id=500 - 45 20 0:37 / /var/lib/nfs/rpc_pipefs rw,relatime - rpc_pipefs sunrpc rw - 47 20 0:38 / /mnt/sounds rw,relatime - cifs //foo.home/bar/ rw,unc=\\foo.home\bar,username=kzak,domain=SRGROUP,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.111.1,posixpaths,serverino,acl,rsize=16384,wsize=57344 --48 20 0:39 / /mnt/foo\040(deleted) rw,relatime - bar /fooooo rw - 49 20 0:56 / /mnt/test/foo bar rw,relatime shared:323 - tmpfs tmpfs rw --- -2.34.0 - diff --git a/gnu/packages/patches/valgrind-fix-default-debuginfo-path.patch b/gnu/packages/patches/valgrind-fix-default-debuginfo-path.patch deleted file mode 100644 index f78dec02dc..0000000000 --- a/gnu/packages/patches/valgrind-fix-default-debuginfo-path.patch +++ /dev/null @@ -1,100 +0,0 @@ -From a7f17b57a94e9cde6d7fa96ac86be5c4fc4f9211 Mon Sep 17 00:00:00 2001 -From: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> -Date: Sun, 24 Apr 2022 22:20:50 +0200 -Subject: [PATCH] valgrind: fix default debuginfo path - -Description: Workaround for missing symbol in Guix's ld.so. The - correct fix (not stripping all the ld.so symbols) will be done in the - next Guix release as it requires to recompile a lot of packages. - -Forwarded: not-needed -Bug-Guix: https://issues.guix.gnu.org/54728 -Author: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> ---- - coregrind/m_debuginfo/readelf.c | 11 ++++++----- - docs/xml/manual-core-adv.xml | 4 ++-- - docs/xml/manual-core.xml | 2 +- - 3 files changed, 9 insertions(+), 8 deletions(-) - -diff --git a/coregrind/m_debuginfo/readelf.c b/coregrind/m_debuginfo/readelf.c -index c586e3f33..947fcc500 100644 ---- a/coregrind/m_debuginfo/readelf.c -+++ b/coregrind/m_debuginfo/readelf.c -@@ -1509,9 +1509,9 @@ DiImage* find_debug_file( struct _DebugInfo* di, - - if (buildid != NULL) { - debugpath = ML_(dinfo_zalloc)("di.fdf.1", -- VG_(strlen)(buildid) + 33); -+ VG_(strlen)(buildid) + DEBUGPATH_EXTRA_BYTES_1); - -- VG_(sprintf)(debugpath, "/usr/lib/debug/.build-id/%c%c/%s.debug", -+ VG_(sprintf)(debugpath, "DEFAULT_DEBUGINFO_PATH/.build-id/%c%c/%s.debug", - buildid[0], buildid[1], buildid + 2); - - dimg = open_debug_file(debugpath, buildid, 0, rel_ok, NULL); -@@ -1536,7 +1536,8 @@ DiImage* find_debug_file( struct _DebugInfo* di, - - debugpath = ML_(dinfo_zalloc)( - "di.fdf.3", -- VG_(strlen)(objdir) + VG_(strlen)(debugname) + 64 -+ VG_(strlen)(objdir) + VG_(strlen)(debugname) -+ + VG_(strlen)("DEFAULT_DEBUGINFO_PATH/") + 1 - + (extrapath ? VG_(strlen)(extrapath) : 0) - + (serverpath ? VG_(strlen)(serverpath) : 0)); - -@@ -1561,7 +1562,7 @@ DiImage* find_debug_file( struct _DebugInfo* di, - - TRY_OBJDIR_USRMERGE_OBJDIR("%s/%s"); - TRY_OBJDIR_USRMERGE_OBJDIR("%s/.debug/%s"); -- TRY_OBJDIR_USRMERGE_OBJDIR("/usr/lib/debug%s/%s"); -+ TRY_OBJDIR_USRMERGE_OBJDIR("DEFAULT_DEBUGINFO_PATH%s/%s"); - - if (extrapath) { - TRY_OBJDIR("%s%s/%s", extrapath, objdir, debugname); -@@ -1631,7 +1632,7 @@ DiImage* find_debug_file_ad_hoc( const DebugInfo* di, - - debugpath = ML_(dinfo_zalloc)( - "di.fdfah.3", -- VG_(strlen)(objdir) + 64 -+ VG_(strlen)(objdir) + DEBUGPATH_EXTRA_BYTES_2 - + (extrapath ? VG_(strlen)(extrapath) : 0) - + (serverpath ? VG_(strlen)(serverpath) : 0)); - -diff --git a/docs/xml/manual-core-adv.xml b/docs/xml/manual-core-adv.xml -index 1fa801edc..a7c01d5e6 100644 ---- a/docs/xml/manual-core-adv.xml -+++ b/docs/xml/manual-core-adv.xml -@@ -447,7 +447,7 @@ Valgrind embedded gdbserver:</para> - Remote debugging using | vgdb - relaying data between gdb and process 2418 - Reading symbols from /lib/ld-linux.so.2...done. --Reading symbols from /usr/lib/debug/lib/ld-2.11.2.so.debug...done. -+Reading symbols from DEFAULT_DEBUGINFO_PATH/lib/ld-2.11.2.so.debug...done. - Loaded symbols for /lib/ld-linux.so.2 - [Switching to Thread 2418] - 0x001f2850 in _start () from /lib/ld-linux.so.2 -@@ -475,7 +475,7 @@ Remote communication error: Resource temporarily unavailable. - Remote debugging using | vgdb --pid=2479 - relaying data between gdb and process 2479 - Reading symbols from /lib/ld-linux.so.2...done. --Reading symbols from /usr/lib/debug/lib/ld-2.11.2.so.debug...done. -+Reading symbols from DEFAULT_DEBUGINFO_PATH/lib/ld-2.11.2.so.debug...done. - Loaded symbols for /lib/ld-linux.so.2 - [Switching to Thread 2479] - 0x001f2850 in _start () from /lib/ld-linux.so.2 -diff --git a/docs/xml/manual-core.xml b/docs/xml/manual-core.xml -index dc33e1269..f6eb60086 100644 ---- a/docs/xml/manual-core.xml -+++ b/docs/xml/manual-core.xml -@@ -1409,7 +1409,7 @@ that can report errors, e.g. Memcheck, but not Cachegrind.</para> - <listitem> - <para>By default Valgrind searches in several well-known paths - for debug objects, such -- as <computeroutput>/usr/lib/debug/</computeroutput>.</para> -+ as <computeroutput>DEFAULT_DEBUGINFO_PATH/</computeroutput>.</para> - - <para>However, there may be scenarios where you may wish to put - debug objects at an arbitrary location, such as external storage --- -2.35.1 - diff --git a/gnu/packages/patches/zig-do-not-link-against-librt.patch b/gnu/packages/patches/zig-do-not-link-against-librt.patch new file mode 100644 index 0000000000..3239efbdd4 --- /dev/null +++ b/gnu/packages/patches/zig-do-not-link-against-librt.patch @@ -0,0 +1,10 @@ +--- a/src/target.zig 2023-04-22 11:44:47.917416658 +0200 ++++ b/src/target.zig 2023-04-22 11:45:04.577465352 +0200 +@@ -478,7 +478,6 @@ + "-lpthread", + "-lc", + "-ldl", +- "-lrt", + "-lutil", + }, + }, diff --git a/gnu/packages/patches/zsh-egrep-failing-test.patch b/gnu/packages/patches/zsh-egrep-failing-test.patch new file mode 100644 index 0000000000..10828ca6bb --- /dev/null +++ b/gnu/packages/patches/zsh-egrep-failing-test.patch @@ -0,0 +1,11 @@ +--- a/Test/E01options.ztst 2023-03-30 21:34:12.372309112 +0200 ++++ b/Test/E01options.ztst 2023-03-30 21:34:33.212335339 +0200 +@@ -649,7 +649,7 @@ + >noktarg1 + >0 1 + +- showopt() { setopt | egrep 'localoptions|ksharrays'; } ++ showopt() { setopt | grep -E 'localoptions|ksharrays'; } + f1() { setopt localoptions ksharrays; showopt } + f2() { setopt ksharrays; showopt } + setopt kshoptionprint diff --git a/gnu/packages/pciutils.scm b/gnu/packages/pciutils.scm index ec6bb76d5d..741dcdf787 100644 --- a/gnu/packages/pciutils.scm +++ b/gnu/packages/pciutils.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2022 Brendan Tildesley <mail@brendan.scot> +;;; Copyright © 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -80,20 +81,24 @@ Each database is contained in a specific package output, such as the (define-public pciutils (package (name "pciutils") - (version "3.7.0") + (version "3.8.0") (source (origin (method url-fetch) (uri (string-append "mirror://kernel.org/software/utils/pciutils/pciutils-" version ".tar.xz")) - (patches (search-patches "pciutils-hurd-configure.patch")) (sha256 (base32 - "1ss0rnfsx8gvqjxaji4mvbhf9xyih4cadmgadbwwv8mnx1xvjh4x")))) + "01aglgw9ds9qiswcbi2lx90lswncikrlyv8mmp4haix8542bvvci")))) (build-system gnu-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'unbundle-pci.ids + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (copy-file (search-input-file (or native-inputs inputs) + "share/hwdata/pci.ids") + "pci.ids"))) (replace 'configure (lambda* (#:key outputs #:allow-other-keys) ;; There's no 'configure' script, just a raw makefile. @@ -116,50 +121,50 @@ Each database is contained in a specific package output, such as the (string-append "PREFIX := " (assoc-ref outputs "out") "\n")) (("^MANDIR:=.*$") - ;; By default the thing tries to automatically - ;; determine whether to use $prefix/man or - ;; $prefix/share/man, and wrongly so. + ;; By default the thing tries to automatically + ;; determine whether to use $prefix/man or + ;; $prefix/share/man, and wrongly so. (string-append "MANDIR := " (assoc-ref outputs "out") "/share/man\n")) (("^SHARED=.*$") ;; Build libpciutils.so. "SHARED := yes\n") + (("^ZLIB=.*$") ;; Ask for zlib support, for 'pci.ids.gz' decompression. "ZLIB := yes\n") (("^IDSDIR=.*$") ;; Installation directory of 'pci.ids.gz'. - "IDSDIR = $(SHAREDIR)/hwdata\n")))) + "IDSDIR = $(SHAREDIR)/hwdata\n") + + ;; Do not install the update script nor its man page. + ((".*INSTALL.*update-pciids .*") "") + (("update-pciids update-pciids.8 ") "") + (("(.*INSTALL.*)update-pciids.8(.*)" _ head tail) + (string-append head tail))))) (replace 'install (lambda* (#:key outputs #:allow-other-keys) ;; Install the commands, library, and .pc files. - (invoke "make" "install" "install-lib"))) - - ,@(if (hurd-target?) - '((add-after 'unpack 'apply-hurd-patch - (lambda* (#:key inputs #:allow-other-keys) - (let ((patch (assoc-ref inputs "hurd-patch"))) - (invoke "patch" "-p1" "--batch" "-i" - patch))))) - '())) + (invoke "make" "install" "install-lib")))) ;; Make sure programs have an RPATH so they can find libpciutils.so. - #:make-flags (list (string-append "LDFLAGS=-Wl,-rpath=" + #:make-flags (list ,(string-append "CC=" + (if (%current-target-system) + (cc-for-target) + "gcc")) + (string-append "LDFLAGS=-Wl,-rpath=" (assoc-ref %outputs "out") "/lib")) ;; No test suite. #:tests? #f)) (native-inputs - (list which pkg-config)) + (list `(,hwdata "pci") pkg-config which)) (inputs `(,@(if (not (hurd-target?)) `(("kmod" ,kmod)) '()) - ,@(if (hurd-target?) - `(("hurd-patch" ,(search-patch "pciutils-hurd-fix.patch"))) - '()) ("zlib" ,zlib))) (home-page "https://mj.ucw.cz/sw/pciutils/") (synopsis "Programs for inspecting and manipulating PCI devices") diff --git a/gnu/packages/pcre.scm b/gnu/packages/pcre.scm index fdc86e5047..7c53a27685 100644 --- a/gnu/packages/pcre.scm +++ b/gnu/packages/pcre.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> -;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2017, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2017, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> @@ -33,99 +33,102 @@ #:use-module (guix utils) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix build-system gnu)) (define-public pcre (package - (name "pcre") - (version "8.45") - (source (origin - (method url-fetch) - (uri (string-append "mirror://sourceforge/pcre/pcre/" - version "/pcre-" version ".tar.bz2")) - (sha256 - (base32 - "1f7zichy6iimmkfrqdl575sdlm795cyc75szgg1vc2xvsbf6zbjd")))) - (build-system gnu-build-system) - (outputs '("out" ;library & headers - "bin" ;depends on Readline (adds 20MiB to the closure) - "doc" ;1.8 MiB of HTML - "static")) ;1.8 MiB static libraries - (inputs (list bzip2 readline zlib)) - (arguments - `(#:disallowed-references ("doc") - #:configure-flags '("--enable-utf" - "--enable-pcregrep-libz" - "--enable-pcregrep-libbz2" - "--enable-pcretest-libreadline" - "--enable-unicode-properties" - "--enable-pcre16" - "--enable-pcre32" - ;; pcretest fails on powerpc32. - ;; riscv64-linux is an unsupported architecture. - ,@(if (or (target-ppc32?) - (target-riscv64?)) - '() - `("--enable-jit"))) - #:phases (modify-phases %standard-phases - (add-after 'install 'move-static-libs - (lambda* (#:key outputs #:allow-other-keys) - (let ((source (string-append (assoc-ref outputs "out") "/lib")) - (static (string-append (assoc-ref outputs "static") "/lib"))) - (mkdir-p static) - (for-each (lambda (lib) - (link lib (string-append static "/" - (basename lib))) - (delete-file lib)) - (find-files source "\\.a$")))))))) - (synopsis "Perl Compatible Regular Expressions") - (description - "The PCRE library is a set of functions that implement regular expression + (name "pcre") + (version "8.45") + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/pcre/pcre/" + version "/pcre-" version ".tar.bz2")) + (sha256 + (base32 + "1f7zichy6iimmkfrqdl575sdlm795cyc75szgg1vc2xvsbf6zbjd")))) + (build-system gnu-build-system) + (outputs '("out" ;library & headers + "bin" ;depends on Readline (adds 20MiB to the closure) + "doc" ;1.8 MiB of HTML + "static")) ;1.8 MiB static libraries + (inputs (list bzip2 readline zlib)) + (arguments + (list + #:disallowed-references '("doc") + #:configure-flags #~'("--enable-utf" + "--enable-pcregrep-libz" + "--enable-pcregrep-libbz2" + "--enable-pcretest-libreadline" + "--enable-unicode-properties" + "--enable-pcre16" + "--enable-pcre32" + ;; pcretest fails on powerpc32. + ;; riscv64-linux is an unsupported architecture. + #$@(if (or (target-ppc32?) (target-riscv64?)) + #~() + #~("--enable-jit"))) + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'move-static-libs + (lambda _ + (let ((source (string-append #$output "/lib")) + (static (string-append #$output:static "/lib"))) + (mkdir-p static) + (for-each (lambda (lib) + (link lib (string-append static "/" + (basename lib))) + (delete-file lib)) + (find-files source "\\.a$")))))))) + (synopsis "Perl Compatible Regular Expressions") + (description + "The PCRE library is a set of functions that implement regular expression pattern matching using the same syntax and semantics as Perl 5. PCRE has its own native API, as well as a set of wrapper functions that correspond to the POSIX regular expression API.") - (license license:bsd-3) - (home-page "https://www.pcre.org/"))) + (license license:bsd-3) + (home-page "https://www.pcre.org/"))) (define-public pcre2 (package (name "pcre2") - (version "10.37") + (version "10.40") (source (origin (method url-fetch) - (uri (string-append "mirror://sourceforge/pcre/pcre2/" - version "/pcre2-" version ".tar.bz2")) + (uri (string-append "https://github.com/PCRE2Project/pcre2" + "/releases/download/pcre2-" version + "/pcre2-" version ".tar.bz2")) (sha256 (base32 - "0w6jaswjmg3bc0wsw6msn5bvk66p90kf2asnnj9rhll0idpak5ad")))) - (build-system gnu-build-system) - (inputs (list bzip2 readline zlib)) - (arguments - `(#:configure-flags '("--enable-unicode" - "--enable-pcre2grep-libz" - "--enable-pcre2grep-libbz2" - "--enable-pcre2test-libreadline" - "--enable-pcre2-16" - "--enable-pcre2-32" - ;; pcre2_jit_test fails on powerpc32. - ;; riscv64-linux is an unsupported architecture. - ,@(if (or (target-ppc32?) - (target-riscv64?)) - '() - `("--enable-jit")) - "--disable-static") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-paths - (lambda _ - (substitute* "RunGrepTest" - (("/bin/echo") (which "echo")))))))) - (synopsis "Perl Compatible Regular Expressions") - (description - "The PCRE library is a set of functions that implement regular expression + "0s4x2l6g0sb9piwkr3sxqwdswz2g6bk1hhwngv0kv4w38wybir0l")))) + (build-system gnu-build-system) + (inputs (list bzip2 readline zlib)) + (arguments + (list #:configure-flags + #~'("--enable-unicode" + "--enable-pcre2grep-libz" + "--enable-pcre2grep-libbz2" + "--enable-pcre2test-libreadline" + "--enable-pcre2-16" + "--enable-pcre2-32" + ;; pcre2_jit_test fails on powerpc32. + ;; riscv64-linux is an unsupported architecture. + #$@(if (or (target-ppc32?) (target-riscv64?)) + #~() + #~("--enable-jit")) + "--disable-static") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-paths + (lambda _ + (substitute* "RunGrepTest" + (("/bin/echo") (which "echo")))))))) + (synopsis "Perl Compatible Regular Expressions") + (description + "The PCRE library is a set of functions that implement regular expression pattern matching using the same syntax and semantics as Perl 5. PCRE has its own native API, as well as a set of wrapper functions that correspond to the POSIX regular expression API.") - (license license:bsd-3) - (home-page "https://www.pcre.org/"))) + (license license:bsd-3) + (home-page "https://www.pcre.org/"))) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index 17637af0f6..ff7d895774 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -20,7 +20,7 @@ ;;; Copyright © 2020-2022 Nicolas Goaziou <mail@nicolasgoaziou.fr> ;;; Copyright © 2020, 2022 Michael Rohleder <mike@rohleder.de> ;;; Copyright © 2020 Timotej Lazar <timotej.lazar@araneo.si> -;;; Copyright © 2020, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com> ;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com> @@ -84,6 +84,7 @@ #:use-module (gnu packages lua) #:use-module (gnu packages man) #:use-module (gnu packages markup) + #:use-module (gnu packages nss) #:use-module (gnu packages ocr) #:use-module (gnu packages pcre) #:use-module (gnu packages perl) @@ -286,29 +287,30 @@ please install the @code{flyer-composer-gui} package."))) (define-public poppler (package (name "poppler") - (version "21.07.0") + (version "22.09.0") (source (origin (method url-fetch) (uri (string-append "https://poppler.freedesktop.org/poppler-" version ".tar.xz")) (sha256 (base32 - "1m54hsi8z6c13jdbjwz55flkra1mahmkw2igavbf8p86d2gv4sp2")))) + "0bhyli95h3dkirjc0ibh08s4nim6rn7f38sbfzdwln8k454gga6p")))) (build-system cmake-build-system) ;; FIXME: ;; use libcurl: no - (inputs `(("fontconfig" ,fontconfig) - ("freetype" ,freetype) - ("libjpeg" ,libjpeg-turbo) - ("libpng" ,libpng) - ("libtiff" ,libtiff) - ("lcms" ,lcms) - ("openjpeg" ,openjpeg) - ("zlib" ,zlib) - - ;; To build poppler-glib (as needed by Evince), we need Cairo and - ;; GLib. But of course, that Cairo must not depend on Poppler. - ("cairo" ,cairo-sans-poppler))) + (inputs (list fontconfig + freetype + libjpeg-turbo + libpng + libtiff + lcms + nss ;for 'pdfsig' + openjpeg + poppler-data + zlib + ;; To build poppler-glib (as needed by Evince), we need Cairo and + ;; GLib. But of course, that Cairo must not depend on Poppler. + cairo-sans-poppler)) (propagated-inputs ;; As per poppler-cairo and poppler-glib.pc. ;; XXX: Ideally we'd propagate Cairo too, but that would require a @@ -317,24 +319,26 @@ please install the @code{flyer-composer-gui} package."))) (native-inputs (list pkg-config `(,glib "bin") ; glib-mkenums, etc. - gobject-introspection)) + gobject-introspection + python)) (arguments - `(#:tests? #f ;no test data provided with the tarball - #:configure-flags - (let* ((out (assoc-ref %outputs "out")) - (lib (string-append out "/lib"))) - (list "-DENABLE_UNSTABLE_API_ABI_HEADERS=ON" ;to install header files - "-DENABLE_ZLIB=ON" - "-DENABLE_BOOST=OFF" ;disable Boost to save size - (string-append "-DCMAKE_INSTALL_LIBDIR=" lib) - (string-append "-DCMAKE_INSTALL_RPATH=" lib))) - ,@(if (%current-target-system) - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'set-PKG_CONFIG - (lambda _ - (setenv "PKG_CONFIG" ,(pkg-config-for-target)))))) - '()))) + (list + ;; The Poppler test suite needs to be downloaded separately and contains + ;; non-free (and non-auditable) files, so we skip them. See + ;; <https://lists.gnu.org/archive/html/guix-devel/2022-06/msg00394.html>. + #:tests? #f + #:configure-flags + #~(list "-DENABLE_UNSTABLE_API_ABI_HEADERS=ON" ;to install header files + "-DENABLE_ZLIB=ON" + "-DENABLE_BOOST=OFF" ;disable Boost to save size + (string-append "-DCMAKE_INSTALL_LIBDIR=" #$output "/lib") + (string-append "-DCMAKE_INSTALL_RPATH=" #$output "/lib")) + #:phases + (if (%current-target-system) #~%standard-phases + #~(modify-phases %standard-phases + (add-after 'unpack 'set-PKG_CONFIG + (lambda _ + (setenv "PKG_CONFIG" #$(pkg-config-for-target)))))))) (synopsis "PDF rendering library") (description "Poppler is a PDF rendering library based on the xpdf-3.0 code base.") @@ -371,26 +375,6 @@ When present, Poppler is able to correctly render CJK and Cyrillic text.") (license (list license:bsd-3 license:gpl2)))) -;; XXX: Remove it on core-updates. It is only needed for evince 42.3 that -;; requires a recent poppler. -(define-public poppler-next - (package - (inherit poppler) - (name "poppler-next") - (version "22.09.0") - (source (origin - (method url-fetch) - (uri (string-append "https://poppler.freedesktop.org/poppler-" - version ".tar.xz")) - (sha256 - (base32 - "0bhyli95h3dkirjc0ibh08s4nim6rn7f38sbfzdwln8k454gga6p")))) - (native-inputs - (list pkg-config - `(,glib "bin") ; glib-mkenums, etc. - gobject-introspection - python)) )) - (define-public poppler-qt5 (package/inherit poppler (name "poppler-qt5") @@ -899,52 +883,34 @@ line tools for batch rendering @command{pdfdraw}, rewriting files (define-public qpdf (package - (name "qpdf") - (version "10.0.1") - (source (origin - (method url-fetch) - (uri (string-append "mirror://sourceforge/qpdf/qpdf/" version - "/qpdf-" version ".tar.gz")) - (sha256 - (base32 - "0yw2cpw7ygfd6jlgpwbi8vsnvv9p55zxp9h17x77z2qq733pf8jx")))) - (build-system gnu-build-system) - (arguments - `(#:configure-flags '(,@(if (%current-target-system) - ;; We cannot check for these devices - ;; when cross compiling. - `("ac_cv_file__dev_random=yes" - "ac_cv_file__dev_urandom=yes") - '())) - #:disallowed-references (,perl) - #:phases - (modify-phases %standard-phases - (add-before 'configure 'patch-paths - (lambda _ - (substitute* "make/libtool.mk" - (("SHELL=/bin/bash") - (string-append "SHELL=" (which "bash")))) - (substitute* (append - '("qtest/bin/qtest-driver") - (find-files "." "\\.test")) - (("/usr/bin/env") (which "env"))) - #t))))) - (native-inputs - (list pkg-config perl)) - (propagated-inputs - ;; In Requires.private of libqpdf.pc. - (list libjpeg-turbo zlib)) - (synopsis "Command-line tools and library for transforming PDF files") - (description - "QPDF is a command-line program that does structural, content-preserving + (name "qpdf") + (version "11.1.0") + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/qpdf/qpdf/" version + "/qpdf-" version ".tar.gz")) + (sha256 + (base32 + "0bg2d4585nxss2zakq105ibhzzsa1bhwpmr0k8752fg2qqxcz9rl")))) + (build-system cmake-build-system) + (arguments + (list #:configure-flags #~'("-DBUILD_STATIC_LIBS=OFF"))) + (native-inputs + (list perl pkg-config)) + (propagated-inputs + ;; In Requires.private of libqpdf.pc. + (list libjpeg-turbo zlib)) + (synopsis "Command-line tools and library for transforming PDF files") + (description + "QPDF is a command-line program that does structural, content-preserving transformations on PDF files. It could have been called something like pdf-to-pdf. It includes support for merging and splitting PDFs and to manipulate the list of pages in a PDF file. It is not a PDF viewer or a program capable of converting PDF into other formats.") - ;; Prior to the 7.0 release, QPDF was licensed under Artistic 2.0. - ;; Users can still choose to use the old license at their option. - (license (list license:asl2.0 license:clarified-artistic)) - (home-page "https://qpdf.sourceforge.net/"))) + ;; Prior to the 7.0 release, QPDF was licensed under Artistic 2.0. + ;; Users can still choose to use the old license at their option. + (license (list license:asl2.0 license:clarified-artistic)) + (home-page "https://qpdf.sourceforge.net/"))) (define-public qpdfview (package @@ -1649,7 +1615,7 @@ manipulating PDF documents from the command line. It supports python-cairosvg python-cffi python-cssselect2 - python-fonttools-full + python-fonttools python-html5lib python-pillow python-pydyf diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm index 335e08d146..4fa061362e 100644 --- a/gnu/packages/perl.scm +++ b/gnu/packages/perl.scm @@ -106,14 +106,14 @@ ;; Yeah, Perl... It is required early in the bootstrap process by Linux. (package (name "perl") - (version "5.34.0") + (version "5.36.0") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/src/5.0/perl-" version ".tar.gz")) (sha256 (base32 - "16mywn5afpv1mczv9dlc1w84rbgjgrr0pyr4c0hhb2wnif0zq7jm")) + "02p0ljvxgay5g8s8j1kghdylkj581qx3qlwavlmgd5n3iapqaq72")) (patches (search-patches "perl-no-sys-dirs.patch" "perl-autosplit-default-time.patch" @@ -241,10 +241,9 @@ "/lib',\n")))) config2))))))) (inputs - (append (list coreutils-minimal) - (if (%current-target-system) - (list bash-minimal) - '()))) + (if (%current-target-system) + (list bash-minimal coreutils-minimal) + '())) (native-inputs (if (%current-target-system) `(("perl-cross" @@ -252,10 +251,10 @@ (method git-fetch) (uri (git-reference (url "https://github.com/arsv/perl-cross") - (commit "1.3.6"))) - (file-name (git-file-name "perl-cross" "1.3.6")) + (commit "1.4"))) + (file-name (git-file-name "perl-cross" "1.4")) (sha256 - (base32 "0k5vyj40czbkfl7r3dcwxpc7dvdlp2xliaav358bviq3dq9vq9bb"))))) + (base32 "1ydjvlhrk06ccyj4bm8by7xk90krsll2k380mc3x1mhfrc7r9gzy"))))) '())) (native-search-paths (list (search-path-specification (variable "PERL5LIB") diff --git a/gnu/packages/plotutils.scm b/gnu/packages/plotutils.scm index fdda6d4871..46e86158b6 100644 --- a/gnu/packages/plotutils.scm +++ b/gnu/packages/plotutils.scm @@ -312,19 +312,19 @@ colors, styles, options and details.") texlive-epsf texlive-etoolbox texlive-fonts-ec - texlive-generic-infwarerr - texlive-generic-kvdefinekeys + texlive-infwarerr + texlive-kvdefinekeys texlive-grfext texlive-hyperref texlive-latex-base texlive-latex-geometry - texlive-latex-graphics - texlive-latex-kvoptions + texlive-graphics + texlive-kvoptions texlive-latex-media9 - texlive-latex-ocgx2 - texlive-latex-pdftexcmds texlive-oberdiek ;for ifluatex + texlive-latex-ocgx2 texlive-latex-parskip + texlive-pdftexcmds texlive-tex-texinfo)))) (inputs (list bash-minimal diff --git a/gnu/packages/polkit.scm b/gnu/packages/polkit.scm index a5c1b0dc98..6fe7824a57 100644 --- a/gnu/packages/polkit.scm +++ b/gnu/packages/polkit.scm @@ -8,9 +8,9 @@ ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2021 Morgan Smith <Morgan.J.Smith@outlook.com> -;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech> ;;; Copyright © 2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -28,11 +28,11 @@ ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. (define-module (gnu packages polkit) - #:use-module ((guix licenses) #:select (lgpl2.0+)) - #:use-module (guix packages) - #:use-module (guix gexp) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix memoization) + #:use-module ((guix licenses) #:select (lgpl2.0+)) + #:use-module (guix packages) #:use-module (guix utils) #:use-module (guix build utils) #:use-module (guix build-system cmake) @@ -40,92 +40,130 @@ #:use-module (guix build-system meson) #:use-module (gnu packages) #:use-module (gnu packages gettext) + #:use-module (gnu packages docker) #:use-module (gnu packages freedesktop) #:use-module (gnu packages glib) #:use-module (gnu packages gtk) #:use-module (gnu packages docbook) - #:use-module (gnu packages gnuzilla) #:use-module (gnu packages javascript) #:use-module (gnu packages linux) #:use-module (gnu packages nss) #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) + #:use-module (gnu packages python) + #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) - #:use-module (gnu packages xml) - #:export (polkit)) + #:use-module (gnu packages xml)) -(define-public polkit-mozjs +(define-public polkit (package (name "polkit") (version "121") (source (origin - (method url-fetch) - (uri (string-append - "https://www.freedesktop.org/software/polkit/releases/" - name "-" version ".tar.gz")) - (patches (search-patches "polkit-disable-systemd.patch")) - (sha256 - (base32 - "1apz3bh7nbpmlp1cr00pb8z8wp0c7yb23ninb959jz3r38saxiwx")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Disable a test that requires Python, D-Bus and a few - ;; libraries and fails with "ERROR: timed out waiting for bus - ;; process to terminate". - (substitute* "test/meson.build" - (("subdir\\('polkitbackend'\\)") - "")) - ;; Look up actions and rules from /etc/polkit ... - (substitute* "src/polkitbackend/meson.build" - (("'-DPACKAGE_SYSCONF_DIR=.*,") - "'-DPACKAGE_SYSCONF_DIR=\"/etc\"',")) - (substitute* "src/polkitbackend/polkitbackendinteractiveauthority.c" - (("PACKAGE_DATA_DIR \"/polkit-1/actions\"") - "PACKAGE_SYSCONF_DIR \"/polkit-1/actions\"")) - ;; ... but install package files below the prefix. - (substitute* "meson.build" - (("pk_sysconfdir = get_option\\('sysconfdir'\\)") - "pk_sysconfdir = get_option('prefix') + '/etc'")) - ;; Set the setuid helper's real location. - (substitute* "src/polkitagent/polkitagentsession.c" - (("PACKAGE_PREFIX \"/lib/polkit-1/polkit-agent-helper-1\"") - "\"/run/setuid-programs/polkit-agent-helper-1\"")))))) + (method url-fetch) + (uri (string-append + "https://www.freedesktop.org/software/polkit/releases/" + name "-" version ".tar.gz")) + (patches (search-patches "polkit-disable-systemd.patch")) + (sha256 + (base32 + "1apz3bh7nbpmlp1cr00pb8z8wp0c7yb23ninb959jz3r38saxiwx")) + (modules '((guix build utils))) + (snippet + '(begin + ;; This is so that the default example rules files can be + ;; installed along the package; otherwise it would fail + ;; attempting to write to /etc. Unlike with GNU Autotools, + ;; Meson can't override the pkgsysconfdir value at install + ;; time; instead, we rewrite the pkgsysconfdir references + ;; in the build system to point to #$output/etc. + ;; Look up actions and rules from /etc/polkit ... + (substitute* "src/polkitbackend/meson.build" + (("'-DPACKAGE_SYSCONF_DIR=.*,") + "'-DPACKAGE_SYSCONF_DIR=\"/etc\"',")) + (substitute* "src/polkitbackend/polkitbackendinteractiveauthority.c" + (("PACKAGE_DATA_DIR \"/polkit-1/actions\"") + "PACKAGE_SYSCONF_DIR \"/polkit-1/actions\"")) + ;; ... but install package files below the prefix. + (substitute* "meson.build" + (("pk_sysconfdir = get_option\\('sysconfdir'\\)") + "pk_sysconfdir = get_option('prefix') + '/etc'")) + ;; Set the setuid helper's real location. + (substitute* "src/polkitagent/polkitagentsession.c" + (("PACKAGE_PREFIX \"/lib/polkit-1/polkit-agent-helper-1\"") + "\"/run/setuid-programs/polkit-agent-helper-1\"")))))) (build-system meson-build-system) + (arguments + (list + #:imported-modules `(,@%meson-build-system-modules + (guix build syscalls)) + #:modules '((guix build meson-build-system) + (guix build syscalls) + (guix build utils) + (ice-9 match)) + #:configure-flags + #~(list "--sysconfdir=/etc" + "-Dsession_tracking=libelogind" + "-Dman=true" + "-Dtests=true" + ;; Work around cross-compilation failure. The build system + ;; probes for the _target_ gobject-introspection, but if we + ;; change it to native, Meson fails with: + ;; ERROR: Pkg-config binary for machine + ;; MachineChoice.BUILD not found, giving up. + ;; Just disable introspection for now. + #$@(if (%current-target-system) + '("-Dintrospection=false") + '())) + #:phases + #~(modify-phases %standard-phases + (add-before 'check 'patch-bash + (lambda _ + (substitute* (list "subprojects/mocklibc-1.0/bin/mocklibc" + (string-append "../polkit-v." #$version + "/test/data/etc/passwd") + (string-append "../polkit-v." #$version + "/test/data/etc/polkit-1" + "/rules.d/10-testing.rules")) + (("/bin/(bash|false|true)" _ command) + (which command))))) + (replace 'check + (lambda* (#:key tests? test-options #:allow-other-keys) + (when tests? + ;; Run the test suite through tini to ensure signals are + ;; properly handled and zombie processes reaped. + (match (primitive-fork) + (0 ;child process + (set-child-subreaper!) + ;; Use tini so that signals are properly handled and + ;; doubly-forked processes get reaped; otherwise, + ;; python-dbusmock would waste time polling for the dbus + ;; processes it spawns to be reaped, in vain. + (apply execlp "tini" "--" + "meson" "--" "test" "-t" "0" "--print-errorlogs" + test-options)) + (pid + (match (waitpid pid) + ((_ . status) + (unless (zero? status) + (error "`meson test' exited with status" + status)))))))))))) (inputs - (list elogind - expat - linux-pam - mozjs-91 - nspr)) + (list duktape expat elogind linux-pam nspr)) (propagated-inputs (list glib)) ;required by polkit-gobject-1.pc (native-inputs - (list pkg-config - gettext-minimal - perl + (list gettext-minimal `(,glib "bin") ;for glib-mkenums + docbook-xsl ;for man page generation gobject-introspection - libxml2 ;for man page generation + libxml2 ;for XML_CATALOG_FILES libxslt ;for man page generation - docbook-xsl)) ;for man page generation - (arguments - (list #:configure-flags - #~'("--sysconfdir=/etc" - "-Dsession_tracking=libelogind" - "-Dman=true" - "-Dtests=true" - "-Djs_engine=mozjs" - ;; Work around broken gobject-introspection detection when - ;; cross-compiling. The build system probes for the _target_ - ;; gobject-introspection, but if we change it to native, Meson - ;; fails with: - ;; ERROR: Pkg-config binary for machine MachineChoice.BUILD - ;; not found, giving up. - ;; Just disable introspection for now. - #$@(if (%current-target-system) - '("-Dintrospection=false") - '())))) + perl + pkg-config + python + python-dbusmock + tini)) (home-page "https://www.freedesktop.org/wiki/Software/polkit/") (synopsis "Authorization API for privilege management") (description "Polkit is an application-level toolkit for defining and @@ -135,36 +173,6 @@ making process with respect to granting access to privileged operations for unprivileged applications.") (license lgpl2.0+))) -;;; Variant of polkit built with Duktape, a lighter JavaScript engine compared -;;; to mozjs. -(define-public polkit-duktape - (let ((base polkit-mozjs)) - (package/inherit base - (name "polkit-duktape") - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:configure-flags flags) - #~(delete "-Djs_engine=mozjs" #$flags)))) - (inputs - (modify-inputs (package-inputs base) - (replace "mozjs" duktape)))))) - -(define polkit-for-system - (mlambda (system) - "Return a polkit package that can be built for SYSTEM; that is, either the -regular polkit that requires mozjs or its duktape variant." - (if (string-prefix? "x86_64" system) - polkit-mozjs - polkit-duktape))) - -;;; Define a top level polkit variable that can be built on any of the -;;; supported platforms. This is to work around the fact that our -;;; mrustc-bootstrapped rust toolchain currently only supports the x86_64 -;;; architecture. -(define-syntax polkit - (identifier-syntax (polkit-for-system - (or (%current-target-system) (%current-system))))) - (define-public polkit-qt (package (name "polkit-qt") diff --git a/gnu/packages/potassco.scm b/gnu/packages/potassco.scm index 0e6973d980..386ff62f0c 100644 --- a/gnu/packages/potassco.scm +++ b/gnu/packages/potassco.scm @@ -35,6 +35,7 @@ #:use-module (gnu packages libffi) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-xyz)) (define-public libpotassco diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm index a002378966..74e51ec61e 100644 --- a/gnu/packages/pretty-print.scm +++ b/gnu/packages/pretty-print.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> ;;; Copyright © 2021 Greg Hogan <code@greghogan.com> ;;; Copyright © 2022 Zhu Zihao <all_but_last@163.com> -;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,6 +34,7 @@ #:use-module (guix download) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages bison) @@ -274,12 +275,13 @@ a fast alternative to @code{IOStreams}.") (version "3.1.9") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnu/src-highlite/source-highlight-" - version ".tar.gz")) - (sha256 - (base32 - "148w47k3zswbxvhg83z38ifi85f9dqcpg7icvvw1cm6bg21x4zrs")))) + (method url-fetch) + (uri (string-append "mirror://gnu/src-highlite/source-highlight-" + version ".tar.gz")) + (patches (search-patches "source-highlight-gcc-compat.patch")) + (sha256 + (base32 + "148w47k3zswbxvhg83z38ifi85f9dqcpg7icvvw1cm6bg21x4zrs")))) (build-system gnu-build-system) ;; The ctags that comes with emacs does not support the --excmd options, ;; so can't be used @@ -288,39 +290,35 @@ a fast alternative to @code{IOStreams}.") (native-inputs (list bison flex)) (arguments - `(#:configure-flags - (list (string-append "--with-boost=" - (assoc-ref %build-inputs "boost"))) - #:parallel-tests? #f ;There appear to be race conditions - #:phases - (modify-phases %standard-phases - ,@(if (%current-target-system) - ;; 'doc/Makefile.am' tries to run stuff even when - ;; cross-compiling. Explicitly skip it. - ;; XXX: Inline this on next rebuild cycle. - `((add-before 'build 'skip-doc-directory - (lambda _ - (substitute* "Makefile" - (("^SUBDIRS = (.*) doc(.*)$" _ before after) - (string-append "SUBDIRS = " before - " " after "\n"))) - #t))) - '()) - (add-before 'check 'patch-test-files - (lambda _ - ;; Unpatch shebangs in test input so that source-highlight - ;; is still able to infer input language - (substitute* '("tests/test.sh" - "tests/test2.sh" - "tests/test.tcl") - (((string-append "#! *" (which "sh"))) "#!/bin/sh")) - ;; Initial patching unrecoverably removes whitespace, so - ;; remove it also in the comparison output. - (substitute* '("tests/test.sh.html" - "tests/test2.sh.html" - "tests/test.tcl.html") - (("#! */bin/sh") "#!/bin/sh")) - #t))))) + (list #:configure-flags + #~(list (string-append "--with-boost=" (assoc-ref %build-inputs "boost"))) + #:parallel-tests? #f ;There appear to be race conditions + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'rename-lesspipe-to-lesspipe.sh.in + (lambda _ + (substitute* "src/src-hilite-lesspipe.sh.in" + (("lesspipe") "lesspipe.sh")))) + (add-before 'build 'skip-doc-directory + (lambda _ + (substitute* "Makefile" + (("^SUBDIRS = (.*) doc(.*)$" _ before after) + (string-append "SUBDIRS = " before + " " after "\n"))))) + (add-before 'check 'patch-test-files + (lambda _ + ;; Unpatch shebangs in test input so that source-highlight + ;; is still able to infer input language + (substitute* '("tests/test.sh" + "tests/test2.sh" + "tests/test.tcl") + (((string-append "#! *" (which "sh"))) "#!/bin/sh")) + ;; Initial patching unrecoverably removes whitespace, so + ;; remove it also in the comparison output. + (substitute* '("tests/test.sh.html" + "tests/test2.sh.html" + "tests/test.tcl.html") + (("#! */bin/sh") "#!/bin/sh"))))))) (home-page "https://www.gnu.org/software/src-highlite/") (synopsis "Produce a document with syntax highlighting from a source file") (description diff --git a/gnu/packages/protobuf.scm b/gnu/packages/protobuf.scm index 82cf8f452d..23feef7ba5 100644 --- a/gnu/packages/protobuf.scm +++ b/gnu/packages/protobuf.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2014, 2022 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org> ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> -;;; Copyright © 2017, 2018, 2019, 2022 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2017, 2018, 2019, 2022, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net> @@ -354,7 +354,7 @@ any memory-restricted system.") (list python-grpc-stubs python-grpcio-tools python-pytest - python-typing-extensions-next)) + python-typing-extensions)) (propagated-inputs (list protobuf python-protobuf @@ -469,8 +469,19 @@ structured data.") (sha256 (base32 "04bqb12smlckzmgkj6vgmpbr3cby0n6726cmz33bqr7kn1vb728l")))) - (arguments '()) ;no "--cpp_implementation" here - (inputs (list python-six)))) + (arguments + (list + #:phases + '(modify-phases %standard-phases + (add-after 'unpack 'compatibility + (lambda _ + (substitute* '("google/protobuf/internal/containers.py" + "google/protobuf/internal/well_known_types.py") + (("collections.Mutable") + "collections.abc.Mutable"))))))) + (inputs (list python-six)) + (native-inputs + (list python-setuptools-for-tensorflow)))) (define-public python-proto-plus (package diff --git a/gnu/packages/pulseaudio.scm b/gnu/packages/pulseaudio.scm index aff864eb99..ef4f8ba8cf 100644 --- a/gnu/packages/pulseaudio.scm +++ b/gnu/packages/pulseaudio.scm @@ -15,6 +15,7 @@ ;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz> ;;; Copyright © 2020 Marius Bakke <marius@gnu.org> ;;; Copyright © 2021 Brice Waegeneire <brice@waegenei.re> +;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,6 +35,7 @@ (define-module (gnu packages pulseaudio) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix utils) #:use-module ((guix licenses) #:prefix l:) @@ -46,6 +48,7 @@ #:use-module (gnu packages) #:use-module (gnu packages algebra) #:use-module (gnu packages audio) + #:use-module (gnu packages autogen) #:use-module (gnu packages autotools) #:use-module (gnu packages avahi) #:use-module (gnu packages check) @@ -74,38 +77,27 @@ (define-public libsndfile (package (name "libsndfile") - (version "1.0.30") + (version "1.2.0") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/erikd/libsndfile" - "/releases/download/v" version - "/libsndfile-" version ".tar.bz2")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/libsndfile/libsndfile/") + (commit version))) + (file-name (git-file-name name version)) (sha256 (base32 - "06k1wj3lwm7vf21s8yqy51k6nrkn9z610bj1gxb618ag5hq77wlx")) - (modules '((ice-9 textual-ports) (guix build utils))) + "10lm5mn171ynykkvq5ad8m1zriv01w25s6hx0l3wphdd4p6f7c92")) + (modules '((guix build utils))) (snippet '(begin - ;; Remove carriage returns (CRLF) to prevent bogus - ;; errors from bash like "$'\r': command not found". - (let ((data (call-with-input-file - "tests/pedantic-header-test.sh.in" - (lambda (port) - (string-join - (string-split (get-string-all port) - #\return)))))) - (call-with-output-file "tests/pedantic-header-test.sh.in" - (lambda (port) (format port data)))) - - ;; While at it, fix hard coded executable name. + ;; Fix hard coded executable name. (substitute* "tests/test_wrapper.sh.in" - (("^/usr/bin/env") "env")) - #t)))) + (("^/usr/bin/env") "env")))))) (build-system gnu-build-system) (propagated-inputs (list flac libogg libvorbis opus)) (native-inputs - (list pkg-config python)) + (list autoconf autogen automake libtool pkg-config python)) (home-page "http://www.mega-nerd.com/libsndfile/") (synopsis "Reading and writing files containing sampled sound") (description @@ -178,57 +170,55 @@ rates.") (define-public pulseaudio (package (name "pulseaudio") - (version "15.0") + (version "16.1") (source (origin - (method url-fetch) - (uri (string-append - "https://freedesktop.org/software/pulseaudio/releases/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "1851rg4h6sjwanvd294hn52z321rc6vbs4gbfrlw53597dx8h2x4")) - (modules '((guix build utils))) - (snippet - ;; Disable console-kit support by default since it's deprecated - ;; anyway. - '(begin - (substitute* "src/daemon/default.pa.in" - (("load-module module-console-kit" all) - (string-append "#" all "\n"))) - #t)) - (patches (search-patches - "pulseaudio-fix-mult-test.patch" - "pulseaudio-longer-test-timeout.patch")))) + (method url-fetch) + (uri (string-append + "https://freedesktop.org/software/pulseaudio/releases/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "1r2aa0g7al9jhrrbrnih6i3bfznd73kkbafrbzwpjyflj7735vwf")) + (modules '((guix build utils))) + (snippet + ;; Disable console-kit support by default since it's deprecated + ;; anyway. + '(substitute* "src/daemon/default.pa.in" + (("load-module module-console-kit" all) + (string-append "#" all "\n")))) + (patches (search-patches + "pulseaudio-fix-mult-test.patch" + "pulseaudio-longer-test-timeout.patch")))) (build-system meson-build-system) (arguments - `(#:configure-flags - (let ((out (assoc-ref %outputs "out"))) - (list "-Doss-output=disabled" - "-Dlocalstatedir=/var" - (string-append "-Dudevrulesdir=" - out "/lib/udev/rules.d") - ;; Ensure the RUNPATH contains all installed library locations. - (string-append "-Dc_link_args=-Wl,-rpath=" - out "/lib/pulseaudio:" - out "/lib:" - out "/lib/pulse-" ,version "/modules"))) - #:phases (modify-phases %standard-phases - (add-before 'check 'pre-check - (lambda _ - ;; 'tests/lock-autospawn-test.c' wants to create a file - ;; under ~/.config/pulse. - (setenv "HOME" (getcwd)) - ;; 'thread-test' needs more time on hydra and on slower - ;; machines, so we set the default timeout to 120 seconds. - (setenv "CK_DEFAULT_TIMEOUT" "120") - #t))))) + (list + #:configure-flags + #~(list "-Doss-output=disabled" + "-Dlocalstatedir=/var" + (string-append "-Dudevrulesdir=" + #$output "/lib/udev/rules.d") + ;; Ensure the RUNPATH contains all installed library locations. + (string-append "-Dc_link_args=-Wl,-rpath=" + #$output "/lib/pulseaudio:" + #$output "/lib:" + #$output "/lib/pulse-" #$version "/modules")) + #:phases + #~(modify-phases %standard-phases + (add-before 'check 'pre-check + (lambda _ + ;; 'tests/lock-autospawn-test.c' wants to create a file + ;; under ~/.config/pulse. + (setenv "HOME" (getcwd)) + ;; 'thread-test' needs more time on hydra and on slower + ;; machines, so we set the default timeout to 120 seconds. + (setenv "CK_DEFAULT_TIMEOUT" "120")))))) (inputs (list alsa-lib bluez sbc speexdsp libsndfile - jack-1 ; For routing the output to jack. + jack-1 ; For routing the output to jack. dbus glib libltdl @@ -241,16 +231,16 @@ rates.") libxcb libxtst elogind - eudev)) ;for the detection of hardware audio devices + eudev)) ;for the detection of hardware audio devices (native-inputs - `(("check" ,check) - ("doxygen" ,doxygen) - ("gettext" ,gettext-minimal) - ("glib:bin" ,glib "bin") - ("m4" ,m4) - ("perl" ,perl) - ("perl-xml-parser" ,perl-xml-parser) - ("pkg-config" ,pkg-config))) + (list check + doxygen + gettext-minimal + `(,glib "bin") + m4 + perl + perl-xml-parser + pkg-config)) (propagated-inputs ;; 'libpulse*.la' contain `-ltdb' and `-lcap', so propagate them. (list libcap tdb)) diff --git a/gnu/packages/python-build.scm b/gnu/packages/python-build.scm index 17f8892c05..70719c44d4 100644 --- a/gnu/packages/python-build.scm +++ b/gnu/packages/python-build.scm @@ -4,10 +4,13 @@ ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> ;;; Copyright © 2020, 2023 Marius Bakke <marius@gnu.org> ;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org> -;;; Copyright © 2018, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2018, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2019 Vagrant Cascadian <vagrant@debian.org> ;;; Copyright © 2021 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2021, 2022 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2020, 2021, 2022, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2022 Garek Dyszel <garekdyszel@disroot.org> +;;; Copyright © 2022 Greg Hogan <code@greghogan.com> + ;;; ;;; This file is part of GNU Guix. ;;; @@ -28,6 +31,7 @@ #:use-module (gnu packages) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system python) + #:use-module (guix build-system pyproject) #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) @@ -41,109 +45,48 @@ ;;; ;;; Code: -(define-public python-pip + +;;; These are dependencies used by the build systems contained herein; they +;;; feel a bit out of place but are kept here to prevent circular module +;;; dependencies. +(define-public python-pathspec (package - (name "python-pip") - (version "22.2.2") + (name "python-pathspec") + (version "0.11.1") (source (origin (method url-fetch) - (uri (pypi-uri "pip" version)) + (uri (pypi-uri "pathspec" version)) (sha256 (base32 - "0jwac0bhfp48w4fqibf1ysrs2grksdv92hwqm7bmdw2jn2fr5l9z")))) + "11qnlcanr1mqcpqpq1hmnwrs26csbsa2bafc7biq09x91y0dx617")))) (build-system python-build-system) - (arguments - '(#:tests? #f)) ; there are no tests in the pypi archive. - (home-page "https://pip.pypa.io/") - (synopsis "Package manager for Python software") + (home-page "https://github.com/cpburnz/python-pathspec") + (synopsis "Utility library for gitignore style pattern matching of file paths") (description - "Pip is a package manager for Python software, that finds packages on the -Python Package Index (PyPI).") - (license license:expat))) + "This package provides a utility library for gitignore style pattern +matching of file paths.") + (license license:mpl2.0))) -(define-public python-setuptools +(define-public python-pluggy (package - (name "python-setuptools") - (version "64.0.3") - (source - (origin - (method url-fetch) - (uri (pypi-uri "setuptools" version)) - (sha256 - (base32 - "1sllqf0bhsl2yilf1w0xnlz0r4yaksmwaj0ap91zdc6kgbigdjiv")) - (modules '((guix build utils))) - (snippet - ;; TODO: setuptools now bundles the following libraries: - ;; packaging, pyparsing, six and appdirs. How to unbundle? - ;; Remove included binaries which are used to build self-extracting - ;; installers for Windows. - '(for-each delete-file (find-files "setuptools" - "^(cli|gui).*\\.exe$"))))) - (build-system python-build-system) - ;; FIXME: Tests require pytest, which itself relies on setuptools. - ;; One could bootstrap with an internal untested setuptools. - (arguments (list #:tests? #f)) - (home-page "https://pypi.org/project/setuptools/") - (synopsis "Library designed to facilitate packaging Python projects") - (description "Setuptools is a fully-featured, stable library designed to -facilitate packaging Python projects, where packaging includes: -@itemize -@item Python package and module definitions -@item distribution package metadata -@item test hooks -@item project installation -@item platform-specific details. -@end itemize") - (license (list license:psfl ;setuptools itself - license:expat ;six, appdirs, pyparsing - license:asl2.0 ;packaging is dual ASL2/BSD-2 - license:bsd-2)))) + (name "python-pluggy") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pluggy" version)) + (sha256 + (base32 + "0n8iadlas2z1b4h0fc73b043c7iwfvx9rgvqm1azjmffmhxkf922")))) + (build-system python-build-system) + (native-inputs (list python-setuptools-scm)) + (synopsis "Plugin and hook calling mechanism for Python") + (description "Pluggy is an extraction of the plugin manager as used by +Pytest but stripped of Pytest specific details.") + (home-page "https://pypi.org/project/pluggy/") + (license license:expat))) -;; This is the last version with use_2to3 support. -(define-public python-setuptools-57 - (package - (inherit python-setuptools) - (version "57.5.0") - (source (origin - (inherit (package-source python-setuptools)) - (uri (pypi-uri "setuptools" version)) - (sha256 - (base32 - "091sp8lrin7qllrhhx7y0iiv5gdb1d3l8a1ip5knk77ma1njdlyr")))))) - -(define-public python-wheel - (package - (name "python-wheel") - (version "0.37.0") - (source - (origin - (method url-fetch) - (uri (pypi-uri "wheel" version)) - (sha256 - (base32 - "1bbga5i49rj1cwi4sjpkvfhl1f8vl9lfky2lblsy768nk4wp5vz2")))) - (build-system python-build-system) - (arguments - ;; FIXME: The test suite runs "python setup.py bdist_wheel", which in turn - ;; fails to find the newly-built bdist_wheel library, even though it is - ;; available on PYTHONPATH. What search path is consulted by setup.py? - '(#:tests? #f)) - (home-page "https://bitbucket.org/pypa/wheel/") - (synopsis "Format for built Python packages") - (description - "A wheel is a ZIP-format archive with a specially formatted filename and -the @code{.whl} extension. It is designed to contain all the files for a PEP -376 compatible install in a way that is very close to the on-disk format. Many -packages will be properly installed with only the @code{Unpack} step and the -unpacked archive preserves enough information to @code{Spread} (copy data and -scripts to their final locations) at any later time. Wheel files can be -installed with a newer @code{pip} or with wheel's own command line utility.") - (license license:expat))) - -;;; XXX: Not really at home, but this seems the best place to prevent circular -;;; module dependencies. (define-public python-toml (package (name "python-toml") @@ -174,21 +117,8 @@ Language (TOML) configuration files.") (uri (pypi-uri "tomli_w" version)) (sha256 (base32 "1fg13bfq5qy1ym4x77815nhxh1xpfs0drhn9r9464cz00m1l6qzl")))) - (build-system python-build-system) - (arguments - (list - #:tests? #f ;to avoid extra dependencies - #:phases - #~(modify-phases %standard-phases - ;; XXX: PEP 517 manual build copied from python-isort. - (replace 'build - (lambda _ - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'install - (lambda _ - (let ((whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" #$output whl))))))) + (build-system pyproject-build-system) + (arguments (list #:tests? #f)) ;to avoid extra dependencies (native-inputs (list python-pypa-build python-flit-core)) (home-page "https://github.com/hukkin/tomli-w") (synopsis "Minimal TOML writer") @@ -239,34 +169,23 @@ Python file, so it can be easily copied into your project.") (define-public python-tomli (package (name "python-tomli") - (version "2.0.0") + (version "2.0.1") (source (origin (method url-fetch) (uri (pypi-uri "tomli" version)) (sha256 - (base32 "1q8lrh9ypa6zpgbc5f7z23p7phzblp4vpxdrpfr1wajhb17w74n2")))) - (build-system python-build-system) + (base32 "0kwazq3i18rphcr8gak4fgzdcj5w5bbn4k4j2l6ma32gj496qlny")))) + (build-system pyproject-build-system) (arguments `(#:tests? #f ;disabled to avoid extra dependencies #:phases (modify-phases %standard-phases - (replace 'build + (add-before 'build 'add-self-to-path (lambda _ - (setenv "PYTHONPATH" (string-append (getcwd) ":" - (getenv "GUIX_PYTHONPATH"))) - (invoke "python" "-m" "build" "--wheel" "--no-isolation" - "--skip-dependency-check"))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" out whl))))))) - (native-inputs - `(("python-flit-core-bootstrap" ,python-flit-core-bootstrap) - ("python-pypa-build" ,python-pypa-build) - ("python-six", python-six-bootstrap))) + ;; The build system of tomli requires... tomli. + (setenv "PYTHONPATH" "src")))))) + (native-inputs (list python-flit-core-bootstrap python-six-bootstrap)) (home-page "https://github.com/hukkin/tomli") (synopsis "Small and fast TOML parser") (description "Tomli is a minimal TOML parser that is fully compatible with @@ -274,6 +193,171 @@ Python file, so it can be easily copied into your project.") @code{python-toml}.") (license license:expat))) +(define-public python-trove-classifiers + (package + (name "python-trove-classifiers") + (version "2023.3.9") + (source (origin + (method url-fetch) + (uri (pypi-uri "trove-classifiers" version)) + (sha256 + (base32 + "00xvldq94dy0zxz40idbbx40smrkfvq75r26ywszxg6lq7wg4hpf")))) + (build-system pyproject-build-system) + (arguments (list #:build-backend "setuptools.build_meta" + #:tests? #f)) ;keep dependencies to a minimum + (native-inputs (list python-wheel)) + (home-page "https://github.com/pypa/trove-classifiers") + (synopsis "Canonical source for classifiers on PyPI") + (description "This package is the canonical source for classifiers use on +PyPI (pypi.org).") + (license license:asl2.0))) + +(define-public python-typing-extensions + (package + (name "python-typing-extensions") + (version "4.5.0") + (source (origin + (method url-fetch) + (uri (pypi-uri "typing_extensions" version)) + (sha256 + (base32 + "1jx7ki3sji60v7h2805b2phq9ynsvshj5xiygdh9kmirj6kz9daw")))) + (build-system pyproject-build-system) + ;; Disable the test suite to keep the dependencies to a minimum. Also, + ;; the test suite requires Python's test module, not available in Guix. + (arguments (list #:tests? #f)) + (native-inputs (list python-flit-core)) + (home-page "https://github.com/python/typing_extensions") + (synopsis "Experimental type hints for Python") + (description + "The typing_extensions module contains additional @code{typing} hints not +yet present in the of the @code{typing} standard library. +Included are implementations of: +@enumerate +@item ClassVar +@item ContextManager +@item Counter +@item DefaultDict +@item Deque +@item NewType +@item NoReturn +@item overload +@item Protocol +@item runtime +@item Text +@item Type +@item TYPE_CHECKING +@item AsyncGenerator +@end enumerate\n") + (license license:psfl))) + + +;;; +;;; Python builder packages. +;;; +(define-public python-pip + (package + (name "python-pip") + (version "23.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pip" version)) + (sha256 + (base32 + "0jnk639v9h7ghslm4jnlic6rj3v29nygflx1hgxxndg5gs4kk1a0")))) + (build-system python-build-system) + (arguments + '(#:tests? #f)) ; there are no tests in the pypi archive. + (home-page "https://pip.pypa.io/") + (synopsis "Package manager for Python software") + (description + "Pip is a package manager for Python software, that finds packages on the +Python Package Index (PyPI).") + (license license:expat))) + +(define-public python-setuptools + (package + (name "python-setuptools") + (version "67.6.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "setuptools" version)) + (sha256 + (base32 + "16myxkpa89r045il88zcygdy1zbi2mvvpz5b4a70p9jhklmfjz95")) + (modules '((guix build utils))) + (snippet + ;; TODO: setuptools now bundles the following libraries: + ;; packaging, pyparsing, six and appdirs. How to unbundle? + ;; Remove included binaries which are used to build self-extracting + ;; installers for Windows. + '(for-each delete-file (find-files "setuptools" + "^(cli|gui).*\\.exe$"))))) + (build-system python-build-system) + ;; FIXME: Tests require pytest, which itself relies on setuptools. + ;; One could bootstrap with an internal untested setuptools. + (arguments (list #:tests? #f)) + (home-page "https://pypi.org/project/setuptools/") + (synopsis "Library designed to facilitate packaging Python projects") + (description "Setuptools is a fully-featured, stable library designed to +facilitate packaging Python projects, where packaging includes: +@itemize +@item Python package and module definitions +@item distribution package metadata +@item test hooks +@item project installation +@item platform-specific details. +@end itemize") + (license (list license:psfl ;setuptools itself + license:expat ;six, appdirs, pyparsing + license:asl2.0 ;packaging is dual ASL2/BSD-2 + license:bsd-2)))) + +;; This is the last version with use_2to3 support. +(define-public python-setuptools-57 + (package + (inherit python-setuptools) + (version "57.5.0") + (source (origin + (inherit (package-source python-setuptools)) + (uri (pypi-uri "setuptools" version)) + (sha256 + (base32 + "091sp8lrin7qllrhhx7y0iiv5gdb1d3l8a1ip5knk77ma1njdlyr")))))) + +(define-public python-wheel + (package + (name "python-wheel") + (version "0.40.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "wheel" version)) + (sha256 + (base32 + "0ww8fgkvwv35ypj4cnngczdwp6agr4qifvk2inb32azfzbrrc4fd")))) + (build-system python-build-system) + (arguments + ;; FIXME: The test suite runs "python setup.py bdist_wheel", which in turn + ;; fails to find the newly-built bdist_wheel library, even though it is + ;; available on PYTHONPATH. What search path is consulted by setup.py? + '(#:tests? #f)) + (home-page "https://github.com/pypa/wheel") + (synopsis "Format for built Python packages") + (description + "A wheel is a ZIP-format archive with a specially formatted filename and +the @code{.whl} extension. It is designed to contain all the files for a PEP +376 compatible install in a way that is very close to the on-disk format. Many +packages will be properly installed with only the @code{Unpack} step and the +unpacked archive preserves enough information to @code{Spread} (copy data and +scripts to their final locations) at any later time. Wheel files can be +installed with a newer @code{pip} or with wheel's own command line utility.") + (license license:expat))) + +;;; TODO: Deprecate with https://github.com/pypa/pyproject-hooks. (define-public python-pep517-bootstrap (hidden-package (package @@ -412,14 +496,22 @@ order to make bootstrapping easier.") (define-public python-poetry-core (package (name "python-poetry-core") - (version "1.0.7") + (version "1.5.2") (source (origin (method url-fetch) - (uri (pypi-uri "poetry-core" version)) + (uri (pypi-uri "poetry_core" version)) (sha256 - (base32 "01n2rbsvks7snrq3m1d08r3xz9q2715ajb62fdb6rvqnb9sirhcq")))) - (build-system python-build-system) + (base32 "053c8dw632p7jkhjb51k0wcx6hdw4r3lk97mds76df653qxnqmf6")))) + (build-system pyproject-build-system) + (arguments + `(#:tests? #f ;disabled to avoid extra dependencies + #:phases + (modify-phases %standard-phases + (add-before 'build 'add-self-to-path + (lambda _ + ;; The build system requires itself. + (setenv "PYTHONPATH" "src")))))) (home-page "https://github.com/python-poetry/poetry-core") (synopsis "Poetry PEP 517 build back-end") (description @@ -433,13 +525,13 @@ compatible build front-ends to build Poetry managed projects.") (define-public python-flit-core-bootstrap (package (name "python-flit-core-bootstrap") - (version "3.5.1") + (version "3.8.0") (source (origin (method url-fetch) (uri (pypi-uri "flit" version)) (sha256 - (base32 "04152qj46sqbnlrj7ch9p7svjrrlpzbk0qr39g2yr0s4f5vp6frf")))) + (base32 "0dz9sp2zlhkmk6sm5gapbbb30f7xq3n3jn5zxx5pkp25ppsaiwnh")))) (build-system python-build-system) (propagated-inputs (list python-toml)) @@ -464,7 +556,7 @@ compatible build front-ends to build Poetry managed projects.") ;; The sanity-check phase fails because flit depends on tomli at ;; run-time, but this core variant avoids it to avoid a cycle. (delete 'sanity-check)))) - (home-page "https://github.com/takluyver/flit") + (home-page "https://github.com/pypa/flit") (synopsis "Core package of the Flit Python build system") (description "This package provides @code{flit-core}, a PEP 517 build backend for packages using Flit. The only public interface is the API @@ -481,45 +573,21 @@ specified by PEP 517, @code{flit_core.buildapi}.") (define-public python-flit-scm (package (name "python-flit-scm") - (version "1.6.2") + (version "1.7.0") (source (origin (method url-fetch) (uri (pypi-uri "flit_scm" version)) (sha256 (base32 - "0p3lj2g1643m2dm14kihvfb6gn6jviglhm3dzdpn2c8zpqs17svg")))) - (build-system python-build-system) - (arguments - (list - #:tests? #f ;no test suite - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'relax-setuptools-scm-version - (lambda _ - (substitute* "pyproject.toml" - (("setuptools_scm~=6.4") - "setuptools_scm>=6.3")))) - ;; XXX: PEP 517 manual build/install procedures copied from - ;; python-isort. - (replace 'build - (lambda _ - ;; ZIP does not support timestamps before 1980. - (setenv "SOURCE_DATE_EPOCH" "315532800") - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let ((whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" #$output whl))))))) - (native-inputs - (list python-pypa-build - python-flit-core - python-setuptools-scm - python-tomli)) - (propagated-inputs - (list python-flit-core - python-setuptools-scm - python-tomli)) + "1ckbkykfr7f7wzjzgh0gm7h6v3pqzx2l28rw6dsvl6zk4kxxc6wn")))) + (build-system pyproject-build-system) + (arguments (list #:tests? #f ;to avoid extra dependencies + ;; flit-scm wants to use flit-core, which it renames to + ;; 'buildapi', but that isn't found even when adding the + ;; current directory to PYTHONPATH. Use setuptools' + ;; builder instead. + #:build-backend "setuptools.build_meta")) + (propagated-inputs (list python-flit-core python-setuptools-scm python-tomli)) (home-page "https://gitlab.com/WillDaSilva/flit_scm") (synopsis "PEP 518 build backend combining flit_core and setuptools_scm") (description "This package provides a PEP 518 build backend that uses @@ -530,16 +598,16 @@ system, then @code{flit_core} to build the package.") (define-public python-setuptools-scm (package (name "python-setuptools-scm") - (version "6.3.2") + (version "7.1.0") (source (origin (method url-fetch) (uri (pypi-uri "setuptools_scm" version)) (sha256 - (base32 "1wm0i27siyy1yqr9rv7lqvb65agay9051yi8jzmi8dgb3q4ai6m4")))) + (base32 "09wg4zg30ir1c2cvwqipaz3hwaxz503fgw5zdvaxgakilx2q6l3c")))) (build-system python-build-system) - (propagated-inputs - `(("python-packaging",python-packaging-bootstrap) - ("python-tomli" ,python-tomli))) + (arguments (list #:tests? #f)) ;avoid extra dependencies such as pytest + (propagated-inputs (list python-packaging-bootstrap python-tomli + python-typing-extensions)) (home-page "https://github.com/pypa/setuptools_scm/") (synopsis "Manage Python package versions in SCM metadata") (description @@ -569,3 +637,81 @@ installed, will expose packages in a local directory on @code{sys.path} in ``editable mode''. In other words, changes to the package source will be reflected in the package visible to Python, without needing a reinstall.") (license license:expat))) + +(define-public python-hatchling + (package + (name "python-hatchling") + (version "1.14.0") + (source (origin + (method url-fetch) + (uri (pypi-uri "hatchling" version)) + (sha256 + (base32 + "1nn5cyc9fgrbawz38drfkl2s588k2gn3yqdm2cldbx9zy0fsjbj6")))) + (build-system pyproject-build-system) + (arguments + (list #:tests? #f ;to keep dependencies to a minimum + #:phases #~(modify-phases %standard-phases + (add-before 'build 'add-src-to-path + ;; Hatchling uses itself to build itself. + (lambda _ + (setenv "PYTHONPATH" "src")))))) + (propagated-inputs (list python-editables + python-packaging-bootstrap + python-pathspec + python-pluggy + python-tomli + python-trove-classifiers)) + (home-page "https://hatch.pypa.io/latest/") + (synopsis "Modern, extensible Python build backend") + (description "Hatch is a modern, extensible Python project manager. It +has features such as: +@itemize +@item Standardized build system with reproducible builds by default +@item Robust environment management with support for custom scripts +@item Easy publishing to PyPI or other indexes +@item Version management +@item Configurable project generation with sane defaults +@item Responsive CLI, ~2-3x faster than equivalent tools. +@end itemize") + (license license:expat))) + +(define-public python-hatch-fancy-pypi-readme + (package + (name "python-hatch-fancy-pypi-readme") + (version "22.8.0") + (source (origin + (method url-fetch) + (uri (pypi-uri "hatch_fancy_pypi_readme" version)) + (sha256 + (base32 + "0sn2wsfbpsbf2mqhjvw62h1cfy5mz3d7iqyqvs5c20cnl0n2i4fs")))) + (build-system pyproject-build-system) + (arguments (list #:tests? #f)) ;avoid extra test dependencies + (propagated-inputs (list python-hatchling python-tomli + python-typing-extensions)) + (home-page "https://github.com/hynek/hatch-fancy-pypi-readme") + (synopsis "Fancy PyPI READMEs with Hatch") + (description "This hatch plugin allows defining a project description in +terms of concatenated fragments that are based on static strings, files and +parts of files defined using cut-off points or regular expressions.") + (license license:expat))) + +(define-public python-hatch-vcs + (package + (name "python-hatch-vcs") + (version "0.3.0") + (source (origin + (method url-fetch) + (uri (pypi-uri "hatch_vcs" version)) + (sha256 + (base32 + "1viz2mdfxfqpsd5f30410q6smj90qfxihvy9idzwd0p4ziy11iff")))) + (arguments (list #:tests? #f)) ;avoid extra test dependencies + (build-system pyproject-build-system) + (propagated-inputs (list python-hatchling python-setuptools-scm)) + (home-page "https://github.com/ofek/hatch-vcs") + (synopsis "Hatch plugin for versioning with your preferred VCS") + (description "This package is a plugin for Hatch that uses your preferred +version control system (like Git) to determine project versions.") + (license license:expat))) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 9ce093697d..6866c42402 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -174,9 +174,9 @@ tests in cram.") (add-installed-pythonpath inputs outputs) (invoke "pytest"))))))) (native-inputs - (list python-pytest-flake8 python-pytest-xdist-next python-tabulate)) + (list python-pytest-flake8 python-pytest-xdist python-tabulate)) (propagated-inputs - (list python-pytest-6 python-six)) + (list python-pytest python-six)) (home-page "https://github.com/nicoulaj/pytest-csv") (synopsis "CSV reporter for Pytest") (description "This package provides a plugin for Pytest that enables a @@ -249,7 +249,10 @@ are useful when writing automated tests in Python.") (file-name (git-file-name name version)) (sha256 (base32 - "1915ab77nfb1rfw4i2ps0zy19wpf20lwxn81qxxbwyd2gy7m0fn8")))) + "1915ab77nfb1rfw4i2ps0zy19wpf20lwxn81qxxbwyd2gy7m0fn8")) + (modules '((guix build utils))) + (snippet '(substitute* "setup.py" + (("'coverage>=4.1,<6.0',") "'coverage',"))))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -260,7 +263,8 @@ are useful when writing automated tests in Python.") (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? - (invoke "pytest" "-vv") + ;; Test fails for unknown reasons. No fix available. + (invoke "pytest" "-vv" "-k" "not test_reporter_with_branches") (format #t "test suite not run~%"))))))) (propagated-inputs (list python-coverage python-docopt python-pyyaml python-requests)) @@ -957,7 +961,7 @@ in Pytest.") (when tests? (add-installed-pythonpath inputs outputs) (invoke "python" "-m" "pytest"))))))) - (native-inputs (list python-pytest-7.1 python-setuptools-scm)) + (native-inputs (list python-pytest python-setuptools-scm)) (home-page "https://github.com/pytest-dev/pytest-subtests") (synopsis "Unittest subTest() support and subtests fixture") (description "This Pytest plugin provides unittest @code{subTest()} @@ -1156,25 +1160,18 @@ compliance.") (define-public python-pytest-isort (package (name "python-pytest-isort") - (version "2.0.0") + (version "3.1.0") (source (origin (method url-fetch) - (uri (pypi-uri "pytest-isort" version)) + (uri (pypi-uri "pytest_isort" version)) (sha256 - (base32 "05wi28zlqk3jafpjal8j523y5jcsx3xl3id9rx93qfjgkif8q6l2")))) + (base32 "0v0qa5l22y3v0nfkpvghbinzyj2rh4f54k871lrp992lbvf02y06")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "pytest"))))))) + `(#:tests? #f)) ; No tests in PyPi tarball. (propagated-inputs (list python-isort python-pytest)) - (native-inputs - (list python-mock)) (home-page "https://github.com/moccu/pytest-isort/") (synopsis "Pytest plugin to check import ordering using isort") (description @@ -1308,14 +1305,14 @@ for the @code{pytest} framework.") (define-public python-pytest-benchmark (package (name "python-pytest-benchmark") - (version "3.4.1") + (version "4.0.0") (source (origin (method url-fetch) (uri (pypi-uri "pytest-benchmark" version)) (sha256 (base32 - "0ivvrnhax2xr62grlgw4hlyjmmjp6nc35431j7c82nny2bwn7qj0")))) + "1la802m5r49y1zqilmhqh0qvbnz139lw0qb3jmm9lngy7sw8a1zv")))) (build-system python-build-system) (arguments '(#:test-target "check")) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index bf083497d0..3e7704bf48 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -76,30 +76,6 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (srfi srfi-1)) -(define-public python-potr - (package - (name "python-potr") - (version "1.0.2") - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/python-otr/pure-python-otr") - (commit version))) - (file-name - (git-file-name name version)) - (sha256 - (base32 "1hzw6h01fm216nmipyylgz0zybd80w1xsk12m7djycnhqrnrvvv1")))) - (build-system python-build-system) - (propagated-inputs - (list python-pycrypto)) - (synopsis "Python OTR Implementation") - (description "Python OTR is an Off-The-Record Protocol Implementation in -Python. It does not bind to libotr.") - (home-page "https://github.com/python-otr/pure-python-otr") - (license license:lgpl3+))) - (define-public python-base58 (package (name "python-base58") @@ -265,41 +241,6 @@ messages, and verify the signatures. The keys and signatures are very short, making them easy to handle and incorporate into other protocols.") (license license:expat))) -;;; Pycrypto is abandoned upstream: -;;; -;;; https://github.com/dlitz/pycrypto/issues/173 -;;; -;;; TODO Remove this package from GNU Guix. -(define-public python-pycrypto - (package - (name "python-pycrypto") - (version "2.6.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pycrypto" version)) - (patches (search-patches "python-pycrypto-CVE-2013-7459.patch" - "python-pycrypto-time-clock.patch")) - (sha256 - (base32 - "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj")))) - (build-system python-build-system) - (inputs - (list python gmp)) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'build 'set-build-env - ;; pycrypto runs an autoconf configure script behind the scenes - (lambda _ (setenv "CONFIG_SHELL" (which "bash")) #t))))) - (home-page "https://www.dlitz.net/software/pycrypto/") - (synopsis "Cryptographic modules for Python") - (description - "Pycrypto is a collection of both secure hash functions (such as SHA256 -and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal, -etc.). The package is structured to make adding new modules easy.") - (license license:public-domain))) - (define-public python-kerberos (package (name "python-kerberos") @@ -580,7 +521,7 @@ is used by the Requests library to verify HTTPS requests.") python-hypothesis python-iso8601 python-pretend - python-pytest-7.1 ;for subtests + python-pytest ;for subtests python-pytest-benchmark python-pytest-subtests)) (inputs (list python-cryptography-rust)) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index e53dded72a..c0a1c4794f 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2016, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016-2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2019 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2019, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2019, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org> ;;; Copyright © 2020 Pierre Langlois <pierre.langlois@gmx.com> ;;; Copyright © 2020, 2021, 2022 Vinicius Monego <monego@posteo.net> @@ -82,33 +82,23 @@ (define-public python-scipy (package (name "python-scipy") - (version "1.9.1") + (version "1.10.1") (source (origin (method url-fetch) (uri (pypi-uri "scipy" version)) (sha256 - (base32 "1jcb94xal7w7ax80kaivqqics36v8smi4a3xngyxbrh0i538rli6")))) - (build-system python-build-system) + (base32 "19gk88nvrxl050nasz25qpmmqvbdk247bkj09jx8jibv1awdzy9c")))) + (build-system pyproject-build-system) (arguments (list + ;; FIXME: The default 'mesonpy' build system doesn't seem to work with + ;; our pyproject-build-system, errors with: AttributeError: 'list' + ;; object has no attribute 'items' (see: + ;; https://issues.guix.gnu.org/62781). + #:build-backend "setuptools.build_meta" #:phases #~(modify-phases %standard-phases - (add-after 'unpack 'loosen-requirements - (lambda _ - (substitute* "pyproject.toml" - (("numpy==") "numpy>=") - (("meson==") "meson>=")))) - (replace 'build - (lambda _ - ;; ZIP does not support timestamps before 1980. - (setenv "SOURCE_DATE_EPOCH" "315532800") - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'install - (lambda _ - (let ((whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" #$output whl)))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -158,7 +148,6 @@ meson-python pkg-config python-cython - python-pypa-build python-pytest python-pytest-xdist python-threadpoolctl)) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index d84b5efdf9..6eaec07c71 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -58,6 +58,7 @@ ;;; Copyright © 2022 msimonin <matthieu.simonin@inria.fr> ;;; Copyright © 2022 Michael Rohleder <mike@rohleder.de> ;;; Copyright © 2022 Baptiste Strazzulla <bstrazzull@hotmail.fr> +;;; Copyright © 2023 John Kehayias <john.kehayias@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -289,23 +290,17 @@ by calling @code{FrozenList.freeze}.") (define-public python-aiosignal (package (name "python-aiosignal") - (version "1.2.0") + (version "1.3.1") (source (origin (method url-fetch) (uri (pypi-uri "aiosignal" version)) (sha256 - (base32 "1wkxbdgw07ay8yzx3pg1jcm46p3d21rfb5g4k17ysz3vdkdngvbq")))) - (build-system python-build-system) - (arguments - '(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "pytest" "tests"))))))) + (base32 "1z4cnqww6j0xl6f3vx2r6kfv1hdny1pnlll7difvfj8nbvhrdkal")))) + (build-system pyproject-build-system) + (arguments (list #:test-flags #~(list "tests"))) (propagated-inputs (list python-frozenlist)) - (native-inputs (list python-pytest python-pytest-asyncio)) + (native-inputs (list python-pytest python-pytest-asyncio python-pytest-cov)) (home-page "https://github.com/aio-libs/aiosignal") (synopsis "Callback manager for Python @code{asyncio} projects") (description "This Python module provides @code{Signal}, an abstraction to @@ -316,13 +311,13 @@ for adding, removing and dropping callbacks.") (define-public python-aiohttp (package (name "python-aiohttp") - (version "3.8.1") + (version "3.8.4") (source (origin (method url-fetch) (uri (pypi-uri "aiohttp" version)) (sha256 - (base32 "0y3m1dzl4h6frg8vys0fc3m83ijd1plfpihv3kvmxqadlphp2m7w")) + (base32 "0p5bj6g7ca19gvwk8fz00k579ma9w9kd27ssh2zl3r61ca8ilbmz")) (snippet #~(begin (use-modules ((guix build utils))) @@ -338,12 +333,14 @@ for adding, removing and dropping callbacks.") (modify-phases %standard-phases (add-after 'unpack 'fix-tests (lambda _ - ;; disable brotli tests, because we’re not providing that optional library + ;; Disable brotli tests, because we’re not providing that + ;; optional library. (substitute* "tests/test_http_parser.py" ((" async def test_feed_eof_no_err_brotli") " @pytest.mark.xfail\n async def test_feed_eof_no_err_brotli")) - ;; make sure the timestamp of this file is > 1990, because a few - ;; tests like test_static_file_if_modified_since_past_date depend on it + ;; Make sure the timestamp of this file is > 1990, because a few + ;; tests like test_static_file_if_modified_since_past_date depend + ;; on it. (let ((late-90s (* 60 60 24 365 30))) (utime "tests/data.unknown_mime_type" late-90s late-90s)) @@ -383,33 +380,35 @@ for adding, removing and dropping callbacks.") "not test_client_session_timeout_zero and " "not test_empty_body and " "not test_mark_formdata_as_processed[pyloop] and " - "not test_receive_runtime_err[pyloop]"))) + "not test_receive_runtime_err[pyloop] " + ;; These tests fail for unknown reasons (see: + ;; https://github.com/aio-libs/aiohttp/issues/7130) + "and not test_no_warnings " + "and not test_default_loop " + "and not test_ctor_global_loop " + "and not test_set_loop_default_loop "))) (when tests? ;; This tests requires the 'proxy.py' module, not yet ;; packaged. (delete-file "tests/test_proxy_functional.py") ;; Sometimes tests fail when run in parallel. - (or - (invoke "pytest" "-vv" - ;; Disable loading the aiohttp coverage plugin - ;; to avoid a circular dependency (code coverage - ;; is not very interesting to us anyway). - "-o" "addopts=''" "--ignore=aiohttp" - "-n" (number->string (parallel-job-count)) - "-k" skipped-tests) - (invoke "pytest" "-vv" - "-o" "addopts=''" "--ignore=aiohttp" - "-k" skipped-tests))))))))) + (invoke "pytest" "-vv" + "-o" "addopts=''" "--ignore=aiohttp" + ;; These tests cause errors (see: + ;; https://github.com/aio-libs/aiohttp/issues/7130). + "--ignore" "tests/test_web_sendfile_functional.py" + "--ignore" "tests/test_web_urldispatcher.py" + "-k" skipped-tests)))))))) (propagated-inputs (list python-aiodns python-aiosignal python-attrs + python-asynctest python-async-timeout python-charset-normalizer python-frozenlist python-idna-ssl python-multidict - python-typing-extensions python-yarl)) (native-inputs (list gunicorn-bootstrap @@ -457,17 +456,16 @@ aiohttp. It supports SOCKS4(a) and SOCKS5.") (define-public python-aiodns (package (name "python-aiodns") - (version "1.1.1") + (version "3.0.0") (source (origin (method url-fetch) (uri (pypi-uri "aiodns" version)) (sha256 (base32 - "1snr5paql8dgvc676n8xq460wypjsb1xj53cf3px1s4wczf7lryq")))) + "1mlcw14hxyzd2yg89gj1l84gfi8nbl7h32iw17myxz23wymxyswl")))) (build-system python-build-system) - (propagated-inputs - (list python-pycares)) + (propagated-inputs (list python-pycares)) (arguments `(#:tests? #f)) ;tests require internet access (home-page "https://github.com/saghul/aiodns") @@ -1045,7 +1043,7 @@ over a different origin than that of the web application.") (define-public python-httplib2 (package (name "python-httplib2") - (version "0.15.0") + (version "0.22.0") (source (origin ;; Tests not included in the release tarball. @@ -1056,8 +1054,8 @@ over a different origin than that of the web application.") (file-name (git-file-name name version)) (sha256 (base32 - "11bis23xqbl6aa5m5yswwcf6zn4j24lyi7bfskd31h4zb368ggsj")))) - (build-system python-build-system) + "1zkp3glv0iha7p68p5m0sb8mrrammkdc0mx32517xry52s4iva7g")))) + (build-system pyproject-build-system) (arguments (list #:phases @@ -1067,7 +1065,8 @@ over a different origin than that of the web application.") (substitute* "requirements-test.txt" (("==") ">="))))))) (native-inputs - (list python-flake8 + (list python-cryptography + python-flake8 python-future python-mock python-pytest @@ -1431,7 +1430,7 @@ and that could be anything you want.") (add-installed-pythonpath inputs outputs) (invoke "python" "-m" "pytest" "-vv" "test"))))))) (native-inputs - (list python-hypothesis-next python-pytest)) + (list python-hypothesis python-pytest)) (propagated-inputs (list python-hpack python-hyperframe)) (home-page "https://github.com/python-hyper/h2") @@ -2273,14 +2272,14 @@ connection to each user.") (define-public python-tornado-6 (package (name "python-tornado") - (version "6.1") + (version "6.2") (source (origin (method url-fetch) (uri (pypi-uri "tornado" version)) (sha256 (base32 - "14cpzdv6p6qvk6vn02krdh5rcfdi174ifdbr5s6lcnymgcfyiiik")))) + "04rwzjfqa31ajz8vvkfcsp1539m8n960msnppxkcckp8plch8qwv")))) (build-system python-build-system) (arguments '(#:phases @@ -3401,14 +3400,14 @@ addon for removing tracking fields from URLs.") (define-public python-urllib3 (package (name "python-urllib3") - (version "1.26.9") + (version "1.26.15") (source (origin (method url-fetch) (uri (pypi-uri "urllib3" version)) (sha256 (base32 - "13j4mkk6vgix4bixfqk3fhydsl3r5f61z94ss4fmwsl0fxjg3fma")))) + "01dkqv0rsjqyw4wrp6yj8h3bcnl7c678qkj845596vs7p4bqff4a")))) (build-system python-build-system) (arguments `(#:tests? #f)) (propagated-inputs @@ -3687,15 +3686,15 @@ Python.") (when tests? (invoke "pytest" "-v"))))))) (native-inputs - (list python-mock - python-pytest + (list python-pytest python-pytest-asyncio python-pytest-httpserver)) (propagated-inputs (list python-requests - python-cookies - python-six - python-types-toml)) + python-toml + python-types-toml + python-typing-extensions + python-urllib3)) (home-page "https://github.com/getsentry/responses") (synopsis "Utility for mocking out the `requests` Python library") (description "A utility library for mocking out the `requests` Python @@ -4283,7 +4282,11 @@ users' sessions over extended periods of time.") (arguments `(#:tests? #f)) (propagated-inputs - (list python-httplib2 python-pyasn1 python-pyasn1-modules python-rsa + (list python-httplib2 + python-pyasn1 + python-pyasn1-modules + python-pyparsing + python-rsa python-six)) (home-page "https://github.com/google/oauth2client/") (synopsis "OAuth 2.0 client library") @@ -4443,7 +4446,7 @@ for Flask programs that are using @code{python-alembic}.") (define-public python-genshi (package (name "python-genshi") - (version "0.7.5") + (version "0.7.7") (source (origin (method git-fetch) @@ -4452,7 +4455,7 @@ for Flask programs that are using @code{python-alembic}.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "04i0caywiwrgw09grz988n15qr9lr31d9n6a529p8v80cy1fv23c")))) + (base32 "06q14mn5n56rdnqvsbbjixygilblgg85fzw029n96qf6f1rvldiq")))) (propagated-inputs (list python-six)) (build-system python-build-system) @@ -4806,17 +4809,17 @@ supports features like HTTP keep-alive, reget, throttling and more.") (define-public python-pycares (package (name "python-pycares") - (version "2.3.0") + (version "4.3.0") (source (origin (method url-fetch) (uri (pypi-uri "pycares" version)) (sha256 (base32 - "0h4fxw5drrhfyslzmfpljk0qnnpbhhb20hnnndzahhbwylyw1x1n")))) + "0i8d0433wmm7wi8i2l2hjiyhmy35b9s888qrk6fqx5xcdmpnjhn5")))) (build-system python-build-system) - (arguments - `(#:tests? #f)) ;tests require internet access + (arguments `(#:tests? #f)) ;tests require internet access + (propagated-inputs (list python-cffi)) (home-page "https://github.com/saghul/pycares") (synopsis "Python interface for @code{c-ares}") (description "@code{pycares} is a Python module which provides an @@ -7292,13 +7295,13 @@ of the CRC32C hashing algorithm.") (define-public python-google-auth (package (name "python-google-auth") - (version "2.6.6") + (version "2.17.3") (source (origin (method url-fetch) (uri (pypi-uri "google-auth" version)) (sha256 - (base32 "04ikassansqkkw4pa98in7q9r4z001m6bi2r3ssxwwrb0f79790v")))) + (base32 "1z2f0vj374rscvlivhvf9xxjlg4lng4mgpqnygfhy4wbqlmiwcff")))) (build-system python-build-system) (arguments `(#:phases @@ -7316,6 +7319,7 @@ of the CRC32C hashing algorithm.") (native-inputs (list python-flask python-freezegun + python-mock python-oauth2client python-pyopenssl python-pytest diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 6ea91a2719..c5da7b1dd5 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -1,13 +1,13 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org> ;;; Copyright © 2013-2022 Ludovic Courtès <ludo@gnu.org> -;;; Copyright © 2013, 2014, 2015, 2016, 2019 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2013, 2014, 2015, 2016, 2019, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2014, 2017, 2021, 2022 Eric Bavier <bavier@posteo.net> ;;; Copyright © 2014, 2015 Federico Beffa <beffa@fbengineering.ch> ;;; Copyright © 2015 Omar Radwan <toxemicsquire4@gmail.com> ;;; Copyright © 2015 Pierre-Antoine Rault <par@rigelk.eu> -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2015, 2016, 2020 Christine Lemmer-Webber <cwebber@dustycloud.org> ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr> ;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org> @@ -114,7 +114,7 @@ ;;; Copyright © 2021 ZmnSCPxj <ZmnSCPxj@protonmail.com> ;;; Copyright © 2021 Filip Lajszczak <filip@lajszczak.dev> ;;; Copyright © 2021 Greg Hogan <code@greghogan.com> -;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com> +;;; Copyright © 2022, 2023 John Kehayias <john.kehayias@protonmail.com> ;;; Copyright © 2022 Aleksandr Vityazev <avityazev@posteo.org> ;;; Copyright © 2022 Evgeny Pisemsky <evgeny@pisemsky.com> ;;; Copyright © 2022 drozdov <drozdov@portalenergy.tech> @@ -135,6 +135,7 @@ ;;; Copyright © 2023 Gabriel Wicki <gabriel@erlikon.ch> ;;; Copyright © 2023 Amade Nemes <nemesamade@gmail.com> ;;; Copyright © 2023 Bruno Victal <mirai@makinata.eu> +;;; Copyright © 2023 Kaelyn Takata <kaelyn.alexi@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -968,7 +969,7 @@ Markdown. All extensions are found under the module namespace of pymdownx.") "0rv0cbala7ibjbaf6kkcn0mdhqdbajnvlcw0f15gwzfwg10g0z1q")))) (build-system python-build-system) (native-inputs - (list python-pytest-7.1 ;for pytest-subtests + (list python-pytest ;for pytest-subtests python-pytest-cov python-pytest-mpl python-pytest-subtests @@ -1059,7 +1060,7 @@ generator MkDocs.") (define-public python-slixmpp (package (name "python-slixmpp") - (version "1.5.2") + (version "1.8.3") (source (origin (method git-fetch) @@ -1071,7 +1072,7 @@ generator MkDocs.") (file-name (git-file-name name version)) (sha256 - (base32 "15mqxcws14bjvh5jcfwl86zsvrymkdw3ya07vb44md7vfnsnclwx")))) + (base32 "0cvr037qhf0fpby5dci6ckqngaly1mnjs2zpndwgmvr3dyvrd8l8")))) (build-system python-build-system) (arguments `(#:phases @@ -1087,7 +1088,12 @@ generator MkDocs.") ("gnupg" ,gnupg) ("pkg-config" ,pkg-config))) (propagated-inputs - (list python-aiodns python-aiohttp python-pyasn1 + (list python-aiodns + python-aiohttp + python-cryptography + python-defusedxml + python-emoji + python-pyasn1 python-pyasn1-modules)) (inputs (list libidn python)) ; We are building a Python extension. @@ -1755,51 +1761,6 @@ compositions like @code{XOR} and @code{NAND} are emulated on top of them. Expressions are constructed from parsed strings or directly in Python.") (license license:bsd-2))) -(define-public python-hatchling - (package - (name "python-hatchling") - (version "1.13.0") - (source (origin - (method url-fetch) - (uri (pypi-uri "hatchling" version)) - (sha256 - (base32 - "1isk1kqra0sm2sj2yp39sgk62mx0bp1jnbkwdcl3a1vjrji7blpq")))) - (build-system pyproject-build-system) - (arguments - (list - #:tests? #false ;there are none - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'do-not-depend-on-hatchling - (lambda _ - ;; We don't use hatchling. - (delete-file "pyproject.toml") - (call-with-output-file "pyproject.toml" - (lambda (port) - (format port "\ -[build-system] -build-backend = 'setuptools.build_meta' -requires = ['setuptools'] -"))) - (call-with-output-file "setup.cfg" - (lambda (port) - (format port "\ -[metadata] -name = hatchling -version = '~a' " #$version)))))))) - (propagated-inputs - (list python-editables - python-importlib-metadata - python-packaging - python-pathspec - python-pluggy - python-tomli)) - (home-page "https://pypi.org/project/hatchling/") - (synopsis "Extensible Python build backend") - (description "Hatchling is an extensible Python build backend.") - (license license:expat))) - (define-public python-hdf4 (package (name "python-hdf4") @@ -1863,14 +1824,14 @@ library.") (define-public python-h5py (package (name "python-h5py") - (version "3.6.0") + (version "3.8.0") (source (origin (method url-fetch) (uri (pypi-uri "h5py" version)) (sha256 (base32 - "0afv805vqrm5071g7alwv41920nhh8kjv4m5nbia9awj9a0x4ll7")))) + "0pyr6z4h2xqbp49yx2i1401gl6yqh03h771zslwcy0201hpxiskg")))) (build-system python-build-system) (arguments `(#:tests? #f ; no test target @@ -2350,8 +2311,20 @@ other machines, such as over the network.") (substitute* "setuptools/py33compat.py" (("html_parser.HTMLParser\\(\\).unescape") "html.unescape")) + ;; collections classes have moved in Python 3.10 + (substitute* "pkg_resources/_vendor/pyparsing.py" + (("collections.MutableMapping") + "collections.abc.MutableMapping") + (("collections.Iterable") + "collections.abc.Iterable")) ;; This needs distutils.msvc9compiler - (delete-file "setuptools/tests/test_msvc.py")))))) + (delete-file "setuptools/tests/test_msvc.py") + ;; See https://github.com/pypa/setuptools/issues/2558 + (delete-file "setuptools/command/bdist_wininst.py") + (substitute* "setuptools/command/install_scripts.py" + (("bw_cmd =.*") "\n") + (("is_wininst =.*") + "is_wininst = False\n"))))))) (native-inputs (list python-pytest python-mock python-six))))) @@ -2434,13 +2407,18 @@ language. It aims to be fast.") (define-public python-aenum (package (name "python-aenum") - (version "2.2.4") + (version "3.1.12") (source (origin (method url-fetch) (uri (pypi-uri "aenum" version)) (sha256 - (base32 "0r1812bjm72x73pl7y4yhffr4zbdjgxa08avsy4b3di0pqgqv0l1")))) + (base32 "1w1ffkcxgnimi5w8802qk6w2qxz9k8hpvsg6yy2zi08ahs8iqlry")) + (modules '((guix build utils))) + (snippet + ;; Delete the Python 2 specific files which won't compile + ;; in Python 3. + '(for-each delete-file (find-files "." "_py2.py$"))))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -3143,14 +3121,14 @@ lossless but can be tweaked for more aggressive cleaning.") (define-public python-mechanize (package (name "python-mechanize") - (version "0.4.5") + (version "0.4.7") (source (origin (method url-fetch) (uri (pypi-uri "mechanize" version)) (sha256 (base32 - "1z9kqcwb8gfq2l6i42z624kxpd8692a0c8gw2x5bbm7n848w2mb3")))) + "02b845y85ka5sl2cj93lll3v326d8bww07bq1q0y1643h7sshwqp")))) (build-system python-build-system) (propagated-inputs (list python-html5lib)) @@ -3555,6 +3533,7 @@ and is not compatible with JSON.") (build-system python-build-system) (arguments (list + #:tests? #f ;TODO: Circular dependency on pytest #:phases #~(modify-phases %standard-phases ;; XXX: PEP 517 manual build/install procedures copied from @@ -3574,7 +3553,7 @@ and is not compatible with JSON.") (lambda* (#:key tests? #:allow-other-keys) (when tests? (invoke "pytest" "-vv" "tests"))))))) - (native-inputs (list python-flit-scm python-pypa-build python-pytest)) + (native-inputs (list python-flit-scm python-pypa-build)) (home-page "https://github.com/agronholm/exceptiongroup") (synopsis "PEP 654 backport from Python 3.11") (description "This is a backport of the @code{BaseExceptionGroup} and @@ -3737,14 +3716,14 @@ port forwards using @acronym{UPnP, Universal Plug and Play}.") (define-public python-py (package (name "python-py") - (version "1.10.0") + (version "1.11.0") (source (origin (method url-fetch) (uri (pypi-uri "py" version)) (sha256 (base32 - "1lqvkqk3b440g9z82gqbzlzas84wrm6ir8kplzhzavmn2pd1pf11")))) + "06c7m7sfcn7587xd4s2bng8m6q1gsfd3j93afhplfjq74r0mrisi")))) (build-system python-build-system) (arguments ;; FIXME: "ImportError: 'test' module incorrectly imported from @@ -3970,7 +3949,7 @@ with sensible defaults out of the box.") "010j9zz0gd2za5l4hibicypnfw721x0gxp3rr0329bc97vw5maha")))) (build-system python-build-system) (propagated-inputs - (list python-pillow python-toml python-numpy-next python-attrs)) + (list python-pillow python-toml python-numpy python-attrs)) (inputs (list libx11 libpng libxcursor)) (native-inputs (list python-wheel)) (home-page "https://github.com/ful1e5/clickgen") @@ -4074,37 +4053,6 @@ compare, diff, and patch JSON and JSON-like structures in Python.") (define-public python-jsonschema (package (name "python-jsonschema") - (version "3.2.0") - (source (origin - (method url-fetch) - (uri (pypi-uri "jsonschema" version)) - (sha256 - (base32 - "0ykr61yiiizgvm3bzipa3l73rvj49wmrybbfwhvpgk3pscl5pa68")))) - (build-system python-build-system) - (arguments - '(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (when tests? - (setenv "JSON_SCHEMA_TEST_SUITE" "json") - (invoke "trial" "jsonschema"))))))) - (native-inputs - `(("python-setuptools_scm" ,python-setuptools-scm) - ("python-twisted" ,python-twisted))) - (propagated-inputs - (list python-attrs python-pyrsistent python-six)) - (home-page "https://github.com/Julian/jsonschema") - (synopsis "Implementation of JSON Schema for Python") - (description - "Jsonschema is an implementation of JSON Schema for Python.") - (license license:expat))) - -;;; TODO: Make the default python-jsonschema on core-updates -(define-public python-jsonschema-next - (package - (inherit python-jsonschema) ;; XXX: Update to the latest version requires new build system - Hatch ;; https://hatch.pypa.io/ (version "4.5.1") @@ -4115,13 +4063,32 @@ compare, diff, and patch JSON and JSON-like structures in Python.") (sha256 (base32 "1z0x22691jva7lwfcfh377jdmlz68zhiawxzl53k631l34k8hvbw")))) (build-system pyproject-build-system) - (native-inputs - (list python-setuptools-scm python-twisted)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, but + ;; without the git metadata available, the version string is set to + ;; '0.0.0'. + (lambda _ + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "JSON_SCHEMA_TEST_SUITE" "json") + (invoke "trial" "jsonschema"))))))) + (native-inputs (list python-setuptools-scm python-twisted)) (propagated-inputs (list python-attrs python-importlib-metadata python-pyrsistent - python-typing-extensions)))) + python-typing-extensions)) + (home-page "https://github.com/Julian/jsonschema") + (synopsis "Implementation of JSON Schema for Python") + (description + "Jsonschema is an implementation of JSON Schema for Python.") + (license license:expat))) (define-public python-schema (package @@ -4349,6 +4316,18 @@ JavaScript-like message boxes. Types of dialog boxes include: (base32 "1ynkqpv2akldmvkll5vh5zhwj433s1d59iv0f76lygyak4silgwr")))) (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'skip-broken-test + (lambda _ + ;; FIXME: This test fails for no good reason: + ;; https://github.com/pympler/pympler/issues/153 + (substitute* "test/muppy/test_tracker.py" + (("^([[:blank:]]+)def test_stracker_create_summary" all indent) + (string-append indent "@unittest.skipIf(True, \ +'Fails on Guix too for unknown reasons')\n" all)))))))) (synopsis "Measure, monitor and analyze memory behavior") (description "Pympler is a development tool to measure, monitor and analyze @@ -4608,14 +4587,14 @@ possible.") (define-public python-markupsafe (package (name "python-markupsafe") - (version "2.0.1") + (version "2.1.1") (source (origin (method url-fetch) (uri (pypi-uri "MarkupSafe" version)) (sha256 (base32 - "02k2ynmqvvd0z0gakkf8s4idyb606r7zgga41jrkhqmigy06fk2r")))) + "0jqxp5sfrc0byp6bk0gwdmildi4mck2gprp42afri3z4r5y1k4bz")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -5055,14 +5034,13 @@ leaf preserving the overall structure.") (define-public python-docutils (package (name "python-docutils") - (version "0.17.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "docutils" version)) - (sha256 - (base32 - "09gii36lp1bs26cpxqyfd20xahnpbrbjzcnba2xq08y3wk97frb8")))) + (version "0.19") + (source (origin + (method url-fetch) + (uri (pypi-uri "docutils" version)) + (sha256 + (base32 + "1rprvir116g5rz2bgzkzgyn6mv0z8582rz7bgxbpy2y3adkmm69k")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -5070,8 +5048,7 @@ leaf preserving the overall structure.") (lambda* (#:key tests? #:allow-other-keys) (if tests? (invoke "python" "test/alltests.py") - (format #t "test suite not run~%")) - #t))))) + (format #t "test suite not run~%"))))))) (home-page "https://docutils.sourceforge.net/") (synopsis "Python Documentation Utilities") (description @@ -5085,18 +5062,6 @@ via commands such as @command{rst2man}, as well as supporting Python code.") ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses. (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+)))) -;; TODO: Make this the default in the next rebuild cycle. -(define-public python-docutils-0.19 - (package - (inherit python-docutils) - (version "0.19") - (source (origin - (method url-fetch) - (uri (pypi-uri "docutils" version)) - (sha256 - (base32 - "1rprvir116g5rz2bgzkzgyn6mv0z8582rz7bgxbpy2y3adkmm69k")))))) - ;; awscli refuses to be built with docutils < 0.16. (define-public python-docutils-0.15 (package @@ -5492,7 +5457,7 @@ operating_system/path_expansion.robot"))) (invoke "xvfb-run" "atest/run.py"))))))) (native-inputs (list python-docutils - python-jsonschema-next + python-jsonschema python-invoke python-lxml python-pygments @@ -6128,25 +6093,6 @@ and integrated feature-set for programming Python effectively.") (define-public python-language-server (deprecated-package "python-language-server" python-lsp-server)) -(define-public python-pathspec - (package - (name "python-pathspec") - (version "0.9.0") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pathspec" version)) - (sha256 - (base32 - "1cdbdb3s6ldnjpwbi0bgl0xlmw4mbfxk08bbdxc3srx26na4jr75")))) - (build-system python-build-system) - (home-page "https://github.com/cpburnz/python-path-specification") - (synopsis "Utility library for gitignore style pattern matching of file paths") - (description - "This package provides a utility library for gitignore style pattern -matching of file paths.") - (license license:mpl2.0))) - (define-public python-black (package (name "python-black") @@ -6366,7 +6312,7 @@ writing C extensions for Python as easy as Python itself.") (define-public python-numpy (package (name "python-numpy") - (version "1.21.6") + (version "1.23.2") (source (origin (method url-fetch) @@ -6375,7 +6321,7 @@ writing C extensions for Python as easy as Python itself.") version "/numpy-" version ".tar.gz")) (sha256 (base32 - "0b0c5y35rd3mvwfk5is1d5ppfw9nl4d2rgx9xkwh1p0w394wdvyl")))) + "00bx3idjwhmzkdawg2dx1bp0316ig37jfx0dm82bvyv1hbj013dp")))) (build-system python-build-system) (arguments (list @@ -6397,7 +6343,10 @@ writing C extensions for Python as easy as Python itself.") [openblas] libraries = openblas library_dirs = ~a/lib -include_dirs = ~:*~a/include~%" #$(this-package-input "openblas")))))) +include_dirs = ~:*~a/include~%" + (dirname (dirname + (search-input-file + inputs "include/openblas_config.h")))))))) (add-before 'build 'fix-executable-paths (lambda* (#:key inputs #:allow-other-keys) ;; Make /gnu/store/...-bash-.../bin/sh the default shell, @@ -6421,7 +6370,20 @@ include_dirs = ~:*~a/include~%" #$(this-package-input "openblas")))))) ;; These tests may fail on 32-bit systems (see: ;; https://github.com/numpy/numpy/issues/18387). "not test_float_remainder_overflow " - "and not test_pareto" + "and not test_pareto " + ;; The 'test_rint_big_int' test fails on older + ;; x86_64 CPUs such as the Core 2 Duo (see: + ;; https://github.com/numpy/numpy/issues/22170). + "and not test_rint_big_int " + ;; The huge_array test is too large for 32-bit (see: + ;; https://bugs.gentoo.org/843599 and + ;; https://bugs.gentoo.org/846548). + ;; TestKind.test_all is a Fortran type failure + ;; that may be toolchain or environment related. + #$@(if (or (target-x86?) (target-arm32?)) + `(" and not test_identityless_reduction_huge_array" + " and not (TestKind and test_all)") + '()) ;; These tests seem to fail on machines without ;; an FPU is still under investigation upstream. ;; https://github.com/numpy/numpy/issues/20635 @@ -6431,9 +6393,10 @@ include_dirs = ~:*~a/include~%" #$(this-package-input "openblas")))))) '()))))))))) (native-inputs (list python-cython - python-hypothesis-next + python-hypothesis python-pytest python-pytest-xdist + python-typing-extensions gfortran)) (inputs (list bash openblas)) (home-page "https://numpy.org") @@ -6447,22 +6410,6 @@ capabilities.") '((upstream-name . "numpy"))) (license license:bsd-3))) -(define-public python-numpy-next - (package - (inherit python-numpy) - (name "python-numpy-next") - (version "1.22.3") - (source - (origin - (inherit (package-source python-numpy)) - (method url-fetch) - (uri (string-append - "https://github.com/numpy/numpy/releases/download/v" - version "/numpy-" version ".tar.gz")) - (sha256 - (base32 - "19dw91pqbqcniw2z57kiyqs1qp56g7kqy1bdyv664g8s62sc01m9")))))) - (define-public python-numpy-documentation (package (inherit python-numpy) @@ -6970,23 +6917,18 @@ parse and apply unified diffs. It has features such as: (define-public python-numpydoc (package (name "python-numpydoc") - (version "1.2.1") + (version "1.5.0") (source (origin (method url-fetch) (uri (pypi-uri "numpydoc" version)) (sha256 (base32 - "1xjsli2fqks4iv3524v1d329siad7bbsi4kr174zvhsl1pnjds3w")))) + "0k2z3g4s3w39h1nd293542hl9qv55j29gcr3bkia0rr3ldsppnxh")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'relax-requirements - (lambda _ - (substitute* "setup.py" - (("'Jinja2>=2.10,<3.1'") - "'Jinja2>=2.10'")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -7003,14 +6945,14 @@ parse and apply unified diffs. It has features such as: (define-public python-numexpr (package (name "python-numexpr") - (version "2.7.3") + (version "2.8.4") (source (origin (method url-fetch) (uri (pypi-uri "numexpr" version)) (sha256 (base32 - "09d8yfsx33ddwfkpn8805w2mxnn4cvf47yc66g4azldpz4lnaqa3")))) + "0iv1h1lvry5vmzqyvwxfbckyhzm1vbb1bmhmj4dnj64d84vjahym")))) (build-system python-build-system) (arguments `(#:tests? #f)) ; no tests included (propagated-inputs @@ -7208,16 +7150,23 @@ tests = True~%" (assoc-ref inputs "tcl") (assoc-ref inputs "tk")))))) (invoke "pytest" "-n" (number->string (parallel-job-count)) "-m" "not network" "--pyargs" "matplotlib" - ;; The 'test_lazy_auto_backend_selection' fails - ;; because it would require an X server; skip it. - "-k" "not test_lazy_auto_backend_selection")))))))) + "-k" + (string-append + ;; The 'test_lazy_auto_backend_selection' fails + ;; because it would require an X server; skip it. + "not test_lazy_auto_backend_selection" + ;; test_getattr fails for the GTK backend because + ;; of an unexpected warning from Python 3.10 + ;; (via the gi module): + ;; https://gitlab.gnome.org/GNOME/pygobject/-/issues/494 + " and not test_getattr"))))))))) (propagated-inputs (list gobject-introspection python-cairocffi python-certifi python-cycler python-dateutil - python-fonttools + python-fonttools-minimal python-kiwisolver python-numpy python-packaging @@ -7693,31 +7642,43 @@ by pycodestyle.") (define-public python-distlib (package (name "python-distlib") - (version "0.3.1") + (version "0.3.5") (source (origin (method url-fetch) - (uri (pypi-uri "distlib" version ".zip")) + (uri (pypi-uri "distlib" version)) (sha256 (base32 - "1wdzv7fsjhrkhh1wfkarlhcwa8m00mgcpdsvknmf2qy8f9l13xpd")))) + "1zmjraasgqkz0gfv4mc4w4fj4k2fxj62h1pf5dgb5qqbqwvmgxx7")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'build 'no-/bin/sh - (lambda _ - (substitute* '("distlib/scripts.py" "tests/test_scripts.py") - (("/bin/sh") (which "sh"))) - #t)) - (add-before 'check 'prepare-test-env - (lambda _ - (setenv "HOME" "/tmp") - ;; NOTE: Any value works, the variable just has to be present. - (setenv "SKIP_ONLINE" "1") - #t))))) - (native-inputs (list unzip)) - (home-page "https://bitbucket.org/pypa/distlib") + (list + #:phases + #~(modify-phases %standard-phases + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (add-before 'build 'no-/bin/sh + (lambda _ + (substitute* '("distlib/scripts.py" "tests/test_scripts.py") + (("/bin/sh") (which "sh"))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (setenv "HOME" "/tmp") + ;; NOTE: Any value works, the variable just has to be present. + (setenv "SKIP_ONLINE" "1") + (when tests? + (invoke "pytest" "-vv")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs + (list python-pypa-build python-pytest)) + (home-page "https://github.com/pypa/distlib") (synopsis "Distribution utilities") (description "Distlib is a library which implements low-level functions that relate to packaging and distribution of Python software. It is intended to be @@ -7823,7 +7784,6 @@ retrieve text and metadata from PDFs as well as merge entire files together.") (package (name "python-pillow") (version "9.2.0") - (replacement python-pillow/security-fixes) (source (origin (method url-fetch) (uri (pypi-uri "Pillow" version)) @@ -7832,7 +7792,9 @@ retrieve text and metadata from PDFs as well as merge entire files together.") "011wgm1mssjchpva9wsi2a07im9czyjvik137xlp5f0g7vykdrkm")) (modules '((guix build utils))) (snippet '(begin - (delete-file-recursively "src/thirdparty"))))) + (delete-file-recursively "src/thirdparty"))) + (patches + (search-patches "python-pillow-CVE-2022-45199.patch")))) (build-system python-build-system) (native-inputs (list python-pytest)) (inputs (list freetype @@ -7871,10 +7833,6 @@ a general image processing tool.") "http://www.pythonware.com/products/pil/license.htm" "The PIL Software License")))) -(define python-pillow/security-fixes - (package-with-patches python-pillow - (search-patches "python-pillow-CVE-2022-45199.patch"))) - (define-public python-pillow-2.9 (package (inherit python-pillow) @@ -8959,14 +8917,14 @@ older Python versions.") (define-public python-importlib-metadata (package (name "python-importlib-metadata") - (version "4.11.3") + (version "5.2.0") (source (origin (method url-fetch) (uri (pypi-uri "importlib_metadata" version)) (sha256 (base32 - "0f951zynlh39yicqnhrs3p1qa5p3g6ajjfcggf12y51ppxz5jk7a")))) + "1kf7qclcz820xl5wwjpzcwpfy6shj7ymwh4xzxvpl2xs5gb4hka0")))) (build-system python-build-system) (arguments (list @@ -9764,13 +9722,13 @@ abstract syntax tree (AST) nodes without side effects.") (define-public python-asttokens (package (name "python-asttokens") - (version "2.0.5") + (version "2.2.1") (source (origin (method url-fetch) (uri (pypi-uri "asttokens" version)) (sha256 - (base32 "1mglbkikxvnhrk3inbx0v1qzxwd38qjr6l35sn098yicy0ac2m4s")))) + (base32 "1wwlpvnrh67z4228841zgpqc46vigslzmbvk2izbfc3g585i28j6")))) (build-system python-build-system) (propagated-inputs (list python-six)) (native-inputs (list python-astroid python-pytest python-setuptools-scm)) @@ -9829,13 +9787,13 @@ than the default.") (define-public python-ipython (package (name "python-ipython") - (version "8.2.0") + (version "8.5.0") (source (origin (method url-fetch) (uri (pypi-uri "ipython" version ".tar.gz")) (sha256 - (base32 "1hcxa713wh3axa57412iy02rj0494ljvv6gpnls4lndc5h9yprbh")))) + (base32 "114z175hnv1lgprj06zfcil7lkq013rggjbrc43gsxkmv1fdyyq9")))) (build-system python-build-system) (arguments `(#:phases @@ -10983,17 +10941,18 @@ low-level X clients. It is written entirely in Python.") (define-public python-singledispatch (package (name "python-singledispatch") - (version "3.4.0.3") + (version "4.0.0") (source (origin (method url-fetch) (uri (pypi-uri "singledispatch" version)) (sha256 (base32 - "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv")))) - (build-system python-build-system) + "1z5qbbvvjvh3cwcjv57p7vzhayx0j1ysnvjq0d5py6k5d2ljghzk")))) + (build-system pyproject-build-system) (native-inputs - (list python-six)) ; required for conversion, not at run-time + (list python-pytest + python-six)) ; required for conversion, not at run-time (home-page "https://docs.python.org/3/library/functools.html#functools.singledispatch") (synopsis "Backport of singledispatch feature from Python 3.4") @@ -11086,13 +11045,13 @@ applications.") (define-public python-pyzmq (package (name "python-pyzmq") - (version "22.3.0") + (version "25.0.2") (source (origin (method url-fetch) (uri (pypi-uri "pyzmq" version)) (sha256 - (base32 "0737kizh53n4rjq1xbm6nhr0bq65xflg04i1d8fcky0nwwrw1pcf")) + (base32 "0jai5sbd4ypihsvr4ikq6d93nkmxwv53598sh24dqs78f2xip33b")) (snippet #~(begin (use-modules (guix build utils)) @@ -11100,8 +11059,7 @@ applications.") (delete-file-recursively "bundled") ;; Delete cythonized files. (for-each delete-file - (list "zmq/backend/cython/constants.c" - "zmq/backend/cython/context.c" + (list "zmq/backend/cython/context.c" "zmq/backend/cython/_device.c" "zmq/backend/cython/error.c" "zmq/backend/cython/message.c" @@ -11117,6 +11075,15 @@ applications.") (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq"))) #:phases (modify-phases %standard-phases + (add-after 'unpack 'disable-problematic-tests + (lambda _ + ;; FIXME: The test_draft.TestDraftSockets test fails with: + ;; zmq.error.Again: Resource temporarily unavailable + (delete-file "zmq/tests/test_draft.py") + ;; These tests fail for unknown reasons (see: + ;; https://github.com/zeromq/pyzmq/issues/1853). + (delete-file "zmq/tests/test_auth.py") + (delete-file "zmq/tests/test_zmqstream.py"))) (add-before 'check 'build-extensions (lambda _ ;; Cython extensions have to be built before running the tests. @@ -11124,7 +11091,11 @@ applications.") (inputs (list zeromq)) (native-inputs - (list pkg-config python-cython python-pytest)) + (list pkg-config + python-cython + python-pytest + python-pytest-asyncio + python-tornado)) (home-page "https://github.com/zeromq/pyzmq") (synopsis "Python bindings for 0MQ") (description @@ -12235,17 +12206,17 @@ number of lines in the contained files easily.") (license license:expat))) ;;; Tests are left out in the main package to avoid cycles. -(define-public python-fonttools +(define-public python-fonttools-minimal (hidden-package (package - (name "python-fonttools") - (version "4.28.5") + (name "python-fonttools-minimal") + (version "4.39.3") (source (origin (method url-fetch) (uri (pypi-uri "fonttools" version ".zip")) (sha256 (base32 - "1jhl5n3rfqq7fznvsh6r80n7ylap1a7ppq1040y8cflhyz80ap2l")))) + "1msibi5cmi5znykkg66dq7xshl07lkqjxhrz5hcipqvlggsvjd4j")))) (build-system python-build-system) (native-inputs (list unzip)) @@ -12260,60 +12231,48 @@ also contains a tool called “TTX” which converts TrueType/OpenType fonts to from an XML-based format.") (license license:expat)))) -;;; Rename 'python-fonttools' in next cycle, renaming the current -;;; 'python-fonttools' to 'python-fonttools-minimal'. -(define-public python-fonttools-full - (package/inherit python-fonttools - (arguments - (substitute-keyword-arguments (package-arguments python-fonttools) - ((#:tests? _ #f) - (not (%current-target-system))) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "pytest" "-vv" - "-k" - ;; XXX: These tests need .trm files that are - ;; not shipped with the PyPI release. - (format #f "not ~a" - (string-join - '("test_read_fontdimens_mathsy" - "test_read_fontdimens_mathex" - "test_read_fontdimens_vanilla" - "test_read_boundary_char" - "fontTools.tfmLib" - ;; The MtiTest tests fail for unknown - ;; reasons (see: - ;; https://github.com/fonttools/ - ;; fonttools/issues/3078) - "MtiTest") - " and not ")))))))))) - (native-inputs - (modify-inputs (package-native-inputs python-fonttools) - (append python-pytest))) - (propagated-inputs - (list python-brotli - python-fs - python-lxml - python-lz4 - python-scipy - python-unicodedata2 - python-zopfli)) - (properties (alist-delete 'hidden? (package-properties python-fonttools))))) - -(define-public python-fonttools-next - (package - (inherit python-fonttools-full) - (version "4.39.3") - (source (origin - (inherit (package-source python-fonttools-full)) - (method url-fetch) - (uri (pypi-uri "fonttools" version ".zip")) - (sha256 - (base32 - "1msibi5cmi5znykkg66dq7xshl07lkqjxhrz5hcipqvlggsvjd4j")))))) +(define-public python-fonttools + (let ((base python-fonttools-minimal)) + (package/inherit base + (name "python-fonttools") + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:tests? _ #f) + (not (%current-target-system))) + ((#:phases phases '%standard-phases) + `(modify-phases ,phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + "-k" + ;; XXX: These tests need .trm files that are + ;; not shipped with the PyPI release. + (format #f "not ~a" + (string-join + '("test_read_fontdimens_mathsy" + "test_read_fontdimens_mathex" + "test_read_fontdimens_vanilla" + "test_read_boundary_char" + "fontTools.tfmLib" + ;; The MtiTest tests fail for unknown + ;; reasons (see: + ;; https://github.com/fonttools/ + ;; fonttools/issues/3078) + "MtiTest") + " and not ")))))))))) + (native-inputs + (modify-inputs (package-native-inputs base) + (append python-pytest))) + (propagated-inputs + (list python-brotli + python-fs + python-lxml + python-lz4 + python-scipy + python-unicodedata2 + python-zopfli)) + (properties (alist-delete 'hidden? (package-properties base)))))) (define-public python-ly (package @@ -12340,14 +12299,14 @@ provided that can be used to do various manipulations with LilyPond files.") (define-public python-appdirs (package (name "python-appdirs") - (version "1.4.3") + (version "1.4.4") (source (origin (method url-fetch) (uri (pypi-uri "appdirs" version)) (sha256 (base32 - "14id6wxi12lgyw0mg3bcfnf888ad07jz9yj46gfzhn186z8rcn4y")))) + "0hfzmwknxqhg20aj83fx80vna74xfimg8sk18wb85fmin9kh2pbx")))) (build-system python-build-system) (home-page "https://github.com/ActiveState/appdirs") (synopsis @@ -12440,37 +12399,6 @@ reading and writing MessagePack data.") (base32 "1109s2yynrahwi64ikax68hx0mbclz8p35afmpphw5dwynb49q7s")))))) -;; This msgpack library's name changed from "python-msgpack" to "msgpack" with -;; release 0.5. Some packages like borg still call it by the old name for now. -;; <https://bugs.gnu.org/30662> -(define-public python-msgpack-transitional - (package - (inherit python-msgpack) - (name "python-msgpack-transitional") - (version "0.5.6") - (source (origin - (method url-fetch) - (uri (pypi-uri "msgpack" version)) - (sha256 - (base32 - "1hz2dba1nvvn52afg34liijsm7kn65cmn06dl0xbwld6bb4cis0f")))) - (arguments - (substitute-keyword-arguments (package-arguments python-msgpack) - ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'configure-transitional - (lambda _ - ;; Keep using the old name. - (substitute* "setup.py" - (("TRANSITIONAL = False") - "TRANSITIONAL = 1")) - ;; This old version is not compatible with Python 3.9 - (substitute* '("test/test_buffer.py" "test/test_extension.py") - ((".tostring\\(") ".tobytes(")) - (substitute* '("test/test_buffer.py" "test/test_extension.py") - ((".fromstring\\(") ".frombytes(")) - #t)))))))) - (define-public python-netaddr (package (name "python-netaddr") @@ -13907,20 +13835,21 @@ Debian-related files, such as: (define-public python-json-spec (package (name "python-json-spec") - (version "0.10.1") + (version "0.11.0") (source (origin (method url-fetch) - (uri (pypi-uri "json-spec" version)) + (uri (pypi-uri "json_spec" version)) (sha256 (base32 - "06dpbsq61ja9r89wpa2pzdii47qh3xri9ajdrgn1awfl102znchb")))) + "0fwxirzxx5s9l0lwnjl6ki39xw1fsjm0vr6cm67ws27fkmcxcry7")))) (build-system python-build-system) (propagated-inputs - (list python-pathlib python-six)) + (list python-importlib-metadata + python-termcolor)) (native-inputs (list python-pytest)) - (home-page "http://py.errorist.io/json-spec") + (home-page "https://json-spec.readthedocs.io/") (synopsis "JSON Schema, JSON Pointer and JSON Reference for Python") (description @@ -13986,8 +13915,7 @@ significantly better performance.") python-pylint python-pytest python-pytest-benchmark - python-pytest-cache - python-validictory)) + python-pytest-cache)) (home-page "https://github.com/horejsek/python-fastjsonschema") (synopsis @@ -14252,7 +14180,8 @@ time.") (list python-ipykernel ;; Adding ipywidgets would create a cycle. ;;python-ipywidgets - ;;python-pyppeteer ;TODO: package me + ;; XXX: Disabled, not in guix. + ;;python-pyppeteer python-pytest python-pytest-xdist)) (propagated-inputs @@ -14278,14 +14207,14 @@ time.") texlive-caption texlive-enumitem texlive-fontspec - texlive-generic-iftex + texlive-iftex texlive-grffile texlive-hyperref - texlive-latex-fancyvrb + texlive-fancyvrb texlive-latex-float texlive-latex-geometry texlive-latex-jknapltx - texlive-latex-ms + texlive-ms texlive-latex-parskip texlive-latex-trimspaces texlive-latex-upquote @@ -15139,34 +15068,59 @@ pure Python module that works on virtually all Python versions.") (license license:expat))) (define-public python-execnet - (package - (name "python-execnet") - (version "1.9.0") - (source (origin - (method url-fetch) - (uri (pypi-uri "execnet" version)) - (sha256 - (base32 - "1ia7dvrh0gvzzpi758mx55f9flr16bzdqlmi12swm4ncm4xlyscg")) - (patches (search-patches "python-execnet-read-only-fix.patch")))) - (build-system python-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (when tests? - ;; Unset PYTHONDONTWRITEBYTECODE to match the - ;; expectations of a test in - ;; 'testing/test_gateway.py'. - (unsetenv "PYTHONDONTWRITEBYTECODE") - - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv"))))))) - (native-inputs - (list python-pytest python-setuptools-scm)) - (synopsis "Rapid multi-Python deployment") - (description "Execnet provides a share-nothing model with + ;; The latest release (1.9.0) is old and lacks support for Pytest 7.2. + (let ((commit "d6aa1a56773c2e887515d63e50b1d08338cb78a7") + (revision "1")) + (package + (name "python-execnet") + (version (git-version "1.9.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/pytest-dev/execnet") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0s60jggcjiw38b7xsh1q2lnnr4c4kaki7c5zsv7xyj7df8ngbbsm")))) + (build-system pyproject-build-system) + (arguments + (list + ;; ;; This test hasn't been updated for the latest Pytest yet: + ;; #:test-flags #~(list "--ignore" "testing/test_rsync.py") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'adjust-for-pytest-7.2+ + (lambda _ + ;; This test fails with an error because @py.test has been + ;; deprecated for @pytest in recent Pytest. + (substitute* "testing/test_rsync.py" + (("@py.test") + "@pytest")))) + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, but + ;; without the git metadata available this fails. + (lambda _ + ;; hatch-vcs uses setuptools under the hood. + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" + ;; Massage the version string to a PEP-0440 compatible + ;; one. + #$(car (string-split version #\-))))) + (add-before 'check 'prepare-for-tests + (lambda _ + ;; Unset PYTHONDONTWRITEBYTECODE to match the + ;; expectations of a test in + ;; 'testing/test_gateway.py'. + (unsetenv "PYTHONDONTWRITEBYTECODE")))))) + (native-inputs + (list python-hatchling + python-hatch-vcs + python-py + python-pytest + python-pytest-timeout + python-setuptools-scm)) + (synopsis "Rapid multi-Python deployment") + (description "Execnet provides a share-nothing model with channel-send/receive communication for distributing execution across many Python interpreters across version, platform and network barriers. It has a minimal and fast API targeting the following uses: @@ -15175,8 +15129,8 @@ minimal and fast API targeting the following uses: @item write and deploy hybrid multi-process applications @item write scripts to administer multiple environments @end enumerate") - (home-page "https://codespeak.net/execnet/") - (license license:expat))) + (home-page "https://codespeak.net/execnet/") + (license license:expat)))) (define-public python-icalendar (package @@ -15317,7 +15271,7 @@ with a new public API, and RPython support.") " and not test_macro_require" " and not test_requires_pollutes_core")))))))) (native-inputs - (list python-pytest-7.1 python-wheel)) + (list python-pytest python-wheel)) (propagated-inputs (list python-funcparserlib)) (home-page "https://docs.hylang.org/en/stable/") @@ -15567,39 +15521,6 @@ library as well as on the command line.") (home-page "https://stuvel.eu/rsa") (license license:asl2.0))) -(define-public python-pluggy - (package - (name "python-pluggy") - (version "0.13.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pluggy" version)) - (sha256 - (base32 - "1c35qyhvy27q9ih9n899f3h4sdnpgq027dbiilly2qb5cvgarchm")))) - (build-system python-build-system) - (native-inputs - (list python-setuptools-scm)) - (synopsis "Plugin and hook calling mechanism for Python") - (description "Pluggy is an extraction of the plugin manager as used by -Pytest but stripped of Pytest specific details.") - (home-page "https://pypi.org/project/pluggy/") - (license license:expat))) - -;;; TODO: Make this the default python-pluggy in the next rebuild cycle. -(define-public python-pluggy-next - (package - (inherit python-pluggy) - (version "1.0.0") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pluggy" version)) - (sha256 - (base32 - "0n8iadlas2z1b4h0fc73b043c7iwfvx9rgvqm1azjmffmhxkf922")))))) - (define-public python-plumbum (package (name "python-plumbum") @@ -16071,27 +15992,27 @@ of @acronym{REGEXPs, regular expressions}.") (define-public python-mako (package (name "python-mako") - (version "1.1.3") + (version "1.2.2") (source (origin (method url-fetch) (uri (pypi-uri "Mako" version)) (sha256 (base32 - "09ywrmhr6gdyfx6d5727wwjnz73i6rklqcb4c14m7sqc830wi5c1")))) + "0gqnv9py1dqp01jmf5zxp0vj2dbhq1l9zy55fai319iv6sdqc91p")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? - (invoke "nosetests" "-v") + (invoke "pytest" "-vv") (format #t "test suite not run~%")) #t))))) (propagated-inputs (list python-markupsafe)) (native-inputs - (list python-mock python-nose)) + (list python-mock python-pytest)) (home-page "https://www.makotemplates.org/") (synopsis "Templating language for Python") (description "Mako is a templating language for Python that compiles @@ -16409,7 +16330,7 @@ Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.") python-iniconfig python-moto python-msgpack - python-pytest-7.1 ;for pytest-subtests + python-pytest ;for pytest-subtests python-pytest-celery python-pytest-subtests python-pytest-timeout @@ -16503,7 +16424,7 @@ ISO 8859, etc.).") (lambda _ (setenv "QT_QPA_PLATFORM" "offscreen")))))) (native-inputs - (list python-pytest-7.1 python-pytest-cov python-pytest-xdist)) + (list python-pytest python-pytest-cov python-pytest-xdist)) (inputs (list qtbase-5)) (propagated-inputs @@ -16643,7 +16564,7 @@ import platform reason=\"Fails on 32 bit architectures\") " m)))))))) (build-system python-build-system) - (native-inputs (list python-pytest-6)) + (native-inputs (list python-pytest)) (home-page "https://software.clapper.org/munkres/") (synopsis "Implementation of the Munkres algorithm") (description "The Munkres module provides an implementation of the Munkres @@ -16985,9 +16906,7 @@ for Python inspired by modern web development.") (list which)) (inputs ;; python-magic needs to be able to find libmagic.so. - ;; Use a newer version because 5.39 returns bogus for some archives - ;; (notably Chromium .crx extensions), which breaks e.g. 'diffoscope'. - (list file-next)) + (list file)) (synopsis "File type identification using libmagic") (description "This module uses ctypes to access the libmagic file type @@ -17777,13 +17696,13 @@ docstring and colored output.") (define-public python-tomlkit (package (name "python-tomlkit") - (version "0.7.0") + (version "0.11.6") (source (origin (method url-fetch) (uri (pypi-uri "tomlkit" version)) (sha256 - (base32 "062n694sfv24ylda6nh8228y2q9hrvy554kqx84y7czsjfbg4mxc")))) + (base32 "0wsxnv9bs7jk8ig8blj9c438a1ygvdad7y9cn1zr720nfbjm5fbi")))) (build-system python-build-system) (native-inputs (list python-pytest python-pyyaml)) @@ -17941,7 +17860,7 @@ strings require only one extra byte in addition to the strings themselves.") ;; build system and new Rust dependencies. "--ignore" "tests/test_preconf.py"))))))) (native-inputs - (list python-hypothesis-next + (list python-hypothesis python-immutables python-msgpack python-poetry-core @@ -17994,25 +17913,26 @@ database, file, dict stores. Cachy supports python versions 2.7+ and 3.2+.") (define-public poetry (package (name "poetry") - (version "1.1.12") + (version "1.4.2") (source (origin (method url-fetch) (uri (pypi-uri "poetry" version)) (sha256 (base32 - "0rr54mvcfcv9cv6vw2122y28xvd2pwqpv2x8c8j5ayz3gwsy4rjw")))) + "0g0vczn6qa4b2bdkq4k7fm1g739vyxp2iiblwwsrcmw24jj81m8b")))) (build-system python-build-system) (arguments `(#:tests? #f ;PyPI does not have tests - #:phases - (modify-phases %standard-phases - (add-before 'build 'patch-setup-py - (lambda _ - (substitute* "setup.py" - ;; Relax some of the requirements. - (("(keyring>=21.2.0),<22.0.0" _ keyring) keyring) - (("(packaging>=20.4),<21.0" _ packaging) packaging))))))) + ;; #:phases + ;; (modify-phases %standard-phases + ;; (add-before 'build 'patch-setup-py + ;; (lambda _ + ;; (substitute* "setup.py" + ;; ;; Relax some of the requirements. + ;; (("(keyring>=21.2.0),<22.0.0" _ keyring) keyring) + ;; (("(packaging>=20.4),<21.0" _ packaging) packaging))))) + )) (propagated-inputs (list python-cachecontrol python-cachy @@ -18021,9 +17941,7 @@ database, file, dict stores. Cachy supports python versions 2.7+ and 3.2+.") python-entrypoints python-html5lib python-keyring - ; Use of deprecated version of msgpack reported upstream: - ; https://github.com/python-poetry/poetry/issues/3607 - python-msgpack-transitional + python-msgpack python-packaging python-pexpect python-pip @@ -18461,7 +18379,7 @@ scans through a file and detects issues.") (define-public python-jedi (package (name "python-jedi") - (version "0.18.1") + (version "0.18.2") (source (origin (method git-fetch) @@ -18472,26 +18390,12 @@ scans through a file and detects issues.") (file-name (git-file-name name version)) (sha256 (base32 - "07drmi3ai49jw5n23ibkambcgijqcw073ihypjgxfnks5lv4yqy1")) - (modules '((guix build utils))) - (snippet - ;; Adjust comprehension syntax for Python > 3.8. - ;; From <https://github.com/davidhalter/jedi/issues/1824>. - '(substitute* "test/completion/lambdas.py" - (("if lambda: 3") - "if (lambda: 3)"))))) + "1nhsajmkn3qj32k5z3ymrd3r6dz2aliv2pqb824m5kaib986dm44")) + (modules '((guix build utils))))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'fix-completion-test - (lambda _ - ;; This resolves a failure in the 'test_completion' test (see: - ;; https://github.com/davidhalter/jedi/issues/1824). - ;; TODO: Remove after a new release is made (currently: 0.18.1). - (substitute* "test/completion/lambdas.py" - (("\\[a for a in \\[1,2\\] if lambda: 3\\]\\[0\\]") - "[a for a in [1,2] if (lambda: 3)][0]")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -18985,6 +18889,35 @@ callback-heavy mode of interaction typical in some Kivy applications.") without requiring an event loop, useful for creative responsive GUIs.") (license license:expat))) +(define-public python-asynctest + (package + (name "python-asynctest") + (version "0.13.0") + (source (origin + (method url-fetch) + (uri (pypi-uri "asynctest" version)) + (sha256 + (base32 + "1b3zsy7p84gag6q8ai2ylyrhx213qdk2h2zb6im3xn0m5n264y62")))) + (build-system python-build-system) + (arguments + ;; The test suite appears to be incompatible with Python 3.9+, completes + ;; with 25 failures and 41 errors out of 220 tests (see: + ;; https://github.com/Martiusweb/asynctest/issues/149). + (list #:tests? #f + #:phases #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "unittest" "test"))))))) + (home-page "https://github.com/Martiusweb/asynctest/") + (synopsis "Unittest extensions for testing asyncio libraries") + (description + "The @code{asynctest} Python package is built on top of the standard +@code{unittest} module and cuts down boilerplate code when testing libraries +for @code{asyncio}.") + (license license:asl2.0))) + (define-public python-binaryornot (package (name "python-binaryornot") @@ -19473,42 +19406,6 @@ task each process is busy with. The technique is used by PostgreSQL and the OpenSSH Server for example.") (license license:bsd-3))) -(define-public python-validictory - (package - (name "python-validictory") - (version "1.0.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "validictory" version)) - (sha256 - (base32 - "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q")))) - (build-system python-build-system) - (arguments - '(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'bootstrap - ;; Move the tests out of the package directory to avoid - ;; packaging them. - (lambda* _ - (rename-file "validictory/tests" "tests") - (delete-file "tests/__init__.py"))) - (replace 'check - (lambda _ - (invoke "py.test" "-vv" )))))) - (native-inputs - (list python-pytest)) - (home-page - "https://github.com/jamesturk/validictory") - (synopsis "General purpose Python data validator") - (description "It allows validation of arbitrary Python data structures. - - The schema format is based on the JSON Schema - proposal (http://json-schema.org), so combined with json the library is also - useful as a validator for JSON data.") - (license license:expat))) - (define-public python-pyelftools (package (name "python-pyelftools") @@ -19750,14 +19647,14 @@ from the header, as well as section details and data available.") (define-public python-cheetah (package (name "python-cheetah") - (version "3.2.4") + (version "3.3.1") (source (origin (method url-fetch) - (uri (pypi-uri "Cheetah3" version)) + (uri (pypi-uri "CT3" version)) (sha256 (base32 - "0ar5dqjnqaw0c17mymd6xgd81jn9br9fblawr0x438v1571bkaya")))) + "1j36vampqip18jx0jzngb9rnkhhhl8hqnscg117y0d6cgrgm57qw")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -20175,13 +20072,13 @@ from the header, as well as section details and data available.") (define-public python-m2r (package (name "python-m2r") - (version "0.2.1") + (version "0.3.1") (source (origin (method url-fetch) (uri (pypi-uri "m2r" version)) (sha256 (base32 - "16gdm8i06jjmlpvckpfmlkr4693dh0vs192vgsqn84fsdkbbm45z")) + "1asnwazfznbs0r7x03pj5ns4npz18z3kli538sgdicfg97y6gyxa")) (modules '((guix build utils))) (snippet ;; Adjust test regex for Python 3.10 compatibility. @@ -20219,21 +20116,21 @@ from the header, as well as section details and data available.") and bit flag values.") (license license:expat))) -(define-public python-attrdict +(define-public python-attrdict3 (package - (name "python-attrdict") - (version "2.0.1") + (name "python-attrdict3") + (version "2.0.2") (source (origin (method url-fetch) - (uri (pypi-uri "attrdict" version)) + (uri (pypi-uri "attrdict3" version)) (sha256 (base32 - "0w3vsz64j9npxfgh83hghsh161wwkrx1fxqi1533js2wnnc0dj9m")))) + "1s2z6c9jam5azm746l49wsqsyi29zbbrknq1axsw230jl4f1fk00")))) (build-system python-build-system) ;; The package is no longer maintained and tests need some work. (arguments '(#:tests? #f)) (propagated-inputs (list python-six)) - (home-page "https://github.com/bcj/AttrDict") + (home-page "https://github.com/pirofti/AttrDict3") (synopsis "Attribute-style access dictionaries") (description "This package provides mapping objects whose elements can be accessed @@ -20347,7 +20244,7 @@ both as keys and as attributes.") (define-public python-astroid (package (name "python-astroid") - (version "2.9.0") + (version "2.11.7") (source (origin (method git-fetch) @@ -20356,7 +20253,7 @@ both as keys and as attributes.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "19iiys4233cicpm48fd7lrkm31kk47qiv44wvk952rqbcn4rd2dh")))) + (base32 "0lmm5bhszg1nj0xsjnh5nm39if2jzpa3ycgvhy6ddycz28dy568y")))) (build-system python-build-system) (propagated-inputs (list python-lazy-object-proxy python-typing-extensions python-wrapt)) @@ -20398,7 +20295,7 @@ builds partial trees by inspecting living objects.") (define-public python-isort (package (name "python-isort") - (version "5.10.1") + (version "5.12.0") (source (origin (method git-fetch) @@ -20411,61 +20308,42 @@ builds partial trees by inspecting living objects.") (snippet '(for-each delete-file (find-files "." "\\.whl$"))) (sha256 (base32 - "09spgl2k9xrprr5gbpfc91a8p7mx7a0c64ydgc91b3jhrmnd9jg1")))) + "1vbwc4gpffclf6hw08lvvgqlvsgfjlw7gjsm28jfcrln2pixla7j")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'loosen-requirements - (lambda _ - ;; Permit newer versions of black. - (substitute* "example_isort_formatting_plugin/pyproject.toml" - (("\\^20\\.08b1") - ">= 20.08b1")))) - ;; A foretaste of what our future python-build-system will need to - ;; do. - (replace 'build - (lambda _ - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" out whl)))) - (add-after 'install 'install-example-plugins - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - ;; Patch to use the core poetry API. - (substitute* '("example_isort_formatting_plugin/pyproject.toml" - "example_isort_sorting_plugin/pyproject.toml" - "example_shared_isort_profile/pyproject.toml") - (("poetry>=0.12") - "poetry-core>=1.0.0") - (("poetry.masonry.api") - "poetry.core.masonry.api")) - ;; Build the example plugins. - (for-each (lambda (source-directory) - (invoke "python" "-m" "build" "--wheel" - "--no-isolation" "--outdir=dist" - source-directory)) - '("example_isort_formatting_plugin" - "example_isort_sorting_plugin" - "example_shared_isort_profile")) - ;; Install them to temporary storage, for the test. - (setenv "HOME" (getcwd)) - (let ((example-whls (find-files "dist" "^example.*\\.whl$"))) - (apply invoke "pip" "--no-cache-dir" "--no-input" - "install" "--user" "--no-deps" example-whls))))) - (replace 'check - (lambda* (#:key tests? inputs outputs #:allow-other-keys) - (when tests? - (let ((bin (string-append (assoc-ref outputs "out") "/bin"))) - (setenv "PATH" (string-append (getenv "PATH") ":" bin))) - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv" "tests/unit/" - "-k" "not test_gitignore" ;requires git - "--ignore=tests/unit/test_deprecated_finders.py"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (replace 'build + (lambda _ + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl)))) + (add-after 'install 'install-example-plugins + (lambda _ + (for-each (lambda (source-directory) + (invoke "python" "-m" "build" "--wheel" + "--no-isolation" "--outdir=dist" + source-directory)) + '("example_isort_formatting_plugin" + "example_isort_sorting_plugin" + "example_shared_isort_profile")) + ;; Install them to temporary storage, for the test. + (setenv "HOME" (getcwd)) + (let ((example-whls (find-files "dist" "^example.*\\.whl$"))) + (apply invoke "pip" "--no-cache-dir" "--no-input" + "install" "--user" "--no-deps" example-whls)))) + (replace 'check + (lambda* (#:key tests? inputs outputs #:allow-other-keys) + (when tests? + (let ((bin (string-append #$output "/bin"))) + (setenv "PATH" (string-append (getenv "PATH") ":" bin))) + (invoke "pytest" "-vv" "tests/unit/" + "-k" "not test_gitignore" ;requires git + "--ignore=tests/unit/test_deprecated_finders.py"))))))) (native-inputs (list python-black python-colorama @@ -20851,12 +20729,8 @@ while only declaring the test-specific fields.") (if tests? (invoke "pytest" "-vv") (format #t "test suite not run~%"))))))) - (native-inputs - `(("python-pretend" ,python-pretend) - ("python-pytest" ,python-pytest))) - (propagated-inputs - `(("python-pyparsing" ,python-pyparsing) - ("python-six" ,python-six))) + (native-inputs (list python-pretend python-pytest)) + (propagated-inputs (list python-pyparsing python-six)) (home-page "https://github.com/pypa/packaging") (synopsis "Core utilities for Python packages") (description "Packaging is a Python module for dealing with Python packages. @@ -22719,7 +22593,8 @@ based on the CPython 2.7 and 3.7 parsers.") (method url-fetch) (uri (pypi-uri "typeguard" version)) (sha256 - (base32 "1i5qzcyw2715h1g1hvj7fxykck2bkxyshpngjr3nfcx1lf6smv80")))) + (base32 "1i5qzcyw2715h1g1hvj7fxykck2bkxyshpngjr3nfcx1lf6smv80")) + (patches (search-patches "python-typeguard-python3.10.patch")))) (build-system python-build-system) (arguments (list @@ -22741,82 +22616,6 @@ based on the CPython 2.7 and 3.7 parsers.") with PEP 484 argument (and return) type annotations.") (license license:expat))) -(define-public python-typing-extensions - (package - (name "python-typing-extensions") - (version "4.0.1") - (source (origin - ;; The test script is missing from the PyPI archive. - (method git-fetch) - (uri (git-reference - (url "https://github.com/python/typing") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0a35fh5wk9s538x0w3dz95y0avnhd2srzyv9s1a372711n8hdl4p")))) - (build-system python-build-system) - (arguments - (list - #:tests? #f ;requires Python's test module, not available in Guix - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'enter-source-directory - (lambda _ - (chdir "typing_extensions"))) - ;; XXX: PEP 517 manual build copied from python-isort. - (replace 'build - (lambda _ - (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "python" "src/test_typing_extensions.py")))) - (replace 'install - (lambda _ - (let ((whl (car (find-files "dist" "\\.whl$")))) - (invoke "pip" "--no-cache-dir" "--no-input" - "install" "--no-deps" "--prefix" #$output whl))))))) - (native-inputs (list python-pypa-build python-flit-core)) - (home-page "https://github.com/python/typing/typing_extensions") - (synopsis "Experimental type hints for Python") - (description - "The typing_extensions module contains additional @code{typing} hints not -yet present in the of the @code{typing} standard library. -Included are implementations of: -@enumerate -@item ClassVar -@item ContextManager -@item Counter -@item DefaultDict -@item Deque -@item NewType -@item NoReturn -@item overload -@item Protocol -@item runtime -@item Text -@item Type -@item TYPE_CHECKING -@item AsyncGenerator -@end enumerate\n") - (license license:psfl))) - -(define-public python-typing-extensions-next - (package - (inherit python-typing-extensions) - (name "python-typing-extensions") - (version "4.2.0") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/python/typing") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1bbry1rg7q5ppkgzdk4nwl7q1w8bbhajm4q68wb9dm6rf7hg1023")))))) - (define-public bpython (package (name "bpython") @@ -23009,7 +22808,9 @@ time-based (TOTP) passwords.") (method url-fetch) (uri (pypi-uri "parso" version)) (sha256 - (base32 "185gkxq92kqiw2h5zp1cmyn04055x0lix4hmi5c077xm1clvw1wc")))) + (base32 "185gkxq92kqiw2h5zp1cmyn04055x0lix4hmi5c077xm1clvw1wc")) + (patches + (search-patches "python-parso-unit-tests-in-3.10.patch")))) (native-inputs (list python-pytest)) (build-system python-build-system) @@ -23781,14 +23582,14 @@ validation testing and application logic.") (define-public python-numba (package (name "python-numba") - (version "0.55.1") + (version "0.56.4") (source (origin (method url-fetch) (uri (pypi-uri "numba" version)) (sha256 (base32 - "18rf8i32m1045zxglvicpgldvzmqdxqvs3dhjd7wilb64sd0ds83")))) + "1vlnmirhay8gl36cxa94nvlgs41k9p7vdkp0xzbq65682bsgxn9j")))) (build-system python-build-system) (arguments `(#:phases @@ -24237,25 +24038,19 @@ that is accessible to other projects developed in Cython.") (define-public python-sortedcontainers (package (name "python-sortedcontainers") - (version "2.1.0") + (version "2.4.0") (source (origin (method url-fetch) (uri (pypi-uri "sortedcontainers" version)) (sha256 (base32 - "0fm0w5id2yhqld95hg2m636vjgkz377rvgdfqaxc25vbylr9lklp")))) + "126vpywl7aly6zir033a9indgyficlzl68qls61nn2y3djhabji5")))) (build-system python-build-system) (arguments - ;; FIXME: Tests require many extra dependencies, and would introduce - ;; a circular dependency on hypothesis, which uses this package. + ;; TODO: Circular dependency on pytest. '(#:tests? #f)) - (propagated-inputs - `(("python-appdirs" ,python-appdirs) - ("python-distlib" ,python-distlib) - ("python-filelock" ,python-filelock) - ("python-six" ,python-six-bootstrap))) - (home-page "https://www.grantjenks.com/docs/sortedcontainers/") + (home-page "https://grantjenks.com/docs/sortedcontainers/") (synopsis "Sorted List, Sorted Dict, Sorted Set") (description "This package provides a sorted collections library, written in @@ -24597,7 +24392,16 @@ RFC 8265 and RFC 8266.") (sha256 (base32 "1mp9lk0b2qa37b7y6ak4lvf6ifw2ylyy6bkf9ik77md3j4xrwlc7")))) - (build-system python-build-system) + (build-system pyproject-build-system) + (arguments + (list + #:phases + '(modify-phases %standard-phases + (add-after 'unpack 'patch-version-check + (lambda _ + ;; Python 3.10 is indeed more recent than Python 3.4. + (substitute* "setup.py" + ((" or py_version\\[0\\] == '3'.*") ":"))))))) (propagated-inputs (list python-six)) (home-page "https://github.com/abseil/abseil-py") @@ -24861,7 +24665,8 @@ _cyclic_garbage" ;; OSError: protocol not found. " and not test_getprotobyname" ;; EOFError: Ran out of input. - " and not test_static_tool_sees_all_symbols")))))))) + " and not test_static_tool_sees_all_symbols") + "trio/tests"))))))) (native-inputs (list python-astor python-ipython @@ -25711,14 +25516,14 @@ standard error channel (stderr) in your program.") (define-public python-anyio (package (name "python-anyio") - (version "3.5.0") + (version "3.6.2") (source (origin (method url-fetch) (uri (pypi-uri "anyio" version)) (sha256 (base32 - "19m58805wir4i2s45dd5ynwlzb7ky1218isbir53gpqzzgigzbm0")))) + "08bljjq5xq0l9id36q3vvjgygirq7g7q2bs41hdg82p379khvsi5")))) (build-system python-build-system) (arguments `(#:phases @@ -28007,7 +27812,7 @@ By default it uses the open Python vulnerability database Safety DB.") (native-inputs `(("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts texlive-fonts-ec - texlive-generic-iftex + texlive-iftex texlive-hyperref texlive-oberdiek texlive-lm @@ -28834,13 +28639,13 @@ and frame grabber interface.") (define-public python-scikit-build (package (name "python-scikit-build") - (version "0.14.0") + (version "0.17.1") (source (origin (method url-fetch) - (uri (pypi-uri "scikit-build" version)) + (uri (pypi-uri "scikit_build" version)) (sha256 - (base32 "1wx1m9vnxnnz59lyaisgyxldp313kciyd4af8lf112vb8vbjy9yk")))) + (base32 "0v1qcn3nsjxqdl6fa07b7acq6xndqbvvic5dvsgbjgldkjr1drqp")))) (build-system pyproject-build-system) (arguments (list @@ -28858,7 +28663,9 @@ and frame grabber interface.") ;; These tests attempt to pull dependencies from the Internet. (delete-file "tests/test_distribution.py") (delete-file "tests/test_pep518.py") - (invoke "pytest" "-vv" + ;; The tests marked as "isolate" are tests that require access + ;; to the network. + (invoke "pytest" "-vv" "-m" "not isolated" "-n" (number->string (parallel-job-count)) "-k" (string-append ;; These tests attempt to write to read-only @@ -28877,14 +28684,21 @@ and frame grabber interface.") ;; nondeterministically (see: ;; https://github.com/scikit-build/scikit-build/issues/711). "and not test_generator_cleanup " - "and not test_generator_selection ")))))))) + "and not test_generator_selection " + ;; The compiler test fails with a + ;; SKBuildGeneratorNotFoundError error (see: + ;; https://github.com/scikit-build/scikit-build/issues/945). + "and not test_cxx_compiler ")))))))) (native-inputs (list cmake-minimal gfortran - git-minimal/pinned ;for tests + git-minimal/pinned ;for tests ninja python-coverage python-cython + python-hatchling + python-hatch-fancy-pypi-readme + python-hatch-vcs python-mock python-packaging python-path @@ -28896,7 +28710,7 @@ and frame grabber interface.") python-requests python-setuptools-scm)) (propagated-inputs - (list python-distro python-packaging python-wheel)) + (list python-distro python-packaging python-tomli python-wheel)) (home-page "https://github.com/scikit-build/scikit-build") (synopsis "Build system generator for Python C/C++/Fortran/Cython extensions") (description "Scikit-build is an improved build system generator for @@ -29375,7 +29189,8 @@ supports x86_64 instructions up to AVX-512 and SHA.") (file-name (git-file-name name version)) (sha256 (base32 - "0bzf6pv85dzfxfysm6zbj8m40hp0xzr9h8qlk4hp3nmy88rznqvr")))) + "0bzf6pv85dzfxfysm6zbj8m40hp0xzr9h8qlk4hp3nmy88rznqvr")) + (patches (search-patches "python-sgmllib3k-assertions.patch")))) (build-system python-build-system) (home-page "https://github.com/hsoft/sgmllib") (synopsis "Python 3 port of sgmllib") @@ -29498,7 +29313,7 @@ symbolic expressions in pure Python using the technique of logical unification." "0w9giq196wps7mbm47c4shdzs5yvwvqajqzkim2p92i51sm5qgvm")))) (build-system python-build-system) (native-inputs - (list python-pytest-6 python-toml)) + (list python-pytest python-toml)) (propagated-inputs (list python-logical-unification)) (home-page "https://github.com/pythological/python-cons") diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 077814719d..bfe8a68352 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -150,6 +150,7 @@ "python-2.7-adjust-tests.patch" "python-cross-compile.patch" "python-2.7-CVE-2021-3177.patch" + "python-2.7-expat-compat.patch" "python-2.7-no-static-lib.patch")) (modules '((guix build utils))) (snippet @@ -419,11 +420,11 @@ data types.") ;; Current 2.x version. (define-public python-2 python-2.7) -(define-public python-3.9 +(define-public python-3.10 (package (inherit python-2) (name "python") - (version "3.9.9") + (version "3.10.7") (source (origin (method url-fetch) (uri (string-append "https://www.python.org/ftp/python/" @@ -433,11 +434,10 @@ data types.") "python-3-deterministic-build-info.patch" "python-3-fix-tests.patch" "python-3-hurd-configure.patch" - "python-3-search-paths.patch" - "python-3-no-static-lib.patch")) + "python-3-search-paths.patch")) (sha256 (base32 - "09vd7g71i11iz5ydqghwc8kaxr0vgji94hhwwnj77h3kll28r0h6")) + "0j6wvh2ad5jjq5n7sjmj1k66mh6lipabavchc3rb4vsinwaq9vbf")) (modules '((guix build utils))) (snippet '(begin @@ -451,6 +451,8 @@ data types.") (find-files "Lib/distutils/command" "\\.exe$")))))) (arguments (substitute-keyword-arguments (package-arguments python-2) + ((#:configure-flags flags) + `(append ,flags '("--without-static-libpython"))) ((#:make-flags _) `(list (string-append (format #f "TESTOPTS=-j~d" (parallel-job-count)) @@ -575,7 +577,7 @@ data types.") (files (list "share/zoneinfo"))))))) ;; Current 3.x version. -(define-public python-3 python-3.9) +(define-public python-3 python-3.10) ;; Current major version. (define-public python python-3) @@ -633,30 +635,36 @@ for more information."))) (inputs `(("bash" ,bash))) (propagated-inputs `(("python" ,python))) (arguments - `(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((bin (string-append (assoc-ref %outputs "out") "/bin")) - (python (string-append (assoc-ref %build-inputs "python") "/bin/"))) - (mkdir-p bin) - (for-each + (list #:modules '((guix build utils)) + #:builder + #~(begin + (use-modules (guix build utils)) + (let ((bin (string-append #$output "/bin")) + (python (string-append + ;; XXX: '%build-inputs' contains the native + ;; Python when cross-compiling. + #$(if (%current-target-system) + (this-package-input "python") + #~(assoc-ref %build-inputs "python")) + "/bin/"))) + (mkdir-p bin) + (for-each (lambda (old new) (symlink (string-append python old) (string-append bin "/" new))) `("python3" ,"pydoc3" ,"pip3") `("python" ,"pydoc" ,"pip")) - ;; python-config outputs search paths based upon its location, - ;; use a bash wrapper to avoid changing its outputs. - (let ((bash (string-append (assoc-ref %build-inputs "bash") - "/bin/bash")) - (old (string-append python "python3-config")) - (new (string-append bin "/python-config"))) - (with-output-to-file new - (lambda () - (format #t "#!~a~%" bash) - (format #t "exec \"~a\" \"$@\"~%" old) - (chmod new #o755)))))))) + ;; python-config outputs search paths based upon its location, + ;; use a bash wrapper to avoid changing its outputs. + (let ((bash (string-append (assoc-ref %build-inputs "bash") + "/bin/bash")) + (old (string-append python "python3-config")) + (new (string-append bin "/python-config"))) + (with-output-to-file new + (lambda () + (format #t "#!~a~%" bash) + (format #t "exec \"~a\" \"$@\"~%" old) + (chmod new #o755)))))))) (synopsis "Wrapper for the Python 3 commands") (description "This package provides wrappers for the commands of Python@tie{}3.x such diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 8cda634cef..913470c9d3 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -1,11 +1,11 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2013, 2014, 2015, 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> -;;; Copyright © 2015, 2018, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2015, 2018, 2019, 2020, 2021, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is> ;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be> -;;; Copyright © 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2017, 2018, 2019, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017 Quiliro <quiliro@fsfla.org> ;;; Copyright © 2017, 2018, 2020, 2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018, 2020, 2022 Nicolas Goaziou <mail@nicolasgoaziou.fr> @@ -21,7 +21,7 @@ ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de> ;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021, 2022 Brendan Tildesley <mail@brendan.scot> -;;; Copyright © 2021, 2022 Guillaume Le Vaillant <glv@posteo.net> +;;; Copyright © 2021, 2022, 2023 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2021 Nicolò Balzarotti <nicolo@nixo.xyz> ;;; Copyright © 2022 Foo Chuan Wei <chuanwei.foo@hotmail.com> ;;; Copyright © 2022 Zhu Zihao <all_but_last@163.com> @@ -54,6 +54,7 @@ #:use-module (guix build-system meson) #:use-module (guix build-system trivial) #:use-module (guix build-system python) + #:use-module (guix build-system pyproject) #:use-module (guix build-system qt) #:use-module (guix gexp) #:use-module (guix packages) @@ -125,6 +126,8 @@ #:use-module (gnu packages xml) #:use-module (srfi srfi-1)) +(define %qt-version "5.15.8") + (define-public qite (let ((commit "75fb3b6bbd5c6a5a8fc35e08a6efbfb588ed546a") (revision "74")) @@ -337,7 +340,7 @@ system, and the core design of Django is reused in Grantlee.") (define-public qtbase-5 (package (name "qtbase") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -756,6 +759,9 @@ developers using C++ or QML, a CSS & JavaScript like language.") ;; The 'tst_qfilesystemwatcher' installs a watcher on ;; '/home', which doesn't exist in the build container. "tst_qfilesystemwatcher" + ;; Not all of the tested formats are supported by our + ;; build of openssl; 871 passed, 122 failed. + "tst_qsslkey" ;; The 'mockplugins' test fail following error: "Unknown ;; platform linux-g++", and the other plugin tests ;; depend on it. @@ -806,8 +812,9 @@ developers using C++ or QML, a CSS & JavaScript like language.") ;; attempt to complete paths they assume exist, such as ;; "/home", "/etc" or "/root" and fail. "tst_qcompleter" - "tst_qfiledialog") "|") - ")"))))) + "tst_qfiledialog" + ;; This test is susceptible to the 600 ms timeout used: + "tst_qpauseanimation") "|") ")"))))) (replace 'patch-mkspecs (lambda* (#:key outputs #:allow-other-keys) (let* ((archdata (search-input-directory outputs "lib/qt6")) @@ -875,7 +882,7 @@ developers using C++ or QML, a CSS & JavaScript like language.") (package (inherit qtbase-5) (name "qt3d") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -967,7 +974,7 @@ came with the @{qtgraphicaleffects} Qt 5 package.") (package (inherit qtbase-5) (name "qtsvg") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1066,7 +1073,7 @@ HostData=lib/qt5 (define-public qtimageformats (package (inherit qtsvg-5) (name "qtimageformats") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1093,7 +1100,7 @@ support for MNG, TGA, TIFF and WBMP image formats."))) (define-public qtx11extras (package (inherit qtsvg-5) (name "qtx11extras") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1158,7 +1165,7 @@ XLSX document format.") (define-public qtxmlpatterns (package (inherit qtsvg-5) (name "qtxmlpatterns") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1187,7 +1194,7 @@ xmlpatternsvalidator."))) (package (inherit qtsvg-5) (name "qtdeclarative") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1365,7 +1372,7 @@ integrate QML code with JavaScript and C++.") (package (inherit qtsvg-5) (name "qtconnectivity") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1383,7 +1390,7 @@ with Bluetooth and NFC."))) (define-public qtwebsockets-5 (package (inherit qtsvg-5) (name "qtwebsockets") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1446,7 +1453,7 @@ consume data received from the server, or both.") (package (inherit qtsvg-5) (name "qtsensors") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1475,7 +1482,7 @@ recognition API for devices."))) (package (inherit qtsvg-5) (name "qtmultimedia") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1614,7 +1621,7 @@ set of plugins for interacting with pulseaudio and GStreamer.") (package (inherit qtsvg-5) (name "qtwayland") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1714,7 +1721,7 @@ compositor libraries.") (package (inherit qtsvg-5) (name "qtserialport") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1745,7 +1752,7 @@ interacting with serial ports from within Qt."))) (package (inherit qtsvg-5) (name "qtserialbus") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1772,7 +1779,7 @@ and others."))) (define-public qtwebchannel-5 (package (inherit qtsvg-5) (name "qtwebchannel") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1828,7 +1835,7 @@ application).") (package (inherit qtsvg-5) (name "qtwebglplugin") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1857,7 +1864,7 @@ OpenGL ES 2.0 and can be used in HTML5 canvas elements"))) (package (inherit qtsvg-5) (name "qtwebview") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -1875,13 +1882,13 @@ native APIs where it makes sense."))) (package (inherit qtsvg-5) (name "qtlocation") - (version "5.15.5") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) (sha256 (base32 - "0mlhhhcxx3gpr9kh04c6fljxcj50c2j21r0wb9f7d7nk4flip7b2")))) + "0r16qxy0pfpwvna4gpz67jk3qv3qizfd659kc9iwdh8bhz7lpjrw")))) (arguments (substitute-keyword-arguments (package-arguments qtsvg-5) ((#:tests? _ #f) #f) ; TODO: Enable the tests @@ -1932,7 +1939,7 @@ plugin for Adobe After Effects.") (package (inherit qtsvg-5) (name "qttools") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2014,7 +2021,7 @@ the Qt community.") (package (inherit qtsvg-5) (name "qtscript") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2033,7 +2040,7 @@ ECMAScript and Qt."))) (package (inherit qtsvg-5) (name "qtquickcontrols") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2053,7 +2060,7 @@ can be used to build complete interfaces in Qt Quick."))) (package (inherit qtsvg-5) (name "qtquickcontrols2") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2080,7 +2087,7 @@ not available."))) (package (inherit qtsvg-5) (name "qtgraphicaleffects") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2103,7 +2110,7 @@ coloring, and many more."))) (package (inherit qtsvg-5) (name "qtgamepad") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2129,7 +2136,7 @@ and mobile applications targeting TV-like form factors."))) (package (inherit qtsvg-5) (name "qtscxml") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2187,7 +2194,7 @@ information and perform area based monitoring.") (package (inherit qtsvg-5) (name "qtpurchasing") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2203,7 +2210,7 @@ purchasing goods and services."))) (package (inherit qtsvg-5) (name "qtcharts") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2232,15 +2239,16 @@ selecting one of the charts themes.") (package (inherit qtsvg-5) (name "qtdatavis3d") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) (sha256 (base32 "1mr2kdshahxrkjs9wlgpr59jbqvyvlax16rlnca4iq00w3v5hrdh")))) - (arguments (substitute-keyword-arguments (package-arguments qtsvg-5) - ((#:tests? _ #f) #f))) ; TODO: Enable the tests + (arguments + (substitute-keyword-arguments (package-arguments qtsvg-5) + ((#:tests? _ #f) #f))) ; TODO: Enable the tests (inputs (list qtbase-5 qtdeclarative-5)) (synopsis "Qt Data Visualization module") (description "The Qt Data Visualization module provides a way to visualize @@ -2253,7 +2261,7 @@ customized by using themes or by adding custom items and labels to them.") (define-public qtnetworkauth-5 (package (inherit qtsvg-5) (name "qtnetworkauth") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) @@ -2326,15 +2334,16 @@ processes or computers.") (package (inherit qtsvg-5) (name "qtspeech") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) (uri (qt-urls name version)) (sha256 (base32 "1q56lyj7s05sx52j5z6gcs000mni4c7mb7qyq4lfval7c06hw5p6")))) - (arguments (substitute-keyword-arguments (package-arguments qtsvg-5) - ((#:tests? _ #f) #f))) ; TODO: Enable the tests + (arguments + (substitute-keyword-arguments (package-arguments qtsvg-5) + ((#:tests? _ #f) #f))) ; TODO: Enable the tests (inputs (list qtbase-5)) (native-inputs (list perl qtdeclarative-5 qtmultimedia-5 qtxmlpatterns)) (synopsis "Qt Speech module") @@ -2433,7 +2442,7 @@ using the Enchant spell-checking library.") (package (inherit qtsvg-5) (name "qtwebengine") - (version "5.15.8") + (version %qt-version) (source (origin (method url-fetch) @@ -2637,7 +2646,7 @@ linux/libcurl_wrapper.h") ruby)) (inputs (list alsa-lib - atk + at-spi2-core cups-minimal curl dbus @@ -3195,7 +3204,7 @@ instances.") (define-public python-sip (package (name "python-sip") - (version "5.5.0") + (version "6.7.7") (source (origin (method url-fetch) @@ -3205,12 +3214,13 @@ instances.") "/sip-" version ".tar.gz"))) (sha256 (base32 - "1idaivamp1jvbbai9yzv471c62xbqxhaawccvskaizihkd0lq0jx")))) + "1qm9q9lhfky5zvxxkssf4zdfv5k1zikji4hz80d48vdfm1pw1sfy")) + (patches (search-patches "python-sip-include-dirs.patch")))) (build-system python-build-system) (native-inputs (list python-wrapper)) (propagated-inputs - (list python-toml python-packaging)) + (list python-toml python-packaging python-ply)) (home-page "https://www.riverbankcomputing.com/software/sip/intro") (synopsis "Python binding creator for C and C++ libraries") (description @@ -3272,7 +3282,7 @@ module provides support functions to the automatically generated code.") (define-public python-pyqt (package (name "python-pyqt") - (version "5.15.5") + (version "5.15.9") (source (origin (method url-fetch) @@ -3285,11 +3295,12 @@ module provides support functions to the automatically generated code.") (file-name (string-append "PyQt5-" version ".tar.gz")) (sha256 (base32 - "0aya963kkmbwfwmpd0p6k85y4g7wl5zarjqxxfgir403zalbf4dl")) + "1h649rb1afdxskp28x524yp5kd9a97ainh9bd4mkxp4h390fhhfw")) (patches (search-patches "pyqt-configure.patch")))) - (build-system gnu-build-system) + (build-system pyproject-build-system) (native-inputs - (list qtbase-5)) ; for qmake + (list qtbase-5 ; for qmake + python-pyqt-builder)) (propagated-inputs (list python-sip python-pyqt5-sip)) (inputs @@ -3308,47 +3319,24 @@ module provides support functions to the automatically generated code.") ("qtx11extras" ,qtx11extras) ("qtxmlpatterns" ,qtxmlpatterns))) (arguments - `(#:modules ((srfi srfi-1) - ((guix build python-build-system) #:select (python-version)) - ,@%gnu-build-system-modules) - #:imported-modules ((guix build python-build-system) - ,@%gnu-build-system-modules) + (list + #:tests? #f ; No tests. + #:configure-flags + #~`(@ ("--verbose" . "") ; Print commands run. + ("--confirm-license" . "") + ("--jobs" . ,(number->string (parallel-job-count)))) #:phases - (modify-phases %standard-phases + #~(modify-phases %standard-phases ;; When building python-pyqtwebengine, <qprinter.h> can not be ;; included. Here we substitute the full path to the header in the ;; store. - (add-before 'configure 'substitute-source + (add-after 'unpack 'substitute-source (lambda* (#:key inputs #:allow-other-keys) (let* ((qtbase (assoc-ref inputs "qtbase")) (qtprinter.h (string-append "\"" qtbase "/include/qt5/QtPrintSupport/qprinter.h\""))) - (substitute* "sip/QtPrintSupport/qprinter.sip" - (("<qprinter.h>") qtprinter.h))))) - (replace 'configure - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin")) - (sip (string-append out "/share/sip")) - (plugins (string-append out "/lib/qt5/plugins")) - (designer (string-append plugins "/designer")) - (qml (string-append plugins "/PyQt5")) - (python (assoc-ref inputs "python")) - (lib (string-append out "/lib/python" - (python-version python) - "/site-packages")) - (stubs (string-append lib "/PyQt5"))) - (invoke "python" "configure.py" - "--confirm-license" - "--bindir" bin - "--destdir" lib - "--designer-plugindir" designer - "--qml-plugindir" qml - ; Where to install the PEP 484 Type Hints stub - ; files. Without this the stubs are tried to be - ; installed into the python package's - ; site-package directory, which is read-only. - "--stubsdir" stubs - "--sipdir" sip))))))) + (substitute* (list "sip/QtPrintSupport/qprinter.sip" + "sip/QtPrintSupport/qpyprintsupport_qlist.sip") + (("<qprinter.h>") qtprinter.h)))))))) (home-page "https://www.riverbankcomputing.com/software/pyqt/intro") (synopsis "Python bindings for Qt") (description @@ -3360,14 +3348,14 @@ contain over 620 classes.") (define-public python-pyqt5-sip (package (name "python-pyqt5-sip") - (version "12.10.1") + (version "12.11.1") (source (origin (method url-fetch) (uri (pypi-uri "PyQt5_sip" version)) (sha256 (base32 - "09771b6fdn0rx34l5a0wzcd899yd57zxp5sw3bsqhd25biwhiq4p")))) + "0sa3vad8r7qm98k4ngimwjp87bh2f9f2vv19cnzb3vb11zdgplwp")))) (build-system python-build-system) (arguments `(#:tests? #f)) ;; No test code. @@ -3379,7 +3367,7 @@ contain over 620 classes.") (define-public python-pyqtwebengine (package (name "python-pyqtwebengine") - (version "5.15.5") + (version "5.15.9") (source (origin (method url-fetch) @@ -3392,9 +3380,10 @@ contain over 620 classes.") (sha256 (base32 "0hdr0g0rzlhsnylhfk826pq1lw8p9dqcr8yma2wy9dgjrj6n0ixb")))) - (build-system gnu-build-system) + (build-system pyproject-build-system) (native-inputs (list python python-sip + python-pyqt-builder ;; qtbase is required for qmake qtbase-5)) (inputs @@ -3406,49 +3395,23 @@ contain over 620 classes.") ("qtdeclarative-5" ,qtdeclarative-5) ("qtwebchannel-5" ,qtwebchannel-5) ("qtwebengine-5" ,qtwebengine-5))) - (arguments - `(#:modules ((srfi srfi-1) - ((guix build python-build-system) #:select (python-version)) - ,@%gnu-build-system-modules) - #:imported-modules ((guix build python-build-system) - ,@%gnu-build-system-modules) + (arguments + (list + #:tests? #f ; No tests. + #:configure-flags + #~`(@ ("--verbose" . "") ; Print commands run. + ("--jobs" . ,(number->string (parallel-job-count)))) #:phases - (modify-phases %standard-phases - (replace 'configure - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (sipdir (string-append out "/share/sip")) - (pyqt-sipdir (string-append - (assoc-ref inputs "python-pyqt") "/share/sip")) - (python (assoc-ref inputs "python")) - (lib (string-append out "/lib/python" - (python-version python) - "/site-packages/PyQt5")) - (stubs (string-append lib "/PyQt5"))) - - (mkdir-p sipdir) - (invoke "python" "configure.py" - "-w" - "--no-dist-info" - "--destdir" lib - "--no-qsci-api" - "--stubsdir" stubs - "--sipdir" sipdir - "--pyqt-sipdir" pyqt-sipdir)))) - ;; Because this has a different prefix than python-pyqt then we need - ;; to make this a namespace of its own. - (add-after 'install 'make-namespace - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((__init__.py (string-append - (assoc-ref outputs "out") - "/lib/python" - (python-version (assoc-ref inputs "python")) - "/site-packages/PyQt5/__init__.py"))) - (with-output-to-file __init__.py - (lambda _ (display " -from pkgutil import extend_path -__path__ = extend_path(__path__, __name__) -"))))))))) + #~(modify-phases %standard-phases + (add-after 'unpack 'set-include-dirs + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((python (assoc-ref inputs "python")) + (python-pyqt (assoc-ref inputs "python-pyqt")) + (sip-include-dirs (string-append + python-pyqt "/lib/python" + (python-version python) + "/site-packages/PyQt5/bindings"))) + (setenv "SIP_INCLUDE_DIRS" sip-include-dirs))))))) (home-page "https://www.riverbankcomputing.com/software/pyqtwebengine/intro") (synopsis "Python bindings for QtWebEngine") (description @@ -3461,14 +3424,14 @@ itself.") (define-public python-pyqt-builder (package (name "python-pyqt-builder") - (version "1.9.0") + (version "1.14.1") (source (origin (method url-fetch) (uri (pypi-uri "PyQt-builder" version)) (sha256 (base32 - "0nh0054c54ji3sm6d268fccf0y5f613spswwgwqd3rnn816hnljl")))) + "00m5piryz9l4hp5z1ncaqicsp29kj71akdh4b10432zz18q3xg43")))) (build-system python-build-system) (inputs (list python-sip)) @@ -3527,15 +3490,15 @@ bindings (PySide, PySide2, PyQt4 and PyQt5).") (define-public qscintilla (package (name "qscintilla") - (version "2.11.6") + (version "2.13.4") (source (origin (method url-fetch) (uri (string-append "https://www.riverbankcomputing.com/static" "/Downloads/QScintilla/" version - "/QScintilla-" version ".tar.gz")) + "/QScintilla_src-" version ".tar.gz")) (sha256 (base32 - "19r0vpqb4m9bqwxmjp9w6x0hgahkrg7zryk78hwgplj7vdbn0d77")))) + "11lrhybp32nz1dxns4pxxd8rbj2gshva20zan0kg85p164gjc349")))) (build-system gnu-build-system) (arguments `(#:phases @@ -3543,7 +3506,7 @@ bindings (PySide, PySide2, PyQt4 and PyQt5).") (replace 'configure (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) - (chdir "Qt4Qt5") + (chdir "src") (substitute* "qscintilla.pro" (("\\$\\$\\[QT_INSTALL_LIBS\\]") (string-append out "/lib")) @@ -3568,40 +3531,35 @@ indicators, code completion and call tips.") (define-public python-qscintilla (package/inherit qscintilla (name "python-qscintilla") + (build-system pyproject-build-system) (arguments - `(#:configure-flags - (list "--pyqt=PyQt5" - (string-append "--pyqt-sipdir=" - (assoc-ref %build-inputs "python-pyqt") - "/share/sip") - (string-append "--qsci-incdir=" - (assoc-ref %build-inputs "qscintilla") - "/include") - (string-append "--qsci-libdir=" - (assoc-ref %build-inputs "qscintilla") - "/lib")) - #:phases - (modify-phases %standard-phases - (replace 'configure - (lambda* (#:key inputs outputs configure-flags #:allow-other-keys) - (let ((out (assoc-ref outputs "out")) - (python (assoc-ref inputs "python"))) - (chdir "Python") - (apply invoke "python3" "configure.py" - configure-flags) - ;; Install to the right directory - (substitute* '("Makefile" - "Qsci/Makefile") - (("\\$\\(INSTALL_ROOT\\)/gnu/store/[^/]+") out) - (((string-append python "/lib")) - (string-append out "/lib"))) - ;; And fix the installed.txt file - (substitute* "installed.txt" - (("/gnu/store/[^/]+") out)))))))) + (list #:tests? #f + #:configure-flags + #~`(@ ("--qsci-include-dir" . ,(string-append + #$(this-package-input "qscintilla") + "/include")) + ("--qsci-library-dir" . ,(string-append + #$(this-package-input "qscintilla") + "/lib"))) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'prepare-build + (lambda _ + (chdir "Python") + (symlink "pyproject-qt5.toml" "pyproject.toml"))) + (add-after 'unpack 'set-include-dirs + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((python (assoc-ref inputs "python")) + (python-pyqt (assoc-ref inputs "python-pyqt")) + (sip-include-dirs (string-append + python-pyqt "/lib/python" + (python-version python) + "/site-packages/PyQt5/bindings"))) + (setenv "SIP_INCLUDE_DIRS" sip-include-dirs))))))) + (native-inputs + (list python-pyqt-builder qtbase-5)) (inputs - `(("qscintilla" ,qscintilla) - ("python" ,python) - ("python-pyqt" ,python-pyqt))) + (list python-pyqt python-sip qscintilla)) (description "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control. QScintilla includes features especially useful when editing and debugging source code. These include support for syntax styling, error @@ -3955,7 +3913,7 @@ color-related widgets.") (define-public python-shiboken-2 (package (name "python-shiboken-2") - (version "5.15.5") + (version %qt-version) (source (origin (method url-fetch) (uri (string-append "https://download.qt.io/official_releases" @@ -3964,7 +3922,8 @@ color-related widgets.") version ".tar.xz")) (sha256 (base32 - "0cwvw6695215498rsbm2xzkwaxdr3w7zfvy4kc62c01k6pxs881r")))) + "0pbbdypwkn3vrgy8ww207fl8pqq4jv80bck9qz5v9dfyr0166hr3")) + (patches (search-patches "python-shiboken-2-compat.patch")))) (build-system cmake-build-system) (inputs (list clang-toolchain diff --git a/gnu/packages/radio.scm b/gnu/packages/radio.scm index 5999257433..f80b2751b1 100644 --- a/gnu/packages/radio.scm +++ b/gnu/packages/radio.scm @@ -714,7 +714,7 @@ used by RDS Spy, and audio files containing @dfn{multiplex} signals (MPX).") (texlive-updmap.cfg (list texlive-amsfonts texlive-amsmath ;; TODO: Add newunicodechar. - texlive-latex-graphics)) + texlive-graphics)) xorg-server-for-tests)) (inputs (list alsa-lib @@ -924,7 +924,7 @@ to access different radio hardware.") ("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts texlive-amsmath ;; TODO: Add newunicodechar. - texlive-latex-graphics))))) + texlive-graphics))))) (inputs (list fftwf)) (arguments diff --git a/gnu/packages/rdesktop.scm b/gnu/packages/rdesktop.scm index f5a2797c6a..be4fe83cdc 100644 --- a/gnu/packages/rdesktop.scm +++ b/gnu/packages/rdesktop.scm @@ -102,25 +102,24 @@ to remotely control a user's Windows desktop.") pkg-config xmlto)) (inputs - `(("alsa-lib" ,alsa-lib) - ("cups" ,cups) - ("ffmpeg" ,ffmpeg-4) - ("libjpeg" ,libjpeg-turbo) - ("libusb" ,libusb) - ("libx11" ,libx11) - ("libxkbfile" ,libxkbfile) - ("libxcursor" ,libxcursor) - ("libxext" ,libxext) - ("libxi" ,libxi) - ("libxv" ,libxv) - ("libxrandr" ,libxrandr) - ("libxrender" ,libxrender) - ("libxinerama" ,libxinerama) - ("libxshmfence" ,libxshmfence) - ("pulseaudio" ,pulseaudio) - ("zlib" ,zlib))) - (propagated-inputs - (list libxkbcommon openssl wayland)) + (list alsa-lib + cups + ffmpeg-4 + libjpeg-turbo + libusb + libx11 + libxkbfile + libxcursor + libxext + libxi + libxv + libxrandr + libxrender + libxinerama + libxshmfence + pulseaudio + zlib)) + (propagated-inputs (list libxkbcommon openssl wayland)) (arguments (list #:build-type "RELEASE" #:configure-flags diff --git a/gnu/packages/readline.scm b/gnu/packages/readline.scm index edd4752c05..8200a24f1a 100644 --- a/gnu/packages/readline.scm +++ b/gnu/packages/readline.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2016, 2019 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2018, 2021 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2019, 2020 Marius Bakke <marius@gnu.org> +;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -27,6 +27,7 @@ #:use-module (gnu packages ncurses) #:use-module (gnu packages perl) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix build-system gnu) @@ -51,7 +52,8 @@ (define %patch-series-8.1 (patch-series "8.1" - (1 "0i4ikdqgcjnb40y2ss3lm09rq56zih5rzma3bib50dk3d1d4cak8"))) + (1 "0i4ikdqgcjnb40y2ss3lm09rq56zih5rzma3bib50dk3d1d4cak8") + (2 "1p15sfx5xg5k4lam12lyd0givk7dfjddqpnb1jdp3c4clray0nz5"))) (define %patch-series-7.0 (patch-series @@ -79,27 +81,30 @@ (patch-flags '("-p0")))) (build-system gnu-build-system) (propagated-inputs (list ncurses)) - (arguments `(#:configure-flags - (list (string-append "LDFLAGS=-Wl,-rpath -Wl," - (assoc-ref %build-inputs "ncurses") - "/lib") + (arguments + (list #:configure-flags + #~(list (string-append + "LDFLAGS=-Wl,-rpath -Wl," + (dirname (search-input-file %build-inputs + "lib/libncurses.so"))) - ;; This test does an 'AC_TRY_RUN', which aborts when - ;; cross-compiling, so provide the correct answer. - ,@(if (%current-target-system) - '("bash_cv_wcwidth_broken=no") - '()) - ;; MinGW: ncurses provides the termcap api. - ,@(if (target-mingw?) - '("bash_cv_termcap_lib=ncurses") - '())) + ;; This test does an 'AC_TRY_RUN', which aborts when + ;; cross-compiling, so provide the correct answer. + #$@(if (%current-target-system) + '("bash_cv_wcwidth_broken=no") + '()) + ;; MinGW: ncurses provides the termcap api. + #$@(if (target-mingw?) + '("bash_cv_termcap_lib=ncurses") + '())) - ,@(if (target-mingw?) - ;; MinGW: termcap in ncurses - ;; some SIG_* #defined in _POSIX - '(#:make-flags '("TERMCAP_LIB=-lncurses" - "CPPFLAGS=-D_POSIX -D'chown(f,o,g)=0'")) - '()))) + #:make-flags + (if (target-mingw?) + ;; MinGW: termcap in ncurses + ;; some SIG_* #defined in _POSIX + #~'("TERMCAP_LIB=-lncurses" + "CPPFLAGS=-D_POSIX -D'chown(f,o,g)=0'") + #~'()))) (synopsis "Edit command lines while typing, with history support") (description "The GNU readline library allows users to edit command lines as they diff --git a/gnu/packages/rpc.scm b/gnu/packages/rpc.scm index 59a4c41343..a88c79f8b9 100644 --- a/gnu/packages/rpc.scm +++ b/gnu/packages/rpc.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2019, 2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2020, 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org> @@ -31,6 +31,7 @@ #:use-module (guix utils) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (guix build-system pyproject) #:use-module (guix build-system python) #:use-module (gnu packages adns) #:use-module (gnu packages autotools) @@ -42,6 +43,7 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages protobuf) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-xyz) #:use-module (gnu packages regex) #:use-module (gnu packages tls) @@ -107,7 +109,7 @@ (find-files "." "\\.a$")))) #t))))) (inputs - (list abseil-cpp c-ares/cmake openssl re2 zlib)) + (list abseil-cpp-cxxstd11 c-ares/cmake openssl re2 zlib)) (native-inputs `(("pkg-config" ,pkg-config) ("protobuf" ,protobuf) @@ -122,6 +124,24 @@ mile of distributed computing to connect devices, mobile applications and browsers to backend services.") (license license:asl2.0))) +(define-public grpc-for-python-grpcio + (package + (inherit grpc) + (name "grpc") + (version "1.47.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/grpc/grpc") + (commit (string-append "v" version)) + (recursive? #true))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1nl2d92f3576m69991d7gwyk1giavm04fagr612yjh90rni01ikw")))) + (inputs + (list abseil-cpp-20211102.0 c-ares/cmake openssl re2 zlib)))) + ;; Some packages require this older version. (define-public grpc-1.16.1 (package @@ -151,10 +171,12 @@ browsers to backend services.") "src/core/lib/iomgr/ev_epollex_linux.cc") (("gettid\\(") "sys_gettid(")))))))) + (inputs + (modify-inputs (package-inputs grpc) + (replace "abseil-cpp" abseil-cpp-20200923.3))) (native-inputs (modify-inputs (package-native-inputs grpc) - (delete "abseil-cpp" "protobuf") - (prepend abseil-cpp-20200923.3 protobuf-3.6))))) + (replace "protobuf" protobuf-3.6))))) (define-public python-grpc-stubs (package @@ -188,6 +210,8 @@ type information of gRPC.") (modules '((guix build utils) (ice-9 ftw))) (snippet '(begin + ;; Delete this generated file. + (delete-file "src/python/grpcio/grpc/_cython/cygrpc.cpp") (with-directory-excursion "third_party" ;; Delete the bundled source code of libraries that are possible ;; to provide as inputs. @@ -199,18 +223,23 @@ type information of gRPC.") "address_sorting" "upb" "xxhash"))))))))))) - (build-system python-build-system) + (build-system pyproject-build-system) (arguments (list #:phases #~(modify-phases %standard-phases (add-before 'build 'use-system-libraries (lambda _ + (substitute* "setup.py" + (("EXTENSION_INCLUDE_DIRECTORIES = \\(" m) + (string-append m " ('" #$(this-package-input "grpc") + "/include/grpc/impl/codegen/',) + "))) (setenv "GRPC_PYTHON_BUILD_SYSTEM_CARES" "1") (setenv "GRPC_PYTHON_BUILD_SYSTEM_OPENSSL" "1") (setenv "GRPC_PYTHON_BUILD_SYSTEM_ZLIB" "1") (setenv "GRPC_PYTHON_BUILD_SYSTEM_RE2" "1") (setenv "GRPC_PYTHON_BUILD_SYSTEM_ABSL" "1") + (setenv "GRPC_PYTHON_BUILD_WITH_CYTHON" "1") ;; Fix the linker options to link with abseil-cpp, which is ;; looked under /usr/lib. (substitute* "setup.py" @@ -222,7 +251,9 @@ type information of gRPC.") (substitute* '("setup.py" "src/python/grpcio/commands.py") (("'cc'") "'gcc'"))))))) (inputs - (list abseil-cpp c-ares openssl re2 zlib)) + (list abseil-cpp-20211102.0 c-ares grpc-for-python-grpcio openssl re2 zlib)) + (native-inputs + (list python-cython)) (propagated-inputs (list python-six)) (home-page "https://grpc.io") diff --git a/gnu/packages/rpm.scm b/gnu/packages/rpm.scm index 0b6cacadef..b7802e3ecd 100644 --- a/gnu/packages/rpm.scm +++ b/gnu/packages/rpm.scm @@ -105,14 +105,6 @@ applying deltarpms, compatible with the original deltarpm packages.") (format #f "glib_docpath = '~a'~%" (search-input-directory (or native-inputs inputs) "share/gtk-doc/html")))))) - (add-after 'unpack 'fix-docbook-references - ;; gtk-doc doesn't seem to honor DocBook 4.1.2's docbook.cat's - ;; catalog file, even when adding it to XML_CATALOG_FILES. Work - ;; around it by adjusting the DocBook references directly. - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "modulemd/modulemd-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd") - (search-input-file inputs "xml/dtd/docbook/docbookx.dtd"))))) (add-after 'install 'move-documentation (lambda* (#:key outputs #:allow-other-keys) (let ((dst (string-append #$output:doc "/share/gtk-doc"))) @@ -126,6 +118,7 @@ applying deltarpms, compatible with the original deltarpm packages.") gobject-introspection ;for g-ir-scanner gtk-doc help2man + libxml2 ;for XML_CATALOG_FILES pkg-config python)) ;for 'site-packages' call (inputs diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 834c0dfbd4..1dcd5f76a5 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com> ;;; Copyright © 2017 Nikita <nikita@n0.is> ;;; Copyright © 2017, 2019-2022 Marius Bakke <marius@gnu.org> -;;; Copyright © 2017, 2018, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017-2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2017, 2018, 2020, 2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2017, 2018, 2019 Christopher Baines <mail@cbaines.net> @@ -162,8 +162,7 @@ a focus on simplicity and productivity.") (define-public ruby-2.7 (package (inherit ruby-2.6) - (version "2.7.4") - (replacement ruby-2.7-fixed) ; security fixes + (version "2.7.6") (source (origin (inherit (package-source ruby-2.6)) @@ -172,7 +171,7 @@ a focus on simplicity and productivity.") "/ruby-" version ".tar.gz")) (sha256 (base32 - "0nxwkxh7snmjqf787qsp4i33mxd1rbf9yzyfiky5k230i680jhrh")))) + "042xrdk7hsv4072bayz3f8ffqh61i8zlhvck10nfshllq063n877")))) (arguments `(#:test-target "test" #:configure-flags '("--enable-shared") ; dynamic linking @@ -5501,8 +5500,9 @@ slowest tests in a minitest suite.") `(#:phases (modify-phases %standard-phases (replace 'check - (lambda _ - (invoke "script/test")))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "sh" "script/test"))))))) (native-inputs (list bundler ruby-turn)) (synopsis "Pretty-print hashes and arrays in MiniTest") @@ -6440,23 +6440,19 @@ across multiple CPU cores.") (define-public ruby-parser (package (name "ruby-parser") - (version "3.2.1.1") + (version "3.2.2.0") (source (origin (method url-fetch) (uri (rubygems-uri "parser" version)) (sha256 (base32 - "1a2v5f8fw7nxm41xp422p1pbr41hafy62bp95m7vg42cqp5y4grc")))) + "0s5afi89p76k8vpwiqvh343pm5l23ijqlpszhz65afym3zpkxhzx")))) (build-system ruby-build-system) - (arguments - '(#:tests? #f)) ; tests not included in gem - (native-inputs - (list bundler ruby-cliver ruby-simplecov ruby-racc)) - (inputs - (list ragel)) - (propagated-inputs - (list ruby-ast)) + (arguments '(#:tests? #f)) ; tests not included in gem + (native-inputs (list bundler ruby-cliver ruby-simplecov ruby-racc)) + (inputs (list ragel)) + (propagated-inputs (list ruby-ast)) (synopsis "Ruby parser written in pure Ruby") (description "This package provides a Ruby parser written in pure Ruby.") @@ -7042,8 +7038,7 @@ aware transformations between times in different time zones.") (lambda* (#:key inputs #:allow-other-keys) (substitute* "Rakefile" (("https://data.iana.org/time-zones/releases") - (assoc-ref inputs "tzdata"))) - #t)) + (assoc-ref inputs "tzdata"))))) (add-before 'check 'pre-check (lambda _ (setenv "HOME" (getcwd)) @@ -7053,8 +7048,7 @@ aware transformations between times in different time zones.") ((" sh\\(\\\"make -C" text) (string-append " sh(\"sed -i 's@/bin/sh@sh@' #{tzdb_combined_path}/Makefile \")\n" " sh(\"sed -i 's@cc=@cc?=@' #{tzdb_combined_path}/Makefile \")\n" text))) - (setenv "cc" ,(cc-for-target)) - #t))))) + (setenv "cc" ,(cc-for-target))))))) (propagated-inputs (list ruby-tzinfo)) (native-inputs @@ -7087,14 +7081,7 @@ aware transformations between times in different time zones.") (uri "https://data.iana.org/time-zones/releases/tzcode2021a.tar.gz.asc") (sha256 (base32 - "1qhlj4lr810s47s1lwcvv1sgvg2sflf98w4sbg1lc8wzv5qxxv7g"))))) - - ;; XXX: Explicitly depend on 'guile-final', which was previously - ;; implied via the '%guile-for-build' fluid but not explicit. - ;; TODO: Remove this argument on the next rebuild cycle. - #:guile (module-ref (resolve-interface - '(gnu packages commencement)) - 'guile-final))))) + "1qhlj4lr810s47s1lwcvv1sgvg2sflf98w4sbg1lc8wzv5qxxv7g"))))))))) (synopsis "Data from the IANA Time Zone database") (description "This library provides @code{TZInfo::Data}, which contains data from the @@ -10364,14 +10351,14 @@ neither too verbose nor too minimal.") (define-public ruby-sqlite3 (package (name "ruby-sqlite3") - (version "1.4.2") + (version "1.4.4") (source (origin (method url-fetch) (uri (rubygems-uri "sqlite3" version)) (sha256 (base32 - "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78")))) + "1z1wa639c278bsipczn6kv8b13fj85pi8gk7x462chqx6k0wm0ax")))) (build-system ruby-build-system) (arguments `(#:phases @@ -10382,7 +10369,7 @@ neither too verbose nor too minimal.") (inputs (list sqlite)) (native-inputs - (list ruby-hoe ruby-rake-compiler ruby-mini-portile)) + (list ruby-hoe ruby-rake-compiler ruby-mini-portile-2)) (synopsis "Interface with SQLite3 databases") (description "This module allows Ruby programs to interface with the SQLite3 database diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index ba32757dd1..5c012168ca 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -177,7 +177,7 @@ low-end hardware and serving many concurrent requests.") (native-inputs (list pkg-config)) (inputs - (list atk + (list at-spi2-core gtk glib pango diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 133c46fb7c..d07f4ef10c 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -176,14 +176,6 @@ ("zlib" ,zlib))) (native-inputs `(("bison" ,bison) - ;; A compiler bug in gcc 10/11/12/13 prevents us from using gcc-10.4. See: - ;; https://github.com/thepowersgang/mrustc/issues/266 - ;; https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105860 - ("gcc" ,gcc-9) - ;; TODO: STARTFILE_PREFIX_SPEC is fixed on gcc<10 on core-updates. - ,@(if (target-riscv64?) - `(("gcc:lib" ,gcc-9 "lib")) - '()) ("flex" ,flex) ("pkg-config" ,pkg-config) ;; Required for the libstd sources. @@ -796,7 +788,7 @@ safety and thread safety guarantees.") (format #f "prefix = ~s" (assoc-ref outputs "rustfmt")))) (invoke "./x.py" "install" "rustfmt"))))))) ;; Add test inputs. - (native-inputs (cons* `("gdb" ,gdb) + (native-inputs (cons* `("gdb" ,gdb/pinned) `("procps" ,procps) (package-native-inputs base-rust)))))) diff --git a/gnu/packages/samba.scm b/gnu/packages/samba.scm index 1e9c64f3cc..9b0a2f0ec5 100644 --- a/gnu/packages/samba.scm +++ b/gnu/packages/samba.scm @@ -13,6 +13,7 @@ ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech> ;;; Copyright © 2022 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be> +;;; Copyright © 2022 Simon Streit <simon@netpanic.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -42,6 +43,7 @@ #:use-module (gnu packages acl) #:use-module (gnu packages admin) #:use-module (gnu packages autotools) + #:use-module (gnu packages avahi) #:use-module (gnu packages backup) #:use-module (gnu packages base) #:use-module (gnu packages check) @@ -66,7 +68,8 @@ #:use-module (gnu packages time) #:use-module (gnu packages tls) #:use-module (gnu packages web) - #:use-module (gnu packages xml)) + #:use-module (gnu packages xml) + #:use-module (srfi srfi-1)) (define-public cifs-utils (package @@ -169,143 +172,92 @@ The library is small, thread safe, and written in portable ANSI C with no external dependencies.") (license license:x11))) -(define-public samba - (package - (name "samba") - (replacement samba/security-fixes) - (version "4.16.8") - (source - ;; For updaters: the current PGP fingerprint is - ;; 81F5E2832BD2545A1897B713AA99442FB680B620. - (origin - (method url-fetch) - (uri (string-append "https://download.samba.org/pub/samba/stable/" - "samba-" version ".tar.gz")) - (sha256 - (base32 "11a1vikbijaq7csg49h5ivn25gx84v6wx8z8kgsj1wmkhsf9bcmv")))) - (build-system gnu-build-system) - (arguments - (list - #:make-flags #~(list "TEST_OPTIONS=--quick") ;some tests are very long - #:phases - #~(modify-phases %standard-phases - (add-before 'configure 'setup-docbook-stylesheets - (lambda* (#:key inputs #:allow-other-keys) - ;; Append Samba's own DTDs to XML_CATALOG_FILES - ;; (c.f. docs-xml/build/README). - (copy-file "docs-xml/build/catalog.xml.in" - "docs-xml/build/catalog.xml") - (substitute* "docs-xml/build/catalog.xml" - (("/@abs_top_srcdir@") - (string-append (getcwd) "/docs-xml"))) - ;; Honor XML_CATALOG_FILES. - (substitute* "buildtools/wafsamba/wafsamba.py" - (("XML_CATALOG_FILES=\"\\$\\{SAMBA_CATALOGS\\}" all) - (string-append all " $XML_CATALOG_FILES"))))) - (replace 'configure - ;; Samba uses a custom configuration script that runs WAF. - (lambda* (#:key inputs #:allow-other-keys) - (let* ((libdir (string-append #$output "/lib"))) - (invoke "./configure" - #$@(if (member (%current-system) - (package-transitive-supported-systems - python-cryptography)) - '("--enable-selftest") - '()) - "--enable-fhs" - (string-append "--prefix=" #$output) - "--sysconfdir=/etc" - "--localstatedir=/var" - ;; Install public and private libraries into - ;; a single directory to avoid RPATH issues. - (string-append "--libdir=" libdir) - (string-append "--with-privatelibdir=" libdir) - "--with-system-mitkrb5" ;#$(this-package-input "mit-krb5") - (string-append "--with-system-mitkdc=" - (search-input-file inputs "sbin/krb5kdc")) - "--with-experimental-mit-ad-dc")))) - (add-before 'install 'disable-etc,var-samba-directories-setup - (lambda _ - (substitute* "dynconfig/wscript" - (("bld\\.INSTALL_DIR.*") ""))))) - ;; FIXME: The test suite seemingly hangs after failing to provision the - ;; test environment. - #:tests? #f)) - (inputs - (list acl - cmocka - cups - gamin - dbus - gpgme - gnutls - jansson - libarchive - libtirpc - linux-pam - lmdb - mit-krb5 - openldap - perl - python - popt - readline - tdb)) - (propagated-inputs - ;; In Requires or Requires.private of pkg-config files. - (list ldb talloc tevent)) - (native-inputs - (append - (list perl-parse-yapp - pkg-config) - ;; The python-cryptography dependency is needed for the krb5 tests. - ;; Since python-cryptography requires Rust, add it conditionally - ;; depending on such support. - (if (member (%current-system) - (package-transitive-supported-systems - python-cryptography)) - (list python-cryptography) - '()) - (list python-dnspython - python-iso8601 - python-markdown - rpcsvc-proto ;for 'rpcgen' - python-pyasn1 ;for krb5 tests - ;; For generating man pages. - docbook-xml-4.2 - docbook-xsl-next ;otherwise the man pages are corrupted - libxslt - libxml2))) ;for XML_CATALOG_FILES - (home-page "https://www.samba.org/") - (synopsis - "The standard Windows interoperability suite of programs for GNU and Unix") - (description - "Since 1992, Samba has provided secure, stable and fast file and print -services for all clients using the SMB/CIFS protocol, such as all versions of -DOS and Windows, OS/2, GNU/Linux and many others. - -Samba is an important component to seamlessly integrate Linux/Unix Servers and -Desktops into Active Directory environments using the winbind daemon.") - (license license:gpl3+))) - -;;; FIXME: Invert inheritance relationship; the "pinned" package shouldn't be -;;; susceptible to changes in the free one. (define-public samba/pinned - ;; Version that rarely changes, depended on by libsoup. (hidden-package (package - (inherit samba) - (replacement samba/security-fixes) - (version "4.15.3") + (name "samba") + (version "4.17.0") (source + ;; For updaters: the current PGP fingerprint is + ;; 81F5E2832BD2545A1897B713AA99442FB680B620. (origin (method url-fetch) (uri (string-append "https://download.samba.org/pub/samba/stable/" "samba-" version ".tar.gz")) (sha256 - (base32 "1nrp85aya0pbbqdqjaqcw82cnzzys16yls37hi2h6mci8d09k4si")))) - ;; Note: this is duplicated from samba for robustness annd because - ;; docbook-xsl (rather than docbook-xsl-next) is used. + (base32 "0fl2y5avmyxjadh6zz0fwz35akd6c4j9lldzp2kyvjrgm36qx1h4")))) + (build-system gnu-build-system) + (arguments + (list + #:make-flags #~(list "TEST_OPTIONS=--quick") ;some tests are very long + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'setup-docbook-stylesheets + (lambda* (#:key inputs #:allow-other-keys) + ;; Append Samba's own DTDs to XML_CATALOG_FILES + ;; (c.f. docs-xml/build/README). + (copy-file "docs-xml/build/catalog.xml.in" + "docs-xml/build/catalog.xml") + (substitute* "docs-xml/build/catalog.xml" + (("/@abs_top_srcdir@") + (string-append (getcwd) "/docs-xml"))) + ;; Honor XML_CATALOG_FILES. + (substitute* "buildtools/wafsamba/wafsamba.py" + (("XML_CATALOG_FILES=\"\\$\\{SAMBA_CATALOGS\\}" all) + (string-append all " $XML_CATALOG_FILES"))))) + (replace 'configure + ;; Samba uses a custom configuration script that runs WAF. + (lambda* (#:key inputs #:allow-other-keys) + (let* ((libdir (string-append #$output "/lib"))) + (invoke "./configure" + #$@(if (member (%current-system) + (package-transitive-supported-systems + python-cryptography)) + '("--enable-selftest") + '()) + "--enable-fhs" + (string-append "--prefix=" #$output) + "--sysconfdir=/etc" + "--localstatedir=/var" + ;; Install public and private libraries into + ;; a single directory to avoid RPATH issues. + (string-append "--libdir=" libdir) + (string-append "--with-privatelibdir=" libdir) + "--with-system-mitkrb5" + (string-append "--with-system-mitkdc=" + (search-input-file inputs "sbin/krb5kdc")) + "--with-experimental-mit-ad-dc")))) + (add-before 'install 'disable-etc,var-samba-directories-setup + (lambda _ + (substitute* "dynconfig/wscript" + (("bld\\.INSTALL_DIR.*") ""))))) + ;; FIXME: The test suite seemingly hangs after failing to provision the + ;; test environment. + #:tests? #f)) + (inputs + (list acl + avahi + cmocka + cups + gamin + dbus + gpgme + gnutls + jansson + libarchive + libtirpc + linux-pam + lmdb + mit-krb5 + openldap + perl + python + popt + readline + tdb)) + (propagated-inputs + ;; In Requires or Requires.private of pkg-config files. + (list ldb talloc tevent)) (native-inputs (append (list perl-parse-yapp @@ -325,34 +277,47 @@ Desktops into Active Directory environments using the winbind daemon.") python-pyasn1 ;for krb5 tests ;; For generating man pages. docbook-xml-4.2 - docbook-xsl ;otherwise the man pages are corrupted + docbook-xsl libxslt - libxml2)))))) ;for XML_CATALOG_FILES + libxml2))) ;for XML_CATALOG_FILES + (home-page "https://www.samba.org/") + (synopsis + "The standard Windows interoperability suite of programs for GNU and Unix") + (description + "Since 1992, Samba has provided secure, stable and fast file and print +services for all clients using the SMB/CIFS protocol, such as all versions of +DOS and Windows, OS/2, GNU/Linux and many others. +Samba is an important component to seamlessly integrate Linux/Unix Servers and +Desktops into Active Directory environments using the winbind daemon.") + (license license:gpl3+)))) -(define samba/security-fixes +(define-public samba (package (inherit samba/pinned) (version "4.18.1") (source + ;; For updaters: the current PGP fingerprint is + ;; 81F5E2832BD2545A1897B713AA99442FB680B620. (origin (method url-fetch) (uri (string-append "https://download.samba.org/pub/samba/stable/" - "samba-" version ".tar.gz")) + "samba-" version ".tar.gz")) (sha256 - (base32 "03ncp49pfpzjla205y3xpb9iy61dz4pryyrvyz26422a4hpsmpnf")))))) + (base32 "03ncp49pfpzjla205y3xpb9iy61dz4pryyrvyz26422a4hpsmpnf")))) + (properties (alist-delete 'hidden? (package-properties samba/pinned))))) (define-public talloc (package (name "talloc") - (version "2.3.3") + (version "2.3.4") (source (origin (method url-fetch) (uri (string-append "https://www.samba.org/ftp/talloc/talloc-" version ".tar.gz")) (sha256 (base32 - "1ala3l6v8qk2pwq97z1zdkj1isnfnrp1923srp2g22mxd0impsbb")))) + "01b5pq39z1l26f86dy8jqb37fsjbvsvx5ji65jmy8rsy4sz9x7qp")))) (build-system gnu-build-system) (arguments '(#:phases @@ -412,14 +377,14 @@ destructors. It is the core memory allocator used in Samba.") (define-public tevent (package (name "tevent") - (version "0.11.0") + (version "0.13.0") (source (origin (method url-fetch) (uri (string-append "https://www.samba.org/ftp/tevent/tevent-" version ".tar.gz")) (sha256 (base32 - "1fl2pj4p8p5fa2laykwf1sfjdw7pkw9slklj3vzc5ah8x348d6pf")))) + "030x6ziapxiqvmi2m23ri2p9rsa202gfqr7b3cv48lx5gy8plhxr")))) (build-system gnu-build-system) (arguments '(#:phases @@ -446,14 +411,14 @@ many event types, including timers, signals, and the classic file descriptor eve (define-public ldb (package (name "ldb") - (version "2.4.1") + (version "2.6.1") (source (origin (method url-fetch) (uri (string-append "https://www.samba.org/ftp/ldb/ldb-" version ".tar.gz")) (sha256 (base32 - "13yd7lavbx8bxwnmzl0j7xnl2gl4wmnn0q9g7n3y7bvbnhm07hb9")) + "1j9n2yzhd35xjh0mdfgym58xfbma1d27bcavjv1q4rzqgpvh6x26")) (modules '((guix build utils))) (snippet '(begin diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 3cf585480e..2fae1676cc 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm @@ -18,6 +18,8 @@ ;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com> ;;; Copyright © 2022 Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> ;;; Copyright © 2023 Jake Leporte <jakeleporte@outlook.com> +;;; Copyright © 2023 Timotej Lazar <timotej.lazar@araneo.si> +;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -57,6 +59,7 @@ #:use-module (gnu packages docbook) #:use-module (gnu packages documentation) #:use-module (gnu packages dns) + #:use-module (gnu packages flex) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages graphviz) @@ -209,7 +212,8 @@ the low-level development kit for the Yubico YubiKey authentication device.") "softhsm-" version ".tar.gz")) (sha256 (base32 - "1wkmyi6n3z2pak1cj5yk6v6bv9w0m24skycya48iikab0mrr8931")))) + "1wkmyi6n3z2pak1cj5yk6v6bv9w0m24skycya48iikab0mrr8931")) + (patches (search-patches "softhsm-fix-openssl3-tests.patch")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-gost"))) ; TODO Missing the OpenSSL @@ -228,23 +232,24 @@ with a PKCS #11 Cryptographic Token Interface.") (define-public pcsc-lite (package (name "pcsc-lite") - (version "1.9.3") + (version "1.9.8") (source (origin (method url-fetch) (uri (string-append "https://pcsclite.apdu.fr/files/" "pcsc-lite-" version ".tar.bz2")) (sha256 (base32 - "0n9y9m1wr5bwanpnylpdza3sf7lawi63jjizrl1aj5yxf4y46mk9")))) + "12923c6l5qzga1xlcxvm0vzbqrxnxq1qgzlrxf2y5gpcaz2q0bah")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--enable-usbdropdir=/var/lib/pcsc/drivers" "--disable-libsystemd"))) (native-inputs - (list perl ; for pod2man + (list flex + perl ;for pod2man pkg-config)) (inputs - `(("libudev" ,eudev))) + (list python eudev)) (home-page "https://pcsclite.apdu.fr/") (synopsis "Middleware to access a smart card using PC/SC") (description @@ -578,30 +583,19 @@ Notable features: "0vrivl1dwql6nfi48z6dy56fwy2z13d7abgahgrs2mcmqng7hra2")))) (build-system gnu-build-system) (arguments - `(#:configure-flags - (list "--enable-gtk-doc" - (string-append "--with-udevrulesdir=" - (assoc-ref %outputs "out") - "/lib/udev/rules.d")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-xml - (lambda* (#:key inputs #:allow-other-keys) - ;; Avoid a network connection attempt during the build. - (substitute* "gtk-doc/u2f-host-docs.xml" - (("http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd") - (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook/docbookx.dtd"))) - #t))))) - (inputs - (list json-c-0.13 hidapi)) + (list #:configure-flags + #~(list "--enable-gtk-doc" + (string-append "--with-udevrulesdir=" #$output + "/lib/udev/rules.d")))) + (inputs (list json-c-0.13 hidapi)) (native-inputs (list help2man gengetopt pkg-config gtk-doc docbook-xml-4.3 - eudev)) + eudev + libxml2)) ;for XML_CATALOG_FILES (home-page "https://developers.yubico.com/libu2f-host/") ;; TRANSLATORS: The U2F protocol has a "server side" and a "host side". (synopsis "U2F host-side C library and tool") diff --git a/gnu/packages/selinux.scm b/gnu/packages/selinux.scm index d898b55129..c45570744a 100644 --- a/gnu/packages/selinux.scm +++ b/gnu/packages/selinux.scm @@ -162,7 +162,11 @@ module into a binary representation.") ;; Python bindings. Instruct it to use the correct output. (substitute* "src/Makefile" (("--prefix=\\$\\(PREFIX\\)") - (string-append "--prefix=" #$output:python))) + (string-append "--prefix=" #$output:python + ;; Python 3.10 refuses to execute the install + ;; command unless these flags are present. + " --single-version-externally-managed" + " --root=/"))) (apply invoke "make" "install-pywrap" make-flags))))))) ;; These libraries are in "Requires.private" in libselinux.pc. diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm index 3f0a550920..c2c36eede8 100644 --- a/gnu/packages/serialization.scm +++ b/gnu/packages/serialization.scm @@ -39,6 +39,7 @@ #:use-module (guix build-system cmake) #:use-module (guix build-system copy) #:use-module (guix build-system gnu) + #:use-module (guix build-system meson) #:use-module (guix build-system python) #:use-module (gnu packages) #:use-module (gnu packages autotools) @@ -452,26 +453,16 @@ in which the loaded data is arranged in memory.") (define-public jsoncpp (package (name "jsoncpp") - (version "1.9.4") + (version "1.9.5") (home-page "https://github.com/open-source-parsers/jsoncpp") (source (origin (method git-fetch) (uri (git-reference (url home-page) (commit version))) (file-name (git-file-name name version)) - (patches - (search-patches "jsoncpp-pkg-config-version.patch")) (sha256 (base32 - "0qnx5y6c90fphl9mj9d20j2dfgy6s5yr5l0xnzid0vh71zrp6jwv")))) - (build-system cmake-build-system) - (arguments - `(#:configure-flags '("-DBUILD_SHARED_LIBS:BOOL=YES" - ,@(if (%current-target-system) - `("-DJSONCPP_WITH_POST_BUILD_UNITTEST=OFF") - '())) - ,@(if (%current-target-system) - '() - `(#:cmake ,cmake-bootstrap)))) + "06zss7z56ykzwcsfdxarmini63hkf8i8gx70q3yw9wb0bw7wj9rv")))) + (build-system meson-build-system) (synopsis "C++ library for interacting with JSON") (description "JsonCpp is a C++ library that allows manipulating JSON values, including serialization and deserialization to and from strings. It can also @@ -494,7 +485,14 @@ it a convenient format to store user input files.") (file-name (git-file-name name version)) (sha256 (base32 - "1180ln8blrb0mwzpcf78k49hlki6di65q77rsvglf83kfcyh4d7z")))))) + "1180ln8blrb0mwzpcf78k49hlki6di65q77rsvglf83kfcyh4d7z")))) + (build-system cmake-build-system) + (arguments + (list #:configure-flags + #~'("-DBUILD_SHARED_LIBS:BOOL=YES" + #$@(if (%current-target-system) + #~("-DJSONCPP_WITH_POST_BUILD_UNITTEST=OFF") + #~())))))) (define-public json.sh (let ((commit "0d5e5c77365f63809bf6e77ef44a1f34b0e05840") ;no releases diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm index 1ffe4ce5d8..a2a4b70bce 100644 --- a/gnu/packages/shells.scm +++ b/gnu/packages/shells.scm @@ -384,17 +384,17 @@ written by Paul Haahr and Byron Rakitzis.") (define-public tcsh (package (name "tcsh") - (version "6.22.03") + (version "6.24.01") (source (origin (method url-fetch) ;; Old tarballs are moved to old/. - (uri (list (string-append "ftp://ftp.astron.com/pub/tcsh/" + (uri (list (string-append "https://astron.com/pub/tcsh/" "tcsh-" version ".tar.gz") - (string-append "ftp://ftp.astron.com/pub/tcsh/" + (string-append "https://astron.com/pub/tcsh/" "old/tcsh-" version ".tar.gz"))) (sha256 (base32 - "1dv24bsp6faayinvwds092ylk9sb6894rl9ddm87y31a7mjzsb5y")) + "0zhxp4m1fxyd3a2qyvs97gzlrb0h0ah1gjrqcbilgydiffws2nan")) (patches (search-patches "tcsh-fix-autotest.patch")) (patch-flags '("-p0")))) (build-system gnu-build-system) @@ -406,28 +406,16 @@ written by Paul Haahr and Byron Rakitzis.") (inputs (list ncurses)) (arguments - `(#:phases - (modify-phases %standard-phases - ,@(if (%current-target-system) - '((add-before 'configure 'set-cross-cc - (lambda _ - (substitute* "configure" - (("CC_FOR_GETHOST=\"cc\"") - "CC_FOR_GETHOST=\"gcc\"")) - #t))) - '()) - ,@(if (target-riscv64?) - ;; TODO: remove after commit - ;; 3c33503f9aec4412dc1a95927a8c5c357c7b851e or 6.24.00 - `((add-after 'unpack 'update-config-scripts - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (for-each (lambda (file) - (install-file - (search-input-file - (or native-inputs inputs) - (string-append "/bin/" file)) ".")) - '("config.guess" "config.sub"))))) - '()) + (list + #:phases + #~(modify-phases %standard-phases + #$@(if (%current-target-system) + #~((add-before 'configure 'set-cross-cc + (lambda _ + (substitute* "configure" + (("CC_FOR_GETHOST=\"cc\"") + "CC_FOR_GETHOST=\"gcc\""))))) + #~()) (add-before 'check 'patch-test-scripts (lambda _ ;; Take care of pwd @@ -454,15 +442,11 @@ written by Paul Haahr and Byron Rakitzis.") ;; This file is ISO-8859-1 encoded. (with-fluids ((%default-port-encoding #f)) (substitute* "tests/testsuite" - (("/bin/sh") (which "sh")))) - #t)) + (("/bin/sh") (which "sh")))))) (add-after 'install 'post-install - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref %outputs "out")) - (bin (string-append out "/bin"))) - (with-directory-excursion bin - (symlink "tcsh" "csh")) - #t)))))) + (lambda _ + (with-directory-excursion (string-append #$output "/bin") + (symlink "tcsh" "csh"))))))) (home-page "https://www.tcsh.org/") (synopsis "Unix shell based on csh") (description @@ -487,7 +471,8 @@ history mechanism, job control and a C-like syntax.") ".tar.xz"))) (sha256 (base32 - "06crvpqbpm8sq5c215f4b985z7npwnqnj0i0g53hnq6fp8h3b5xn")))) + "06crvpqbpm8sq5c215f4b985z7npwnqnj0i0g53hnq6fp8h3b5xn")) + (patches (search-patches "zsh-egrep-failing-test.patch")))) (build-system gnu-build-system) (arguments `(#:configure-flags `("--with-tcsetpgrp" @@ -913,29 +898,19 @@ scripts.") (define-public gash (package (name "gash") - (version "0.2.0") + (version "0.3.0") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/gash/gash-" version ".tar.gz")) (sha256 (base32 - "13m0yz5h9nj3x40mr6wr5xcpq1lscndfwcicw3skrz801025hhgf")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Allow builds with Guile 3.0. - (substitute* "configure" - (("search=\"2\\.2 2\\.0\"") - "search=\"3.0 2.2 2.0\"")) - #t)))) + "1af2jz4a6rzsshi379wzw4b8d04zvfamdhfzip2pgmk821lyqsjl")))) (build-system gnu-build-system) (native-inputs (list pkg-config)) (inputs (list guile-3.0)) - (arguments - '(#:make-flags '("XFAIL_TESTS=tests/redirects.org"))) (home-page "https://savannah.nongnu.org/projects/gash/") (synopsis "POSIX-compatible shell written in Guile Scheme") (description "Gash is a POSIX-compatible shell written in Guile @@ -947,23 +922,14 @@ as part of the Guix bootstrap process.") (define-public gash-utils (package (name "gash-utils") - (version "0.1.0") + (version "0.2.0") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/gash/gash-utils-" version ".tar.gz")) (sha256 (base32 - "0ib2p52qmbac5n0s5bys4fiwim461ps546976l1n7pwbs0avh7fk")) - (patches (search-patches "gash-utils-ls-test.patch")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Allow builds with Guile 3.0. - (substitute* "configure" - (("search=\"2\\.2 2\\.0\"") - "search=\"3.0 2.2 2.0\"")) - #t)))) + "18ylb54l9lmaynapbncc1zhbsirhihznrxihhxgqrpqgyjkfbap6")))) (build-system gnu-build-system) (native-inputs (list pkg-config)) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 40633b75c6..ff124717e8 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -110,24 +110,24 @@ texlive-capt-of texlive-carlisle ;remreset texlive-etoolbox - texlive-generic-ltxcmds + texlive-ltxcmds texlive-hyperref texlive-latex-base ;alltt, atbegshi, makeidx, textcomp texlive-latex-cmap - texlive-latex-fancyhdr - texlive-latex-fancyvrb + texlive-fancyhdr + texlive-fancyvrb texlive-latex-float texlive-latex-fncychap texlive-latex-framed texlive-latex-geometry - texlive-latex-graphics ;graphicx, color - texlive-latex-kvoptions + texlive-graphics ;graphicx, color + texlive-kvoptions texlive-latex-needspace texlive-latex-parskip texlive-latex-preview texlive-latex-tabulary - texlive-latex-titlesec - texlive-latex-tools ;multicol, longtable + texlive-titlesec + texlive-tools ;multicol, longtable texlive-latex-upquote texlive-latex-varwidth texlive-oberdiek ;hypcap @@ -794,7 +794,15 @@ scientific documentation.") (base32 "0p3abj91c3l72ajj5jwblscsdf1jflrnn0djx2h5y6f2wjbx9ipf")))) (build-system python-build-system) - (arguments '(#:tests? #f)) ; No tests. + (arguments + (list + #:tests? #f ; No tests. + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'allow-newer-docutil + (lambda _ + (substitute* "setup.py" + (("docutils<0.18") "docutils<0.20"))))))) (propagated-inputs (list python-docutils python-sphinx)) (home-page "https://github.com/snide/sphinx_rtd_theme/") (synopsis "ReadTheDocs.org theme for Sphinx") diff --git a/gnu/packages/spice.scm b/gnu/packages/spice.scm index f492957fb2..98faaed940 100644 --- a/gnu/packages/spice.scm +++ b/gnu/packages/spice.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2019 Rutger Helling <rhelling@mykolab.com> ;;; Copyright © 2019, 2020, 2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2023 Efraim Flashner <efraim@flashner.co.il> ;;; ;;; This file is part of GNU Guix. ;;; @@ -27,6 +28,7 @@ #:use-module (gnu packages autotools) #:use-module (gnu packages base) #:use-module (gnu packages bash) + #:use-module (gnu packages build-tools) #:use-module (gnu packages compression) #:use-module (gnu packages cyrus-sasl) #:use-module (gnu packages gl) @@ -356,6 +358,12 @@ resolution scaling on graphical console window resize.") (base32 "1rrjlclm6ad63gah1fa4yfwrz4z6vgq2yrybbvzvvdbxrgl4vgzv")))) (build-system meson-build-system) + (arguments + (list #:configure-flags + ;; Otherwise, the validate-runpath phase fails. + #~(list (string-append "-Dc_link_args=-Wl,-rpath=" + (search-input-directory %build-inputs + "lib/nss"))))) (propagated-inputs ;; The following inputs are required in the pkg-config file. (list glib diff --git a/gnu/packages/sqlite.scm b/gnu/packages/sqlite.scm index 71cc923a3a..2e727bd933 100644 --- a/gnu/packages/sqlite.scm +++ b/gnu/packages/sqlite.scm @@ -38,6 +38,7 @@ #:use-module (guix download) #:use-module (guix build-system gnu) #:use-module (guix utils) + #:use-module (guix deprecation) #:use-module (ice-9 match) #:use-module (srfi srfi-26)) @@ -62,14 +63,14 @@ (define-public sqlite (package (name "sqlite") - (version "3.36.0") + (version "3.39.3") (source (origin (method url-fetch) - (uri (sqlite-uri version 2021)) + (uri (sqlite-uri version 2022)) (patches (search-patches "sqlite-hurd.patch")) (sha256 (base32 - "1qxwkfvd185dfcqbakrzikrsw6ffr5jp1gl3dch9dsdyjvmw745x")))) + "1f922kq16g7f4h3gpzim78lvrp5xw9nvlvqw97s2qgxyh8qgns3q")))) (build-system gnu-build-system) (inputs (list readline)) (outputs '("out" "static")) diff --git a/gnu/packages/ssh.scm b/gnu/packages/ssh.scm index b91e70aaed..af5072fdc2 100644 --- a/gnu/packages/ssh.scm +++ b/gnu/packages/ssh.scm @@ -63,6 +63,7 @@ #:use-module (gnu packages popt) #:use-module (gnu packages protobuf) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) @@ -170,7 +171,7 @@ applications.") (define-public libssh2 (package (name "libssh2") - (version "1.9.0") + (version "1.10.0") (source (origin (method url-fetch) (uri (string-append @@ -178,13 +179,14 @@ applications.") version ".tar.gz")) (sha256 (base32 - "1zfsz9nldakfz61d2j70pk29zlmj7w2vv46s9l3x2prhcgaqpyym")) - (patches (search-patches "libssh2-CVE-2019-17498.patch")))) + "0l8xwhhscvss7q007vpbkbv7jh9s43579rx2sf8lnfgd7l7yjr1d")))) (build-system gnu-build-system) ;; The installed libssh2.pc file does not include paths to libgcrypt and ;; zlib libraries, so we need to propagate the inputs. (propagated-inputs (list libgcrypt zlib)) - (arguments `(#:configure-flags `("--with-libgcrypt"))) + (arguments + (list #:configure-flags #~'("--with-libgcrypt" + "--disable-static"))) (synopsis "Client-side C library implementing the SSH2 protocol") (description "libssh2 is a library intended to allow software developers access to diff --git a/gnu/packages/sssd.scm b/gnu/packages/sssd.scm index 051d7df014..a6b4c8aa90 100644 --- a/gnu/packages/sssd.scm +++ b/gnu/packages/sssd.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2020 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2021 Timotej Lazar <timotej.lazar@araneo.si> ;;; Copyright © 2021, 2022 Remco van 't Veer <remco@remworks.net> +;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -36,6 +37,7 @@ #:use-module (gnu packages autotools) #:use-module (gnu packages bash) #:use-module (gnu packages check) + #:use-module (gnu packages compression) #:use-module (gnu packages crypto) #:use-module (gnu packages curl) #:use-module (gnu packages cyrus-sasl) @@ -81,37 +83,18 @@ `(#:configure-flags ;; The net tool is used to update the stored machine key for samba. (list (string-append "--with-samba-data-tool=" - (assoc-ref %build-inputs "samba") "/bin/net")) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'use-local-docbook - ;; Patch Makefile and docs to use local docbook resources. - (lambda _ - (let* ((docbook-xml (assoc-ref %build-inputs "docbook-xml")) - (docbook-xsl (assoc-ref %build-inputs "docbook-xsl")) - (xsldir (string-append docbook-xsl "/xml/xsl/docbook-xsl-" - ,(package-version docbook-xsl)))) - (with-directory-excursion "doc" - (substitute* - '("Makefile.am" "adcli.xml" "adcli-devel.xml" "adcli-docs.xml") - (("http://docbook.sourceforge.net/release/xsl/current(/[^\"]*)" _ path) - (string-append xsldir path)) - (("http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd") - (string-append docbook-xml "/xml/dtd/docbook/docbookx.dtd"))) - (substitute* "Makefile.am" - (("\\$\\(XMLTO\\)" xmlto) - (string-append xmlto " --searchpath " xsldir "/html")))))))))) + (search-input-file %build-inputs "bin/net"))))) (native-inputs (list autoconf automake - docbook-xml + docbook-xml-4.3 docbook-xsl libtool + libxml2 ;for XML_CATALOG_FILES libxslt - util-linux ; For `rev` command used in tests. + util-linux ;For `rev` command used in tests. xmlto)) - (inputs - (list cyrus-sasl mit-krb5 samba openldap)) + (inputs (list cyrus-sasl mit-krb5 samba openldap zlib)) (home-page "https://gitlab.freedesktop.org/realmd/adcli/") (synopsis "Helper library and tools for Active Directory client operations") (description "@command{adcli} is a command‐line tool to join a computer to diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index de82d87f36..e1cdd6b850 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -384,11 +384,11 @@ as.POSIXct(if (\"\" != Sys.getenv(\"SOURCE_DATE_EPOCH\")) {\ texlive-grfext texlive-amsfonts texlive-latex-base - texlive-latex-fancyvrb - texlive-latex-graphics + texlive-fancyvrb + texlive-graphics texlive-hyperref texlive-oberdiek - texlive-latex-tools + texlive-tools texlive-latex-upquote texlive-url texlive-latex-xkeyval)) diff --git a/gnu/packages/swig.scm b/gnu/packages/swig.scm index b5195e2cc5..51024ef487 100644 --- a/gnu/packages/swig.scm +++ b/gnu/packages/swig.scm @@ -43,7 +43,9 @@ name "-" version ".tar.gz")) (sha256 (base32 - "1z06m5zv87mha6hvys1iay810ghc1jngilfby1ms2n4d1mryjfym")))) + "1z06m5zv87mha6hvys1iay810ghc1jngilfby1ms2n4d1mryjfym")) + ;; Remove with next release. + (patches (search-patches "swig-support-gcc-12.patch")))) (build-system gnu-build-system) (native-inputs (list boost `(,pcre "bin") ;for 'pcre-config' diff --git a/gnu/packages/syndication.scm b/gnu/packages/syndication.scm index 55c9d871e3..cc6ead859e 100644 --- a/gnu/packages/syndication.scm +++ b/gnu/packages/syndication.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2021 Felix Gruber <felgru@posteo.net> ;;; Copyright © 2022 Luis Felipe López Acevedo <luis.felipe.la@protonmail.com> ;;; Copyright © 2022 Liliana Marie Prikler <liliana.prikler@gmail.com> +;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -523,8 +524,6 @@ a simple interface that makes it easy to organize and browse feeds.") (sha256 (base32 "1i0llzzm3lc2kw7rjhb46c7wlknsb6r9bdrf61chi2pk6hpjyscv")))) (build-system meson-build-system) - (arguments - (list #:meson meson-0.63)) (inputs (list fmt tidy-html pybind11 python pugixml)) (native-inputs (list cmake pkg-config)) ; need cmake to find pybind11 (home-page "https://gitlab.com/gabmus/syndication-domination") @@ -536,7 +535,7 @@ parser. It is \"not fit for use at this point\", but gfeeds uses it anyway.") (define-public gfeeds (package (name "gfeeds") - (version "1.0.3") + (version "2.2.0") (source (origin (method git-fetch) (uri (git-reference @@ -545,7 +544,7 @@ parser. It is \"not fit for use at this point\", but gfeeds uses it anyway.") (file-name (git-file-name name version)) (sha256 (base32 - "1lkvhff7pl1y4brqsix6sar5yl8flyhfp3w96fx0klhk3586bvhg")))) + "0p2hyjif9yhpc6r3ig7fdxpb2q8s9g42mz38svsc38gq7hb13b2w")))) (build-system meson-build-system) (arguments (list @@ -557,12 +556,12 @@ parser. It is \"not fit for use at this point\", but gfeeds uses it anyway.") (("mpv") (search-input-file inputs "/bin/mpv"))))) (add-after 'unpack 'skip-icon-cache (lambda _ - (substitute* "meson_post_install.py" - (("gtk-update-icon-cache") "true")))) + (substitute* "meson.build" + (("gtk_update_icon_cache: true") + "gtk_update_icon_cache: false")))) (add-after 'install 'wrap-gfeeds (lambda* (#:key outputs #:allow-other-keys) - (wrap-program (string-append - (assoc-ref outputs "out") "/bin/gfeeds") + (wrap-program (search-input-file outputs "/bin/gfeeds") `("PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH"))) `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH"))) `("XDG_DATA_DIRS" ":" prefix (,(getenv "XDG_DATA_DIRS"))))))))) diff --git a/gnu/packages/tcl.scm b/gnu/packages/tcl.scm index f071b13146..2a5fbc6fe8 100644 --- a/gnu/packages/tcl.scm +++ b/gnu/packages/tcl.scm @@ -46,14 +46,14 @@ (define-public tcl (package (name "tcl") - (version "8.6.11") + (version "8.6.12") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/tcl/Tcl/" version "/tcl" version "-src.tar.gz")) (sha256 (base32 - "0n4211j80mxr6ql0xx52rig8r885rcbminfpjdb2qrw6hmk8c14c")))) + "19n1wk6ypx19p26gywvibwbhqs2zapp93n3136qlhzhn1zfrbj96")))) (build-system gnu-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -193,7 +193,7 @@ X11 GUIs.") (define-public tk (package (name "tk") - (version "8.6.11.1") + (version "8.6.12") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/tcl/Tcl/" @@ -201,7 +201,7 @@ X11 GUIs.") version "-src.tar.gz")) (sha256 (base32 - "1gh9k7l76qg9l0sb78ijw9xz4xl1af47aqbdifb6mjpf3cbsnv00")) + "0c0665h9b55cr3p6civcrgaixx6dldz7k7v870lyssyb7wgmqf8j")) (patches (search-patches "tk-find-library.patch")))) (build-system gnu-build-system) (arguments diff --git a/gnu/packages/telephony.scm b/gnu/packages/telephony.scm index c921507fd3..7666176908 100644 --- a/gnu/packages/telephony.scm +++ b/gnu/packages/telephony.scm @@ -297,6 +297,9 @@ reimplementation.") (sha256 (base32 "1mv080rvrhyxyhgqiqr8r9jdqhg3xhfawjvfj5zgj47h59nggjba")))) (build-system gnu-build-system) + (arguments + ;; Does not work with std=c++17, which is the default in modern GCC versions. + `(#:configure-flags '("CXXFLAGS=-std=c++14"))) (inputs (list gnutls)) (synopsis "Common C++ framework for threaded applications") (description "GNU uCommon C++ is meant as a very light-weight C++ library diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index c8f7923552..4e4a7b4aef 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be> ;;; Copyright © 2016-2023 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> -;;; Copyright © 2017, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2017, 2020-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2018 Danny Milosavljevic <dannym+a@scratchpost.org> ;;; Copyright © 2018, 2020 Arun Isaac <arunisaac@systemreboot.net> @@ -20,6 +20,7 @@ ;;; Copyright © 2021 Ivan Gankevich <i.gankevich@spbu.ru> ;;; Copyright © 2021 Julien Lepiller <julien@lepiller.eu> ;;; Copyright © 2021 Thiago Jung Bauermann <bauermann@kolabnow.com> +;;; Copyright © 2022 Simon South <simon@simonsouth.net> ;;; Copyright © 2022 Jack Hill <jackhill@jackhill.us> ;;; Copyright © 2022 Fabio Natali <me@fabionatali.com> ;;; Copyright © 2022 Philip McGrath <philip@philipmcgrath.com> @@ -367,6 +368,14 @@ files from LOCATIONS with expected checksum HASH. CODE is not currently in use. #:phases (modify-phases %standard-phases + (add-after 'unpack 'patch-psutils-test + (lambda _ + ;; This test fails due to a rounding difference with libpaper 1.2: + ;; https://github.com/rrthomas/libpaper/issues/23 + ;; Adjust the expected outcome to account for the minute difference. + (substitute* "texk/psutils/tests/playres.ps" + (("844\\.647799") + "844.647797")))) (add-after 'unpack 'configure-ghostscript-executable ;; ps2eps.pl uses the "gswin32c" ghostscript executable on Windows, ;; and the "gs" ghostscript executable on Unix. It detects Unix by @@ -606,8 +615,8 @@ This package contains the binaries.") (mkdir-p doc) (copy-recursively (string-append #$source "/doc") doc))))))) - (propagated-inputs (list texlive-generic-iftex - texlive-generic-ltxcmds + (propagated-inputs (list texlive-iftex + texlive-ltxcmds texlive-hyperref texlive-latex-xkeyval texlive-zref)) @@ -3153,41 +3162,93 @@ with the required packages, constitutes what every LaTeX distribution should contain.") (license license:lppl1.3c+)))) -(define-public texlive-latex-atveryend - (package - (inherit (simple-texlive-package - "texlive-latex-atveryend" - '("/doc/latex/atveryend/README.md" - "/tex/latex/atveryend/") - (base32 - "1gz5ssxjlqa53a8blsmdk2qjahzc910ldh26xjxfxgqnqb03rqx7") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/atveryend") - (synopsis "Hooks at the very end of a document") - (description - "This LaTeX package provides two hooks for @code{\\end@{document@}} -that are executed after the hook of @code{\\AtEndDocument}: +(define-public texlive-atveryend + (let ((template (simple-texlive-package + "texlive-atveryend" + (list "doc/latex/atveryend/" + "source/latex/atveryend/" + "tex/latex/atveryend/") + (base32 "1rp805h0m99rxs107a798l951lyahlnp7irfklfadn2a2ljzhafn")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ #t) + "latex/atveryend") + ((#:build-targets _ #t) + #~(list "atveryend.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/atveryend/"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))) + (add-after 'copy-files 'remove-generated-file + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion #$output + (for-each delete-file + (find-files "." "\\.(drv|ins)$"))))))))) + (home-page "https://ctan.org/macros/latex/contrib/atveryend") + (synopsis "Hooks at the very end of a document") + (description + "This LaTeX packages provides two hooks for @code{\\end{document}} that +are executed after the hook of @code{\\AtEndDocument}: @code{\\AfterLastShipout} can be used for code that is to be executed right after the last @code{\\clearpage} before the @file{.aux} file is closed. -@code{\\AtVeryEndDocument} is used for code after closing and final reading -of the @file{.aux} file.") - (license license:lppl1.3c+))) +@code{\\AtVeryEndDocument} is used for code after closing and final reading of +the @file{.aux} file.") + (license license:lppl1.3+)))) -(define-public texlive-latex-auxhook - (package - (inherit (simple-texlive-package - "texlive-latex-auxhook" - '("/doc/latex/auxhook/README.md" - "/tex/latex/auxhook/") - (base32 - "1xh445shr00rh43nnz03xh8k2mdrxgsr03lllqpgvwhm6yzsydkf") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/auxhook") - (synopsis "Hooks for auxiliary files") - (description - "This package provides hooks for adding code at the beginning of +(define-deprecated-package texlive-latex-atveryend texlive-atveryend) + +(define-public texlive-auxhook + (let ((template (simple-texlive-package + "texlive-auxhook" + (list "doc/latex/auxhook/" + "source/latex/auxhook/" + "tex/latex/auxhook/") + (base32 + "1qfs7bz8ryp4prr2fw4hwypnfc6yr4rc4wd8qy4rpmab0hab0vdy")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/auxhook") + ((#:build-targets _ '()) + #~(list "auxhook.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/auxhook"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/auxhook") + (synopsis "Hooks for auxiliary files") + (description + "This package provides hooks for adding code at the beginning of @file{.aux} files.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-auxhook texlive-auxhook) (define-public texlive-latex-epstopdf-pkg (package @@ -3258,30 +3319,6 @@ users, via its Plain TeX version.)") (package (inherit (simple-texlive-package "texlive-fancyvrb" - (list "/doc/latex/fancyvrb" - "/tex/latex/fancyvrb/") - (base32 - "1qlrmc70ck2v3wqh8gjd5jl0f6011zzcsg9a93qf1z9b9virvjy2") - #:trivial? #t)) - (propagated-inputs (list texlive-latex-upquote)) - (home-page "https://ctan.org/macros/latex/contrib/fancyvrb") - (synopsis "Sophisticated verbatim text") - (description - "This package provides tools for the flexible handling of verbatim text -including: verbatim commands in footnotes; a variety of verbatim environments -with many parameters; ability to define new customized verbatim environments; -save and restore verbatim text and environments; write and read files in -verbatim mode; build @code{example} environments (showing both result and -verbatim source).") - (license license:lppl1.3+))) - -;; FIXME: This package needs to be deprecated in favour of `texlive-fancyvrb', -;; but this triggers 17k rebuilds. So leave it there and wait for -;; core-updates or a topic branch to catch-up. -(define-public texlive-latex-fancyvrb - (package - (inherit (simple-texlive-package - "texlive-latex-fancyvrb" (list "/doc/latex/fancyvrb/README" "/tex/latex/fancyvrb/") (base32 @@ -3298,6 +3335,8 @@ verbatim mode; build \"example\" environments (showing both result and verbatim source).") (license license:lppl1.0+))) +(define-deprecated-package texlive-latex-fancyvrb texlive-fancyvrb) + (define-public texlive-glyphlist (package (inherit (simple-texlive-package @@ -3350,6 +3389,57 @@ packages.") set default \"driver\" options for the color and graphics packages.") (license license:public-domain))) +(define-public texlive-graphics + (let ((template (simple-texlive-package + "texlive-graphics" + (list "doc/latex/graphics/" + "source/latex/graphics/" + "tex/latex/graphics/") + (base32 + "0prw1zcv4fcj3zg0kyhj0k7ax0530adl60bajzvbv3fi16d7rqlq")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/graphics") + ((#:build-targets _ '()) + #~(list "graphics-drivers.ins" "graphics.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/graphics"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + ;; This file is not generated from the sources. + (install-file + (string-append + origin + "/tex/latex/graphics/graphics-2017-06-25.sty") + (string-append + #$output + "/share/texmf-dist/tex/latex/graphics"))))))))) + (propagated-inputs (list texlive-graphics-def texlive-graphics-cfg)) + (home-page "https://ctan.org/macros/latex/required/graphics") + (synopsis "The LaTeX standard graphics bundle") + (description + "This is a collection of LaTeX packages for: producing colour including +graphics (e.g., PostScript) files rotation and scaling of text in LaTeX +documents. It comprises the packages color, graphics, graphicx, trig, epsfig, +keyval, and lscape.") + (license license:lppl1.3c)))) + +(define-deprecated-package texlive-latex-graphics texlive-graphics) + (define-public texlive-greek-fontenc (package (inherit (simple-texlive-package @@ -3367,71 +3457,83 @@ set default \"driver\" options for the color and graphics packages.") for Greek text font encodings for use with fontenc.") (license license:lppl1.3+))) -(define-public texlive-latex-graphics - (package - (name "texlive-latex-graphics") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "graphics")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "0fgjl58f25zvagssz4dwmmsclzw8cr7mx00kdrbx2kcnamcb7h8d")))) - (build-system texlive-build-system) - (arguments '(#:tex-directory "latex/graphics")) - (propagated-inputs - (list texlive-graphics-cfg texlive-graphics-def)) - (home-page "https://www.ctan.org/pkg/latex-graphics") - (synopsis "LaTeX standard graphics bundle") - (description - "This is a collection of LaTeX packages for producing color, including -graphics (e.g. PostScript) files, and rotation and scaling of text in LaTeX -documents. It comprises the packages color, graphics, graphicx, trig, epsfig, -keyval, and lscape.") - (license license:lppl1.3c+))) - -(define-public texlive-latex-hycolor - (package - (inherit (simple-texlive-package - "texlive-latex-hycolor" - (list "/doc/latex/hycolor/README.md" - "/tex/latex/hycolor/") - (base32 - "026lfb4l7b3q8g6zc68siqandhb1x98cbycn7njknqva6s99aiqn") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/latex-graphics") - (synopsis "Color for hyperref and bookmark") - (description - "This package provides the code for the @code{color} option that is +(define-public texlive-hycolor + (let ((template (simple-texlive-package + "texlive-hycolor" + (list "doc/latex/hycolor/" + "source/latex/hycolor/" + "tex/latex/hycolor/") + (base32 + "0hmkx37wwmznxjqqnca87shy7qrgqrh2cn5r941ddgivnym31xbh")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/hycolor") + ((#:build-targets _ '()) + #~(list "hycolor.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/hycolor"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/latex-graphics") + (synopsis "Color for hyperref and bookmark") + (description + "This package provides the code for the @code{color} option that is used by @code{hyperref} and @code{bookmark}.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-hycolor texlive-hycolor) (define-public texlive-xcolor (let ((template (simple-texlive-package "texlive-xcolor" - (list "/doc/latex/xcolor/" - "/source/latex/xcolor/") + (list "doc/latex/xcolor/" + "dvips/xcolor/" + "source/latex/xcolor/" + "tex/latex/xcolor/") (base32 - "12q6spmpxg30alhvarjmxzigmz7lazapbrb0mc4vhbn6n1sdz7pp")))) + "1d7108b67fcaf1sgyk43ph18l0z5m35iqg3aahqs1ymzwdfnd3f7")))) (package (inherit template) + (outputs '("out" "doc")) (arguments (substitute-keyword-arguments (package-arguments template) - ((#:tex-directory _ #t) + ((#:tex-directory _ '()) "latex/xcolor") + ((#:build-targets _ '()) + #~(list "xcolor.ins")) ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'chdir - (lambda _ (chdir "source/latex/xcolor") #t)) - (add-after 'install 'move-files - (lambda* (#:key outputs #:allow-other-keys) - (let ((share (string-append (assoc-ref outputs "out") - "/share/texmf-dist"))) - (mkdir-p (string-append share "/dvips/xcolor")) - (rename-file (string-append share "/tex/latex/xcolor/xcolor.pro") - (string-append share "/dvips/xcolor/xcolor.pro")) - #t))))))) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ (chdir "source/latex/xcolor"))) + (replace 'copy-files + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + (let ((share (string-append #$output + "/share/texmf-dist"))) + (mkdir-p (string-append share "/dvips/xcolor")) + (rename-file + (string-append share "/tex/latex/xcolor/xcolor.pro") + (string-append share "/dvips/xcolor/xcolor.pro")))))))))) ;; TODO: Propagate texlive-hyperref and many others in the next rebuild ;; cycle. Grep for '\usepackage' to see what packages it requires. ;; (propagated-inputs (list texlive-hyperref ...)) @@ -3520,48 +3622,62 @@ XML, using UTF-8 or a suitable 8-bit encoding.") (define-public texlive-hyperref (let ((template (simple-texlive-package "texlive-hyperref" - (list "/doc/latex/hyperref/" - "/source/latex/hyperref/" - ;; These files are not generated from the sources - "/tex/latex/hyperref/minitoc-hyper.sty" - "/tex/latex/hyperref/ntheorem-hyper.sty" - "/tex/latex/hyperref/xr-hyper.sty") - (base32 - "0nmbxaq676m2y9fgdji0bxqchmrli4hwhspijaszx51b3ki6bj2h")))) + (list "doc/latex/hyperref/" + "source/latex/hyperref/" + "tex/latex/hyperref/") + (base32 "052k1nygm4msaivn8245n86km4h41knivigw80q58b7rc13s6hrk")))) (package (inherit template) (arguments (substitute-keyword-arguments (package-arguments template) - ((#:tex-directory _ #t) + ((#:tex-directory _ '()) "latex/hyperref") + ((#:build-targets _ '()) + #~(list "hyperref.ins")) ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'chdir - (lambda _ (chdir "source/latex/hyperref") #t)))))) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/hyperref"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + ;; XXX: These files are not auto-generated from the + ;; sources. + (for-each (lambda (f) + (install-file + (string-append origin "/tex/latex/hyperref/" f) + (string-append + #$output + "/share/texmf-dist/tex/latex/hyperref"))) + '("minitoc-hyper.sty" + "ntheorem-hyper.sty" + "xr-hyper.sty"))))))))) (propagated-inputs - (list texlive-generic-atbegshi - texlive-generic-bitset - texlive-generic-etexcmds - texlive-generic-gettitlestring - texlive-generic-iftex - texlive-generic-infwarerr - texlive-generic-intcalc - texlive-generic-kvdefinekeys - texlive-generic-kvsetkeys - texlive-generic-ltxcmds - texlive-generic-pdfescape - texlive-latex-auxhook - texlive-latex-atveryend - texlive-latex-hycolor - texlive-latex-kvoptions - texlive-latex-letltxmacro - texlive-latex-pdftexcmds - texlive-latex-refcount - texlive-latex-rerunfilecheck - texlive-url + (list texlive-atbegshi + texlive-auxhook + texlive-bitset texlive-cm - texlive-latex-graphics ;for keyval + texlive-etexcmds + texlive-gettitlestring + texlive-graphics ;for keyval + texlive-hycolor + texlive-intcalc + texlive-kvdefinekeys + texlive-kvsetkeys + texlive-letltxmacro + texlive-ltxcmds + texlive-pdfescape + texlive-refcount + texlive-rerunfilecheck texlive-stringenc + texlive-url texlive-zapfding)) (home-page "https://www.ctan.org/pkg/hyperref") (synopsis "Extensive support for hypertext in LaTeX") @@ -3579,40 +3695,118 @@ pdf and HTML backends. The package is distributed with the @code{backref} and (define-deprecated-package texlive-latex-hyperref texlive-hyperref) (define-public texlive-oberdiek - (package - (name "texlive-oberdiek") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "oberdiek")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1cadrkpdqs65gxsaszfgfd8wqp8pvpik2sjmlyq3hz5p9yna3p9m")))) - (build-system texlive-build-system) - (arguments - '(#:tex-directory "latex/oberdiek" - #:build-targets '("oberdiek.ins") - #:phases - (modify-phases %standard-phases - ;; "ifpdf.ins" is not generated, so we need to process the dtx file. - (add-after 'unpack 'do-not-process-ifpdf.ins - (lambda _ - (substitute* "oberdiek.ins" - (("ifpdf.ins") "ifpdf.dtx")) - #t))))) - (propagated-inputs - (list texlive-generic-iftex)) - (home-page "https://www.ctan.org/pkg/oberdiek") - (synopsis "Bundle of packages submitted by Heiko Oberdiek") - (description - "The bundle comprises various LaTeX packages, providing among others: + (let ((template (simple-texlive-package + "texlive-oberdiek" + (list "bibtex/bib/oberdiek/" + "doc/latex/oberdiek/" + "source/latex/oberdiek/" + "tex/generic/oberdiek/" + "tex/latex/oberdiek/") + (base32 + "00lp24fckawpy997j7zagsxv89jif40wgjq8fw502v06d225ikp3")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/oberdiek") + ((#:build-targets _ '()) + #~(list "oberdiek.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/oberdiek"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + ;; XXX: `#:tex-directory' is limited to one location, but + ;; the package needs to install files elsewhere, so we do + ;; that manually here. + (with-directory-excursion origin + (let ((extra '("bibtex/bib/oberdiek" + "tex/generic/oberdiek"))) + (for-each + (lambda (d) + (for-each (lambda (f) + (install-file + f + (string-append #$output + "/share/texmf-dist/" + d))) + (find-files d))) + extra)))))))))) + (propagated-inputs + (list texlive-auxhook + texlive-grfext + texlive-grffile + texlive-iftex + texlive-infwarerr + texlive-kvoptions + texlive-pdftexcmds)) + (home-page "https://www.ctan.org/pkg/oberdiek") + (synopsis "Bundle of packages submitted by Heiko Oberdiek") + (description + "The bundle comprises various LaTeX packages, providing among others: better accessibility support for PDF files; extensible chemists reaction arrows; record information about document class(es) used; and many more.") - (license license:lppl1.3+))) + (license license:lppl1.3+)))) (define-deprecated-package texlive-latex-oberdiek texlive-oberdiek) +(define-public texlive-rerunfilecheck + (let ((template (simple-texlive-package + "texlive-rerunfilecheck" + (list "doc/latex/rerunfilecheck/" + "source/latex/rerunfilecheck/" + "tex/latex/rerunfilecheck/") + (base32 + "0f53b6dlnlrxkzj7h7x750p0489i2gg3isfqn0dlpncpq23w1r36")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/rerunfilecheck") + ((#:build-targets _ '()) + #~(list "rerunfilecheck.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/rerunfilecheck"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-atveryend + texlive-infwarerr + texlive-kvoptions + texlive-pdftexcmds + texlive-uniquecounter)) + (home-page "https://www.ctan.org/pkg/rerunfilecheck") + (synopsis "Checksum based rerun checks on auxiliary files") + (description + "This package provides additional rerun warnings if some auxiliary +files have changed. It is based on MD5 checksum, provided by pdfTeX.") + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-rerunfilecheck texlive-rerunfilecheck) + (define-public texlive-onedown (let ((template (simple-texlive-package @@ -3657,63 +3851,62 @@ diagrams, automated check on consistency of suit and hands, and multilingual output of bridge terms.") (license license:lppl1.3+)))) -(define-public texlive-latex-rerunfilecheck - (package - (inherit (simple-texlive-package - "texlive-latex-rerunfilecheck" - '("/doc/latex/rerunfilecheck/" - "/tex/latex/rerunfilecheck/") - (base32 - "1myz0d5bxhxvl4220ikywh921qld8n324kk9kscqbc5iw4063g56") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-infwarerr texlive-generic-uniquecounter - texlive-latex-atveryend texlive-latex-kvoptions - texlive-latex-pdftexcmds)) - (home-page "https://www.ctan.org/pkg/rerunfilecheck") - (synopsis "Checksum based rerun checks on auxiliary files") - (description - "This package provides additional rerun warnings if some auxiliary -files have changed. It is based on MD5 checksum, provided by pdfTeX.") - (license license:lppl1.3c+))) +(define-public texlive-tools + (let ((template (simple-texlive-package + "texlive-tools" + (list "doc/latex/tools/" + "source/latex/tools/" + "tex/latex/tools/") + (base32 + "0c0ixkcvrlzx6sdj25ak3bx0j65qghf51w66yg5wlnpg08d3awrs")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/tools") + ((#:build-targets _ '()) + #~(list "tools.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/tools"))) + (replace 'copy-files + (lambda _ + (let ((origin #$(package-source this-package)) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + ;; These files are not generated. + (let ((directory "/tex/latex/tools")) + (with-directory-excursion (string-append origin directory) + (for-each + (lambda (f) + (install-file f (string-append #$output + "/share/texmf-dist" + directory))) + '("array-2016-10-06.sty" + "array-2020-02-10.sty" + "multicol-2017-04-11.sty" + "varioref-2016-02-16.sty"))))))))))) + (home-page "https://www.ctan.org/tex-archive/macros/latex/required/tools/") + (synopsis "LaTeX standard tools bundle") + (description "This package provides a collection of simple tools that +are part of the LaTeX required tools distribution, comprising the packages: +@code{afterpage}, @code{array}, @code{bm}, @code{calc}, @code{dcolumn}, +@code{delarray}, @code{enumerate}, @code{fileerr}, @code{fontsmpl}, +@code{ftnright}, @code{hhline}, @code{indentfirst}, @code{layout}, +@code{longtable}, @code{multicol}, @code{rawfonts}, @code{showkeys}, +@code{somedefs}, @code{tabularx}, @code{theorem}, @code{trace}, +@code{varioref}, @code{verbatim}, @code{xr}, and @code{xspace}.") + (license license:lppl1.3+)))) -(define-public texlive-latex-tools - (package - (name "texlive-latex-tools") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "tools")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1vm5wfyd0vbmv31a29fc7k8y14xiw00msvdx9n7dzsn9zpfjflqs")))) - (build-system texlive-build-system) - (arguments - '(#:tex-directory "latex/tools" - #:build-targets '("tools.ins") - #:phases (modify-phases %standard-phases - (add-after 'install 'provide-array-2016-10-06.sty - (lambda* (#:key outputs #:allow-other-keys) - ;; XXX: array.sty does: - ;; "DeclareRelease{}{2016-10-06}{array-2016-10-06.sty}" - ;; ...which causes some users (hypre) to look for that - ;; file specifically. Provide it. - (with-directory-excursion (string-append - (assoc-ref outputs "out") - "/share/texmf-dist/tex" - "/latex/tools") - (symlink "array.sty" "array-2016-10-06.sty"))))))) - (home-page "https://www.ctan.org/pkg/latex-tools") - (synopsis "LaTeX standard tools bundle") - (description - "This package is a collection of (variously) simple tools provided as -part of the LaTeX required tools distribution, comprising the following -packages: afterpage, array, bm, calc, dcolumn, delarray, enumerate, fileerr, -fontsmpl, ftnright, hhline, indentfirst, layout, longtable, multicol, -rawfonts, showkeys, somedefs, tabularx, theorem, trace, varioref, verbatim, -xr, and xspace.") - (license license:lppl1.3+))) +(define-deprecated-package texlive-latex-tools texlive-tools) (define-public texlive-url (package @@ -4640,6 +4833,7 @@ with the LaTeX @code{picture} environment.") "11f14dzhwsy4pli21acccip43d36nf3pac33ihjffnps1i2mhqkd")))) (package (inherit template) + (outputs '("out" "doc")) (arguments (substitute-keyword-arguments (package-arguments template) ((#:tex-directory _ #t) @@ -4649,14 +4843,34 @@ with the LaTeX @code{picture} environment.") (add-after 'unpack 'chdir (lambda _ (chdir "source/latex/psnfss"))) - (add-before 'copy-files 'unchdir - (lambda _ - (chdir "../../.."))) - (add-after 'copy-files 'delete-extra-files - (lambda* (#:key outputs #:allow-other-keys) - (delete-file-recursively - (string-append (assoc-ref outputs "out") - "/share/texmf-dist/source/latex/psnfss/build")))))))) + (add-after 'install 'chdir-back + (lambda _ + (chdir "../../.."))) + (add-after 'chdir-back 'clean-installed-files + (lambda _ + ;; Remove the generated .sty files from the build area as + ;; these were already copied to the default output in the + ;; "install" phase. + (delete-file-recursively "source/latex/psnfss/build"))) + (add-after 'clean-installed-files 'move-doc-files + (lambda* (#:key outputs #:allow-other-keys) + (let* ((doc (assoc-ref outputs "doc")) + (doc-root (string-append doc "/share/texmf-dist")) + (doc-path "doc/latex/psnfss") + (source-path "source/latex/psnfss")) + ;; Move the PDF documentation to the "doc" output. + (let* ((file-name "psnfss2e.pdf") + (source (string-append doc-path "/" file-name)) + (target-dir (string-append doc-root "/" doc-path))) + (mkdir-p target-dir) + (copy-file source + (string-append target-dir "/" file-name)) + (delete-file source)) + + ;; Keep the remaining files together with the package's + ;; source, as per the installation instructions. + (copy-recursively doc-path source-path) + (delete-file-recursively "doc")))))))) (native-inputs (list texlive-cm)) (home-page "https://www.ctan.org/pkg/psnfss") @@ -4686,6 +4900,7 @@ part of the LaTeX required set of packages.") texlive-cm texlive-cm-super ; to avoid bitmap fonts texlive-fonts-latex + texlive-graphics texlive-metafont texlive-latex-base texlive-kpathsea ;for mktex.opt @@ -4695,9 +4910,8 @@ part of the LaTeX required set of packages.") texlive-babel texlive-generic-babel-english texlive-latex-cyrillic - texlive-latex-graphics texlive-psnfss - texlive-latex-tools + texlive-tools texlive-tetex))) (package (name "texlive-base") @@ -5302,24 +5516,47 @@ Unicode characters. The document should be processed by (pdf)LaTeX with the Unicode option of @code{inputenc} or @code{inputenx}, or by XeLaTeX/LuaLaTeX.") (license license:lppl1.3c+))) -(define-public texlive-latex-pdftexcmds - (package - (inherit (simple-texlive-package - "texlive-latex-pdftexcmds" - '("/doc/generic/pdftexcmds/" - "/tex/generic/pdftexcmds/") - (base32 - "1hph0djbfc8hlwfc41rzlf8l3ccyyvc0n7a0qdrr9881jwd6iv1b") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-iftex texlive-generic-infwarerr - texlive-generic-ltxcmds)) - (home-page "https://www.ctan.org/pkg/pdftexcmds") - (synopsis "LuaTeX support for pdfTeX utility functions") - (description - "This package makes a number of utility functions from pdfTeX -available for luaTeX by reimplementing them using Lua.") - (license license:lppl1.3c+))) +(define-public texlive-pdftexcmds + (let ((template (simple-texlive-package + "texlive-pdftexcmds" + (list "doc/generic/pdftexcmds/" + "source/generic/pdftexcmds/" + "tex/generic/pdftexcmds/") + (base32 + "0gad1vi0r5xw7gyj1cb2cp58j4dqrw4awcfxmfrna9xbz91g4sn9")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/pdftexcmds") + ((#:build-targets _ '()) + #~(list "pdftexcmds.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/generic/pdftexcmds"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-iftex texlive-infwarerr texlive-ltxcmds)) + (home-page "https://www.ctan.org/pkg/pdftexcmds") + (synopsis "LuaTeX support for pdfTeX utility functions") + (description + "This package makes a number of utility functions from pdfTeX +available for LuaTeX by reimplementing them using Lua.") + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-pdftexcmds texlive-pdftexcmds) (define-public texlive-latex-psfrag (package @@ -5358,12 +5595,12 @@ rotated.") (propagated-inputs (list texlive-bigfoot ; for suffix texlive-filemod - texlive-latex-graphics + texlive-graphics texlive-latex-ifplatform texlive-latex-l3kernel ; for expl3 texlive-oberdiek texlive-latex-psfrag - texlive-latex-tools ; for shellesc + texlive-tools ; for shellesc texlive-latex-trimspaces texlive-latex-xkeyval)) (home-page "https://www.ctan.org/pkg/pstool") @@ -5377,24 +5614,48 @@ re-processing.") (define-deprecated-package texlive-latex-pstool texlive-pstool) -(define-public texlive-latex-refcount - (package - (inherit (simple-texlive-package - "texlive-latex-refcount" - (list "/doc/latex/refcount/" - "/tex/latex/refcount/") - (base32 - "0pkmqj2qihndlv3ks33xzqw91q46jx79r3aygj68d8dflyddi583") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/refcount") - (synopsis "Counter operations with label references") - (description - "This package provides the @code{\\setcounterref} and +(define-public texlive-refcount + (let ((template (simple-texlive-package + "texlive-refcount" + (list "doc/latex/refcount/" + "source/latex/refcount/" + "tex/latex/refcount/") + (base32 + "128cvwdl4wcdshvs59yn5iljdxxdrc5jircbxav77y7kc3l33z7z")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/refcount") + ((#:build-targets _ '()) + #~(list "refcount.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/refcount"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/refcount") + (synopsis "Counter operations with label references") + (description + "This package provides the @code{\\setcounterref} and @code{\\addtocounterref} commands which use the section (or other) number from the reference as the value to put into the counter. It also provides @code{\\setcounterpageref} and @code{\\addtocounterpageref} that do the corresponding thing with the page reference of the label.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-refcount texlive-refcount) (define-public texlive-seminar (package @@ -5833,7 +6094,7 @@ BibLaTeX, and is considered experimental.") (arguments '(#:tex-directory "latex/geometry")) (propagated-inputs (list texlive-oberdiek ;for ifpdf - texlive-latex-graphics)) ;for keyval + texlive-graphics)) ;for keyval (home-page "https://www.ctan.org/pkg/geometry") (synopsis "Flexible and complete interface to document dimensions") (description @@ -5997,15 +6258,15 @@ routine.") texlive-booktabs texlive-cm texlive-fontspec - texlive-generic-iftex + texlive-iftex texlive-latex-base texlive-latex-eukdate - texlive-latex-graphics + texlive-graphics texlive-latex-multirow texlive-lm ;for lmroman10-regular texlive-stix2-otf)) - (propagated-inputs (list texlive-fontspec texlive-generic-iftex - texlive-latex-graphics)) + (propagated-inputs (list texlive-fontspec texlive-iftex + texlive-graphics)) (home-page "https://ctan.org/pkg/metalogo") (synopsis "Extended TeX logo macros") (description "This package exposes spacing parameters for various TeX @@ -6121,7 +6382,7 @@ also provides compacted versions of enumerate and itemize.") texlive-booktabs texlive-caption texlive-context - texlive-latex-fancyvrb + texlive-fancyvrb texlive-etoolbox texlive-fonts-latex texlive-fontspec @@ -6131,13 +6392,13 @@ also provides compacted versions of enumerate and itemize.") ;; them. texlive-stringenc texlive-zapfding - texlive-latex-graphics + texlive-graphics texlive-kpathsea ;for cp227.tcx & friends texlive-makecmds texlive-metalogo texlive-microtype texlive-paralist - texlive-latex-tools + texlive-tools texlive-tex-ini-files)) ;for pdftexconfig ;; polyglossia.sty \RequirePackage or \\usepackage these other TexLive ;; packages. @@ -6153,7 +6414,7 @@ also provides compacted versions of enumerate and itemize.") texlive-zapfding texlive-makecmds texlive-latex-l3packages ;expl3, l3keys2e, xparse - texlive-latex-tools + texlive-tools texlive-latex-xkeyval)) (home-page "https://www.ctan.org/pkg/polyglossia") (synopsis "Alternative to Babel for XeLaTeX and LuaLaTeX") @@ -6489,39 +6750,45 @@ using box macros and flexible verbatim macros. You can box mathematics, floats, center, flushleft, and flushright, lists, and pages.") (license license:lppl1.2+))) -(define-public texlive-latex-fancyhdr - (package - (name "texlive-latex-fancyhdr") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (svn-reference - (url (string-append "svn://www.tug.org/texlive/tags/" - %texlive-tag "/Master/texmf-dist/" - "/tex/latex/fancyhdr")) - (revision %texlive-revision))) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1h2zv7cps0pknqhy2dyfclyi002lmsfshm0rn6ywfl9p4fnvh0bc")))) - (build-system trivial-build-system) - (arguments - `(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((target (string-append (assoc-ref %outputs "out") - "/share/texmf-dist/tex/latex/fancyhdr"))) - (mkdir-p target) - (copy-recursively (assoc-ref %build-inputs "source") target) - #t)))) - (home-page "https://www.ctan.org/pkg/fancyhdr") - (synopsis "Extensive control of page headers and footers in LaTeX2e") - (description - "The package provides extensive facilities, both for constructing headers -and footers, and for controlling their use (for example, at times when LaTeX -would automatically change the heading style in use).") - (license license:lppl))) +(define-public texlive-fancyhdr + (let ((template (simple-texlive-package + "texlive-fancyhdr" + (list "doc/latex/fancyhdr/" + "source/latex/fancyhdr/" + "tex/latex/fancyhdr/") + (base32 + "15fainwxs22gg4xhwsv1vmjgdhg34dbkir26nnk4pb6jprpwb83f")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/fancyhdr") + ((#:build-targets _ '()) + #~(list "fancyhdr.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ (chdir "source/latex/fancyhdr"))) + (replace 'copy-files + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/fancyhdr") + (synopsis "Extensive control of page headers and footers in LaTeX2e") + (description + "This package provides extensive facilities, both for constructing +headers and footers, and for controlling their use (for example, at times when +LaTeX would automatically change the heading style in use).") + (license license:lppl)))) + +(define-deprecated-package texlive-latex-fancyhdr texlive-fancyhdr) (define-public texlive-latex-float (package @@ -6571,6 +6838,48 @@ the same place. The package also has a range of techniques for labelling footnotes with symbols rather than numbers.") (license license:lppl1.3+))) +(define-public texlive-letltxmacro + (let ((template (simple-texlive-package + "texlive-letltxmacro" + (list "doc/latex/letltxmacro/" + "source/latex/letltxmacro/" + "tex/latex/letltxmacro/") + (base32 + "16bmwsng9p80jf78sdmib24apwnw3raw306cs1ms50z5s9dsfdby")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/letltxmacro") + ((#:build-targets _ '()) + #~(list "letltxmacro.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/letltxmacro"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/letltxmacro") + (synopsis "Let assignment for macros") + (description + "TeX’s @code{\\let} assignment does not work for LaTeX macros with +optional arguments, or for macros that are defined as robust macros by +@code{\\DeclareRobustCommand}. This package defines @code{\\LetLtxMacro} +that also takes care of the involved internal macros.") + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-letltxmacro texlive-letltxmacro) + (define-public texlive-latex-frankenstein (package (name "texlive-latex-frankenstein") @@ -6610,52 +6919,47 @@ BibTeX bibliography style. The individual packages are: @code{abbrevs}, ;; later. (license license:lppl1.2+))) -(define-public texlive-latex-letltxmacro - (package - (inherit (simple-texlive-package - "texlive-latex-letltxmacro" - (list "/doc/latex/letltxmacro/" - "/tex/latex/letltxmacro/") - (base32 - "0yy1m1jiyxq2pssp0pidaa2swx6lyxw3zwpm2r8m0v2r3lvsyyxx") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/letltxmacro") - (synopsis "Let assignment for macros") - (description - "TeX’s @code{\\let} assignment does not work for LaTeX macros with -optional arguments, or for macros that are defined as robust macros by -@code{\\DeclareRobustCommand}. This package defines @code{\\LetLtxMacro} -that also takes care of the involved internal macros.") - (license license:lppl1.3c+))) - (define-public texlive-listings - (package - (name "texlive-listings") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "listings")) - (file-name - ;; TODO: Drop "latex-" on next rebuild cycle. - (string-append "texlive-latex-listings-" version "-checkout")) - (sha256 - (base32 - "082zri3gp8s6p2difhk1pbix2vzmvsf6fmld2z78v35xwk3fiya0")))) - (build-system texlive-build-system) - (arguments - '(#:tex-directory "latex/listings" - #:build-targets '("listings.ins"))) - (home-page "https://www.ctan.org/pkg/listings") - (synopsis "Typeset source code listings using LaTeX") - (description - "The package enables the user to typeset programs (programming code) + (let ((template + (simple-texlive-package + "texlive-listings" + (list "doc/latex/listings/" + "source/latex/listings/" + "tex/latex/listings/") + (base32 "15dnm0j86305x84ss3ymhhcczcw45b2liq01vrab6fj204wzsahk")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/listings") + ((#:build-targets _ '()) + #~(list "listings.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/listings"))) + (replace 'copy-files + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/listings") + (synopsis "Typeset source code listings using LaTeX") + (description + "The package enables the user to typeset programs (programming code) within LaTeX; the source code is read directly by TeX---no front-end processor is needed. Keywords, comments and strings can be typeset using different styles. Support for @code{hyperref} is provided.") - (license license:lppl1.3+))) + (license license:lppl1.3+)))) -(define-public texlive-latex-listings - (deprecated-package "texlive-latex-listings" texlive-listings)) +(define-deprecated-package texlive-latex-listings texlive-listings) (define-public texlive-latex-jknapltx (package @@ -6696,23 +7000,47 @@ transliterate semitic languages; patches to make (La)TeX formulae embeddable in SGML; use maths minus in text as appropriate; simple Young tableaux.") (license license:gpl2))) -(define-public texlive-latex-kvoptions - (package - (inherit (simple-texlive-package - "texlive-latex-kvoptions" - (list "/doc/latex/kvoptions/" - "/tex/latex/kvoptions/") - (base32 - "02i4n2n3j4lg68d3nam08m63kb4irc99wfhyc2z51r02lm1wwmvw") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-kvsetkeys texlive-generic-ltxcmds)) - (home-page "https://www.ctan.org/pkg/kvoptions") - (synopsis "Key/value format for package options") - (description - "This package provides facilities for using key-value format in +(define-public texlive-kvoptions + (let ((template (simple-texlive-package + "texlive-kvoptions" + (list "doc/latex/kvoptions/" + "source/latex/kvoptions/" + "tex/latex/kvoptions/") + (base32 + "1b8q93l54160b8gn3fq484n15n6cylrhmf2xk7p42czg2rqw7w3l")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/kvoptions") + ((#:build-targets _ '()) + #~(list "kvoptions.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/kvoptions"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-kvsetkeys texlive-ltxcmds)) + (home-page "https://www.ctan.org/pkg/kvoptions") + (synopsis "Key/value format for package options") + (description + "This package provides facilities for using key-value format in package options.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-latex-kvoptions texlive-kvoptions) (define-public texlive-fonts-ec (package @@ -6969,12 +7297,12 @@ format under XeTeX.") (mkdir-p doc) (copy-recursively (string-append (getenv "ROOT_DIR") "/doc") doc)))))) - (propagated-inputs (list texlive-generic-atbegshi - texlive-generic-gettitlestring - texlive-generic-iftex - texlive-latex-atveryend - texlive-latex-kvoptions - texlive-latex-pdftexcmds + (propagated-inputs (list texlive-atbegshi + texlive-gettitlestring + texlive-iftex + texlive-atveryend + texlive-kvoptions + texlive-pdftexcmds texlive-latex-xkeyval)) (home-page "https://github.com/ho-tex/zref") (synopsis "Reference scheme for LaTeX") @@ -7089,26 +7417,53 @@ format. LaTeX support, for using these fonts in mathematics, is available via one of the packages @code{calrsfs} and @code{mathrsfs}.") (license (license:fsf-free "http://mirrors.ctan.org/fonts/rsfs/README")))) -(define-public texlive-latex-eso-pic - (package - (name "texlive-latex-eso-pic") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "eso-pic")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "12f7pbhiav4iz3rra5vq85v9f14h8j1ybi42kvnkzgjsay87p7gf")))) - (build-system texlive-build-system) - (arguments '(#:tex-directory "latex/eso-pic")) - (home-page "https://www.ctan.org/pkg/eso-pic") - (synopsis "Add picture commands (or backgrounds) to every page") - (description - "The package adds one or more user commands to LaTeX's @code{shipout} +(define-public texlive-eso-pic + (let ((template (simple-texlive-package + "texlive-eso-pic" + (list "doc/latex/eso-pic/" + "source/latex/eso-pic/" + "tex/latex/eso-pic/") + (base32 + "05bqm4x209wji0q6xk1jrjp0nzqafp44dlq30hlpcagrggjb3d9s")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/eso-pic") + ((#:build-targets _ '()) + #~(list "eso-pic.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/eso-pic"))) + (replace 'copy-files + (lambda _ + (let ((origin #$(package-source this-package)) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc) + ;; This file is not generated. + (install-file + (string-append origin + "/tex/latex/eso-pic/showframe.sty") + (string-append + #$output + "/share/texmf-dist/tex/latex/eso-pic"))))))))) + (home-page "https://ctan.org/macros/latex/contrib/eso-pic") + (synopsis "Add picture commands (or backgrounds) to every page") + (description + "The package adds one or more user commands to LaTeX's @code{shipout} routine, which may be used to place the output at fixed positions. The @code{grid} option may be used to find the correct places.") - (license license:lppl1.3+))) + (license license:lppl1.3+)))) + +(define-deprecated-package texlive-latex-eso-pic texlive-eso-pic) (define-public texlive-latex-eepic (package @@ -7308,29 +7663,51 @@ the box width to that of the enclosed text, up to the maximum width given. The package also defines some associated length commands.") (license license:gpl3+))) -(define-public texlive-latex-pdfpages - (package - (name "texlive-latex-pdfpages") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "pdfpages")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "140kl8r7g2ak2frjn5pmwiwibfynyfwp897r9vk8pypmn390lzr2")))) - (build-system texlive-build-system) - (arguments '(#:tex-directory "latex/pdfpages")) - (home-page "https://www.ctan.org/pkg/pdfpages") - (synopsis "Include PDF documents in LaTeX") - (description - "This package simplifies the inclusion of external multi-page PDF +(define-public texlive-pdfpages + (let ((template (simple-texlive-package + "texlive-pdfpages" + (list "doc/latex/pdfpages/" + "source/latex/pdfpages/" + "tex/latex/pdfpages/") + (base32 + "0a68vxkygk20fp51fkp7nvs8mc7h6irdvxal8qsnn9zrgr965d76")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/pdfpages") + ((#:build-targets _ '()) + #~(list "pdfpages.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/pdfpages"))) + (replace 'copy-files + (lambda _ + (let ((origin #$(package-source this-package)) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-tools texlive-oberdiek texlive-graphics texlive-eso-pic)) + (home-page "https://ctan.org/macros/latex/contrib/pdfpages") + (synopsis "Include PDF documents in LaTeX") + (description + "This package simplifies the inclusion of external multi-page PDF documents in LaTeX documents. Pages may be freely selected and it is possible to put several logical pages onto each sheet of paper. Furthermore a lot of hypertext features like hyperlinks and article threads are provided. The package supports pdfTeX (pdfLaTeX) and VTeX. With VTeX it is even possible to use this package to insert PostScript files, in addition to PDF files.") - (license license:lppl1.3+))) + (license license:lppl1.3+)))) + +(define-deprecated-package texlive-latex-pdfpages texlive-pdfpages) (define-public texlive-stix2-otf (let ((base (simple-texlive-package @@ -7435,23 +7812,41 @@ the whole font.") (define-deprecated-package texlive-fonts-stmaryrd texlive-stmaryrd) -(define-public texlive-latex-subfigure - (package - (name "texlive-latex-subfigure") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "subfigure")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "15spcl5wb7w269qd6y596vp4yi8sa5ppcx8w4z2i9kyp02r3a0yb")))) - (build-system texlive-build-system) - (arguments '(#:tex-directory "latex/subfigure")) - (home-page "https://www.ctan.org/pkg/subfigure") - (synopsis "Figures divided into subfigures") - (description - "This (deprecated) package provides support for the manipulation and +(define-public texlive-subfigure + (let ((template (simple-texlive-package + "texlive-subfigure" + (list "doc/latex/subfigure/" + "source/latex/subfigure/" + "tex/latex/subfigure/") + (base32 + "1327ygajf6gza5msvhfjjnk6r3sw7vb7rxg23v4gx4dmyxqfqrbi")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/subfigure") + ((#:build-targets _ '()) + #~(list "subfigure.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/subfigure"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/subfigure") + (synopsis "Figures divided into subfigures") + (description + "This (deprecated) package provides support for the manipulation and reference of small or \"sub\" figures and tables within a single figure or table environment. It is convenient to use this package when your subfigures are to be separately captioned, referenced, or are to be included in the @@ -7460,7 +7855,9 @@ used inside a figure environment for each subfigure. An optional first argument is used as the caption for that subfigure. The package is now considered obsolete: it was superseded by @code{subfig}, but users may find the more recent @code{subcaption} package more satisfactory.") - (license license:lppl))) + (license license:lppl)))) + +(define-deprecated-package texlive-latex-subfigure texlive-subfigure) (define-public texlive-latex-tabulary (package @@ -7714,9 +8111,9 @@ Simple Young tableaux. texlive-jknappen texlive-hyperref texlive-latex-colortbl - texlive-latex-fancyhdr - texlive-latex-graphics ;for color.sty - texlive-latex-tools ;for array.sty + texlive-fancyhdr + texlive-graphics ;for color.sty + texlive-tools ;for array.sty texlive-marvosym texlive-tex-ini-files ;for pdftexconfig texlive-ulem)) @@ -7791,33 +8188,15 @@ The (currently) supported encodings are: OT1, T1, IL2, TS1, T2*, X2, QX, and LGR. The package doesn't (currently) support mathematics.") (license license:lppl))) -(define-public texlive-latex-titlesec +(define-public texlive-titlesec (package - (name "texlive-latex-titlesec") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (svn-reference - (url (string-append "svn://www.tug.org/texlive/tags/" - %texlive-tag "/Master/texmf-dist/" - "/tex/latex/titlesec")) - (revision %texlive-revision))) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1kw7dvxvdfbf31zw0n8r0g5xak3vcdf25n33fqw93j59zpc5nvbl")))) - (build-system trivial-build-system) - (arguments - `(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((target (string-append (assoc-ref %outputs "out") - "/share/texmf-dist/tex/latex/titlesec"))) - (mkdir-p target) - (copy-recursively (assoc-ref %build-inputs "source") target) - #t)))) - (home-page "https://www.ctan.org/pkg/titlesec") + (inherit + (simple-texlive-package + "texlive-titlesec" + (list "doc/latex/titlesec/" "tex/latex/titlesec/") + (base32 "01nwh4p15xblc3kgivjliihy9kr8yr2cqsf9wn2iwqv1njx0i2zw") + #:trivial? #t)) + (home-page "https://ctan.org/macros/latex/contrib/titlesec") (synopsis "Select alternative section titles") (description "This package provides an interface to sectioning commands for selection @@ -7827,6 +8206,8 @@ styles. It also includes a package to change the page styles when there are floats in a page. You may assign headers/footers to individual floats, too.") (license license:lppl))) +(define-deprecated-package texlive-latex-titlesec texlive-titlesec) + (define-public texlive-latex-type1cm (package (name "texlive-latex-type1cm") @@ -8847,35 +9228,45 @@ including: It also ensures compatibility with the @code{media9} and @code{animate} packages.") (license license:lppl))) -(define-public texlive-latex-ms - (package - (name "texlive-latex-ms") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "ms")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "04ww5abfm7dx81d21yr2gwy9jswaalnfm2384xp4cyx7srd9spfv")))) - (build-system texlive-build-system) - (arguments - '(#:tex-directory "latex/ms" - #:tex-format "latex")) - (home-page "https://ctan.org/pkg/ms") - (synopsis "Various LATEX packages by Martin Schröder") - (description - "A bundle of LATEX packages by Martin Schröder; the collection comprises: +(define-public texlive-ms + (let ((template + (simple-texlive-package + "texlive-ms" + (list "doc/latex/ms/" "source/latex/ms/" "tex/latex/ms/") + (base32 "1cgrpx5mybiirjjdmni8kvqdg37dwfkixq3h9ami0mgxqqqfl2x3")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "latex/ms") + ((#:tex-format _ "latex") "latex") + ((#:build-targets _ '()) + #~(list "count1to.ins" "multitoc.ins")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/ms"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://ctan.org/macros/latex/contrib/ms") + (synopsis "Various LaTeX packages by Martin Schroder") + (description + "The remains of a bundle of LaTeX packages by Martin Schroder; the +collection comprises: count1to, make use of TeX counters; and multitoc, +typeset the table of contents in multiple columns.") + (license license:lppl)))) -@itemize -@item @command{count1to}, make use of fixed TEX counters; -@item @command{everysel}, set commands to execute every time a font is selected; -@item @command{everyshi}, set commands to execute whenever a page is shipped out; -@item @command{multitoc}, typeset the table of contents in multiple columns; -@item @command{prelim2e}, mark typeset pages as preliminary; and -@item @command{ragged2e}, typeset ragged text and allow hyphenation. -@end itemize\n") - (license license:lppl1.3c+))) +(define-deprecated-package texlive-latex-ms texlive-ms) (define-public texlive-ncctools (let ((template (simple-texlive-package @@ -9101,69 +9492,57 @@ from a typewriter. The package also offers double and wavy underlining, and striking out (line through words) and crossing out (/// over words).") (license license:lppl1.3c+))) -(define-deprecated-package texlive-generic-ulem texlive-ulem) - (define-public texlive-pgf (package - (name "texlive-pgf") - (version (number->string %texlive-revision)) - (source - (origin - (method svn-fetch) - (uri (svn-reference - (url (string-append "svn://www.tug.org/texlive/tags/" - %texlive-tag "/Master/texmf-dist/" - "/tex/latex/pgf")) - (revision %texlive-revision))) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1jk10rxz5f8vh46am11b40hxhhikk67h9jr3z877q5qc8kwppgza")))) - (build-system trivial-build-system) - (native-inputs - `(("texlive-latex-pgf-generic" - ,(origin - (method svn-fetch) - (uri (svn-reference - (url (string-append "svn://www.tug.org/texlive/tags/" - %texlive-tag "/Master/texmf-dist/" - "/tex/generic/pgf")) - (revision %texlive-revision))) - (file-name (string-append "texlive-latex-pgf-generic" version "-checkout")) - (sha256 - (base32 - "05zdq7y3am109m5534ahqqp9x5iar3ha68v1r4zkrdly2mijxz2j")))))) + (inherit (simple-texlive-package + "texlive-pgf" + (list "doc/generic/pgf/" + "scripts/pgf/" + "source/generic/pgf/c/" + "source/generic/pgf/testsuite/external/" + "source/generic/pgf/testsuite/mathtest/" + "tex/context/third/pgf/basiclayer/" + "tex/context/third/pgf/frontendlayer/" + "tex/context/third/pgf/math/" + "tex/context/third/pgf/systemlayer/" + "tex/context/third/pgf/utilities/" + "tex/generic/pgf/" + "tex/latex/pgf/basiclayer/" + "tex/latex/pgf/compatibility/" + "tex/latex/pgf/doc/" + "tex/latex/pgf/frontendlayer/" + "tex/latex/pgf/math/" + "tex/latex/pgf/systemlayer/" + "tex/latex/pgf/utilities/" + "tex/plain/pgf/basiclayer/" + "tex/plain/pgf/frontendlayer/" + "tex/plain/pgf/math/" + "tex/plain/pgf/systemlayer/" + "tex/plain/pgf/utilities/") + (base32 + "02qfx9k0ggqfrbrjpfz74w8rkvvzk07rmgr37r7y64gggwpn4cw5") + #:trivial? #t)) (propagated-inputs - (list texlive-xcolor)) - (arguments - `(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((target-generic (string-append (assoc-ref %outputs "out") - "/share/texmf-dist/tex/generic/pgf")) - (target-latex (string-append (assoc-ref %outputs "out") - "/share/texmf-dist/tex/latex/pgf"))) - (mkdir-p target-generic) - (mkdir-p target-latex) - (copy-recursively (assoc-ref %build-inputs "texlive-latex-pgf-generic") target-generic) - (copy-recursively (assoc-ref %build-inputs "source") target-latex) - #t)))) - (home-page "https://www.ctan.org/pkg/tikz") + (list texlive-atveryend + texlive-fp + texlive-graphics + texlive-ms + texlive-pdftexcmds + texlive-xcolor)) + (home-page "https://ctan.org/graphics/pgf/base") (synopsis "Create PostScript and PDF graphics in TeX") (description "PGF is a macro package for creating graphics. It is platform- and format-independent and works together with the most important TeX backend drivers, including pdfTeX and dvips. It comes with a user-friendly syntax layer -called TikZ. - -Its usage is similar to pstricks and the standard picture environment. PGF -works with plain (pdf-)TeX, (pdf-)LaTeX, and ConTeXt. Unlike pstricks, it can -produce either PostScript or PDF output.") - (license license:lppl1.3c+))) +called TikZ. Its usage is similar to pstricks and the standard picture +environment. PGF works with plain (pdf-)TeX, (pdf-)LaTeX, and ConTeXt. Unlike +pstricks, it can produce either PostScript or PDF output.") + ;; The code of the package is dual-license: GPL-2 or LPPL-1.3c+. The + ;; documentation is also dual-license: LPPL-1.3c+ or GFDL-1.2. + (license (list license:gpl2 license:lppl1.3c+ license:fdl1.2+)))) -(define-public texlive-latex-pgf - (deprecated-package "texlive-latex-pgf" texlive-pgf)) +(define-deprecated-package texlive-latex-pgf texlive-pgf) (define-public texlive-latex-koma-script (package @@ -9224,162 +9603,381 @@ refers to the version of scrbook, scrreprt, scrartcl, scrlttr2 and typearea (which are the main parts of the bundle).") (license license:lppl1.3+))) -(define-public texlive-generic-atbegshi - (package - (inherit (simple-texlive-package - "texlive-generic-atbegshi" - '("/doc/latex/atbegshi/" - "/tex/generic/atbegshi/") - (base32 - "184fr5kd3wl44ix63lwb3ll7dhiikkyw1czbnzrl4am4rx0zh4d8") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/atbegshi") - (synopsis "Execute commands at @code{\\shipout} time") - (description - "This package is a modern reimplementation of package @code{everyshi}, +(define-public texlive-atbegshi + (let ((template (simple-texlive-package + "texlive-atbegshi" + (list "doc/latex/atbegshi/" + "source/latex/atbegshi/" + "tex/generic/atbegshi/") + (base32 + "0vd90wdjwj5w4g4xka4nms3rgixjw63iwf0hj0v1akcfflwvgn69")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/atbegshi") + ((#:build-targets _ '()) + #~(list "atbegshi.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/atbegshi"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/atbegshi") + (synopsis "Execute commands at @code{\\shipout} time") + (description + "This package is a modern reimplementation of package @code{everyshi}, providing various commands to be executed before a @code{\\shipout} command. It makes use of e-TeX’s facilities if they are available. The package may be used either with LaTeX or with plain TeX.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-bigintcalc - (package - (inherit (simple-texlive-package - "texlive-generic-bigintcalc" - '("/doc/latex/bigintcalc/README.md" - "/tex/generic/bigintcalc/") - (base32 - "19grk4p1dh566hgpzhnjyjnrw57hpjijcpr7ci401n9jszcc1xkz") - #:trivial? #t)) - (propagated-inputs - (list texlive-latex-pdftexcmds)) - (home-page "https://www.ctan.org/pkg/bigintcalc") - (synopsis "Integer calculations on very large numbers") - (description - "This package provides expandable arithmetic operations with big +(define-deprecated-package texlive-generic-atbegshi texlive-atbegshi) + +(define-public texlive-bigintcalc + (let ((template (simple-texlive-package + "texlive-bigintcalc" + (list "doc/latex/bigintcalc/" + "source/latex/bigintcalc/" + "tex/generic/bigintcalc/") + (base32 + "1cyv4mcvx83ab782l6h2f86a63ipm845r7hv1m6f1z2336vy7rc5")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/bigintcalc") + ((#:build-targets _ '()) + #~(list "bigintcalc.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/bigintcalc"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-pdftexcmds)) + (home-page "https://www.ctan.org/pkg/bigintcalc") + (synopsis "Integer calculations on very large numbers") + (description + "This package provides expandable arithmetic operations with big integers that can exceed TeX's number limits.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-bitset - (package - (inherit (simple-texlive-package - "texlive-generic-bitset" - '("/doc/latex/bitset/README.md" - "/tex/generic/bitset/") - (base32 - "0inj6qpzizvsbxdfsaijnl4iq976kyrnchnm3gc1kc2w389zrn1l") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-infwarerr texlive-generic-intcalc - texlive-generic-bigintcalc)) - (home-page "https://www.ctan.org/pkg/bitset") - (synopsis "Handle bit-vector datatype") - (description - "This package defines and implements the data type bit set, a vector +(define-deprecated-package texlive-generic-bigintcalc texlive-bigintcalc) + +(define-public texlive-bitset + (let ((template (simple-texlive-package + "texlive-bitset" + (list "doc/latex/bitset/" + "source/latex/bitset/" + "tex/generic/bitset/") + (base32 + "1q7vk5gr5a4vaa3l20j178cg2q7a99rxdiyxhzpx9a6lfqfkjddz")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/bitset") + ((#:build-targets _ '()) + #~(list "bitset.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/bitset"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-bigintcalc texlive-infwarerr texlive-intcalc)) + (home-page "https://www.ctan.org/pkg/bitset") + (synopsis "Handle bit-vector datatype") + (description + "This package defines and implements the data type bit set, a vector of bits. The size of the vector may grow dynamically. Individual bits can be manipulated.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-etexcmds - (package - (inherit (simple-texlive-package - "texlive-generic-etexcmds" - '("/doc/latex/etexcmds/README.md" - "/tex/generic/etexcmds/") - (base32 - "11y6pnlq13bp0ybi7c82g8ds8085zv1zaslgqv3dzhgi3dklpc0c") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-infwarerr texlive-generic-iftex)) - (home-page "https://www.ctan.org/pkg/etexcmds") - (synopsis "Avoid name clashes with e-TeX commands") - (description - "New primitive commands are introduced in e-TeX; sometimes the names +(define-deprecated-package texlive-generic-bitset texlive-bitset) + +(define-public texlive-etexcmds + (let ((template (simple-texlive-package + "texlive-etexcmds" + (list "doc/latex/etexcmds/" + "source/latex/etexcmds/" + "tex/generic/etexcmds/") + (base32 + "13cf1fs5x9d8749b2jgxmgnkrx0r4hwpl389r15kq3ldz9jfl627")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/etexcmds") + ((#:build-targets _ '()) + #~(list "etexcmds.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/etexcmds"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-iftex texlive-infwarerr)) + (home-page "https://www.ctan.org/pkg/etexcmds") + (synopsis "Avoid name clashes with e-TeX commands") + (description + "New primitive commands are introduced in e-TeX; sometimes the names collide with existing macros. This package solves the name clashes by adding a prefix to e-TeX’s commands. For example, ε-TeX’s @code{\\unexpanded} is provided as @code{\\etex@@unexpanded}.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-gettitlestring - (package - (inherit (simple-texlive-package - "texlive-generic-gettitlestring" - '("/doc/latex/gettitlestring/" - "/tex/generic/gettitlestring/") - (base32 - "1p4hg9mac03rzvj9dw0ws3zdh55fy1ns954f912algw9f2aq4xgp") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/gettitlestring") - (synopsis "Clean up title references") - (description - "This package provides commands for cleaning up the title string +(define-deprecated-package texlive-generic-etexcmds texlive-etexcmds) + +(define-public texlive-gettitlestring + (let ((template (simple-texlive-package + "texlive-gettitlestring" + (list "doc/latex/gettitlestring/" + "source/latex/gettitlestring/" + "tex/generic/gettitlestring/") + (base32 + "1vbvmwrpsvy37gbwdmsqbbsicjiww3i0bh1yqnb75jiya9an0sjb")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/gettitlestring") + ((#:build-targets _ '()) + #~(list "gettitlestring.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/gettitlestring"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/gettitlestring") + (synopsis "Clean up title references") + (description + "This package provides commands for cleaning up the title string (such as removing @code{\\label} commands) for packages that typeset such strings.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-infwarerr - (package - (inherit (simple-texlive-package - "texlive-generic-infwarerr" - '("/tex/generic/infwarerr/") - (base32 - "19nlrbfmqbkjrrx9x75s9nd6crg1lzimb2fr3hfblaivj6lx8p4r") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/infwarerr") - (synopsis "Information/warning/error macros") - (description - "This package provides a complete set of macros for information, +(define-deprecated-package texlive-generic-gettitlestring texlive-gettitlestring) + +(define-public texlive-infwarerr + (let ((template (simple-texlive-package + "texlive-infwarerr" + (list "doc/latex/infwarerr/" + "source/latex/infwarerr/" + "tex/generic/infwarerr/") + (base32 + "0lpcrpf3d6xfdp68ri22126x57mvmq5dpj9np68ph8p8lhvhqdjd")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/infwarerr") + ((#:build-targets _ '()) + #~(list "infwarerr.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/infwarerr"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/infwarerr") + (synopsis "Information/warning/error macros") + (description + "This package provides a complete set of macros for information, warning and error messages. Under LaTeX, the commands are wrappers for the corresponding LaTeX commands; under Plain TeX they are available as complete implementations.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-intcalc - (package - (inherit (simple-texlive-package - "texlive-generic-intcalc" - '("/tex/generic/intcalc/") - (base32 - "0llrnayqwdqxi91yh7panbbiljina3bynv2hxhi6sssaw3pyd92l") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/intcalc") - (synopsis "Expandable arithmetic operations with integers") - (description - "This package provides expandable arithmetic operations with integers, +(define-deprecated-package texlive-generic-infwarerr texlive-infwarerr) + +(define-public texlive-intcalc + (let ((template (simple-texlive-package + "texlive-intcalc" + (list "doc/latex/intcalc/" + "source/latex/intcalc/" + "tex/generic/intcalc/") + (base32 + "15alwp9cr8wasfajs3p201p7nqml37vly9mpg1j5l6xv95javk7x")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/intcalc") + ((#:build-targets _ '()) + #~(list "intcalc.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/intcalc"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/intcalc") + (synopsis "Expandable arithmetic operations with integers") + (description + "This package provides expandable arithmetic operations with integers, using the e-TeX extension @code{\\numexpr} if it is available.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-kvdefinekeys - (package - (inherit (simple-texlive-package - "texlive-generic-kvdefinekeys" - '("/tex/generic/kvdefinekeys/") - (base32 - "12nn74skhwiszbdhawqds31caz6d59a5pjmwar0r8lmk4f1jr3xh") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/kvdefinekeys") - (synopsis "Define keys for use in the @code{kvsetkeys} package") - (description - "This package provides the @code{\\kv@@define@@key} (analogous to +(define-deprecated-package texlive-generic-intcalc texlive-intcalc) + +(define-public texlive-kvdefinekeys + (let ((template (simple-texlive-package + "texlive-kvdefinekeys" + (list "doc/latex/kvdefinekeys/" + "source/latex/kvdefinekeys/" + "tex/generic/kvdefinekeys/") + (base32 + "1026h223ph3nzhs6jqbasa0bzsrdg3zgllfcwwcavfzb5i6p9jdf")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/kvdefinekeys") + ((#:build-targets _ '()) + #~(list "kvdefinekeys.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/kvdefinekeys"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/kvdefinekeys") + (synopsis "Define keys for use in the @code{kvsetkeys} package") + (description + "This package provides the @code{\\kv@@define@@key} (analogous to keyval’s @code{\\define@@key}, to define keys for use by @code{kvsetkeys}.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-kvsetkeys - (package - (inherit (simple-texlive-package - "texlive-generic-kvsetkeys" - '("/tex/generic/kvsetkeys/") - (base32 - "149vpmv4vms269dzq4sghlngg380sasvxnb3sx9rfs7d9j0finvi") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/kvsetkeys") - (synopsis "Key value parser with default handler support") - (description - "This package provides @code{\\kvsetkeys}, a variant of @code{\\setkeys} +(define-deprecated-package texlive-generic-kvdefinekeys texlive-kvdefinekeys) + +(define-public texlive-kvsetkeys + (let ((template (simple-texlive-package + "texlive-kvsetkeys" + (list "doc/latex/kvsetkeys/" + "source/latex/kvsetkeys/" + "tex/generic/kvsetkeys/") + (base32 + "0b2f2r49vi8x54qshm1h9sh8zhdmy0mc2y44yd05kcmmbiiq7hfz")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/kvsetkeys") + ((#:build-targets _ '()) + #~(list "kvsetkeys.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/kvsetkeys"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/kvsetkeys") + (synopsis "Key value parser with default handler support") + (description + "This package provides @code{\\kvsetkeys}, a variant of @code{\\setkeys} from the @code{keyval} package. Users can specify a handler that deals with unknown options. Active commas and equal signs may be used, and only one level of curly braces are removed from the values.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-generic-kvsetkeys texlive-kvsetkeys) (define-public texlive-generic-listofitems (package @@ -9415,56 +10013,130 @@ the parsing character has been selected by the user, and to access any of these items with a simple syntax.") (license license:lppl1.3c+))) -(define-public texlive-generic-ltxcmds - (package - (inherit (simple-texlive-package - "texlive-generic-ltxcmds" - '("/tex/generic/ltxcmds/") - (base32 - "1lr77yai2qivlx26s5094czpfxmg96bhxps5wbm8xn7cpsw0zbd9") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/ltxcmds") - (synopsis "LaTeX kernel commands extracted for general use") - (description - "This package exports some utility macros from the LaTeX kernel into +(define-public texlive-ltxcmds + (let ((template (simple-texlive-package + "texlive-ltxcmds" + (list "doc/generic/ltxcmds/" + "source/generic/ltxcmds/" + "tex/generic/ltxcmds/") + (base32 + "1izcw9jl64iij541183hc156sjwamvxm7q9fkpfnz8sppyg31fkb")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/ltxcmds") + ((#:build-targets _ '()) + #~(list "ltxcmds.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/generic/ltxcmds"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/ltxcmds") + (synopsis "LaTeX kernel commands extracted for general use") + (description + "This package exports some utility macros from the LaTeX kernel into a separate namespace and also makes them available for other formats such as plain TeX.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-pdfescape - (package - (inherit (simple-texlive-package - "texlive-generic-pdfescape" - '("/tex/generic/pdfescape/") - (base32 - "1vbdjmm9bi9ngzz2z1b8jnf6nzf9xsaj5pvyswg13y4dr00mnz6n") - #:trivial? #t)) - (home-page "https://www.ctan.org/pkg/pdfescape") - (synopsis "Use escape features from pdfTeX with plain TeX") - (description - "This package implements pdfTeX's escape features (@code{\\pdfescapehex}, +(define-deprecated-package texlive-generic-ltxcmds texlive-ltxcmds) + +(define-public texlive-pdfescape + (let ((template (simple-texlive-package + "texlive-pdfescape" + (list "doc/latex/pdfescape/" + "source/latex/pdfescape/" + "tex/generic/pdfescape/") + (base32 + "16a0rdmpa4wxh6gyf46qwfgyh399rwdind2wc89phqd50ky9b5m4")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/pdfescape") + ((#:build-targets _ '()) + #~(list "pdfescape.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/pdfescape"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (home-page "https://www.ctan.org/pkg/pdfescape") + (synopsis "pdfTeX's escape features for plain TeX") + (description + "This package implements pdfTeX's escape features (@code{\\pdfescapehex}, @code{\\pdfunescapehex}, @code{\\pdfescapename}, @code{\\pdfescapestring}) using TeX or e-TeX.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) -(define-public texlive-generic-uniquecounter - (package - (inherit (simple-texlive-package - "texlive-generic-uniquecounter" - '("/doc/latex/uniquecounter/" - "/tex/generic/uniquecounter/") - (base32 - "1bjh8vwiqlkmjqndnh4xp116524x4m3hdcyq2s231jiqy8il8dcc") - #:trivial? #t)) - (propagated-inputs - (list texlive-generic-bigintcalc texlive-generic-infwarerr)) - (home-page "https://www.ctan.org/pkg/uniquecounter") - (synopsis "Unlimited unique counter") - (description - "This package provides a kind of counter that provides unique number +(define-deprecated-package texlive-generic-pdfescape texlive-pdfescape) + +(define-public texlive-uniquecounter + (let ((template (simple-texlive-package + "texlive-uniquecounter" + (list "doc/latex/uniquecounter/" + "source/latex/uniquecounter/" + "tex/generic/uniquecounter/") + (base32 + "1ll3iwk8x44l3qx1dhna399ngg66vbllivv8i3lwzriwkx22xbf3")))) + (package + (inherit template) + (outputs '("out" "doc")) + (arguments + (substitute-keyword-arguments (package-arguments template) + ((#:tex-directory _ '()) + "generic/uniquecounter") + ((#:build-targets _ '()) + #~(list "uniquecounter.dtx")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/uniquecounter"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))))))) + (propagated-inputs + (list texlive-bigintcalc texlive-infwarerr)) + (home-page "https://www.ctan.org/pkg/uniquecounter") + (synopsis "Unlimited unique counter") + (description + "This package provides a kind of counter that provides unique number values. Several counters can be created with different names. The numeric values are not limited.") - (license license:lppl1.3c+))) + (license license:lppl1.3c+)))) + +(define-deprecated-package texlive-generic-uniquecounter texlive-uniquecounter) (define-public texlive-latex-readarray (package @@ -10003,9 +10675,9 @@ may be used instead of @code{\\marginpar} at almost every place where frames made with the @code{framed} package.") (license license:lppl1.3c+)))) -(define-public texlive-generic-iftex +(define-public texlive-iftex (let ((template (simple-texlive-package - "texlive-generic-iftex" + "texlive-iftex" (list "/doc/generic/iftex/" "/tex/generic/iftex/") (base32 @@ -10023,9 +10695,9 @@ package also provides the @code{\\RequirePDFTeX}, @code{\\RequireXeTeX}, and LuaTeX (respectively) is not the engine in use.") (license license:lppl1.3+)))) -(define-deprecated-package texlive-iftex texlive-generic-iftex) +(define-deprecated-package texlive-generic-iftex texlive-iftex) -(define-deprecated-package texlive-generic-ifxetex texlive-generic-iftex) +(define-deprecated-package texlive-generic-ifxetex texlive-iftex) (define-public texlive-tabu (let ((template @@ -10071,37 +10743,6 @@ used in place of @code{tabular}, @code{tabular*} and @code{tabularx} environments, as well as the @code{array} environment in maths mode.") (license license:lppl1.3+)))) -(define-public texlive-tools - (let ((template (simple-texlive-package - "texlive-tools" - (list "/doc/latex/tools/" - "/source/latex/tools/") - (base32 - "1xas0b69r3d5x4zhcqysgybyqaikd9avv6r1bdckb947id3iaz58")))) - (package - (inherit template) - (arguments - (substitute-keyword-arguments (package-arguments template) - ((#:tex-directory _ '()) - "latex/tools") - ((#:build-targets _ '()) - ''("tools.ins")) - ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'chdir - (lambda _ (chdir "source/latex/tools") #t)))))) - (home-page "https://www.ctan.org/tex-archive/macros/latex/required/tools/") - (synopsis "LaTeX standard tools bundle") - (description "This package provides a collection of simple tools that -are part of the LaTeX required tools distribution, comprising the packages: -@code{afterpage}, @code{array}, @code{bm}, @code{calc}, @code{dcolumn}, -@code{delarray}, @code{enumerate}, @code{fileerr}, @code{fontsmpl}, -@code{ftnright}, @code{hhline}, @code{indentfirst}, @code{layout}, -@code{longtable}, @code{multicol}, @code{rawfonts}, @code{showkeys}, -@code{somedefs}, @code{tabularx}, @code{theorem}, @code{trace}, -@code{varioref}, @code{verbatim}, @code{xr}, and @code{xspace}.") - (license license:lppl1.3+)))) - (define-public texlive-latex-xkeyval (package (name "texlive-latex-xkeyval") @@ -10164,17 +10805,12 @@ are part of the LaTeX required tools distribution, comprising the packages: texlive-graphics-def texlive-xcolor texlive-latex-footmisc - - ;; TODO: Use non-deprecated name on next rebuild cycle. - texlive-latex-listings - - texlive-generic-iftex + texlive-iftex + texlive-listings texlive-pstricks texlive-pst-text texlive-tools - - ;; TODO: Use non-deprecated name on next rebuild cycle. - texlive-latex-pgf)) + texlive-pgf)) (home-page "http://www.ctan.org/pkg/xkeyval") (synopsis "Extension of the keyval package") (description @@ -10559,6 +11195,21 @@ uppercase letters commonly used to represent various number sets. LaTeX macro support is provided in package @code{psnfss}.") (license license:gpl3+))) +(define-public texlive-fp + (package + (inherit + (simple-texlive-package + "texlive-fp" + (list "doc/latex/fp/" "tex/latex/fp/" "tex/plain/fp/") + (base32 "1q555fx71cf88sn3npzb0j2i10ak920k0qc9ccdygz99vqg10dad") + #:trivial? #t)) + (home-page "https://ctan.org/macros/latex/contrib/fp") + (synopsis "Fixed point arithmetic") + (description + "This package provides an extensive collection of arithmetic operations +for fixed point real numbers of high precision.") + (license license:lppl))) + (define-public texlive-fpl (package (inherit (simple-texlive-package @@ -11119,22 +11770,39 @@ The macros were designed for use within other macros.") (define-public texlive-grfext (let ((template (simple-texlive-package "texlive-grfext" - (list "/doc/latex/grfext/README.md" - "/source/latex/grfext/grfext.dtx") + (list "doc/latex/grfext/" + "source/latex/grfext/" + "tex/latex/grfext/") (base32 - "1cdvjp9gcnixxlbl8ibwz1yr799gwax5hm686hwmwsigdgafhzgq")))) + "1x35r10mkjg8dzx7aj99y4dwyf69jgs41qwapdx523lbglywmgxp")))) (package (inherit template) + (outputs '("out" "doc")) (arguments (substitute-keyword-arguments (package-arguments template) - ((#:tex-directory _ '()) + ((#:tex-directory _ #t) "latex/grfext") - ((#:build-targets _ '()) - ''("grfext.dtx")) + ((#:build-targets _ #t) + #~(list "grfext.dtx")) ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'chdir - (lambda _ (chdir "source/latex/grfext"))))))) + #~(modify-phases #$phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/latex/grfext"))) + (replace 'copy-files + (lambda* (#:key inputs #:allow-other-keys) + (let ((origin (assoc-ref inputs "source")) + (source (string-append #$output + "/share/texmf-dist/source")) + (doc (string-append #$output:doc + "/share/texmf-dist/doc"))) + (copy-recursively (string-append origin "/source") source) + (copy-recursively (string-append origin "/doc") doc)))) + (add-after 'copy-files 'remove-generated-file + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion #$output + (for-each delete-file + (find-files "." "\\.(drv|ins)$"))))))))) (home-page "https://github.com/ho-tex/grfext") (synopsis "Manipulate the graphics package's list of extensions") (description "This package provides macros for adding to, and reordering @@ -11163,12 +11831,12 @@ the list of graphics file extensions recognised by package graphics.") (native-inputs (list texlive-ydoc)) (propagated-inputs - (list texlive-pgf - texlive-latex-varwidth + (list texlive-latex-varwidth texlive-latex-xkeyval texlive-collectbox texlive-ifoddpage - texlive-storebox)) + texlive-storebox + texlive-pgf)) (home-page "https://www.ctan.org/pkg/adjustbox") (synopsis "Graphics package-alike macros for “general” boxes") (description "The package provides several macros to adjust boxed @@ -11246,8 +11914,7 @@ levels. All functionality is provided by the single @code{\\qrcode} command.") (package (inherit template) (propagated-inputs - (list texlive-etoolbox texlive-latex-environ texlive-pgf - texlive-latex-tools)) + (list texlive-etoolbox texlive-latex-environ texlive-pgf texlive-tools)) (home-page "https://www.ctan.org/pkg/tcolorbox") (synopsis "Colored boxes, for LaTeX examples and theorems, etc") (description "This package provides an environment for colored and @@ -11711,11 +12378,11 @@ and selecting references used in a publication.") texlive-booktabs texlive-endnotes texlive-etoolbox + texlive-fancyhdr texlive-xstring + texlive-graphics texlive-latex-draftwatermark - texlive-latex-fancyhdr texlive-latex-float - texlive-latex-graphics texlive-lm texlive-substr texlive-times diff --git a/gnu/packages/texinfo.scm b/gnu/packages/texinfo.scm index b069c42ca7..3296c468c1 100644 --- a/gnu/packages/texinfo.scm +++ b/gnu/packages/texinfo.scm @@ -49,14 +49,15 @@ (define-public texinfo (package (name "texinfo") - (version "6.7") + (version "6.8") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/texinfo/texinfo-" version ".tar.xz")) + (patches (search-patches "texinfo-headings-single.patch")) (sha256 (base32 - "1aicn1v3czqii08wc91jw089n1x3gfchkf808q2as59dak0h714q")))) + "1i7yb7mrp3inz25zbzv2pllr4y7d58v818f1as7iz8mw53nm7dwf")))) (build-system gnu-build-system) (arguments ;; When cross-compiling, the package is configured twice: once with the diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index 9a1de0fdd8..e0da7757e0 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2017, 2019-2022 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2012-2017, 2019-2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2021 Mark H Weaver <mhw@netris.org> ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net> ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr> @@ -15,7 +15,7 @@ ;;; Copyright © 2018 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> -;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2021, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Solene Rapenne <solene@perso.pw> ;;; Copyright © 2021 Brice Waegeneire <brice@waegenei.re> ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> @@ -40,6 +40,7 @@ (define-module (gnu packages tls) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix deprecation) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -89,7 +90,7 @@ (define-public libtasn1 (package (name "libtasn1") - (version "4.17.0") + (version "4.19.0") (source (origin (method url-fetch) @@ -97,7 +98,7 @@ version ".tar.gz")) (sha256 (base32 - "19a53i1ajs4dd8nnlr2i6gbzvla84ay71g3y1phvh8krx8f5brzc")))) + "0yizlr2y6gfjh86v68qw5wjcfg16arnw1f731kndd17l3jng04qn")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--disable-static"))) @@ -141,52 +142,51 @@ in intelligent transportation networks.") (define-public p11-kit (package (name "p11-kit") - (version "0.23.22") + (version "0.24.1") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/p11-glue/p11-kit/releases/" - "download/" version "/p11-kit-" version ".tar.xz")) - (sha256 - (base32 "1dn6br4v033d3gp2max9lsr3y4q0nj6iyr1yq3kzi8ym7lal13wa")))) + (method url-fetch) + (uri (string-append "https://github.com/p11-glue/p11-kit/releases/" + "download/" version "/p11-kit-" version ".tar.xz")) + (sha256 + (base32 "1y5fm9gwhkh902r26p90qf1g2h1ziqrk4hgf9i9sxm2wzlz7ignq")))) (build-system gnu-build-system) (native-inputs - `(,@(if (hurd-target?) - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("gettext" ,gettext-minimal) ;for autopoint - ("libtool" ,libtool)) - '()) - ("pkg-config" ,pkg-config))) + (append (list pkg-config) + (if (hurd-target?) + (list autoconf automake gettext-minimal libtool) + '()))) (inputs - `(("libffi" ,libffi) - ,@(if (hurd-target?) - `(("libbsd" ,libbsd) - ("hurd-patch" ,(search-patch "p11-kit-hurd.patch"))) - '()) - ("libtasn1" ,libtasn1))) + (append (list libffi libtasn1) + (if (hurd-target?) + (list libbsd) + '()))) (arguments - `(#:configure-flags '("--without-trust-paths") - #:phases (modify-phases %standard-phases - ,@(if (hurd-target?) - '((add-after 'unpack 'apply-hurd-patch - (lambda* (#:key inputs #:allow-other-keys) - (let ((patch (assoc-ref inputs "hurd-patch"))) - (invoke "patch" "-p1" "--batch" "-i" - patch)))) - (replace 'bootstrap - (lambda _ - (invoke "autoreconf" "-fiv")))) - '()) - (add-before 'check 'prepare-tests - (lambda _ - ;; "test-runtime" expects XDG_RUNTIME_DIR to be set up - ;; and looks for .cache and other directories (only). - ;; For simplicity just drop it since it is irrelevant - ;; in the build container. - (substitute* "Makefile" - (("test-runtime\\$\\(EXEEXT\\)") "")) - #t))))) + (list #:configure-flags + ;; Use the default certificates so that users such as flatpak + ;; find them. See <https://issues.guix.gnu.org/49957>. + #~'("--with-trust-paths=/etc/ssl/certs/ca-certificates.crt") + #:phases #~(modify-phases %standard-phases + #$@(if (hurd-target?) + #~((add-after 'unpack 'apply-hurd-patch + (lambda* (#:key inputs #:allow-other-keys) + (define patch + #$(local-file + (search-patch "p11-kit-hurd.patch"))) + (invoke "patch" "-p1" "--batch" "-i" + patch))) + (replace 'bootstrap + (lambda _ + (invoke "autoreconf" "-fiv")))) + #~()) + (add-before 'check 'prepare-tests + (lambda _ + ;; "test-runtime" expects XDG_RUNTIME_DIR to be set up + ;; and looks for .cache and other directories (only). + ;; For simplicity just drop it since it is irrelevant + ;; in the build container. + (substitute* "Makefile" + (("test-runtime\\$\\(EXEEXT\\)") ""))))))) (home-page "https://p11-glue.github.io/p11-glue/p11-kit.html") (synopsis "PKCS#11 library") (description @@ -197,32 +197,10 @@ coordinating the use of PKCS#11 by different components or libraries living in the same process.") (license license:bsd-3))) -(define-public p11-kit-next - (package - (inherit p11-kit) - (version "0.24.1") - (source - (origin - (method url-fetch) - (uri (string-append "https://github.com/p11-glue/p11-kit/releases/" - "download/" version "/p11-kit-" version ".tar.xz")) - (sha256 - (base32 "1y5fm9gwhkh902r26p90qf1g2h1ziqrk4hgf9i9sxm2wzlz7ignq")))) - (build-system meson-build-system) - (arguments - ;; Use the default certificates so that users such as flatpak find them. - ;; See <https://issues.guix.gnu.org/49957>. - (substitute-keyword-arguments (package-arguments p11-kit) - ((#:configure-flags flags ''()) - ''("-Dtrust_paths=/etc/ssl/certs/ca-certificates.crt")) - ;; p11-kit is still on gnu-build-system. - ((#:phases gnu-phases) - '%standard-phases))))) - (define-public gnutls (package (name "gnutls") - (version "3.7.2") + (version "3.7.7") (source (origin (method url-fetch) ;; Note: Releases are no longer on ftp.gnu.org since the @@ -231,108 +209,88 @@ living in the same process.") (version-major+minor version) "/gnutls-" version ".tar.xz")) (patches (search-patches "gnutls-skip-trust-store-test.patch" - "gnutls-cross.patch" - "gnutls-guile-eintr-eagain.patch")) + "gnutls-cross.patch")) (sha256 (base32 - "0li7mwjnm64mbxhacz0rpf6i9qd83f53fvbrx96alpqqk9d6qvk4")))) + "01i1gl15k6qwvxmxx0by1mn9nlmcmym18wdpm7dn9awfsp8474dy")))) (build-system gnu-build-system) (arguments - `(#:tests? ,(not (or (%current-target-system) - (hurd-target?))) - ;; Ensure we don't keep a reference to the tools used for testing. - #:disallowed-references ,(if (hurd-target?) - '() - (list net-tools iproute socat)) - #:configure-flags - (cons* - ;; GnuTLS doesn't consult any environment variables to specify - ;; the location of the system-wide trust store. Instead it has a - ;; configure-time option. Unless specified, its configure script - ;; attempts to auto-detect the location by looking for common - ;; places in the file system, none of which are present in our - ;; chroot build environment. If not found, then no default trust - ;; store is used, so each program has to provide its own - ;; fallback, and users have to configure each program - ;; independently. This seems suboptimal. - "--with-default-trust-store-dir=/etc/ssl/certs" - - ;; Tell the build system that we want Guile bindings installed to - ;; the output instead of Guiles own module directory. - (string-append "--with-guile-site-dir=" - "$(datarootdir)/guile/site/$(GUILE_EFFECTIVE_VERSION)") - (string-append "--with-guile-site-ccache-dir=" - "$(libdir)/guile/$(GUILE_EFFECTIVE_VERSION)/site-ccache") - (string-append "--with-guile-extension-dir=" - "$(libdir)/guile/$(GUILE_EFFECTIVE_VERSION)/extensions") + (list #:tests? (not (or (%current-target-system) + (hurd-target?))) + ;; Ensure we don't keep a reference to the tools used for testing. + #:disallowed-references (if (hurd-target?) + '() + (list net-tools iproute socat)) + #:configure-flags + #~(cons* + ;; GnuTLS doesn't consult any environment variables to specify + ;; the location of the system-wide trust store. Instead it has a + ;; configure-time option. Unless specified, its configure script + ;; attempts to auto-detect the location by looking for common + ;; places in the file system, none of which are present in our + ;; chroot build environment. If not found, then no default trust + ;; store is used, so each program has to provide its own + ;; fallback, and users have to configure each program + ;; independently. This seems suboptimal. + "--with-default-trust-store-dir=/etc/ssl/certs" - (let ((system ,(or (%current-target-system) - (%current-system)))) - (if (string-prefix? "mips64el" system) - (list - ;; FIXME: Temporarily disable p11-kit support since it is - ;; not working on mips64el. - "--without-p11-kit") - '()))) + (let ((system #$(or (%current-target-system) + (%current-system)))) + (if (string-prefix? "mips64el" system) + (list + ;; FIXME: Temporarily disable p11-kit support since it is + ;; not working on mips64el. + "--without-p11-kit") + '()))) - #:phases (modify-phases %standard-phases - ;; fastopen.sh fails to connect to the server in the builder - ;; environment (see: - ;; https://gitlab.com/gnutls/gnutls/-/issues/1095). - (add-after 'unpack 'disable-failing-tests - (lambda _ - (substitute* "tests/fastopen.sh" - (("^unset RETCODE") - "exit 77\n")))) ;skip - ,@(if (target-ppc32?) - ;; https://gitlab.com/gnutls/gnutls/-/issues/1354 - ;; Extend the test timeout from the default of 20 * 1000 - `((add-after 'unpack 'increase-test-timeout - (lambda _ - (setenv "GNUTLS_TEST_TIMEOUT" "60000")))) - '()) - (add-after 'install 'move-doc - (lambda* (#:key outputs #:allow-other-keys) - ;; Copy the 4.1 MiB of section 3 man pages to "doc". - (let* ((out (assoc-ref outputs "out")) - (doc (assoc-ref outputs "doc")) - (mandir (string-append doc "/share/man/man3")) - (oldman (string-append out "/share/man/man3"))) - (mkdir-p mandir) - (copy-recursively oldman mandir) - (delete-file-recursively oldman))))))) - (outputs '("out" ;4.4 MiB + #:phases + #~(modify-phases %standard-phases + ;; fastopen.sh fails to connect to the server in the builder + ;; environment (see: + ;; https://gitlab.com/gnutls/gnutls/-/issues/1095). + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "tests/fastopen.sh" + (("^unset RETCODE") + "exit 77\n")) ;skip + #$@(if (target-ppc32?) + ;; https://gitlab.com/gnutls/gnutls/-/issues/1354 + ;; Extend the test timeout from the default of 20 * 1000 + #~((add-after 'unpack 'increase-test-timeout + (lambda _ + (setenv "GNUTLS_TEST_TIMEOUT" "60000")))) + #~()))) + (add-after 'install 'move-doc + (lambda* (#:key outputs #:allow-other-keys) + ;; Copy the 4.1 MiB of section 3 man pages to "doc". + (let* ((out (assoc-ref outputs "out")) + (doc (assoc-ref outputs "doc")) + (mandir (string-append doc "/share/man/man3")) + (oldman (string-append out "/share/man/man3"))) + (mkdir-p mandir) + (copy-recursively oldman mandir) + (delete-file-recursively oldman))))))) + (outputs '("out" ;4.4 MiB "debug" - "doc")) ;4.1 MiB of man pages + "doc")) ;4.1 MiB of man pages (native-inputs - `(,@(if (%current-target-system) ;for cross-build - `(("guile" ,guile-3.0)) ;to create .go files - '()) - ,@(if (hurd-target?) - '() - `(("net-tools" ,net-tools) - ("iproute" ,iproute) ;for 'ss' - ("socat" ,socat))) ;several tests rely on it - ("pkg-config" ,pkg-config) - ("texinfo" ,texinfo) - ("which" ,which) - ,@(if (hurd-target?) - '() - `(("datefudge" ,datefudge))) ;tests rely on 'datefudge' - ("util-linux" ,util-linux))) ;one test needs 'setsid' - (inputs - (list guile-3.0)) + (append (list pkg-config texinfo which + util-linux) ;one test needs 'setsid' + (if (hurd-target?) + '() + (list net-tools + iproute ;for 'ss' + socat ;several tests rely on it + datefudge)))) ;tests rely on 'datefudge' + (inputs (list libunistring)) (propagated-inputs ;; These are all in the 'Requires.private' field of gnutls.pc. - `(("libtasn1" ,libtasn1) - ("libidn2" ,libidn2) - ("nettle" ,nettle) - ("zlib" ,zlib) - ,@(let ((system (or (%current-target-system) - (%current-system)))) - (if (string-prefix? "mips64el" system) - '() - `(("p11-kit" ,p11-kit)))))) + (append (list libtasn1 libidn2 nettle zlib) + (let ((system (or (%current-target-system) + (%current-system)))) + (if (string-prefix? "mips64el" system) + '() + (list p11-kit))))) (home-page "https://www.gnu.org/software/gnutls/") (synopsis "Transport layer security library") (description @@ -344,34 +302,7 @@ required structures.") (properties '((ftp-server . "ftp.gnutls.org") (ftp-directory . "/gcrypt/gnutls"))))) -(define-public gnutls-latest - (package - (inherit gnutls) - (version "3.7.7") - (source (origin - (method url-fetch) - (uri (string-append "mirror://gnupg/gnutls/v" - (version-major+minor version) - "/gnutls-" version ".tar.xz")) - (patches (search-patches "gnutls-skip-trust-store-test.patch" - "gnutls-cross.patch")) - (sha256 - (base32 - "01i1gl15k6qwvxmxx0by1mn9nlmcmym18wdpm7dn9awfsp8474dy")))) - - ;; Disable Guile bindings: they are now provided by Guile-GnuTLS. - (inputs (modify-inputs (package-inputs gnutls) - (delete "guile") - (append libunistring))) ;GnuTLS depends on it - (native-inputs (modify-inputs (package-native-inputs gnutls) - (delete "guile"))))) - -(define-public gnutls/guile-2.0 - ;; GnuTLS for Guile 2.0. - (package/inherit gnutls - (name "guile2.0-gnutls") - (inputs `(("guile" ,guile-2.0) - ,@(alist-delete "guile" (package-inputs gnutls)))))) +(define-deprecated/public-alias gnutls-latest gnutls) (define-public gnutls/dane ;; GnuTLS with build libgnutls-dane, implementing DNS-based @@ -380,15 +311,8 @@ required structures.") ;; to have the choice between GnuTLS with Dane and without Dane. (package/inherit gnutls (name "gnutls-dane") - (inputs `(("unbound" ,unbound) - ,@(package-inputs gnutls))))) - -(define-public guile2.2-gnutls - (package/inherit gnutls - (name "guile2.2-gnutls") - (inputs `(("guile" ,guile-2.2) - ,@(alist-delete "guile" - (package-inputs gnutls)))))) + (inputs (modify-inputs (package-inputs gnutls) + (prepend unbound))))) (define-public guile-gnutls (package @@ -441,14 +365,14 @@ required structures.") libtool pkg-config texinfo - gnutls-latest ;XXX: 'guile-snarf' invokes the native 'cpp' - guile-3.0 + gnutls + guile-3.0 ;XXX: 'guile-snarf' invokes the native 'cpp' (gnulib-checkout #:version "2022-12-06" #:commit "440b528b1d81dd31b2a2e4dde20d5c837c147811" #:hash (base32 "15mq43abbnkbamchc9lynrvrd5ql8qacgyx2ph4kkngxf1bz3pqy")))) (inputs - (list gnutls-latest + (list gnutls guile-3.0)) (properties '((release-tag-prefix . "v") (release-tag-version-delimiter . "."))) @@ -459,6 +383,16 @@ the @acronym{TLS, Transport-Layer Security} protocol. It supersedes the Guile bindings that were formerly provided as part of GnuTLS.") (license license:lgpl2.1+))) +(define-public guile2.2-gnutls + (package/inherit guile-gnutls + (name "guile2.2-gnutls") + (native-inputs + (modify-inputs (package-native-inputs guile-gnutls) + (replace "guile" guile-2.2))) + (inputs + (modify-inputs (package-inputs guile-gnutls) + (replace "guile" guile-2.2))))) + (define (target->openssl-target target) "Return the value to set CONFIGURE_TARGET_ARCH to when cross-compiling OpenSSL for TARGET." @@ -474,6 +408,9 @@ OpenSSL for TARGET." (let ((kernel (cond ((target-hurd? target) "hurd") + ((and (target-linux? target) + (target-riscv64? target)) + "linux64") ((target-linux? target) "linux") (else @@ -497,8 +434,9 @@ OpenSSL for TARGET." ((and (target-powerpc? target) (target-64bit? target)) "ppc64") + ((target-riscv64? target) + "riscv64") ((target-64bit? target) - ;; linux64-riscv64 isn't recognized until 3.0.0. "generic64") (else (error "unsupported openssl target architecture"))))) @@ -507,8 +445,7 @@ OpenSSL for TARGET." (define-public openssl-1.1 (package (name "openssl") - (version "1.1.1l") - (replacement openssl/fixed) + (version "1.1.1q") (source (origin (method url-fetch) (uri (list (string-append "https://www.openssl.org/source/openssl-" @@ -521,114 +458,106 @@ OpenSSL for TARGET." (patches (search-patches "openssl-1.1-c-rehash-in.patch")) (sha256 (base32 - "1lbblxps2fhmz7bqh058iywh5wxfignbfx1s1kz2fj63b5g3wyhb")))) + "1jhhzp4gh6ymidxm1ckjk948l583awp0w3y2nvqdz7022kk9r4yp")))) (build-system gnu-build-system) (outputs '("out" "doc" ;6.8 MiB of man3 pages and full HTML documentation "static")) ;6.4 MiB of .a files (native-inputs (list perl)) (arguments - `(#:parallel-tests? #f - #:test-target "test" - - ;; Changes to OpenSSL sometimes cause Perl to "sneak in" to the closure, - ;; so we explicitly disallow it here. - #:disallowed-references ,(list (canonical-package perl)) - #:phases - ,#~ - (modify-phases %standard-phases - #$@(if (%current-target-system) - #~((add-before - 'configure 'set-cross-compile - (lambda* (#:key target #:allow-other-keys) - (setenv "CROSS_COMPILE" (string-append target "-")) - (setenv "CONFIGURE_TARGET_ARCH" - #$(target->openssl-target - (%current-target-system)))))) - #~()) - ;; This test seems to be dependant on kernel features. - ;; https://github.com/openssl/openssl/issues/12242 - #$@(if (or (target-arm?) - (target-riscv64?)) - #~((replace 'check - (lambda* (#:key tests? test-target #:allow-other-keys) - (when tests? - (invoke "make" "TESTS=-test_afalg" test-target))))) - #~()) - (replace 'configure - (lambda* (#:key configure-flags #:allow-other-keys) - (let* ((out #$output) - (lib (string-append out "/lib"))) - ;; It's not a shebang so patch-source-shebangs misses it. - (substitute* "config" - (("/usr/bin/env") - (string-append (assoc-ref %build-inputs "coreutils") - "/bin/env"))) - (apply - invoke #$@(if (%current-target-system) - #~("./Configure") - #~("./config")) - "shared" ;build shared libraries - "--libdir=lib" + (list + #:parallel-tests? #f + #:make-flags + ;; 'test_ssl_new.t' in 1.1.1n and 3.0.3 fails due to an expired + ;; certificate: <https://github.com/openssl/openssl/issues/18441>. Skip + ;; it. + #~(list #$@(if (or (target-arm?) (target-riscv64?)) + ;; 'test_afalg' seems to be dependent on kernel features: + ;; <https://github.com/openssl/openssl/issues/12242>. + #~("TESTS=-test_afalg -tls_ssl_new") + #~("TESTS=-test_ssl_new"))) + #:test-target "test" + ;; Changes to OpenSSL sometimes cause Perl to "sneak in" to the closure, + ;; so we explicitly disallow it here. + #:disallowed-references (list (canonical-package perl)) + #:phases + #~(modify-phases %standard-phases + #$@(if (%current-target-system) + #~((add-before 'configure 'set-cross-compile + (lambda* (#:key target #:allow-other-keys) + (setenv "CROSS_COMPILE" (string-append target "-")) + (setenv "CONFIGURE_TARGET_ARCH" + #$(target->openssl-target + (%current-target-system)))))) + #~()) + (replace 'configure + (lambda* (#:key configure-flags #:allow-other-keys) + ;; It's not a shebang so patch-source-shebangs misses it. + (substitute* "config" + (("/usr/bin/env") + (which "env"))) + (apply + invoke #$@(if (%current-target-system) + #~("./Configure") + #~("./config")) + "shared" ;build shared libraries + "--libdir=lib" - ;; The default for this catch-all directory is - ;; PREFIX/ssl. Change that to something more - ;; conventional. - (string-append "--openssldir=" out - "/share/openssl-" - #$(package-version this-package)) + ;; The default for this catch-all directory is + ;; PREFIX/ssl. Change that to something more + ;; conventional. + (string-append "--openssldir=" #$output + "/share/openssl-" + #$(package-version this-package)) - (string-append "--prefix=" out) - (string-append "-Wl,-rpath," lib) - #$@(if (%current-target-system) - #~((getenv "CONFIGURE_TARGET_ARCH")) - #~()) - configure-flags) - ;; Output the configure variables. - (invoke "perl" "configdata.pm" "--dump")))) - (add-after 'install 'move-static-libraries - (lambda _ - ;; Move static libraries to the "static" output. - (let* ((out #$output) - (lib (string-append out "/lib")) - (static #$output:static) - (slib (string-append static "/lib"))) - (for-each (lambda (file) - (install-file file slib) - (delete-file file)) - (find-files - lib - #$(if (target-mingw?) - '(lambda (filename _) - (and (string-suffix? ".a" filename) - (not (string-suffix? ".dll.a" filename)))) - "\\.a$")))))) - (add-after 'install 'move-extra-documentation - (lambda _ - ;; Move man pages and full HTML documentation to "doc". - (let* ((out #$output) - (man (string-append out "/share/man")) - (html (string-append out "/share/doc/openssl")) - (doc #$output:doc) - (man-target (string-append doc "/share/man")) - (html-target (string-append doc "/share/doc/openssl"))) - (mkdir-p (dirname man-target)) - (mkdir-p (dirname html-target)) - (rename-file man man-target) - (rename-file html html-target)))) - (add-after - 'install 'remove-miscellany - (lambda _ - ;; The 'misc' directory contains random undocumented shell and Perl - ;; scripts. Remove them to avoid retaining a reference on Perl. - (delete-file-recursively (string-append #$output "/share/openssl-" - #$(package-version this-package) - "/misc"))))))) + (string-append "--prefix=" #$output) + (string-append "-Wl,-rpath," (string-append #$output "/lib")) + #$@(if (%current-target-system) + #~((getenv "CONFIGURE_TARGET_ARCH")) + #~()) + configure-flags) + ;; Output the configure variables. + (invoke "perl" "configdata.pm" "--dump"))) + (add-after 'install 'move-static-libraries + (lambda _ + ;; Move static libraries to the "static" output. + (let* ((lib (string-append #$output "/lib")) + (slib (string-append #$output:static "/lib"))) + (for-each (lambda (file) + (install-file file slib) + (delete-file file)) + (find-files + lib + #$(if (target-mingw?) + '(lambda (filename _) + (and (string-suffix? ".a" filename) + (not (string-suffix? ".dll.a" + filename)))) + "\\.a$")))))) + (add-after 'install 'move-extra-documentation + (lambda _ + ;; Move man pages and full HTML documentation to "doc". + (let* ((man (string-append #$output "/share/man")) + (html (string-append #$output "/share/doc/openssl")) + (man-target (string-append #$output:doc "/share/man")) + (html-target (string-append + #$output:doc "/share/doc/openssl"))) + (mkdir-p (dirname man-target)) + (mkdir-p (dirname html-target)) + (rename-file man man-target) + (rename-file html html-target)))) + (add-after 'install 'remove-miscellany + (lambda _ + ;; The 'misc' directory contains random undocumented shell and + ;; Perl scripts. Remove them to avoid retaining a reference on + ;; Perl. + (delete-file-recursively + (string-append #$output "/share/openssl-" + #$(package-version this-package) "/misc"))))))) (native-search-paths (list $SSL_CERT_DIR $SSL_CERT_FILE)) (synopsis "SSL/TLS implementation") - (description - "OpenSSL is an implementation of SSL/TLS.") + (description "OpenSSL is an implementation of SSL/TLS.") (license license:openssl) (home-page "https://www.openssl.org/"))) @@ -679,7 +608,7 @@ OpenSSL for TARGET." "/bin/perl")))))))) (license license:asl2.0))) -(define-public openssl openssl-1.1) +(define-public openssl openssl-3.0) (define-public bearssl (package diff --git a/gnu/packages/valgrind.scm b/gnu/packages/valgrind.scm index bd08dffc83..204dd4a3c5 100644 --- a/gnu/packages/valgrind.scm +++ b/gnu/packages/valgrind.scm @@ -106,45 +106,8 @@ also use Valgrind to build new tools.") "/valgrind-" version ".tar.bz2"))) (sha256 (base32 - "1ipkp6yi202pml2r0qwflysmq86dkqd8iyi1y51d6y70vcqw0dl5")) - (patches (search-patches - "valgrind-fix-default-debuginfo-path.patch")))) + "1ipkp6yi202pml2r0qwflysmq86dkqd8iyi1y51d6y70vcqw0dl5")))) (inputs ;; GDB is needed to provide a sane default for `--db-command'. (list gdb `(,(canonical-package glibc) "debug"))) - (arguments - (substitute-keyword-arguments (package-arguments valgrind) - ((#:phases phases #~%standard-phases) - #~(modify-phases #$phases - (add-before 'configure 'patch-default-debuginfo-path - (lambda* (#:key inputs #:allow-other-keys) - ;; This helps Valgrind find the debug symbols of ld.so. - ;; Without it, Valgrind does not work in a Guix shell - ;; container and cannot be used as-is during packages tests - ;; phases. - ;; TODO: Remove on the next rebuild cycle, when libc is not - ;; longer fully stripped. - (define libc-debug - (string-append (ungexp (this-package-input "glibc") "debug") - "/lib/debug")) - - (substitute* '("coregrind/m_debuginfo/readelf.c" - "docs/xml/manual-core-adv.xml" - "docs/xml/manual-core.xml") - (("DEFAULT_DEBUGINFO_PATH") - libc-debug)) - ;; We also need to account for the bigger path in - ;; the malloc-ed variables. - (substitute* '("coregrind/m_debuginfo/readelf.c") - (("DEBUGPATH_EXTRA_BYTES_1") - (number->string - (+ (string-length libc-debug) - (string-length "/.build-id//.debug") - 1)))) - (substitute* '("coregrind/m_debuginfo/readelf.c") - (("DEBUGPATH_EXTRA_BYTES_2") - (number->string - (+ (string-length libc-debug) - (string-length "/usr/lib/debug") - 1)))))))))) (properties '()))) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index 302f7c90ad..8f67a945a1 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -255,9 +255,12 @@ Python 3.3 and later, rather than on Python 2.") "09cva868qb4705s884dzvbwkm78jlw4q8m6xj7nd7cwxy2i2ff8b")))) ;; For subtree documentation. ("asciidoc" ,asciidoc) + ("docbook2x" ,docbook2x) ("docbook-xsl" ,docbook-xsl) - ("xmlto" ,xmlto) - ("pkg-config" ,pkg-config))) + ("libxslt" ,libxslt) + ("pkg-config" ,pkg-config) + ("texinfo" ,texinfo) + ("xmlto" ,xmlto))) (inputs `(("curl" ,curl) ("expat" ,expat) @@ -266,214 +269,213 @@ Python 3.3 and later, rather than on Python 2.") ("python" ,python) ; for git-p4 ("zlib" ,zlib) - ;; For PCRE support in git grep (USE_LIBPCRE2). - ("pcre" ,pcre2) - - ;; For 'gitweb.cgi'. - ("perl-cgi" ,perl-cgi) - - ;; For 'git-svn'. - ("subversion" ,subversion) - ("perl-term-readkey" ,perl-term-readkey) - - ;; For 'git-send-email'. - ("perl-authen-sasl" ,perl-authen-sasl) - ("perl-net-smtp-ssl" ,perl-net-smtp-ssl) - ("perl-io-socket-ssl" ,perl-io-socket-ssl) - - ;; For 'git gui', 'gitk', and 'git citool'. - ("tcl" ,tcl) - ("tk" ,tk) - - ;; For 'git-credential-libsecret' - ("glib" ,glib) - ("libsecret" ,libsecret))) - (outputs '("out" ; the core - "send-email" ; for git-send-email - "svn" ; git-svn - "credential-netrc" ; git-credential-netrc - "credential-libsecret" ; git-credential-libsecret - "subtree" ; git-subtree - "gui")) ; gitk, git gui - (arguments - `(#:make-flags `("V=1" ;more verbose compilation - - ,(string-append "SHELL_PATH=" - (assoc-ref %build-inputs "bash") - "/bin/sh") - - ;; Tests require a bash with completion support. - ,(string-append "TEST_SHELL_PATH=" - (assoc-ref %build-inputs "bash-for-tests") - "/bin/bash") - - "USE_LIBPCRE2=yes" - - ;; By default 'make install' creates hard links for - ;; things in 'libexec/git-core', which leads to huge - ;; nars; see <https://bugs.gnu.org/21949>. - "NO_INSTALL_HARDLINKS=indeed") - - ;; Make sure the full bash does not end up in the final closure. - #:disallowed-references (,bash) - - #:test-target "test" - - ;; The explicit --with-tcltk forces the build system to hardcode the - ;; absolute file name to 'wish'. - #:configure-flags (list (string-append "--with-tcltk=" - (assoc-ref %build-inputs "tk") - "/bin/wish8.6") ; XXX - ,@(if (%current-target-system) - git-cross-configure-flags - '())) - - #:modules ((srfi srfi-1) - (srfi srfi-26) - ((guix build gnu-build-system) #:prefix gnu:) - ,@%gnu-build-system-modules) - #:phases - (modify-phases %standard-phases - ,@(if (%current-target-system) - ;; The git build system assumes build == host - `((add-after 'unpack 'use-host-uname_S - (lambda _ - (substitute* "config.mak.uname" - (("uname_S := .*" all) - (if (equal? ,(%current-target-system) "i586-pc-gnu") - "uname_S := GNU\n" - all))) - #t))) - ;; We do not have bash-for-tests when cross-compiling. - `((add-after 'unpack 'modify-PATH - (lambda* (#:key inputs #:allow-other-keys) - (let ((path (string-split (getenv "PATH") #\:)) - (bash-full (assoc-ref inputs "bash-for-tests"))) - ;; Drop the test bash from PATH so that (which "sh") and - ;; similar does the right thing. - (setenv "PATH" (string-join - (remove (cut string-prefix? bash-full <>) path) - ":")) - #t))))) - ;; Add cross curl-config script to PATH when cross-compiling. - ,@(if (%current-target-system) - '((add-before 'configure 'add-cross-curl-config + ;; For PCRE support in git grep (USE_LIBPCRE2). + ("pcre" ,pcre2) + + ;; For 'gitweb.cgi'. + ("perl-cgi" ,perl-cgi) + + ;; For 'git-svn'. + ("subversion" ,subversion) + ("perl-term-readkey" ,perl-term-readkey) + + ;; For 'git-send-email'. + ("perl-authen-sasl" ,perl-authen-sasl) + ("perl-net-smtp-ssl" ,perl-net-smtp-ssl) + ("perl-io-socket-ssl" ,perl-io-socket-ssl) + + ;; For 'git gui', 'gitk', and 'git citool'. + ("tcl" ,tcl) + ("tk" ,tk) + + ;; For 'git-credential-libsecret' + ("glib" ,glib) + ("libsecret" ,libsecret))) + (outputs '("out" ; the core + "send-email" ; for git-send-email + "svn" ; git-svn + "credential-netrc" ; git-credential-netrc + "credential-libsecret" ; git-credential-libsecret + "subtree" ; git-subtree + "gui")) ; gitk, git gui + (arguments + `(#:make-flags `("V=1" ;more verbose compilation + + ,(string-append "SHELL_PATH=" + (assoc-ref %build-inputs "bash") + "/bin/sh") + + ;; Tests require a bash with completion support. + ,(string-append "TEST_SHELL_PATH=" + (assoc-ref %build-inputs "bash-for-tests") + "/bin/bash") + + "USE_LIBPCRE2=yes" + + ;; By default 'make install' creates hard links for + ;; things in 'libexec/git-core', which leads to huge + ;; nars; see <https://bugs.gnu.org/21949>. + "NO_INSTALL_HARDLINKS=indeed") + + ;; Make sure the full bash does not end up in the final closure. + #:disallowed-references (,bash) + + #:test-target "test" + + ;; The explicit --with-tcltk forces the build system to hardcode the + ;; absolute file name to 'wish'. + #:configure-flags (list (string-append "--with-tcltk=" + (assoc-ref %build-inputs "tk") + "/bin/wish8.6") ; XXX + ,@(if (%current-target-system) + git-cross-configure-flags + '())) + + #:modules ((srfi srfi-1) + (srfi srfi-26) + ((guix build gnu-build-system) #:prefix gnu:) + ,@%gnu-build-system-modules) + #:phases + (modify-phases %standard-phases + ,@(if (%current-target-system) + ;; The git build system assumes build == host + `((add-after 'unpack 'use-host-uname_S + (lambda _ + (substitute* "config.mak.uname" + (("uname_S := .*" all) + (if (equal? ,(%current-target-system) "i586-pc-gnu") + "uname_S := GNU\n" + all)))))) + ;; We do not have bash-for-tests when cross-compiling. + `((add-after 'unpack 'modify-PATH + (lambda* (#:key inputs #:allow-other-keys) + (let ((path (string-split (getenv "PATH") #\:)) + (bash-full (assoc-ref inputs "bash-for-tests"))) + ;; Drop the test bash from PATH so that (which "sh") and + ;; similar does the right thing. + (setenv "PATH" (string-join + (remove (cut string-prefix? bash-full <>) path) + ":"))))))) + ;; Add cross curl-config script to PATH when cross-compiling. + ,@(if (%current-target-system) + '((add-before 'configure 'add-cross-curl-config (lambda* (#:key inputs #:allow-other-keys) (setenv "PATH" (string-append (assoc-ref inputs "curl") "/bin:" - (getenv "PATH"))) - #t))) - '()) - (add-after 'configure 'patch-makefiles - (lambda _ - (substitute* "Makefile" - (("/usr/bin/perl") (which "perl")) - (("/usr/bin/python") (which "python3"))) - #t)) - (add-after 'configure 'add-PM.stamp - (lambda _ - ;; Add the "PM.stamp" to avoid "no rule to make target". - (call-with-output-file "perl/PM.stamp" (const #t)) - #t)) - (add-after 'build 'build-subtree - (lambda* (#:key inputs #:allow-other-keys) - (with-directory-excursion "contrib/subtree" - (substitute* "Makefile" - ;; Apparently `xmlto' does not bother to looks up the stylesheets - ;; specified in the XML, unlike the above substitution. Instead it - ;; uses a hard-coded URL. Work around it here, but if this is - ;; common perhaps we should hardcode this path in xmlto itself. - (("\\$\\(XMLTO\\) -m \\$\\(MANPAGE_XSL\\)") - (string-append "$(XMLTO) -x " - (string-append (assoc-ref inputs "docbook-xsl") - "/xml/xsl/docbook-xsl-" - ,(package-version docbook-xsl)) - "/manpages/docbook.xsl -m $(MANPAGE_XSL)"))) - (invoke "make") - (invoke "make" "install") - (invoke "make" "install-doc") - (substitute* "git-subtree" - (("/bin/sh") (which "sh")))) - #t)) - (add-before 'check 'patch-tests - (lambda _ - (let ((store-directory (%store-directory))) - ;; These files contain some funny bytes that Guile is unable - ;; to decode for shebang patching. Just delete them. - (for-each delete-file '("t/t4201-shortlog.sh" - "t/t7813-grep-icase-iso.sh")) - ;; Many tests contain inline shell scripts (hooks etc). - (substitute* (find-files "t" "\\.sh$") - (("#!/bin/sh") (string-append "#!" (which "sh")))) - ;; Un-do shebang patching here to prevent checksum mismatch. - (substitute* '("t/t4034/perl/pre" "t/t4034/perl/post") - (("^#!.*/bin/perl") "#!/usr/bin/perl")) - (substitute* "t/t5003-archive-zip.sh" - (("cp /bin/sh") (string-append "cp " (which "sh")))) - (substitute* "t/t6030-bisect-porcelain.sh" - (("\"/bin/sh\"") (string-append "\"" (which "sh") "\""))) - ;; FIXME: This test runs `git commit` with a bogus EDITOR - ;; and empty commit message, but does not fail the way it's - ;; expected to. The test passes when invoked interactively. - (substitute* "t/t7508-status.sh" - (("\tcommit_template_commented") "\ttrue")) - ;; More checksum mismatches due to odd shebangs. - (substitute* "t/t9100-git-svn-basic.sh" - (((string-append "\"#!" store-directory ".*/bin/sh")) "\"#!/bin/sh") ) - (substitute* "t/t9300-fast-import.sh" - (((string-append "\t#!" store-directory ".*/bin/sh")) "\t#!/bin/sh") - (((string-append "'#!" store-directory ".*/bin/sh")) "'#!/bin/sh")) - ;; FIXME: Some hooks fail with "basename: command not found". - ;; See 't/trash directory.t9164.../svn-hook.log'. - (delete-file "t/t9164-git-svn-dcommit-concurrent.sh") - - ;; XXX: These tests fail intermittently for unknown reasons: - ;; <https://bugs.gnu.org/29546>. - (for-each delete-file - '("t/t9128-git-svn-cmd-branch.sh" - "t/t9167-git-svn-cmd-branch-subproject.sh" - "t/t9141-git-svn-multiple-branches.sh")) - #t))) - (add-after 'install 'install-shell-completion - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (completions (string-append out "/etc/bash_completion.d"))) - ;; TODO: Install the tcsh and zsh completions in the right place. - (mkdir-p completions) - (copy-file "contrib/completion/git-completion.bash" - (string-append completions "/git")) - #t))) - (add-after 'install 'install-credential-netrc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((netrc (assoc-ref outputs "credential-netrc"))) - (install-file "contrib/credential/netrc/git-credential-netrc.perl" - (string-append netrc "/bin")) - (rename-file (string-append netrc "/bin/git-credential-netrc.perl") - (string-append netrc "/bin/git-credential-netrc")) - ;; Previously, Git.pm was automatically found by netrc. - ;; Perl 5.26 changed how it locates modules so that @INC no - ;; longer includes the current working directory (the Perl - ;; community calls this "dotless @INC"). - (wrap-program (string-append netrc "/bin/git-credential-netrc") - `("PERL5LIB" ":" prefix - (,(string-append (assoc-ref outputs "out") "/share/perl5")))) - #t))) - (add-after 'install 'install-credential-libsecret - (lambda* (#:key outputs #:allow-other-keys) - (let* ((libsecret (assoc-ref outputs "credential-libsecret"))) - (with-directory-excursion "contrib/credential/libsecret" - ((assoc-ref gnu:%standard-phases 'build)) - (install-file "git-credential-libsecret" - (string-append libsecret "/bin")) - #t)))) - (add-after 'install 'install-subtree - (lambda* (#:key outputs #:allow-other-keys) - (let ((subtree (assoc-ref outputs "subtree"))) - (install-file "contrib/subtree/git-subtree" - (string-append subtree "/bin")) - (install-file "contrib/subtree/git-subtree.1" - (string-append subtree "/share/man/man1")) - #t))) + (getenv "PATH")))))) + '()) + (add-after 'configure 'patch-makefiles + (lambda _ + (substitute* "Makefile" + (("/usr/bin/perl") (which "perl")) + (("/usr/bin/python") (which "python3"))))) + (add-after 'configure 'add-PM.stamp + (lambda _ + ;; Add the "PM.stamp" to avoid "no rule to make target". + (call-with-output-file "perl/PM.stamp" (const #t)))) + (add-after 'build 'build-subtree + (lambda* (#:key inputs #:allow-other-keys) + (with-directory-excursion "contrib/subtree" + (substitute* "Makefile" + ;; Apparently `xmlto' does not bother to looks up the stylesheets + ;; specified in the XML, unlike the above substitution. Instead it + ;; uses a hard-coded URL. Work around it here, but if this is + ;; common perhaps we should hardcode this path in xmlto itself. + (("\\$\\(XMLTO\\) -m \\$\\(MANPAGE_XSL\\)") + (string-append "$(XMLTO) -x " + (string-append (assoc-ref inputs "docbook-xsl") + "/xml/xsl/docbook-xsl-" + ,(package-version docbook-xsl)) + "/manpages/docbook.xsl -m $(MANPAGE_XSL)"))) + (invoke "make") + (invoke "make" "install") + (invoke "make" "install-doc") + (substitute* "git-subtree" + (("/bin/sh") (which "sh")))))) + (add-before 'check 'patch-tests + (lambda _ + (let ((store-directory (%store-directory))) + ;; These files contain some funny bytes that Guile is unable + ;; to decode for shebang patching. Just delete them. + (for-each delete-file '("t/t4201-shortlog.sh" + "t/t7813-grep-icase-iso.sh")) + ;; Many tests contain inline shell scripts (hooks etc). + (substitute* (find-files "t" "\\.sh$") + (("#!/bin/sh") (string-append "#!" (which "sh")))) + ;; Un-do shebang patching here to prevent checksum mismatch. + (substitute* '("t/t4034/perl/pre" "t/t4034/perl/post") + (("^#!.*/bin/perl") "#!/usr/bin/perl")) + (substitute* "t/t5003-archive-zip.sh" + (("cp /bin/sh") (string-append "cp " (which "sh")))) + (substitute* "t/t6030-bisect-porcelain.sh" + (("\"/bin/sh\"") (string-append "\"" (which "sh") "\""))) + ;; FIXME: This test runs `git commit` with a bogus EDITOR + ;; and empty commit message, but does not fail the way it's + ;; expected to. The test passes when invoked interactively. + (substitute* "t/t7508-status.sh" + (("\tcommit_template_commented") "\ttrue")) + ;; More checksum mismatches due to odd shebangs. + (substitute* "t/t9100-git-svn-basic.sh" + (((string-append "\"#!" store-directory ".*/bin/sh")) "\"#!/bin/sh") ) + (substitute* "t/t9300-fast-import.sh" + (((string-append "\t#!" store-directory ".*/bin/sh")) "\t#!/bin/sh") + (((string-append "'#!" store-directory ".*/bin/sh")) "'#!/bin/sh")) + ;; FIXME: Some hooks fail with "basename: command not found". + ;; See 't/trash directory.t9164.../svn-hook.log'. + (delete-file "t/t9164-git-svn-dcommit-concurrent.sh") + + ;; XXX: These tests fail intermittently for unknown reasons: + ;; <https://bugs.gnu.org/29546>. + (for-each delete-file + '("t/t9128-git-svn-cmd-branch.sh" + "t/t9167-git-svn-cmd-branch-subproject.sh" + "t/t9141-git-svn-multiple-branches.sh"))))) + (add-after 'install 'install-info-manual + (lambda* (#:key parallel-build? #:allow-other-keys) + (define job-count (if parallel-build? + (number->string (parallel-job-count)) + "1")) + (invoke "make" "-C" "Documentation" "install-info" + "-j" job-count + ;; The Makefile refer to 'docbook2x-texi', but our binary + ;; is named 'docbook2texi'. + "DOCBOOK2X_TEXI=docbook2texi" "PERL_PATH=perl"))) + (add-after 'install 'install-shell-completion + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (completions (string-append out "/etc/bash_completion.d"))) + ;; TODO: Install the tcsh and zsh completions in the right place. + (mkdir-p completions) + (copy-file "contrib/completion/git-completion.bash" + (string-append completions "/git"))))) + (add-after 'install 'install-credential-netrc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((netrc (assoc-ref outputs "credential-netrc"))) + (install-file "contrib/credential/netrc/git-credential-netrc.perl" + (string-append netrc "/bin")) + (rename-file (string-append netrc "/bin/git-credential-netrc.perl") + (string-append netrc "/bin/git-credential-netrc")) + ;; Previously, Git.pm was automatically found by netrc. + ;; Perl 5.26 changed how it locates modules so that @INC no + ;; longer includes the current working directory (the Perl + ;; community calls this "dotless @INC"). + (wrap-program (string-append netrc "/bin/git-credential-netrc") + `("PERL5LIB" ":" prefix + (,(string-append (assoc-ref outputs "out") "/share/perl5"))))))) + (add-after 'install 'install-credential-libsecret + (lambda* (#:key outputs #:allow-other-keys) + (let* ((libsecret (assoc-ref outputs "credential-libsecret"))) + (with-directory-excursion "contrib/credential/libsecret" + ((assoc-ref gnu:%standard-phases 'build)) + (install-file "git-credential-libsecret" + (string-append libsecret "/bin")))))) + (add-after 'install 'install-subtree + (lambda* (#:key outputs #:allow-other-keys) + (let ((subtree (assoc-ref outputs "subtree"))) + (install-file "contrib/subtree/git-subtree" + (string-append subtree "/bin")) + (install-file "contrib/subtree/git-subtree.1" + (string-append subtree "/share/man/man1"))))) (add-after 'install 'restore-sample-hooks-shebang (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -482,128 +484,125 @@ Python 3.3 and later, rather than on Python 2.") (format #t "restoring shebang on `~a'~%" file) (substitute* file (("^#!.*/bin/sh") "#!/bin/sh"))) - (find-files dir ".*")) - #t))) - (add-after 'install 'split - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; Split the binaries to the various outputs. - (let* ((out (assoc-ref outputs "out")) - (se (assoc-ref outputs "send-email")) - (svn (assoc-ref outputs "svn")) - (gui (assoc-ref outputs "gui")) - (gitk (string-append out "/bin/gitk")) - (gitk* (string-append gui "/bin/gitk")) - (git-gui (string-append out "/libexec/git-core/git-gui")) - (git-gui* (string-append gui "/libexec/git-core/git-gui")) - (git-cit (string-append out "/libexec/git-core/git-citool")) - (git-cit* (string-append gui "/libexec/git-core/git-citool")) - (git-se (string-append out "/libexec/git-core/git-send-email")) - (git-se* (string-append se "/libexec/git-core/git-send-email")) - (git-svn (string-append out "/libexec/git-core/git-svn")) - (git-svn* (string-append svn "/libexec/git-core/git-svn")) - (git-sm (string-append out - "/libexec/git-core/git-submodule"))) - (mkdir-p (string-append gui "/bin")) - (mkdir-p (string-append gui "/libexec/git-core")) - (mkdir-p (string-append se "/libexec/git-core")) - (mkdir-p (string-append svn "/libexec/git-core")) - - (for-each (lambda (old new) - (copy-file old new) - (delete-file old) - (chmod new #o555)) - (list gitk git-gui git-cit git-se git-svn) - (list gitk* git-gui* git-cit* git-se* git-svn*)) - - ;; Tell 'git-svn' where Subversion and perl-term-readkey are. - (wrap-program git-svn* - `("PATH" ":" prefix - (,(string-append (assoc-ref inputs "subversion") - "/bin"))) - `("PERL5LIB" ":" prefix - ,(map (lambda (i) (string-append (assoc-ref inputs i) - "/lib/perl5/site_perl")) - '("subversion" "perl-term-readkey"))) - - ;; XXX: The .so for SVN/Core.pm lacks a RUNPATH, so - ;; help it find 'libsvn_client-1.so'. - `("LD_LIBRARY_PATH" ":" prefix - (,(string-append (assoc-ref inputs "subversion") - "/lib")))) - - ;; Tell 'git-send-email' where perl modules are. - (wrap-program git-se* - `("PERL5LIB" ":" prefix - ,(map (lambda (o) (string-append o "/lib/perl5/site_perl")) - (list - ,@(transitive-input-references - 'inputs - (map (lambda (l) - (assoc l (package-inputs this-package))) - '("perl-authen-sasl" - "perl-net-smtp-ssl" - "perl-io-socket-ssl"))))))) - - ;; Tell 'gitweb.cgi' where perl modules are. - (wrap-program (string-append out "/share/gitweb/gitweb.cgi") - `("PERL5LIB" ":" prefix - ,(map (lambda (o) (string-append o "/lib/perl5/site_perl")) - (list - ,@(transitive-input-references - 'inputs - (map (lambda (l) - (assoc l (package-inputs this-package))) - '("perl-cgi"))))))) - - ;; Tell 'git-submodule' where Perl is. - (wrap-program git-sm - `("PATH" ":" prefix - (,(string-append (assoc-ref inputs "perl") - "/bin")))) - - #t))) - (add-after 'split 'install-man-pages - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (man (string-append out "/share/man")) - (manpages (assoc-ref inputs "git-manpages"))) - (mkdir-p man) - (with-directory-excursion man - (invoke "tar" "xvf" manpages)))))))) - - (native-search-paths - ;; For HTTPS access, Git needs a single-file certificate bundle, specified - ;; with $GIT_SSL_CAINFO. - (list (search-path-specification - (variable "GIT_SSL_CAINFO") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt"))) - (search-path-specification - (variable "GIT_EXEC_PATH") - (separator #f) ;single entry - (files '("libexec/git-core"))))) - - (synopsis "Distributed version control system") - (description - "Git is a free distributed version control system designed to handle + (find-files dir ".*"))))) + (add-after 'install 'split + (lambda* (#:key inputs outputs #:allow-other-keys) + ;; Split the binaries to the various outputs. + (let* ((out (assoc-ref outputs "out")) + (se (assoc-ref outputs "send-email")) + (svn (assoc-ref outputs "svn")) + (gui (assoc-ref outputs "gui")) + (gitk (string-append out "/bin/gitk")) + (gitk* (string-append gui "/bin/gitk")) + (git-gui (string-append out "/libexec/git-core/git-gui")) + (git-gui* (string-append gui "/libexec/git-core/git-gui")) + (git-cit (string-append out "/libexec/git-core/git-citool")) + (git-cit* (string-append gui "/libexec/git-core/git-citool")) + (git-se (string-append out "/libexec/git-core/git-send-email")) + (git-se* (string-append se "/libexec/git-core/git-send-email")) + (git-svn (string-append out "/libexec/git-core/git-svn")) + (git-svn* (string-append svn "/libexec/git-core/git-svn")) + (git-sm (string-append out + "/libexec/git-core/git-submodule"))) + (mkdir-p (string-append gui "/bin")) + (mkdir-p (string-append gui "/libexec/git-core")) + (mkdir-p (string-append se "/libexec/git-core")) + (mkdir-p (string-append svn "/libexec/git-core")) + + (for-each (lambda (old new) + (copy-file old new) + (delete-file old) + (chmod new #o555)) + (list gitk git-gui git-cit git-se git-svn) + (list gitk* git-gui* git-cit* git-se* git-svn*)) + + ;; Tell 'git-svn' where Subversion and perl-term-readkey are. + (wrap-program git-svn* + `("PATH" ":" prefix + (,(string-append (assoc-ref inputs "subversion") + "/bin"))) + `("PERL5LIB" ":" prefix + ,(map (lambda (i) (string-append (assoc-ref inputs i) + "/lib/perl5/site_perl")) + '("subversion" "perl-term-readkey"))) + + ;; XXX: The .so for SVN/Core.pm lacks a RUNPATH, so + ;; help it find 'libsvn_client-1.so'. + `("LD_LIBRARY_PATH" ":" prefix + (,(string-append (assoc-ref inputs "subversion") + "/lib")))) + + ;; Tell 'git-send-email' where perl modules are. + (wrap-program git-se* + `("PERL5LIB" ":" prefix + ,(map (lambda (o) (string-append o "/lib/perl5/site_perl")) + (list + ,@(transitive-input-references + 'inputs + (map (lambda (l) + (assoc l (package-inputs this-package))) + '("perl-authen-sasl" + "perl-net-smtp-ssl" + "perl-io-socket-ssl"))))))) + + ;; Tell 'gitweb.cgi' where perl modules are. + (wrap-program (string-append out "/share/gitweb/gitweb.cgi") + `("PERL5LIB" ":" prefix + ,(map (lambda (o) (string-append o "/lib/perl5/site_perl")) + (list + ,@(transitive-input-references + 'inputs + (map (lambda (l) + (assoc l (package-inputs this-package))) + '("perl-cgi"))))))) + + ;; Tell 'git-submodule' where Perl is. + (wrap-program git-sm + `("PATH" ":" prefix + (,(string-append (assoc-ref inputs "perl") + "/bin"))))))) + (add-after 'split 'install-man-pages + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (man (string-append out "/share/man")) + (manpages (assoc-ref inputs "git-manpages"))) + (mkdir-p man) + (with-directory-excursion man + (invoke "tar" "xvf" manpages)))))))) + + (native-search-paths + ;; For HTTPS access, Git needs a single-file certificate bundle, specified + ;; with $GIT_SSL_CAINFO. + (list (search-path-specification + (variable "GIT_SSL_CAINFO") + (file-type 'regular) + (separator #f) ;single entry + (files '("etc/ssl/certs/ca-certificates.crt"))) + (search-path-specification + (variable "GIT_EXEC_PATH") + (separator #f) ;single entry + (files '("libexec/git-core"))))) + + (synopsis "Distributed version control system") + (description + "Git is a free distributed version control system designed to handle everything from small to very large projects with speed and efficiency.") - ;; XXX: Ignore this CVE to work around a name clash with the unrelated - ;; "cpe:2.3:a:jenkins:git" package. The proper fix is for (guix cve) to - ;; account for "vendor names". - (properties '((lint-hidden-cve . ("CVE-2018-1000182" - "CVE-2018-1000110" - "CVE-2019-1003010" - "CVE-2020-2136" - "CVE-2021-21684" - "CVE-2022-30947" - "CVE-2022-30948" - "CVE-2022-30949" - "CVE-2022-36882" - "CVE-2022-36883" - "CVE-2022-36884")))) - (license license:gpl2) - (home-page "https://git-scm.com/"))) + ;; XXX: Ignore this CVE to work around a name clash with the unrelated + ;; "cpe:2.3:a:jenkins:git" package. The proper fix is for (guix cve) to + ;; account for "vendor names". + (properties '((lint-hidden-cve . ("CVE-2018-1000182" + "CVE-2018-1000110" + "CVE-2019-1003010" + "CVE-2020-2136" + "CVE-2021-21684" + "CVE-2022-30947" + "CVE-2022-30948" + "CVE-2022-30949" + "CVE-2022-36882" + "CVE-2022-36883" + "CVE-2022-36884")))) + (license license:gpl2) + (home-page "https://git-scm.com/"))) (define-public git-minimal ;; The size of the closure of 'git-minimal' is two thirds that of 'git'. @@ -619,11 +618,11 @@ everything from small to very large projects with speed and efficiency.") (replace 'patch-makefiles (lambda _ (substitute* "Makefile" - (("/usr/bin/perl") (which "perl"))) - #t)) + (("/usr/bin/perl") (which "perl"))))) (delete 'build-subtree) (delete 'split) (delete 'install-man-pages) + (delete 'install-info-manual) (delete 'install-subtree) (delete 'install-credential-netrc) (delete 'install-credential-libsecret) @@ -647,8 +646,7 @@ everything from small to very large projects with speed and efficiency.") ;; Gitweb depends on Perl as well. (delete-file-recursively - (string-append out "/share/gitweb")) - #t))))) + (string-append out "/share/gitweb"))))))) ((#:make-flags flags) `(delete "USE_LIBPCRE2=yes" ,flags)) ((#:configure-flags flags) @@ -1864,7 +1862,7 @@ execution of any hook written in any language before every commit.") (native-search-paths (list (search-path-specification (variable "HGEXTENSIONPATH") - (files '("lib/python3.9/site-packages/hgext3rd"))))) + (files '("lib/python3.10/site-packages/hgext3rd"))))) (home-page "https://www.mercurial-scm.org/") (synopsis "Decentralized version control system") (description @@ -2691,7 +2689,7 @@ by rclone usable with git-annex.") which ;for tests only ed)) ;ditto (inputs - (list openssl zlib sqlite-next)) ;SQLite 3.37 or later + (list openssl zlib sqlite)) (arguments `(#:configure-flags (list "--with-openssl=auto" "--disable-internal-sqlite") diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 8013d41fa0..240730844a 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -1501,17 +1501,17 @@ quality and performance.") (define-public libva (package (name "libva") - (version "2.16.0") + (version "2.17.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/intel/libva/releases/download/" version "/libva-" version ".tar.bz2")) (sha256 - (base32 "070aj9nw681a4m7f5xb662hhyib0w9q0i0s9v8vplh9cvfhaqpqi")))) + (base32 "1b2f1hik4x3n4n8217sg1k602wqjba8x20r7nsdmmq05qckyprgk")))) (build-system gnu-build-system) (native-inputs - (list pkg-config)) + (list config pkg-config)) (inputs (list libdrm libx11 @@ -1533,6 +1533,14 @@ quality and performance.") #~(list (string-append "dummy_drv_video_ladir=" #$output "/lib/dri")) #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'update-config-scripts + (lambda* (#:key native-inputs inputs #:allow-other-keys) + (for-each (lambda (file) + (install-file + (search-input-file + (or native-inputs inputs) + (string-append "/bin/" file)) ".")) + '("config.guess" "config.sub")))) (add-before 'build 'fix-dlopen-paths (lambda _ (substitute* "va/drm/va_drm_auth_x11.c" @@ -3153,7 +3161,7 @@ and custom quantization matrices.") (list python-pysocks python-websocket-client python-isodate - python-lxml-4.7 + python-lxml python-pycountry python-pycryptodome python-requests @@ -3590,7 +3598,7 @@ application with @code{obs-gamecapture}.") (define-public libvdpau (package (name "libvdpau") - (version "1.4") + (version "1.5") (source (origin (method git-fetch) @@ -3600,7 +3608,7 @@ application with @code{obs-gamecapture}.") (file-name (git-file-name name version)) (sha256 (base32 - "1hc4mcrbr1yhfiy4zfd8wc2iiqbp90z6jswap0jia20vmyk5lqld")))) + "1zfbh5q9adzlydpgwq7hl5w1j2b29j7zns6dxf9fp9pvkj23fz5l")))) (build-system meson-build-system) (native-inputs (list pkg-config)) diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm index 6baf10915a..d555194d0b 100644 --- a/gnu/packages/vim.scm +++ b/gnu/packages/vim.scm @@ -243,7 +243,7 @@ with the editor vim."))) (prepend pkg-config xorg-server-for-tests))) (inputs `(("acl" ,acl) - ("atk" ,atk) + ("at-spi2-core" ,at-spi2-core) ("attr" ,attr) ("cairo" ,cairo) ("fontconfig" ,fontconfig) diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index a27135cf58..4a0d6b0096 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -472,7 +472,7 @@ exec smbd $@"))) flex gettext-minimal `(,glib "bin") ;gtester, etc. - meson-0.63 + meson ninja perl pkg-config diff --git a/gnu/packages/vnc.scm b/gnu/packages/vnc.scm index 0731b5255e..fda4c38dfe 100644 --- a/gnu/packages/vnc.scm +++ b/gnu/packages/vnc.scm @@ -123,7 +123,7 @@ pkg-config)) (inputs (list libappindicator - atk + at-spi2-core avahi cairo cups diff --git a/gnu/packages/web-browsers.scm b/gnu/packages/web-browsers.scm index 7b06e54cdf..b7965ea670 100644 --- a/gnu/packages/web-browsers.scm +++ b/gnu/packages/web-browsers.scm @@ -479,6 +479,7 @@ interface.") python-markupsafe python-pygments python-pynacl + python-pypeg2 python-pyyaml ;; FIXME: python-pyqtwebengine needs to come before python-pyqt so ;; that it's __init__.py is used first. @@ -494,6 +495,11 @@ interface.") #:tests? #f #:phases (modify-phases %standard-phases + (add-after 'unpack 'patch-systemdir + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (substitute* "qutebrowser/utils/standarddir.py" + (("/usr/share") (string-append out "/share")))))) (add-after 'unpack 'find-userscripts (lambda* (#:key outputs #:allow-other-keys) (substitute* "qutebrowser/commands/userscripts.py" diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 6fa3067bbe..7027fbad08 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -1091,19 +1091,29 @@ libraries for working with JNLP applets.") (define-public jansson (package (name "jansson") - (version "2.13.1") + (version "2.14") (source (origin (method url-fetch) - (uri - (string-append "http://www.digip.org/jansson/releases/jansson-" - version ".tar.bz2")) + (uri (string-append "https://github.com/akheron/jansson" + "/releases/download/v" version + "/jansson-" version ".tar.bz2")) (sha256 (base32 - "1g8h18vh8gyxlwfmvdivdp1siad26ywj5zr4j4avgdyjg7wa147f")))) + "1fdgji964mrrz19glx0zh91asji542fvybymvzk6rrbagkr5dagv")))) (build-system gnu-build-system) (arguments - `(#:configure-flags '("--disable-static"))) - (home-page "http://www.digip.org/jansson/") + (list + #:configure-flags #~'("--disable-static") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-tests + (lambda _ + ;; Take a fix from upstream for testing with symbol versioning: + ;; https://github.com/akheron/jansson/pull/593 + (substitute* "test/suites/api/check-exports" + (("(grep ' \\[DT\\] ' \\$test_log/symbols.*) \\| sort" _ cmd) + (string-append cmd "| sed 's/@@libjansson.*//' | sort")))))))) + (home-page "https://github.com/akheron/jansson") (synopsis "JSON C library") (description "Jansson is a C library for encoding, decoding and manipulating JSON @@ -2028,8 +2038,7 @@ from streaming URLs. It is a command-line wrapper for the libquvi library.") ;;("gss" ,gss) zlib)) (arguments - `(#:scons ,scons-3 ;TODO: remove in the next rebuild cycle - #:scons-flags (list (string-append "APR=" (assoc-ref %build-inputs "apr")) + `(#:scons-flags (list (string-append "APR=" (assoc-ref %build-inputs "apr")) (string-append "APU=" (assoc-ref %build-inputs "apr-util")) (string-append "OPENSSL=" (assoc-ref %build-inputs "openssl")) ;; (string-append "GSSAPI=" (assoc-ref %build-inputs "gss")) @@ -4716,13 +4725,14 @@ their web site.") (define-public python-feedparser (package (name "python-feedparser") - (version "6.0.8") + (version "6.0.10") (source (origin (method url-fetch) (uri (pypi-uri "feedparser" version ".tar.gz")) (sha256 - (base32 "0qcnkyjjfj5gg5rhd1j4zzlqx5h34bma18zwgj68q95b0l543q2w")))) + (base32 "0lfa1c8s6abnlksbwxdpq78bg4rb6603mcgarmip3kip8rglini7")) + (patches (search-patches "python-feedparser-missing-import.patch")))) (build-system python-build-system) (propagated-inputs (list python-sgmllib3k)) @@ -6658,7 +6668,7 @@ file links.") (native-inputs (list pkg-config)) (inputs - (list atk + (list at-spi2-core cairo gdk-pixbuf gtk+ @@ -7736,7 +7746,7 @@ derivation by David Revoy from the original MonsterID by Andreas Gohr.") (define-public nghttp2 (package (name "nghttp2") - (version "1.44.0") + (version "1.49.0") (source (origin (method url-fetch) @@ -7745,7 +7755,7 @@ derivation by David Revoy from the original MonsterID by Andreas Gohr.") "nghttp2-" version ".tar.xz")) (sha256 (base32 - "0p9wvva4g8hwj55x19rbyvnq2dbsnf65rphhxnpqs7ll54xlg6an")))) + "0vm692c7q2wc4xxz8c41nr8jps2fkwf51xp8fb233cghpf9d9kxh")))) (build-system gnu-build-system) (outputs (list "out" "lib")) ; only libnghttp2 @@ -7755,44 +7765,42 @@ derivation by David Revoy from the original MonsterID by Andreas Gohr.") cunit python tzdata-for-tests)) (inputs ;; Required to build the tools (i.e. without ‘--enable-lib-only’). - `(("c-ares" ,c-ares) - ("jansson" ,jansson) ; for HPACK tools - ,@(if (hurd-target?) '() - `(("jemalloc" ,jemalloc))) ; fight nghttpd{,x} heap fragmentation - ("libev" ,libev) - ("libxml2" ,libxml2) ; for ‘nghttp -a’ - ("openssl" ,openssl) - ,@(if (hurd-target?) - `(("openssl-static" ,openssl "static")) - '()))) + (append + (if (hurd-target?) + `((,openssl "static")) + (list jemalloc)) ; fight nghttpd{,x} heap fragmentation + (list c-ares + jansson ; for HPACK tools + libev + libxml2 ; for ‘nghttp -a’ + openssl))) (arguments - `(#:configure-flags - (list (string-append "--libdir=" (assoc-ref %outputs "lib") "/lib") - "--enable-app" ; build all the tools - "--enable-hpack-tools" ; ...all the tools - "--disable-examples" - "--disable-static" ; don't bother building .a files - ,@(if (%current-target-system) - '("--disable-python-bindings") - '())) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'break-circular-reference - ;; libnghttp2.pc by default retains a reference to the ‘out’ output, - ;; which is not allowed. Break this cycle. While we could install - ;; only the library to ‘out’ and move everything else to a separate - ;; output, this would inconvenience the majority of (human) users. - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "lib/libnghttp2.pc.in" - (("@prefix@") - (assoc-ref outputs "lib"))) - #t)) - (add-before 'check 'set-timezone-directory - (lambda* (#:key inputs native-inputs #:allow-other-keys) - (setenv "TZDIR" (string-append - (assoc-ref (or native-inputs inputs) "tzdata") - "/share/zoneinfo")) - #t))))) + (list + #:configure-flags + #~(list (string-append "--libdir=" #$output:lib "/lib") + "--enable-app" ; build all the tools + "--enable-hpack-tools" ; ...all the tools + "--disable-examples" + "--disable-static" ; don't bother building .a files + #$@(if (%current-target-system) + '("--disable-python-bindings") + '())) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'break-circular-reference + ;; libnghttp2.pc by default retains a reference to the ‘out’ output, + ;; which is not allowed. Break this cycle. While we could install + ;; only the library to ‘out’ and move everything else to a separate + ;; output, this would inconvenience the majority of (human) users. + (lambda _ + (substitute* "lib/libnghttp2.pc.in" + (("@prefix@") + #$output:lib)))) + (add-before 'check 'set-timezone-directory + (lambda* (#:key inputs native-inputs #:allow-other-keys) + (setenv "TZDIR" (search-input-directory + (or native-inputs inputs) + "share/zoneinfo"))))))) (home-page "https://nghttp2.org/") (synopsis "HTTP/2 protocol client, proxy, server, and library") (description @@ -7820,6 +7828,35 @@ compressed JSON header blocks. @end itemize\n") (license license:expat))) +;; Older variant for Node versions < 17 (upstream commit 43291b98edaa682 +;; add support for newer nghttp2, but is difficult to backport). +(define-public nghttp2-for-node + (hidden-package + (package + (inherit nghttp2) + (version "1.44.0") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/nghttp2/nghttp2/" + "releases/download/v" version "/" + "nghttp2-" version ".tar.xz")) + (sha256 + (base32 + "0p9wvva4g8hwj55x19rbyvnq2dbsnf65rphhxnpqs7ll54xlg6an")))) + (arguments + (substitute-keyword-arguments (package-arguments nghttp2) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-after 'unpack 'workaround-broken-python-version-check + (lambda _ + (substitute* "configure" + ;; The configure script uses a string comparison to + ;; determine whether the Python interpreter is recent + ;; enough, which fails when comparing 3.8 to 3.10. + ;; Convert to tuples for a more reliable check. + (("print \\(ver >= '3\\.8'\\)") + "print (tuple(map(int, ver.split('.'))) >= (3,8))"))))))))))) + (define-public hpcguix-web (package (name "hpcguix-web") diff --git a/gnu/packages/webkit.scm b/gnu/packages/webkit.scm index e5eafcb142..815105800b 100644 --- a/gnu/packages/webkit.scm +++ b/gnu/packages/webkit.scm @@ -292,8 +292,7 @@ propagated by default) such as @code{gst-plugins-good} and (replace "gtk+" gtk))) (inputs (modify-inputs (package-inputs webkitgtk) - (delete "libnotify") - (append pango-next))))) ;TODO: remove after it's the default + (delete "libnotify"))))) ;;; Required by e.g. emacs-next-pgtk, emacs-xwidgets, and some other GNOME ;;; packages for webkit2gtk-4.0. See also the upstream tracker for libsoup 3: diff --git a/gnu/packages/wget.scm b/gnu/packages/wget.scm index 083cf27212..17459344c0 100644 --- a/gnu/packages/wget.scm +++ b/gnu/packages/wget.scm @@ -46,15 +46,16 @@ (define-public wget (package (name "wget") - (version "1.21.3") + (version "1.21.3.24") (source (origin (method url-fetch) - (uri (string-append "mirror://gnu/wget/wget-" - version ".tar.lz")) + ;;(uri (string-append "mirror://gnu/wget/wget-" + ;; version ".tar.lz")) + (uri "https://www.multiprecision.org/wget-1.21.3.24-2b723.tar.lz") (sha256 (base32 - "19afmyr1i3zwdwr8wkyz8q6z5764ik3dm87as194g78l8xggplnv")))) + "17ip94mvax83h0gh4905jqc64g5qf3vgxr3bj9gn02pijjm5lzbp")))) (build-system gnu-build-system) (inputs (list gnutls libidn2 libpsl)) diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index 7c6cec38e7..f1fcc68d5f 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -45,7 +45,7 @@ ;;; Copyright © 2021 Sharlatan Hellseher <sharlatanus@gmail.com> ;;; Copyright © 2021 qblade <qblade@protonmail.com> ;;; Copyright © 2021 lasnesne <lasnesne@lagunposprasihopre.org> -;;; Copyright © 2021 Petr Hodina <phodina@protonmail.com> +;;; Copyright © 2021, 2022 Petr Hodina <phodina@protonmail.com> ;;; Copyright © 2021, 2023 jgart <jgart@dismail.de> ;;; Copyright © 2021 Disseminate Dissent <disseminatedissent@protonmail.com> ;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com> @@ -60,6 +60,8 @@ ;;; Copyright © 2022 Fredrik Salomonsson <plattfot@posteo.net> ;;; Copyright © 2022 ( <paren@disroot.org> ;;; Copyright © 2022 zamfofex <zamfofex@twdb.moe> +;;; Copyright © 2023 Gabriel Wicki <gabriel@erlikon.ch> +;;; Copyright © 2023 Jonathan Brielamier <jonathan.brielmaier@web.de> ;;; ;;; This file is part of GNU Guix. ;;; @@ -131,6 +133,7 @@ #:use-module (gnu packages man) #:use-module (gnu packages maths) #:use-module (gnu packages mpd) + #:use-module (gnu packages pciutils) #:use-module (gnu packages music) #:use-module (gnu packages pcre) #:use-module (gnu packages perl) @@ -1433,7 +1436,7 @@ project derived from the original Calm Window Manager.") (define-public dwl (package (name "dwl") - (version "0.2.1") + (version "0.3.1") (source (origin (method git-fetch) (uri (git-reference @@ -1442,7 +1445,7 @@ project derived from the original Calm Window Manager.") (file-name (git-file-name name version)) (sha256 (base32 - "0js8xjc2rx1ml6s58s90jrak5n7vh3kj5na2j4yy3qy0cb501xcm")))) + "0952kajc60ijy6qz14y6s5n7dyyf14ndzrhs4ynxj97k76742z2l")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; no tests @@ -1562,16 +1565,16 @@ functionality to display information about the most commonly used services.") (define-public wlroots (package (name "wlroots") - (version "0.14.1") + (version "0.16.1") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/swaywm/wlroots") + (url "https://gitlab.freedesktop.org/wlroots/wlroots") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1sshp3lvlkl1i670kxhwsb4xzxl8raz6769kqvgmxzcb63ns9ay1")))) + (base32 "11kcica9waj1a1xgbi12gif9z5z0b4xzycbcgawbgdmj77pws8sk")))) (build-system meson-build-system) (arguments `(#:phases @@ -1582,7 +1585,13 @@ functionality to display information about the most commonly used services.") (("Xwayland") (string-append (assoc-ref inputs "xorg-server-xwayland") "/bin/Xwayland"))) - #t))))) + #t)) + (add-before 'configure 'fix-meson-file + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "backend/drm/meson.build" + (("/usr/share/hwdata/pnp.ids") + (string-append (assoc-ref inputs "hwdata") + "/share/hwdata/pnp.ids")))))))) (propagated-inputs (list ;; As required by wlroots.pc. eudev @@ -1597,7 +1606,9 @@ functionality to display information about the most commonly used services.") xcb-util-wm xorg-server-xwayland)) (native-inputs - (list pkg-config)) + (list + `(,hwdata "pnp") + pkg-config)) (home-page "https://github.com/swaywm/wlroots") (synopsis "Pluggable, composable, unopinionated modules for building a Wayland compositor") @@ -1608,7 +1619,7 @@ modules for building a Wayland compositor.") (define-public sway (package (name "sway") - (version "1.6.1") + (version "1.8") (source (origin (method git-fetch) @@ -1617,7 +1628,7 @@ modules for building a Wayland compositor.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0j4sdbsrlvky1agacc0pcz9bwmaxjmrapjnzscbd2i0cria2fc5j")))) + (base32 "17dqr2lkmcv2ssp7vky27zw599i77whpb1aqh1s6kl8a8vkrz6mg")))) (build-system meson-build-system) (arguments `(;; elogind is propagated by wlroots -> libseat @@ -1646,6 +1657,7 @@ modules for building a Wayland compositor.") libinput-minimal libxkbcommon pango + pcre2 swaybg wayland wlroots)) @@ -1696,7 +1708,7 @@ modules for building a Wayland compositor.") (inputs (list cairo gdk-pixbuf libxkbcommon ;("linux-pam" ,linux-pam) ; FIXME: Doesn't work. wayland)) - (native-inputs (list pango pkg-config scdoc wayland-protocols-next)) + (native-inputs (list pango pkg-config scdoc wayland-protocols)) (home-page "https://github.com/swaywm/sway") (synopsis "Screen locking utility for Wayland compositors") (description "Swaylock is a screen locking utility for Wayland compositors.") @@ -1767,7 +1779,7 @@ display a clock or apply image manipulation techniques to the background image." pkg-config python-minimal scdoc - vala-next)) + vala)) (inputs (list json-glib glib @@ -2738,7 +2750,7 @@ shows a notification for the user on the screen.") (define-public cagebreak (package (name "cagebreak") - (version "1.8.0") + (version "2.0.1") (source (origin (method git-fetch) (uri (git-reference @@ -2747,13 +2759,18 @@ shows a notification for the user on the screen.") (file-name (git-file-name name version)) (sha256 (base32 - "0296mnzk7qd0zvnhw716jvpp7madjsar373ixx4qcff0m0jwfrxm")))) + "0fxfmxl7p63l07lqb83q5lx16hm0rixcidghx00gp08x2yrgr4x9")))) (build-system meson-build-system) - (arguments '(#:configure-flags '("-Dxwayland=true"))) - (native-inputs - (list pandoc pkg-config)) - (inputs - (list libevdev pango wlroots)) + (arguments + `(#:configure-flags '("-Dxwayland=true") + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-data-dir + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "meson.build" + (("/etc/") (string-append (assoc-ref outputs "out") "/etc")))))))) + (native-inputs (list pandoc pkg-config)) + (inputs (list libevdev pango wlroots)) (home-page "https://github.com/project-repo/cagebreak") (synopsis "Tiling wayland compositor inspired by ratpoison") (description @@ -2789,26 +2806,26 @@ read and write, and compatible with JSON.") (define-public hikari (package (name "hikari") - (version "2.3.2") + (version "2.3.3") (source (origin (method url-fetch) (uri (string-append "https://hikari.acmelabs.space/releases/" "hikari-" version ".tar.gz")) (sha256 - (base32 "1jvy21irh6s7czff2hk63spswqibjcjhrpsgmrki5bii9ddi73wy")))) + (base32 "1qjd9dhpmv75idf6jjzwff8wgliad4d0af8pih9526p14vrnyws0")))) (build-system gnu-build-system) (native-inputs (list bmake pkg-config wayland-protocols)) (inputs - `(("cairo" ,cairo) - ("libinput" ,libinput-minimal) - ("libucl" ,libucl) - ("libxkbcommon" ,libxkbcommon) - ("pam" ,linux-pam) - ("pango" ,pango) - ("wayland" ,wayland) - ("wlroots" ,wlroots))) + (list cairo + libinput-minimal + libucl + libxkbcommon + linux-pam + pango + wayland + wlroots)) (arguments `(#:tests? #f ; no tests #:make-flags diff --git a/gnu/packages/wxwidgets.scm b/gnu/packages/wxwidgets.scm index 5440a2725b..b226aa4e83 100644 --- a/gnu/packages/wxwidgets.scm +++ b/gnu/packages/wxwidgets.scm @@ -9,6 +9,7 @@ ;;; Copyright © 2018, 2020, 2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2019 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2022 Marius Bakke <marius@gnu.org> +;;; Copyright © 2023 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2023 Malte Frank Gerdes <malte.f.gerdes@gmail.com> ;;; ;;; This file is part of GNU Guix. @@ -306,7 +307,7 @@ and many other languages.") (native-inputs (list pkg-config python-waf)) (propagated-inputs - (list python-attrdict python-numpy python-pillow python-six)) + (list python-attrdict3 python-numpy python-pillow python-six)) (home-page "https://wxpython.org/") (synopsis "Cross platform GUI toolkit for Python") (description "wxPython is a cross-platform GUI toolkit for the Python diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm index 31770ac2ba..f4ddd15aaa 100644 --- a/gnu/packages/xdisorg.scm +++ b/gnu/packages/xdisorg.scm @@ -11,7 +11,7 @@ ;;; Copyright © 2015 Florian Paul Schmidt <mista.tapas@gmx.net> ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org> ;;; Copyright © 2016, 2018 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2016-2021, 2023 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016, 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2016 Petter <petter@mykolab.ch> @@ -502,14 +502,14 @@ avoiding password prompts when X11 forwarding has already been setup.") (define-public libxkbcommon (package (name "libxkbcommon") - (version "1.3.0") + (version "1.4.1") (source (origin - (method url-fetch) - (uri (string-append "https://xkbcommon.org/download/libxkbcommon-" - version ".tar.xz")) - (sha256 - (base32 - "0ysynzzgzd9jdrh1321r4bgw8wd5zljrlyn5y1a31g39xacf02bv")))) + (method url-fetch) + (uri (string-append "https://xkbcommon.org/download/libxkbcommon-" + version ".tar.xz")) + (sha256 + (base32 + "0fbb2dyjvf71p42y2jmwdcylsvj03w52f5rb23c2d00rwahhfg4l")))) (build-system meson-build-system) (inputs (list libx11 @@ -519,20 +519,17 @@ avoiding password prompts when X11 forwarding has already been setup.") wayland-protocols xkeyboard-config)) (native-inputs - (append (list bison doxygen pkg-config python) - (if (%current-target-system) - ;; wayland-scanner is required at build time. - ;; TODO: Remove this conditional on core-updates. - (list pkg-config-for-build wayland) - '()))) + (list bison doxygen pkg-config python + ;; wayland-scanner is required at build time. + wayland)) (arguments - `(#:configure-flags - (list (string-append "-Dxkb-config-root=" - (assoc-ref %build-inputs "xkeyboard-config") - "/share/X11/xkb") - (string-append "-Dx-locale-root=" - (assoc-ref %build-inputs "libx11") - "/share/X11/locale")))) + (list #:configure-flags + #~(list (string-append "-Dxkb-config-root=" + (search-input-directory + %build-inputs "share/X11/xkb")) + (string-append "-Dx-locale-root=" + (search-input-directory + %build-inputs "share/X11/locale"))))) (home-page "https://xkbcommon.org/") (synopsis "Library to handle keyboard descriptions") (description "Xkbcommon is a library to handle keyboard descriptions, @@ -713,7 +710,7 @@ rasterisation.") (define-public libdrm (package (name "libdrm") - (version "2.4.107") + (version "2.4.114") (source (origin (method url-fetch) (uri (string-append @@ -721,24 +718,24 @@ rasterisation.") version ".tar.xz")) (sha256 (base32 - "127qf1rzhaf13vdd75a58v5q34617hvangjlfnlkcdh37gqcwm65")))) + "09nhk3jx3qzggl5vyii3yh4zm0npjqsbxhzvxrg2xla77a2cyj9h")))) (build-system meson-build-system) (arguments - `(#:configure-flags - '(,@(match (%current-system) + (list #:configure-flags + (match (%current-system) ((or "armhf-linux" "aarch64-linux") - '("-Dexynos=true" - "-Domap=true" - "-Detnaviv=true" - "-Dtegra=true" - "-Dfreedreno-kgsl=true")) - (_ '()))) - - #:phases (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "meson" "test" "--timeout-multiplier" "5"))))))) + #~(list "-Dexynos=enabled" + "-Domap=enabled" + "-Detnaviv=enabled" + "-Dtegra=enabled" + "-Dfreedreno-kgsl=true")) + (_ ''())) + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "meson" "test" "--timeout-multiplier" "5"))))))) (propagated-inputs (list libpciaccess)) (native-inputs @@ -1998,8 +1995,6 @@ actions, a built-in clock, a battery monitor and a system tray.") (base32 "11bfi9his0cc5mzikamr5icv5mh2fyj9jy5l3sbbayj6jk51f68y")))) (build-system meson-build-system) - (arguments - (list #:meson meson-0.63)) ;requires meson 0.61 or later (native-inputs (list pkg-config)) (inputs (list cairo harfbuzz diff --git a/gnu/packages/xiph.scm b/gnu/packages/xiph.scm index 42bf5d5fb8..b47c718fb6 100644 --- a/gnu/packages/xiph.scm +++ b/gnu/packages/xiph.scm @@ -238,14 +238,14 @@ It currently supports: (define-public flac (package (name "flac") - (version "1.3.3") + (version "1.3.4") (source (origin (method url-fetch) (uri (string-append "https://downloads.xiph.org/releases/flac/flac-" version ".tar.xz")) (sha256 (base32 - "0j0p9sf56a2fm2hkjnf7x3py5ir49jyavg4q5zdyd7bcf6yq4gi1")))) + "0dz7am8kbc97a6afml1h4yp085274prg8j7csryds8m3fmz61w4g")))) (build-system gnu-build-system) (arguments `(#:parallel-tests? #f)) diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm index 0b26a63e85..2bc4f66c01 100644 --- a/gnu/packages/xml.scm +++ b/gnu/packages/xml.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> ;;; Copyright © 2015, 2016, 2017, 2018, 2020 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2015, 2016, 2017 Mark H Weaver <mhw@netris.org> -;;; Copyright © 2015, 2016, 2017, 2018, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2015-2018, 2020-2022 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2015 Raimon Grau <raimonster@gmail.com> ;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org> ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name> @@ -13,7 +13,7 @@ ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is> ;;; Copyright © 2016–2022 Tobias Geerinckx-Rice <me@tobias.gr> -;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2016-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com> ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net> ;;; Copyright © 2017 Alex Vong <alexvong1995@gmail.com> @@ -27,7 +27,7 @@ ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org> ;;; Copyright © 2020 Pierre Langlois <pierre.langlois@gmx.com> ;;; Copyright © 2021 Michael Rohleder <mike@rohleder.de> -;;; Copyright © 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2021, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Julien Lepiller <julien@lepiller.eu> ;;; Copyright © 2021 Felix Gruber <felgru@posteo.net> ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net> @@ -80,6 +80,7 @@ #:use-module (guix build-system meson) #:use-module (guix build-system perl) #:use-module (guix build-system python) + #:use-module (guix deprecation) #:use-module (guix utils) #:use-module (gnu packages linux) #:use-module (gnu packages pkg-config)) @@ -117,8 +118,7 @@ the entire document.") (define-public expat (package (name "expat") - (version "2.4.1") - (replacement expat/fixed) + (version "2.5.0") (source (let ((dot->underscore (lambda (c) (if (char=? #\. c) #\_ c)))) (origin (method url-fetch) @@ -130,7 +130,7 @@ the entire document.") "/expat-" version ".tar.xz"))) (sha256 (base32 - "0spvyb9d3hijs4ys3x64cfmilsynl8kv6clfahv8d4lvp86js0yg"))))) + "1gnwihpfz4x18rwd6cbrdggmfqjzwsdfh1gpmc0ph21c4gq2097g"))))) (build-system gnu-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -154,23 +154,6 @@ stream-oriented parser in which an application registers handlers for things the parser might find in the XML document (like start tags).") (license license:expat))) -(define expat/fixed - (package - (inherit expat) - (version "2.4.9") - (source (let ((dot->underscore (lambda (c) (if (char=? #\. c) #\_ c)))) - (origin - (method url-fetch) - (uri (list (string-append "mirror://sourceforge/expat/expat/" - version "/expat-" version ".tar.xz") - (string-append - "https://github.com/libexpat/libexpat/releases/download/R_" - (string-map dot->underscore version) - "/expat-" version ".tar.xz"))) - (sha256 - (base32 - "0m03zh7al39mx4rf0s2bgdn77r658qqf9k3a7bwx6z2wzql0g33f"))))))) - (define-public libebml (package (name "libebml") @@ -195,20 +178,19 @@ binary extension of XML for the purpose of storing and manipulating data in a hierarchical form with variable field lengths.") (license license:lgpl2.1))) +;; Note: Remember to check python-libxml2 when updating this package. (define-public libxml2 (package (name "libxml2") - (version "2.9.12") + (version "2.9.14") (source (origin (method url-fetch) - (uri (string-append "ftp://xmlsoft.org/libxml2/libxml2-" - version ".tar.gz")) + (uri (string-append "https://download.gnome.org/sources/libxml2/" + (version-major+minor version)"/libxml2-" + version ".tar.xz")) (sha256 (base32 - "14hxwzmf5xqppx77z7i0ni9lpzg1a84dqpf8j8l1fvy570g6imn8")) - (patches (search-patches "libxml2-parent-pointers.patch" - "libxml2-terminating-newline.patch" - "libxml2-xpath-recursion-limit.patch")))) + "1vnzk33wfms348lgz9pvkq9li7jm44pvm73lbr3w1khwgljlmmv0")))) (build-system gnu-build-system) (outputs '("out" "static" "doc")) (arguments @@ -224,7 +206,7 @@ hierarchical form with variable field lengths.") (for-each (lambda (dir) (rename-file (string-append src "/share/" dir) (string-append doc "/" dir))) - '("doc" "gtk-doc")) + '("gtk-doc")) (for-each (lambda (ar) (rename-file ar (string-append dst "/" (basename ar)))) @@ -267,6 +249,35 @@ project (but it is usable outside of the Gnome platform).") provides an @code{--xpath0} option to @command{xmllint} that enables it to output XPath results with a null delimiter."))) +(define-public python-libxml2 + (package/inherit libxml2 + (name "python-libxml2") + (source (origin + (inherit (package-source libxml2)) + (patches + (append (search-patches "python-libxml2-utf8.patch") + (origin-patches (package-source libxml2)))))) + (build-system python-build-system) + (outputs '("out")) + (arguments + (list + ;; XXX: Tests are specified in 'Makefile.am', but not in 'setup.py'. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'configure + (lambda* (#:key inputs #:allow-other-keys) + (chdir "python") + (let ((libxml2-headers (search-input-directory + inputs "include/libxml2"))) + (substitute* "setup.py" + ;; The build system ignores C_INCLUDE_PATH & co, so + ;; provide the absolute directory name. + (("/opt/include") + (dirname libxml2-headers))))))))) + (inputs (list libxml2)) + (synopsis "Python bindings for the libxml2 library"))) + (define-public libxlsxwriter (package (name "libxlsxwriter") @@ -309,68 +320,51 @@ formulas and hyperlinks to multiple worksheets in an Excel 2007+ XLSX file.") (license (list license:bsd-2 license:public-domain)))) ; third_party/md5 -(define-public python-libxml2 - (package/inherit libxml2 - (name "python-libxml2") - (source (origin - (inherit (package-source libxml2)) - (patches - (append (search-patches "python-libxml2-utf8.patch") - (origin-patches (package-source libxml2)))))) - (build-system python-build-system) - (outputs '("out")) - (arguments - `(;; XXX: Tests are specified in 'Makefile.am', but not in 'setup.py'. - #:tests? #f - #:phases - (modify-phases %standard-phases - (add-before - 'build 'configure - (lambda* (#:key inputs #:allow-other-keys) - (chdir "python") - (let ((glibc (assoc-ref inputs ,(if (%current-target-system) - "cross-libc" "libc"))) - (libxml2 (assoc-ref inputs "libxml2"))) - (substitute* "setup.py" - ;; For 'libxml2/libxml/tree.h'. - (("ROOT = r'/usr'") - (format #f "ROOT = r'~a'" libxml2)) - ;; For 'iconv.h'. - (("/opt/include") - (string-append glibc "/include"))))))))) - (inputs `(("libxml2" ,libxml2))) - (synopsis "Python bindings for the libxml2 library"))) - (define-public libxslt (package (name "libxslt") - (version "1.1.34") + (version "1.1.37") (source (origin (method url-fetch) - (uri (string-append "ftp://xmlsoft.org/libxslt/libxslt-" - version ".tar.gz")) + (uri (string-append "https://download.gnome.org/sources" + "/libxslt/" (version-major+minor version) + "/libxslt-" version ".tar.xz")) (sha256 (base32 - "0zrzz6kjdyavspzik6fbkpvfpbd25r2qg6py5nnjaabrsr3bvccq")) + "1d1s2bk0m6d7bzml9w90ycl0jlpcy4v07595cwaddk17h3f2fjrs")) (patches (search-patches "libxslt-generated-ids.patch")))) (build-system gnu-build-system) (arguments - `(#:phases (modify-phases %standard-phases - (add-before 'check 'disable-fuzz-tests - (lambda _ - ;; Disable libFuzzer tests, because they require - ;; instrumentation builds of libxml2 and libxslt. - (substitute* "tests/Makefile" - (("exslt plugins fuzz") - "exslt plugins")) - #t))))) + (list #:phases + #~(modify-phases %standard-phases + (add-before 'check 'disable-fuzz-tests + (lambda _ + ;; Disable libFuzzer tests, because they require + ;; instrumentation builds of libxml2 and libxslt. + (substitute* "tests/Makefile" + (("exslt plugins fuzz") + "exslt plugins")) + ;; Also disable Python tests since they require + ;; python-libxml2 which would introduce a + ;; circular dependency. + (substitute* "python/Makefile" + (("cd tests && \\$\\(MAKE\\) tests") + "$(info Python tests are disabled by Guix.)"))))) + #:configure-flags + (if (%current-target-system) + ;; 'configure.ac' uses 'AM_PATH_PYTHON', which looks for + ;; 'python' in $PATH and tries to run it. Skip all that when + ;; cross-compiling. + #~'("--without-python") + #~'()))) (home-page "http://xmlsoft.org/XSLT/index.html") (synopsis "C library for applying XSLT stylesheets to XML documents") - (inputs `(("libgcrypt" ,libgcrypt) - ("libxml2" ,libxml2) - ("python" ,python-minimal-wrapper) - ("zlib" ,zlib) - ("xz" ,xz))) + (inputs + (list libgcrypt + libxml2 + python-minimal-wrapper + zlib + xz)) (native-inputs (list pkg-config)) (description @@ -1747,60 +1741,46 @@ modular implementation of XML-RPC for C and C++.") (outputs '("out" "doc")) (build-system gnu-build-system) (native-inputs - `(("docbook-xml" ,docbook-xml-4.1.2) - ("docbook-xsl" ,docbook-xsl) - ("libxml2" ,libxml2) ;for XML_CATALOG_DIR - ("xmlto" ,xmlto) - ;; Dependencies to regenerate the 'configure' script. - ("autoconf" ,autoconf) - ("automake" ,automake) - ("gettext" ,gettext-minimal) - ("libtool" ,libtool))) + (list docbook-xml-4.1.2 + docbook-xsl + libxml2 ;for XML_CATALOG_DIR + xmlto + ;; Dependencies to regenerate the 'configure' script. + autoconf + automake + gettext-minimal + libtool)) (arguments - `( ;; Note: we cannot use '--enable-full-doc-build' as this would require - ;; Openjade, which in turn requires this package. + (list + ;; Note: we cannot use '--enable-full-doc-build' as this would require + ;; Openjade, which in turn requires this package. - ;; Skip the tests that are known to fail (see: - ;; https://sourceforge.net/p/openjade/mailman/message/6182316/) - #:make-flags '("TESTS_THAT_FAIL=") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-docbook-paths - (lambda* (#:key inputs #:allow-other-keys) - (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml") - "/xml/dtd/docbook")) - (xsldoc (string-append (assoc-ref inputs "docbook-xsl") - "/xml/xsl/docbook-xsl-" - ,(package-version docbook-xsl)))) - (substitute* (find-files "docsrc" "\\.xml$") - (("/usr/share/sgml/docbook/xml-dtd-4.1.2") xmldoc) - (("http://.*/docbookx\\.dtd") - (string-append xmldoc "/docbookx.dtd"))) - #t))) - (add-after 'patch-docbook-paths 'delete-configure - ;; The configure script in the release was made with an older - ;; Autoconf and lacks support for the `--docdir' option. - (lambda _ - (delete-file "configure") - #t)) - (add-after 'delete-configure 'honor-docdir - ;; docdir is not honored due to being hardcoded in the various - ;; Makefile.am (see: https://sourceforge.net/p/openjade/bugs/147/). - (lambda _ - (substitute* '("Makefile.am" "doc/Makefile.am" "docsrc/Makefile.am") - (("^docdir = .*") "docdir = @docdir@\n")) - #t)) - (add-after 'delete-configure 'fix-tests-makefile.am - ;; Remove the trailing $(SHELL) from the TESTS_ENVIRONMENT variable - ;; definition. Otherwise, when targets are built using - ;; "$(am__check_pre) $(LOG_DRIVER) [...]", there would be two - ;; $(SHELL) expansion which fails the build. - (lambda _ - (substitute* "tests/Makefile.am" - (("^\tOSGMLNORM=`echo osgmlnorm\\|sed '\\$\\(transform\\)'`\\\\") - "\tOSGMLNORM=`echo osgmlnorm|sed '$(transform)'`") - (("^\t\\$\\(SHELL\\)\n") "")) - #t))))) + ;; Skip the tests that are known to fail (see: + ;; https://sourceforge.net/p/openjade/mailman/message/6182316/) + #:make-flags #~(list "TESTS_THAT_FAIL=") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'delete-configure + ;; The configure script in the release was made with an older + ;; Autoconf and lacks support for the `--docdir' option. + (lambda _ + (delete-file "configure"))) + (add-after 'delete-configure 'honor-docdir + ;; docdir is not honored due to being hardcoded in the various + ;; Makefile.am (see: https://sourceforge.net/p/openjade/bugs/147/). + (lambda _ + (substitute* '("Makefile.am" "doc/Makefile.am" "docsrc/Makefile.am") + (("^docdir = .*") "docdir = @docdir@\n")))) + (add-after 'delete-configure 'fix-tests-makefile.am + ;; Remove the trailing $(SHELL) from the TESTS_ENVIRONMENT variable + ;; definition. Otherwise, when targets are built using + ;; "$(am__check_pre) $(LOG_DRIVER) [...]", there would be two + ;; $(SHELL) expansion which fails the build. + (lambda _ + (substitute* "tests/Makefile.am" + (("^\tOSGMLNORM=`echo osgmlnorm\\|sed '\\$\\(transform\\)'`\\\\") + "\tOSGMLNORM=`echo osgmlnorm|sed '$(transform)'`") + (("^\t\\$\\(SHELL\\)\n") ""))))))) ;; $SGML_CATALOG_FILES lists 'catalog' or 'CATALOG' or '*.cat' files found ;; under the 'sgml' sub-directory of any given package. (native-search-paths (list (search-path-specification @@ -1853,26 +1833,20 @@ because lxml.etree already has its own implementation of XPath 1.0.") (define-public python-lxml (package (name "python-lxml") - (version "4.6.3") + (version "4.9.1") (source (origin (method url-fetch) (uri (pypi-uri "lxml" version)) (sha256 - (base32 "0s14r1w2x9sdlcsw8mxiqgw4rz5zs5lpqpxrfyn4a1mkndqqbdrr")) - ;; Adapt a test to libxml2 2.9.12, taken from this commit: - ;; https://github.com/lxml/lxml/commit/852ed1092bd80b6b9a51db24371047e - (modules '((guix build utils))) - (snippet - '(substitute* "src/lxml/tests/test_etree.py" - (("self\\.assertEqual\\(\\{'hha': None\\}, el\\.nsmap\\)") - "self.assertEqual({}, el.nsmap)"))))) + (base32 "0grczyrrq2rbwhvpri15cyhv330s494vbz3js3jky8xp5c2rnx7y")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check - (lambda _ - (invoke "make" "test")))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "make" "test"))))))) (inputs (list libxml2 libxslt)) (home-page "https://lxml.de/") @@ -1882,17 +1856,8 @@ because lxml.etree already has its own implementation of XPath 1.0.") libxml2 and libxslt.") (license license:bsd-3))) ; and a few more, see LICENSES.txt -(define-public python-lxml-4.7 - (package - (inherit python-lxml) - (version "4.7.1") - (source - (origin - (inherit (package-source python-lxml)) - (uri (pypi-uri "lxml" version)) - (sha256 - (base32 - "090viyanaki4q7w7i000xl0qh4in52bkl3qal55sz2bbm8w3hqd1")))))) +(define-deprecated python-lxml-4.7 python-lxml) +(export python-lxml-4.7) (define-public python-untangle ;; The latest tagged release is from 2014; use the latest commit. diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm index 203d6d8d2e..f3d30c0ff1 100644 --- a/gnu/packages/xorg.scm +++ b/gnu/packages/xorg.scm @@ -11,7 +11,7 @@ ;;; Copyright © 2016 Alex Kost <alezost@gmail.com> ;;; Copyright © 2016 David Craven <david@craven.ch> ;;; Copyright © 2016, 2017 John Darrington <jmd@gnu.org> -;;; Copyright © 2017, 2018, 2019, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2017-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com> ;;; Copyright © 2017, 2020 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2018–2022 Tobias Geerinckx-Rice <me@tobias.gr> @@ -86,7 +86,6 @@ #:use-module (gnu packages inkscape) #:use-module (gnu packages image) #:use-module (gnu packages imagemagick) - #:use-module (gnu packages libbsd) #:use-module (gnu packages libedit) #:use-module (gnu packages linux) #:use-module (gnu packages llvm) @@ -242,14 +241,14 @@ which can be read by any architecture.") (define-public xorgproto (package (name "xorgproto") - (version "2021.5") + (version "2022.2") (source (origin (method url-fetch) - (uri (string-append "ftp://ftp.freedesktop.org/pub/xorg//individual/proto/" - "xorgproto-" version ".tar.bz2")) + (uri (string-append "mirror://xorg/individual/proto" + "/xorgproto-" version ".tar.xz")) (sha256 (base32 - "05d0kib351qmnlfimaznaw0220fr0ym7fx2gn9h2jqxxilxncbxa")))) + "17kbq1x68jl9mz69ays5c0w72lpkqi937raxk0im7y88pvrdn4sx")))) (build-system gnu-build-system) (propagated-inputs ;; To get util-macros in (almost?) all package inputs. @@ -1274,8 +1273,7 @@ with the Cygwin XWin server when running X11 in a rootless mode.") (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-static"))) - (inputs - (list libbsd xorgproto)) + (inputs (list xorgproto)) (native-inputs (list pkg-config)) (home-page "https://www.x.org/wiki/") @@ -1286,7 +1284,7 @@ with the Cygwin XWin server when running X11 in a rootless mode.") (define-public libxft (package (name "libxft") - (version "2.3.3") + (version "2.3.4") (source (origin (method url-fetch) @@ -1296,15 +1294,15 @@ with the Cygwin XWin server when running X11 in a rootless mode.") ".tar.bz2")) (sha256 (base32 - "05lja9s54090xwh31r0bqms4v3pimng5xr09g2rdnafx2vk6hp12")))) + "1pdbr6gzfvixc791pjf42i9gg8wvfq6cpq6sdca04h4i42mxmpjp")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-static"))) (propagated-inputs ;; xft.pc refers to all these. - `(("libxrender" ,libxrender) - ("freetype" ,freetype) - ("fontconfig" ,fontconfig))) + (list libxrender + freetype + fontconfig)) (inputs (list libx11 xorgproto)) (native-inputs @@ -2038,7 +2036,7 @@ emulate a TI-30 or an HP-10C.") (define-public xcb-proto (package (name "xcb-proto") - (version "1.14") + (version "1.15.2") (source (origin (method url-fetch) @@ -2047,17 +2045,10 @@ emulate a TI-30 or an HP-10C.") version ".tar.xz")) (sha256 (base32 - "01d62r286yfc3rpz714nqdgkl0wk9j0wqkd4ylas1d7r4vmkqshq")) - (modules '((guix build utils))) - (snippet - '(begin - ;; fractions.gcd has been deprecated since python-3.5. - (substitute* "xcbgen/align.py" - (("from fractions import gcd") "from math import gcd")) - #t)))) + "1vak6q53abwxnkfn6by7j24m48kd2iy7jnskkqzzx8l0ysqvwwkh")))) (build-system gnu-build-system) (native-inputs - `(("pkg-config" ,pkg-config) ("python" ,python-minimal-wrapper))) + (list pkg-config python-minimal-wrapper)) (home-page "https://xcb.freedesktop.org/") (synopsis "XML-XCB protocol descriptions") (description @@ -3718,25 +3709,18 @@ extension to the X11 protocol. It includes: (define-public xkeyboard-config (package (name "xkeyboard-config") - (version "2.34") - (source - (origin - (method url-fetch) - (uri (string-append - "ftp://ftp.freedesktop.org/pub/xorg//individual/data/xkeyboard-config/xkeyboard-config-" - version - ".tar.bz2")) - (sha256 - (base32 - "1kmq2ykwmh10sd6155gml4jhdxmvsll6xdg7zw86czpfhrvd48dk")))) - (build-system gnu-build-system) - (inputs - (list libx11 xkbcomp-intermediate)) - (native-inputs - `(("gettext" ,gettext-minimal) - ("perl" ,perl) - ("pkg-config" ,pkg-config) - ("python" ,python))) + (version "2.38") + (source (origin + (method url-fetch) + (uri (string-append + "ftp://ftp.freedesktop.org/pub/xorg//individual/data/xkeyboard-config/" + "xkeyboard-config-" version ".tar.xz")) + (sha256 + (base32 + "0wn8asnbz111194ksi2mysa6ikn4kqgd9rpfydl8icc6mcdsk406")))) + (build-system meson-build-system) + (inputs (list libx11 xkbcomp-intermediate)) + (native-inputs (list gettext-minimal libxslt perl pkg-config python)) (home-page "https://www.x.org/wiki/") (synopsis "Xorg XKB configuration files") (description @@ -4534,17 +4518,17 @@ protocol and arbitrary X extension protocol.") (define-public libxv (package (name "libxv") - (version "1.0.11") + (version "1.0.12") (source (origin (method url-fetch) (uri (string-append "mirror://xorg/individual/lib/libXv-" version - ".tar.bz2")) + ".tar.xz")) (sha256 (base32 - "125hn06bd3d8y97hm2pbf5j55gg4r2hpd3ifad651i4sr7m16v6j")))) + "0j1qqrhbhdi3kqz0am5i1lhs31ql9pbc14z41w0a5xw9yq4zmxxa")))) (build-system gnu-build-system) (arguments `(#:configure-flags '(,@(malloc0-flags) "--disable-static"))) @@ -4661,8 +4645,7 @@ common definitions and porting layer.") '(#:configure-flags '("--disable-static"))) (propagated-inputs (list xorgproto)) - (inputs - (list libbsd xtrans)) + (inputs (list xtrans)) (native-inputs (list pkg-config)) (home-page "https://www.x.org/wiki/") @@ -4673,17 +4656,16 @@ common definitions and porting layer.") (define-public libxau (package (name "libxau") - (version "1.0.9") + (version "1.0.10") (source (origin (method url-fetch) (uri (string-append "mirror://xorg/individual/lib/libXau-" - version - ".tar.bz2")) + version ".tar.xz")) (sha256 (base32 - "1v3krc6x0zliaa66qq1bf9j60x5nqfy68v8axaiglxpnvgqcpy6c")))) + "02hc3azypiiahr9y1cyn0mqc5zd997hh3h0rp7jqfbsd6f9g5rlb")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-static"))) @@ -4834,17 +4816,15 @@ new API's in libXft, or the legacy API's in libX11.") (define-public libxvmc (package (name "libxvmc") - (version "1.0.12") + (version "1.0.13") (source - (origin - (method url-fetch) - (uri (string-append - "mirror://xorg/individual/lib/libXvMC-" - version - ".tar.bz2")) - (sha256 - (base32 - "1kbdjsvkm5l7axv7g477qj18sab2wnqhliy6197syzizgfbsfgbb")))) + (origin + (method url-fetch) + (uri (string-append "mirror://xorg/individual/lib/libXvMC-" + version ".tar.xz")) + (sha256 + (base32 + "0z35xqna3dnrfxgn9aa1y6jx7mrwsn8vi8dcwm3sg23qx9nvx7ha")))) (build-system gnu-build-system) (arguments `(#:configure-flags '(,@(malloc0-flags) "--disable-static"))) @@ -4894,7 +4874,7 @@ protocol.") (define-public libxcb (package (name "libxcb") - (version "1.14") + (version "1.15") (source (origin (method url-fetch) @@ -4902,7 +4882,7 @@ protocol.") "libxcb-" version ".tar.xz")) (sha256 (base32 - "0d2chjgyn5lr9sfhacfvqgnj9l9faz11vn322a06jd6lk3dxcpm5")))) + "0nd035rf83xf531cnjzsf9ykb5w9rdzz6bbyhi683xkwh57p8f6c")))) (build-system gnu-build-system) (outputs '("out" "doc")) ;5.5 MiB of man pages (propagated-inputs @@ -4910,8 +4890,7 @@ protocol.") (inputs (list xcb-proto libxslt)) (native-inputs - `(("pkg-config" ,pkg-config) - ("python" ,python-minimal-wrapper))) + (list pkg-config python-minimal-wrapper)) (arguments `(#:configure-flags (list "--enable-xkb" "--disable-static" @@ -5256,7 +5235,7 @@ Wayland.") (define-public libx11 (package (name "libx11") - (version "1.7.3.1") + (version "1.8.1") (source (origin (method url-fetch) @@ -5264,7 +5243,7 @@ Wayland.") "/individual/lib/libX11-" version ".tar.xz")) (sha256 (base32 - "1289nvs52q9fnp7zl30bdpbvqggnjjb39vy0zll511zvcrr43z9g")))) + "1xyry8i7zqmlkvpbyyqwi18rrdw6ycczlvfp63rh2570pfhimi0v")))) (build-system gnu-build-system) (outputs '("out" "doc")) ;8 MiB of man pages + XML @@ -5291,17 +5270,15 @@ Wayland.") (define-public libxcursor (package (name "libxcursor") - (version "1.2.0") + (version "1.2.1") (source (origin (method url-fetch) - (uri (string-append - "mirror://xorg/individual/lib/libXcursor-" - version - ".tar.bz2")) + (uri (string-append "mirror://xorg/individual/lib/libXcursor-" + version ".tar.xz")) (sha256 (base32 - "10l7c9fm0jmpkm9ab9dz8r6m1pr87vvgqjnbx1psz50h4pwfklrs")))) + "011195an3w4xld3x0dr534kar1xjf52q96hmf0hgvfhh2rrl7ha6")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--disable-static"))) diff --git a/gnu/packages/zig.scm b/gnu/packages/zig.scm index 6d6b7ec4b4..c2f92e04e7 100644 --- a/gnu/packages/zig.scm +++ b/gnu/packages/zig.scm @@ -21,6 +21,7 @@ (define-module (gnu packages zig) #:use-module (guix packages) + #:use-module (guix utils) #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system cmake) @@ -40,7 +41,8 @@ (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1sh5xjsksl52i4cfv1qj36sz5h0ln7cq4pdhgs3960mk8a90im7b")))) + (base32 "1sh5xjsksl52i4cfv1qj36sz5h0ln7cq4pdhgs3960mk8a90im7b")) + (patches (search-patches "zig-do-not-link-against-librt.patch")))) (build-system cmake-build-system) (inputs (list clang-15 ; Clang propagates llvm. @@ -57,14 +59,18 @@ (%current-target-system)) '()) (string-append "-DZIG_TARGET_MCPU=baseline") + "-DZIG_SHARED_LLVM=ON" (string-append "-DZIG_LIB_DIR=" (assoc-ref %outputs "out") "/lib/zig")) #:validate-runpath? #f ; TODO: zig binary can't find ld-linux. #:out-of-source? #f ; for tests #:phases (modify-phases %standard-phases - (add-after 'configure 'set-cache-dir - (lambda _ + (add-after 'unpack 'set-env-variables + (lambda* (#:key inputs native-inputs #:allow-other-keys) + ;; Set CC, since the stage 2 zig relies on it to find the libc + ;; installation, and otherwise silently links against its own. + (setenv "CC" ,(cc-for-target)) ;; Set cache dir, otherwise Zig looks for `$HOME/.cache'. (setenv "ZIG_GLOBAL_CACHE_DIR" (string-append (getcwd) "/zig-cache")))) @@ -130,7 +136,8 @@ toolchain. Among other features it provides (file-name (git-file-name name version)) (sha256 (base32 "0nfvgg23sw50ksy0z0ml6lkdsvmd0278mq29m23dbb2jsirkhry7")) - (patches (search-patches "zig-use-system-paths.patch")))) + (patches (search-patches "zig-use-system-paths.patch" + "zig-do-not-link-against-librt.patch")))) (inputs (list clang-13 ; Clang propagates llvm. lld-13)) diff --git a/gnu/services/cups.scm b/gnu/services/cups.scm index 2e86845e51..8543c51b0d 100644 --- a/gnu/services/cups.scm +++ b/gnu/services/cups.scm @@ -99,6 +99,15 @@ (define (serialize-comma-separated-string-list field-name val) (serialize-field field-name (string-join val ","))) +;; A special case of the above, where we don't want to emit anything at all +;; when #f, to allow CUPS to pick a default we cannot compute ourselves. +;; XXX Ideally, this could be a generic higher-order function, but it's used +;; only once so far: for ready-paper-sizes to handle "Auto" default-paper-size. +(define (comma-separated-string-list-or-#f? val) + (if val (comma-separated-string-list? val) #t)) +(define (serialize-comma-separated-string-list-or-#f field-name val) + (if val (serialize-field field-name (string-join val ",")) #f)) + (define (space-separated-string-list? val) (and (list? val) (and-map (lambda (x) @@ -143,7 +152,7 @@ (define-enumerated-field-type browse-local-protocols (all dnssd none)) (define-enumerated-field-type default-auth-type - (Basic Negotiate)) + (Basic)) (define-enumerated-field-type default-encryption (Never IfRequested Required)) (define-enumerated-field-type error-policy @@ -514,10 +523,10 @@ requests.") "Specifies whether to purge job history data automatically when it is no longer required for quotas.") (browse-dns-sd-sub-types - (comma-separated-string-list (list "_cups")) + (comma-separated-string-list (list "_cups" "_print" "_universal")) "Specifies a list of DNS-SD sub-types to advertise for each shared printer. -For example, @samp{\"_cups\" \"_print\"} will tell network clients that both -CUPS sharing and IPP Everywhere are supported.") +The default @samp{(list \"_cups\" \"_print\" \"_universal\")} tells clients +that CUPS sharing, IPP Everywhere, AirPrint, and Mopria are supported.") (browse-local-protocols (browse-local-protocols 'dnssd) "Specifies which protocols to use for local printer sharing.") @@ -527,16 +536,6 @@ CUPS sharing and IPP Everywhere are supported.") (browsing? (boolean #f) "Specifies whether shared printers are advertised.") - (classification - (string "") - "Specifies the security classification of the server. -Any valid banner name can be used, including \"classified\", \"confidential\", -\"secret\", \"topsecret\", and \"unclassified\", or the banner can be omitted -to disable secure printing functions.") - (classify-override? - (boolean #f) - "Specifies whether users may override the classification (cover page) of -individual print jobs using the @code{job-sheets} option.") (default-auth-type (default-auth-type 'Basic) "Specifies the default type of authentication to use.") @@ -583,10 +582,6 @@ the scheduler to printing a single job at any time.") "Specifies the scheduling priority of filters that are run to print a job. The nice value ranges from 0, the highest priority, to 19, the lowest priority.") - ;; Add this option if the package is built with Kerberos support. - ;; (gss-service-name - ;; (string "http") - ;; "Specifies the service name when using Kerberos authentication.") (host-name-lookups (host-name-lookups #f) "Specifies whether to do reverse lookups on connecting clients. @@ -595,7 +590,7 @@ resolved from the address matches one of the addresses returned for that hostname. Double lookups also prevent clients with unregistered addresses from connecting to your server. Only set this option to @code{#t} or @code{double} if absolutely required.") - ;; Add this option if the package is built with launchd/systemd support. + ;; Add this option if the package is built with socket activation support. ;; (idle-exit-timeout ;; (non-negative-integer 60) ;; "Specifies the length of time to wait before shutting down due to @@ -630,13 +625,6 @@ address enclosed in brackets, an IPv4 address, or @code{*} to indicate all addresses. Values can also be file names of local UNIX domain sockets. The Listen directive is similar to the Port directive but allows you to restrict access to specific interfaces or networks.") - (listen-back-log - (non-negative-integer 128) - "Specifies the number of pending connections that will be allowed. This -normally only affects very busy servers that have reached the MaxClients -limit, but can also be triggered by large numbers of simultaneous connections. -When the limit is reached, the operating system will refuse additional -connections until the scheduler can accept the pending ones.") (location-access-controls (location-access-control-list (list (location-access-control @@ -695,7 +683,7 @@ printer. A value of 0 allows up to MaxJobs jobs per printer.") (max-jobs-per-user (non-negative-integer 0) "Specifies the maximum number of simultaneous jobs that are allowed per -user. A value of 0 allows up to MaxJobs jobs per user.") +user. A value of 0 allows up to @code{max-jobs} jobs per user.") (max-job-time (non-negative-integer 10800) "Specifies the maximum time a job may take to print before it is canceled, @@ -704,39 +692,29 @@ in seconds. Set to 0 to disable cancellation of \"stuck\" jobs.") (non-negative-integer 1048576) "Specifies the maximum size of the log files before they are rotated, in bytes. The value 0 disables log rotation.") + (max-subscriptions + (non-negative-integer 100) + "Specifies the maximum number of simultaneous event subscriptions that are +allowed. Set to @samp{0} to allow an unlimited number of subscriptions.") + (max-subscriptions-per-job + (non-negative-integer 0) + "Specifies the maximum number of simultaneous event subscriptions that are +allowed per job. A value of @samp{0} allows up to @code{max-subscriptions} +per job.") + (max-subscriptions-per-printer + (non-negative-integer 0) + "Specifies the maximum number of simultaneous event subscriptions that are +allowed per printer. A value of @samp{0} allows up to @code{max-subscriptions} +per printer.") + (max-subscriptions-per-user + (non-negative-integer 0) + "Specifies the maximum number of simultaneous event subscriptions that are +allowed per user. A value of @samp{0} allows up to @code{max-subscriptions} +per user.") (multiple-operation-timeout (non-negative-integer 900) "Specifies the maximum amount of time to allow between files in a multiple file print job, in seconds.") - (page-log-format - (string "") - "Specifies the format of PageLog lines. Sequences beginning with -percent (@samp{%}) characters are replaced with the corresponding information, -while all other characters are copied literally. The following percent -sequences are recognized: - -@table @samp -@item %% -insert a single percent character -@item %@{name@} -insert the value of the specified IPP attribute -@item %C -insert the number of copies for the current page -@item %P -insert the current page number -@item %T -insert the current date and time in common log format -@item %j -insert the job ID -@item %p -insert the printer name -@item %u -insert the username -@end table - -A value of the empty string disables page logging. The string @code{%p %u %j -%T %P %C %@{job-billing@} %@{job-originating-host-name@} %@{job-name@} -%@{media@} %@{sides@}} creates a page log with the standard items.") (environment-variables (environment-variables '()) "Passes the specified environment variable(s) to child processes; a list of @@ -794,13 +772,18 @@ indefinitely.") If a numeric value is specified, the job history is preserved for the indicated number of seconds after printing. If @code{#t}, the job history is preserved until the MaxJobs limit is reached.") + (ready-paper-sizes + (comma-separated-string-list-or-#f #f) + "Specifies a list of potential paper sizes that are reported as ready, +that is: loaded. The actual list will contain only the sizes that each +printer supports. If @code{#f}, CUPS will assume +@samp{(list \"Letter\" \"Legal\" \"Tabloid\" \"4x6\" \"Env10\")} +if the default paper size is \"Letter\", and +@samp{(list \"A3\" \"A4\" \"A5\" \"A6\" \"EnvDL\")} otherwise.") (reload-timeout (non-negative-integer 30) "Specifies the amount of time to wait for job completion before restarting the scheduler.") - (rip-cache - (string "128m") - "Specifies the maximum amount of memory to use when converting documents into bitmaps for a printer.") (server-admin (string "root@localhost.localdomain") "Specifies the email address of the server administrator.") diff --git a/gnu/services/dbus.scm b/gnu/services/dbus.scm index e9c9346f56..5a0c634393 100644 --- a/gnu/services/dbus.scm +++ b/gnu/services/dbus.scm @@ -321,19 +321,10 @@ tuples, are all set as environment variables when the bus daemon launches it." polkit-configuration make-polkit-configuration polkit-configuration? (polkit polkit-configuration-polkit ;file-like - (default %default-polkit)) + (default polkit)) (actions polkit-configuration-actions ;list of file-like (default '()))) -(define %default-polkit - ;; The default polkit package. - (let-system (system target) - ;; Since mozjs depends on Rust, which is currently x86_64-only, use - ;; polkit-duktape on other systems. - (if (string-prefix? "x86_64-" (or target system)) - polkit-mozjs - polkit-duktape))) - (define %polkit-accounts (list (user-group (name "polkitd") (system? #t)) (user-account diff --git a/gnu/services/security-token.scm b/gnu/services/security-token.scm index 52afad84a6..2356273398 100644 --- a/gnu/services/security-token.scm +++ b/gnu/services/security-token.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net> +;;; Copyright © 2018, 2022 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2020 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2021 Brice Waegeneire <brice@waegenei.re> ;;; @@ -74,12 +74,7 @@ '((guix build utils))) #~(begin (use-modules (guix build utils)) - ;; XXX: We can't use (guix utils) because it requires a - ;; dynamically-linked Guile, hence the duplicate switch-symlinks. - (define (switch-symlinks link target) - (let ((pivot (string-append link ".new"))) - (symlink target pivot) - (rename-file pivot link))) + (mkdir-p "/var/lib") (switch-symlinks "/var/lib/pcsc" #$(directory-union diff --git a/gnu/system.scm b/gnu/system.scm index c17c6e4e98..50a3bac7e4 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -885,7 +885,7 @@ of PROVENANCE-SERVICE-TYPE to its services." (define %base-packages-utils ;; Default set of utilities packages. (cons* procps psmisc which - (@ (gnu packages admin) shadow-with-man-pages) ;for 'passwd' + shadow ;for 'passwd' e2fsprogs ;for lsattr, chattr, etc. diff --git a/gnu/system/hurd.scm b/gnu/system/hurd.scm index 20dc4ae735..558d1ee9e3 100644 --- a/gnu/system/hurd.scm +++ b/gnu/system/hurd.scm @@ -68,7 +68,7 @@ ;; Note: the Shepherd comes before the Hurd, not just because its duty is to ;; shepherd the herd, but also because we want its 'halt' and 'reboot' ;; commands to take precedence. - (list shepherd hurd bash coreutils file findutils grep sed + (list shepherd-0.8 hurd bash coreutils file findutils grep sed diffutils patch gawk tar gzip bzip2 xz lzip guile-3.0-latest guile-colorized guile-readline net-base inetutils less shadow sudo which diff --git a/gnu/system/locale.scm b/gnu/system/locale.scm index b209b9b9cf..6895b209dc 100644 --- a/gnu/system/locale.scm +++ b/gnu/system/locale.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2014, 2015, 2016, 2017, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2014-2017, 2019-2021, 2023 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2018 Mark H Weaver <mhw@netris.org> ;;; ;;; This file is part of GNU Guix. @@ -147,7 +147,7 @@ data format changes between libc versions." (define %default-locale-libcs ;; The libcs for which we build locales by default. - (list glibc)) + (list glibc-2.33 glibc)) (define %default-locale-definitions ;; Arbitrary set of locales that are built by default. They are here mostly diff --git a/gnu/system/pam.scm b/gnu/system/pam.scm index 2574e019f1..b635681642 100644 --- a/gnu/system/pam.scm +++ b/gnu/system/pam.scm @@ -21,6 +21,7 @@ #:use-module (guix derivations) #:use-module (guix gexp) #:use-module (gnu services) + #:use-module (gnu system setuid) #:use-module (ice-9 match) #:use-module (srfi srfi-1) #:use-module (srfi srfi-9) @@ -375,8 +376,13 @@ strings or string-valued gexps." (define pam-root-service-type (service-type (name 'pam) - (extensions (list (service-extension etc-service-type - /etc-entry))) + (extensions + (list (service-extension + setuid-program-service-type + (lambda (_) + (list (file-like->setuid-program + (file-append linux-pam "/sbin/unix_chkpwd"))))) + (service-extension etc-service-type /etc-entry))) ;; Arguments include <pam-service> as well as procedures. (compose concatenate) |