···262262 fi
263263264264 # Get rid of some "fixed" header files
265265- rm -rfv $out/lib/gcc/*/*/include-fixed/{root,linux,sys/mount.h}
265265+ rm -rfv $out/lib/gcc/*/*/include-fixed/{root,linux,sys/mount.h,bits/statx.h}
266266267267 # Replace hard links for i686-pc-linux-gnu-gcc etc. with symlinks.
268268 for i in $out/bin/*-gcc*; do
···11-{ stdenv, lib, fetchurl, fetchpatch, libiconv, xz, bash }:
11+{ stdenv, lib, fetchurl, fetchpatch, libiconv, xz, bash
22+, gnulib
33+}:
2435# Note: this package is used for bootstrapping fetchurl, and thus
46# cannot use fetchpatch! All mutable patches (generated by GitHub or
···4547 '' + lib.optionalString stdenv.hostPlatform.isCygwin ''
4648 sed -i -e "s/\(cldr_plurals_LDADD = \)/\\1..\/gnulib-lib\/libxml_rpl.la /" gettext-tools/src/Makefile.in
4749 sed -i -e "s/\(libgettextsrc_la_LDFLAGS = \)/\\1..\/gnulib-lib\/libxml_rpl.la /" gettext-tools/src/Makefile.in
5050+ '' +
5151+ # This change to gettext's vendored copy of gnulib is already
5252+ # merged upstream; we can drop this patch on the next version
5353+ # bump. It must be applied twice because gettext vendors gnulib
5454+ # not once, but twice!
5555+ ''
5656+ patch -p2 -d gettext-tools/gnulib-lib/ < ${gnulib.passthru.longdouble-redirect-patch}
5757+ patch -p2 -d gettext-tools/libgrep/ < ${gnulib.passthru.longdouble-redirect-patch}
4858 '';
49595060 strictDeps = true;
+7
pkgs/development/libraries/glibc/default.nix
···6363 # Same for musl: https://github.com/NixOS/nixpkgs/issues/78805
6464 "-Wno-error=missing-attributes"
6565 ])
6666+ (lib.optionals (stdenv.hostPlatform.isPower64) [
6767+ # Do not complain about the Processor Specific ABI (i.e. the
6868+ # choice to use IEEE-standard `long double`). We pass this
6969+ # flag in order to mute a `-Werror=psabi` passed by glibc;
7070+ # hopefully future glibc releases will not pass that flag.
7171+ "-Wno-error=psabi"
7272+ ])
6673 ]);
6774 };
6875
+5-5
pkgs/development/libraries/gnu-config/default.nix
···11{ lib, stdenv, fetchurl }:
2233let
44- rev = "6faca61810d335c7837f320733fe8e15a1431fc2";
44+ rev = "63acb96f92473ceb5e21d873d7c0aee266b3d6d3";
5566 # Don't use fetchgit as this is needed during Aarch64 bootstrapping
77 configGuess = fetchurl {
88 url = "https://git.savannah.gnu.org/cgit/config.git/plain/config.guess?id=${rev}";
99- sha256 = "06wkkhpbx9slmknr2g7mcd8x3zsdhnmmay25l31h3rkdp1wkq7kx";
99+ sha256 = "049qgfh4xjd4fxd7ygm1phd5faqphfvhfcv8dsdldprsp86lf55v";
1010 };
1111 configSub = fetchurl {
1212 url = "https://git.savannah.gnu.org/cgit/config.git/plain/config.sub?id=${rev}";
1313- sha256 = "1qkph8cqanmgy3s4a18bm1a4vk62i8pf8cy5pc1hkpqwn4g6l0di";
1313+ sha256 = "1rk30y27mzls49wyfdb5jhzjr08hkxl7xqhnxmhcmkvqlmpsjnxl";
1414 };
1515in stdenv.mkDerivation {
1616 pname = "gnu-config";
1717- version = "2021-01-25";
1717+ version = "2023-01-21";
18181919 buildCommand = ''
2020 mkdir -p $out
···3434 # configuration script generated by Autoconf, you may include it under
3535 # the same distribution terms that you use for the rest of that
3636 # program.
3737- maintainers = [ maintainers.dezgeg ];
3737+ maintainers = with maintainers; [ dezgeg emilytrau ];
3838 platforms = platforms.all;
3939 };
4040}
···11-{ lib, stdenv, fetchurl, buildPackages, perl, coreutils
11+{ lib, stdenv, fetchurl, buildPackages, perl, coreutils, writeShellScript
22+, makeWrapper
23, withCryptodev ? false, cryptodev
34, withZlib ? false, zlib
45, enableSSL2 ? false
56, enableSSL3 ? false
67, enableKTLS ? stdenv.isLinux
78, static ? stdenv.hostPlatform.isStatic
88-# Used to avoid cross compiling perl, for example, in darwin bootstrap tools.
99-# This will cause c_rehash to refer to perl via the environment, but otherwise
1010-# will produce a perfectly functional openssl binary and library.
1111-, withPerl ? stdenv.hostPlatform == stdenv.buildPlatform
129# path to openssl.cnf file. will be placed in $etc/etc/ssl/openssl.cnf to replace the default
1310, conf ? null
1411, removeReferencesTo
···7269 !(stdenv.hostPlatform.useLLVM or false) &&
7370 stdenv.cc.isGNU;
74717575- nativeBuildInputs = [ perl ]
7272+ nativeBuildInputs = [ makeWrapper perl ]
7673 ++ lib.optionals static [ removeReferencesTo ];
7774 buildInputs = lib.optional withCryptodev cryptodev
7878- # perl is included to allow the interpreter path fixup hook to set the
7979- # correct interpreter in c_rehash.
8080- ++ lib.optional withPerl perl
8175 ++ lib.optional withZlib zlib;
82768377 # TODO(@Ericson2314): Improve with mass rebuild
···172166173167 # 'etc' is a separate output on static builds only.
174168 etc=$out
175175- '') + lib.optionalString (!stdenv.hostPlatform.isWindows)
176176- # Fix bin/c_rehash's perl interpreter line
177177- #
178178- # - openssl 1_0_2: embeds a reference to buildPackages.perl
179179- # - openssl 1_1: emits "#!/usr/bin/env perl"
180180- #
181181- # In the case of openssl_1_0_2, reset the invalid reference and let the
182182- # interpreter hook take care of it.
183183- #
184184- # In both cases, if withPerl = false, the intepreter line is expected be
185185- # "#!/usr/bin/env perl"
186186- ''
187187- substituteInPlace $out/bin/c_rehash --replace ${buildPackages.perl}/bin/perl "/usr/bin/env perl"
188188- '' + ''
169169+ '') + ''
189170 mkdir -p $bin
190171 mv $out/bin $bin/bin
172172+173173+ # c_rehash is a legacy perl script with the same functionality
174174+ # as `openssl rehash`
175175+ # this wrapper script is created to maintain backwards compatibility without
176176+ # depending on perl
177177+ makeWrapper $bin/bin/openssl $bin/bin/c_rehash \
178178+ --add-flags "rehash"
191179192180 mkdir $dev
193181 mv $out/include $dev/
···11{ lib, stdenv, fetchurl, buildPackages, perl, coreutils, fetchFromGitHub
22+, makeWrapper
23, withCryptodev ? false, cryptodev
34, enableSSL2 ? false
45, enableSSL3 ? false
56, static ? stdenv.hostPlatform.isStatic
66-# Used to avoid cross compiling perl, for example, in darwin bootstrap tools.
77-# This will cause c_rehash to refer to perl via the environment, but otherwise
88-# will produce a perfectly functional openssl binary and library.
99-, withPerl ? stdenv.hostPlatform == stdenv.buildPlatform
107, removeReferencesTo
118}:
129···5249 !(stdenv.hostPlatform.useLLVM or false) &&
5350 stdenv.cc.isGNU;
54515555- nativeBuildInputs = [ perl removeReferencesTo ];
5656- buildInputs = lib.optional withCryptodev cryptodev
5757- # perl is included to allow the interpreter path fixup hook to set the
5858- # correct interpreter in c_rehash.
5959- ++ lib.optional withPerl perl;
5252+ nativeBuildInputs = [ makeWrapper perl removeReferencesTo ];
5353+ buildInputs = lib.optional withCryptodev cryptodev;
60546155 # TODO(@Ericson2314): Improve with mass rebuild
6256 configurePlatforms = [];
···140134 if [ -n "$(echo $out/lib/*.so $out/lib/*.dylib $out/lib/*.dll)" ]; then
141135 rm "$out/lib/"*.a
142136 fi
143143- '') + lib.optionalString (!stdenv.hostPlatform.isWindows)
144144- # Fix bin/c_rehash's perl interpreter line
145145- #
146146- # - openssl 1_0_2: embeds a reference to buildPackages.perl
147147- # - openssl 1_1: emits "#!/usr/bin/env perl"
148148- #
149149- # In the case of openssl_1_0_2, reset the invalid reference and let the
150150- # interpreter hook take care of it.
151151- #
152152- # In both cases, if withPerl = false, the intepreter line is expected be
153153- # "#!/usr/bin/env perl"
154154- ''
155155- substituteInPlace $out/bin/c_rehash --replace ${buildPackages.perl}/bin/perl "/usr/bin/env perl"
156156- '' + ''
137137+ '') + ''
157138 mkdir -p $bin
158139 mv $out/bin $bin/bin
140140+141141+ # c_rehash is a legacy perl script with the same functionality
142142+ # as `openssl rehash`
143143+ # this wrapper script is created to maintain backwards compatibility without
144144+ # depending on perl
145145+ makeWrapper $bin/bin/openssl $bin/bin/c_rehash \
146146+ --add-flags "rehash"
147147+159148 mkdir $dev
160149 mv $out/include $dev/
161150 # remove dependency on Perl at runtime
···2626 # do not change headers to not update all vendored build files
2727 dontFixup = true;
28282929+ passthru = {
3030+ # This patch is used by multiple other packages (currently:
3131+ # gnused, gettext) which contain vendored copies of gnulib.
3232+ # Without it, compilation will fail with error messages about
3333+ # "__LDBL_REDIR1_DECL" or similar on platforms with longdouble
3434+ # redirects (currently powerpc64). Once all of those other
3535+ # packages make a release with a newer gnulib we can drop this
3636+ # patch.
3737+ longdouble-redirect-patch = ./gnulib-longdouble-redirect.patch;
3838+ };
3939+2940 meta = with lib; {
3041 description = "Central location for code to be shared among GNU packages";
3142 homepage = "https://www.gnu.org/software/gnulib/";
···11import ./common.nix {
22- version = "7.0.2";
33- sha256 = "sha256-8hHsMmE4PhqJ5FVak7nQF/6Ae5w5kvst/0hx2ubaVK0=";
22+ version = "7.0.3";
33+ sha256 = "sha256-dLQg0J1/Uo6E+XqjMPDdaamKYFPnpOAXZ+7RFQOIB78=";
44}
+9
pkgs/development/tools/misc/texinfo/common.nix
···11{ version, sha256, patches ? [] }:
2233{ lib, stdenv, buildPackages, fetchurl, perl, xz, libintl, bash
44+, gnulib
4556# we are a dependency of gcc, this simplifies bootstraping
67, interactive ? false, ncurses, procps
···30313132 postPatch = ''
3233 patchShebangs tp/maintain
3434+ ''
3535+ # This patch is needed for IEEE-standard long doubles on
3636+ # powerpc64; it does not apply cleanly to texinfo 5.x or
3737+ # earlier. It is merged upstream in texinfo 6.8.
3838+ + lib.optionalString (version == "6.7") ''
3939+ patch -p1 -d gnulib < ${gnulib.passthru.longdouble-redirect-patch}
3340 '';
34413542 # ncurses is required to build `makedoc'
···8289 license = licenses.gpl3Plus;
8390 platforms = platforms.all;
8491 maintainers = with maintainers; [ vrthra oxij ];
9292+ # see comment above in patches section
9393+ broken = stdenv.hostPlatform.isPower64 && lib.strings.versionOlder version "6.0";
85948695 longDescription = ''
8796 Texinfo is the official documentation format of the GNU project.
···11-Executables in src/ directory are built from source files in src/
22-and are linked to libauparse, with both src/auditd-config.c and
33-auparse/auditd-config.c defining "free_config" function.
44-55-It is known (although obscure) behaviour of shared libraries that
66-symbol defined in binary itself overrides symbol in shared library;
77-with static linkage it expectedly results in multiple definition
88-error.
99-1010-This set of fixes explicitly marks libauparse versions of
1111-conflicting functions as weak to have behaviour coherent with
1212-dynamic linkage version -- definitions in src/ overriding definition
1313-in auparse/.
1414-1515-Still, this architecture is very strange and confusing.
1616-1717-diff -r -U5 audit-2.8.5-orig/auparse/auditd-config.c audit-2.8.5/auparse/auditd-config.c
1818---- audit-2.8.5-orig/auparse/auditd-config.c 2019-03-01 20:19:13.000000000 +0000
1919-+++ audit-2.8.5/auparse/auditd-config.c 2021-01-13 11:36:12.716226498 +0000
2020-@@ -68,10 +68,11 @@
2121- };
2222-2323- /*
2424- * Set everything to its default value
2525- */
2626-+#pragma weak clear_config
2727- void clear_config(struct daemon_conf *config)
2828- {
2929- config->local_events = 1;
3030- config->qos = QOS_NON_BLOCKING;
3131- config->sender_uid = 0;
3232-@@ -322,10 +323,11 @@
3333- if (config->log_file == NULL)
3434- return 1;
3535- return 0;
3636- }
3737-3838-+#pragma weak free_config
3939- void free_config(struct daemon_conf *config)
4040- {
4141- free((void*)config->log_file);
4242- }
4343-4444-diff -r -U5 audit-2.8.5-orig/auparse/interpret.c audit-2.8.5/auparse/interpret.c
4545---- audit-2.8.5-orig/auparse/interpret.c 2019-03-01 20:19:13.000000000 +0000
4646-+++ audit-2.8.5/auparse/interpret.c 2021-01-13 11:39:42.107217224 +0000
4747-@@ -545,10 +545,11 @@
4848- else
4949- snprintf(buf, size, "unknown(%d)", uid);
5050- return buf;
5151- }
5252-5353-+#pragma weak aulookup_destroy_uid_list
5454- void aulookup_destroy_uid_list(void)
5555- {
5656- if (uid_cache_created == 0)
5757- return;
5858-5959-@@ -2810,10 +2811,11 @@
6060-6161- /*
6262- * This is the main entry point for the auparse library. Call chain is:
6363- * auparse_interpret_field -> nvlist_interp_cur_val -> interpret
6464- */
6565-+#pragma weak interpret
6666- const char *interpret(const rnode *r, auparse_esc_t escape_mode)
6767- {
6868- const nvlist *nv = &r->nv;
6969- int type;
7070- idata id;
7171-diff -r -U5 audit-2.8.5-orig/auparse/nvlist.c audit-2.8.5/auparse/nvlist.c
7272---- audit-2.8.5-orig/auparse/nvlist.c 2019-02-04 14:26:52.000000000 +0000
7373-+++ audit-2.8.5/auparse/nvlist.c 2021-01-13 11:37:37.190222757 +0000
7474-@@ -27,10 +27,11 @@
7575- #include "nvlist.h"
7676- #include "interpret.h"
7777- #include "auparse-idata.h"
7878-7979-8080-+#pragma weak nvlist_create
8181- void nvlist_create(nvlist *l)
8282- {
8383- l->head = NULL;
8484- l->cur = NULL;
8585- l->cnt = 0;
8686-@@ -47,17 +48,19 @@
8787- while (node->next)
8888- node = node->next;
8989- l->cur = node;
9090- }
9191-9292-+#pragma weak nvlist_next
9393- nvnode *nvlist_next(nvlist *l)
9494- {
9595- if (l->cur)
9696- l->cur = l->cur->next;
9797- return l->cur;
9898- }
9999-100100-+#pragma weak nvlist_append
101101- void nvlist_append(nvlist *l, nvnode *node)
102102- {
103103- nvnode* newnode = malloc(sizeof(nvnode));
104104-105105- newnode->name = node->name;
106106-@@ -141,10 +144,11 @@
107107- if (l->cur->interp_val)
108108- return l->cur->interp_val;
109109- return interpret(r, escape_mode);
110110- }
111111-112112-+#pragma weak nvlist_clear
113113- void nvlist_clear(nvlist* l)
114114- {
115115- nvnode* nextnode;
116116- register nvnode* current;
117117-118118-diff -r -U5 audit-2.8.5-orig/auparse/strsplit.c audit-2.8.5/auparse/strsplit.c
119119---- audit-2.8.5-orig/auparse/strsplit.c 2019-03-01 21:15:30.000000000 +0000
120120-+++ audit-2.8.5/auparse/strsplit.c 2021-01-13 11:38:04.306221556 +0000
121121-@@ -54,10 +54,11 @@
122122- return NULL;
123123- return s;
124124- }
125125- }
126126-127127-+#pragma weak audit_strsplit
128128- char *audit_strsplit(char *s)
129129- {
130130- static char *str = NULL;
131131- char *ptr;
132132-133133-diff -r -U5 audit-2.8.5-orig/lib/strsplit.c audit-2.8.5/lib/strsplit.c
134134---- audit-2.8.5-orig/lib/strsplit.c 2019-03-01 20:19:13.000000000 +0000
135135-+++ audit-2.8.5/lib/strsplit.c 2021-01-13 11:38:29.444220443 +0000
136136-@@ -23,10 +23,11 @@
137137-138138- #include <string.h>
139139- #include "libaudit.h"
140140- #include "private.h"
141141-142142-+#pragma weak audit_strsplit_r
143143- char *audit_strsplit_r(char *s, char **savedpp)
144144- {
145145- char *ptr;
146146-147147- if (s)
+1
pkgs/os-specific/linux/bcc/default.nix
···4040 "-DENABLE_USDT=ON"
4141 "-DENABLE_CPP_API=ON"
4242 "-DCMAKE_USE_LIBBPF_PACKAGE=ON"
4343+ "-DENABLE_LIBDEBUGINFOD=OFF"
4344 ];
44454546 # to replace this executable path:
+1
pkgs/os-specific/linux/kernel/common-config.nix
···904904905905 REGULATOR = yes; # Voltage and Current Regulator Support
906906 RC_DEVICES = option yes; # Enable IR devices
907907+ RC_DECODERS = option yes; # Required for IR devices to work
907908908909 RT2800USB_RT53XX = yes;
909910 RT2800USB_RT55XX = yes;
···9191 moveToOutput 'bin/h5pcc' "''${!outputDev}"
9292 '';
93939494+ # Remove reference to /build, which get introduced
9595+ # into AM_CPPFLAGS since hdf5-1.14.0. Cmake of various
9696+ # packages using HDF5 gets confused trying access the non-existent path.
9797+ postFixup = ''
9898+ for i in h5cc h5pcc h5c++; do
9999+ if [ -f $dev/bin/$i ]; then
100100+ substituteInPlace $dev/bin/$i --replace \
101101+ '-I/build/hdf5-${version}/src/H5FDsubfiling' ""
102102+ fi
103103+ done
104104+ '';
105105+106106+ enableParallelBuilding = true;
107107+94108 passthru.tests = {
95109 inherit (python3.pkgs) h5py;
96110 };
971119898- meta = {
112112+ meta = with lib; {
99113 description = "Data model, library, and file format for storing and managing data";
100114 longDescription = ''
101115 HDF5 supports an unlimited variety of datatypes, and is designed for flexible and efficient
···103117 applications to evolve in their use of HDF5. The HDF5 Technology suite includes tools and
104118 applications for managing, manipulating, viewing, and analyzing data in the HDF5 format.
105119 '';
106106- license = lib.licenses.bsd3; # Lawrence Berkeley National Labs BSD 3-Clause variant
120120+ license = licenses.bsd3; # Lawrence Berkeley National Labs BSD 3-Clause variant
121121+ maintainers = [ maintainers.markuskowa ];
107122 homepage = "https://www.hdfgroup.org/HDF5/";
108108- platforms = lib.platforms.unix;
123123+ platforms = platforms.unix;
109124 };
110125}
···11-From 1c9cc97e9d47d73763810dcb4a36b6cdf31a2254 Mon Sep 17 00:00:00 2001
22-From: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
33-Date: Sun, 30 Jun 2019 11:54:35 -0400
44-Subject: [PATCH] dirmngr: Only use SKS pool CA for SKS pool
55-66-* dirmngr/http.c (http_session_new): when checking whether the
77-keyserver is the HKPS pool, check specifically against the pool name,
88-as ./configure might have been used to select a different default
99-keyserver. It makes no sense to apply Kristian's certificate
1010-authority to anything other than the literal host
1111-hkps.pool.sks-keyservers.net.
1212-1313-Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
1414-GnuPG-Bug-Id: 4593
1515----
1616- dirmngr/http.c | 2 +-
1717- 1 file changed, 1 insertion(+), 1 deletion(-)
1818-1919-diff --git a/dirmngr/http.c b/dirmngr/http.c
2020-index 384f2569d..8e5d53939 100644
2121---- a/dirmngr/http.c
2222-+++ b/dirmngr/http.c
2323-@@ -767,7 +767,7 @@ http_session_new (http_session_t *r_session,
2424-2525- is_hkps_pool = (intended_hostname
2626- && !ascii_strcasecmp (intended_hostname,
2727-- get_default_keyserver (1)));
2828-+ "hkps.pool.sks-keyservers.net"));
2929-3030- /* If the user has not specified a CA list, and they are looking
3131- * for the hkps pool from sks-keyservers.net, then default to
3232---
3333-2.22.0
3434-
+104
pkgs/tools/security/gnupg/22.nix
···11+{ lib, stdenv, fetchurl, buildPackages
22+, pkg-config, texinfo
33+, gettext, libassuan, libgcrypt, libgpg-error, libiconv, libksba, npth
44+, adns, bzip2, gnutls, libusb1, openldap, readline, sqlite, zlib
55+, enableMinimal ? false
66+, withPcsc ? !enableMinimal, pcsclite
77+, guiSupport ? stdenv.isDarwin, pinentry
88+}:
99+1010+assert guiSupport -> enableMinimal == false;
1111+1212+stdenv.mkDerivation rec {
1313+ pname = "gnupg";
1414+ version = "2.2.41";
1515+1616+ src = fetchurl {
1717+ url = "mirror://gnupg/gnupg/${pname}-${version}.tar.bz2";
1818+ hash = "sha256-E/MpEAel6FRvy3vAxmEM5EqqmzmVBZ1PgUW6Cf1b4+E=";
1919+ };
2020+2121+ depsBuildBuild = [ buildPackages.stdenv.cc ];
2222+ nativeBuildInputs = [ pkg-config texinfo ];
2323+ buildInputs = [
2424+ gettext libassuan libgcrypt libgpg-error libiconv libksba npth
2525+ ] ++ lib.optionals (!enableMinimal) [
2626+ adns bzip2 gnutls libusb1 openldap readline sqlite zlib
2727+ ];
2828+2929+ patches = [
3030+ ./fix-libusb-include-path.patch
3131+ ./tests-add-test-cases-for-import-without-uid.patch
3232+ ./accept-subkeys-with-a-good-revocation-but-no-self-sig.patch
3333+ ./22-allow-import-of-previously-known-keys-even-without-UI.patch
3434+ ];
3535+3636+ postPatch = ''
3737+ sed -i 's,hkps://hkps.pool.sks-keyservers.net,hkps://keys.openpgp.org,g' configure doc/dirmngr.texi doc/gnupg.info-1
3838+ # Fix broken SOURCE_DATE_EPOCH usage - remove on the next upstream update
3939+ sed -i 's/$SOURCE_DATE_EPOCH/''${SOURCE_DATE_EPOCH}/' doc/Makefile.am
4040+ sed -i 's/$SOURCE_DATE_EPOCH/''${SOURCE_DATE_EPOCH}/' doc/Makefile.in
4141+ '' + lib.optionalString (stdenv.isLinux && withPcsc) ''
4242+ sed -i 's,"libpcsclite\.so[^"]*","${lib.getLib pcsclite}/lib/libpcsclite.so",g' scd/scdaemon.c
4343+ '';
4444+4545+ configureFlags = [
4646+ "--with-libgpg-error-prefix=${libgpg-error.dev}"
4747+ "--with-libgcrypt-prefix=${libgcrypt.dev}"
4848+ "--with-libassuan-prefix=${libassuan.dev}"
4949+ "--with-ksba-prefix=${libksba.dev}"
5050+ "--with-npth-prefix=${npth}"
5151+ ]
5252+ ++ lib.optional guiSupport "--with-pinentry-pgm=${pinentry}/${pinentry.binaryPath or "bin/pinentry"}"
5353+ ++ lib.optional stdenv.isDarwin "--disable-ccid-driver";
5454+5555+ postInstall = if enableMinimal
5656+ then ''
5757+ rm -r $out/{libexec,sbin,share}
5858+ for f in $(find $out/bin -type f -not -name gpg)
5959+ do
6060+ rm $f
6161+ done
6262+ '' else ''
6363+ mkdir -p $out/lib/systemd/user
6464+ for f in doc/examples/systemd-user/*.{service,socket} ; do
6565+ substitute $f $out/lib/systemd/user/$(basename $f) \
6666+ --replace /usr/bin $out/bin
6767+ done
6868+6969+ # add gpg2 symlink to make sure git does not break when signing commits
7070+ ln -s $out/bin/gpg $out/bin/gpg2
7171+7272+ # Make libexec tools available in PATH
7373+ for f in $out/libexec/; do
7474+ if [[ "$(basename $f)" == "gpg-wks-client" ]]; then continue; fi
7575+ ln -s $f $out/bin/$(basename $f)
7676+ done
7777+7878+ ln -s -t $out/bin $out/libexec/*
7979+ '';
8080+8181+ enableParallelBuilding = true;
8282+8383+ passthru.tests.connman = lib.nixosTests.gnupg;
8484+8585+ meta = with lib; {
8686+ homepage = "https://gnupg.org";
8787+ description = "LTS release of the GNU Privacy Guard, a GPL OpenPGP implementation";
8888+ license = licenses.gpl3Plus;
8989+ longDescription = ''
9090+ The GNU Privacy Guard is the GNU project's complete and free
9191+ implementation of the OpenPGP standard as defined by RFC4880. GnuPG
9292+ "modern" (2.1) is the latest development with a lot of new features.
9393+ GnuPG allows to encrypt and sign your data and communication, features a
9494+ versatile key management system as well as access modules for all kind of
9595+ public key directories. GnuPG, also known as GPG, is a command line tool
9696+ with features for easy integration with other applications. A wealth of
9797+ frontend applications and libraries are available. Version 2 of GnuPG
9898+ also provides support for S/MIME.
9999+ '';
100100+ maintainers = with maintainers; [ fpletz vrthra ];
101101+ platforms = platforms.all;
102102+ mainProgram = "gpg";
103103+ };
104104+}
···11+From: Vincent Breitmoser <look@my.amazin.horse>
22+Date: Thu, 13 Jun 2019 21:27:42 +0200
33+Subject: gpg: allow import of previously known keys, even without UIDs
44+55+* g10/import.c (import_one): Accept an incoming OpenPGP certificate that
66+has no user id, as long as we already have a local variant of the cert
77+that matches the primary key.
88+99+--
1010+1111+This fixes two of the three broken tests in import-incomplete.scm.
1212+1313+GnuPG-Bug-id: 4393
1414+Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
1515+---
1616+ g10/import.c | 44 +++++++++++---------------------------------
1717+ 1 file changed, 11 insertions(+), 33 deletions(-)
1818+1919+2020+diff --git a/g10/import.c b/g10/import.c
2121+index 9fab46ca6..61896a6bf 100644
2222+--- a/g10/import.c
2323++++ b/g10/import.c
2424+@@ -1954,7 +1954,6 @@ import_one_real (ctrl_t ctrl,
2525+ size_t an;
2626+ char pkstrbuf[PUBKEY_STRING_SIZE];
2727+ int merge_keys_done = 0;
2828+- int any_filter = 0;
2929+ KEYDB_HANDLE hd = NULL;
3030+3131+ if (r_valid)
3232+@@ -1992,13 +1991,6 @@ import_one_real (ctrl_t ctrl,
3333+ }
3434+3535+3636+- if (!uidnode)
3737+- {
3838+- if (!silent)
3939+- log_error( _("key %s: no user ID\n"), keystr_from_pk(pk));
4040+- return 0;
4141+- }
4242+-
4343+ if (screener && screener (keyblock, screener_arg))
4444+ {
4545+ log_error (_("key %s: %s\n"), keystr_from_pk (pk),
4646+@@ -2078,18 +2070,10 @@ import_one_real (ctrl_t ctrl,
4747+ }
4848+ }
4949+5050+- /* Delete invalid parts and bail out if there are no user ids left. */
5151+- if (!delete_inv_parts (ctrl, keyblock, keyid, options, otherrevsigs))
5252+- {
5353+- if (!silent)
5454+- {
5555+- log_error ( _("key %s: no valid user IDs\n"), keystr_from_pk(pk));
5656+- if (!opt.quiet)
5757+- log_info(_("this may be caused by a missing self-signature\n"));
5858+- }
5959+- stats->no_user_id++;
6060+- return 0;
6161+- }
6262++ /* Delete invalid parts, and note if we have any valid ones left.
6363++ * We will later abort import if this key is new but contains
6464++ * no valid uids. */
6565++ delete_inv_parts (ctrl, keyblock, keyid, options, otherrevsigs);
6666+6767+ /* Get rid of deleted nodes. */
6868+ commit_kbnode (&keyblock);
6969+@@ -2099,24 +2083,11 @@ import_one_real (ctrl_t ctrl,
7070+ {
7171+ apply_keep_uid_filter (ctrl, keyblock, import_filter.keep_uid);
7272+ commit_kbnode (&keyblock);
7373+- any_filter = 1;
7474+ }
7575+ if (import_filter.drop_sig)
7676+ {
7777+ apply_drop_sig_filter (ctrl, keyblock, import_filter.drop_sig);
7878+ commit_kbnode (&keyblock);
7979+- any_filter = 1;
8080+- }
8181+-
8282+- /* If we ran any filter we need to check that at least one user id
8383+- * is left in the keyring. Note that we do not use log_error in
8484+- * this case. */
8585+- if (any_filter && !any_uid_left (keyblock))
8686+- {
8787+- if (!opt.quiet )
8888+- log_info ( _("key %s: no valid user IDs\n"), keystr_from_pk (pk));
8989+- stats->no_user_id++;
9090+- return 0;
9191+ }
9292+9393+ /* The keyblock is valid and ready for real import. */
9494+@@ -2174,6 +2145,13 @@ import_one_real (ctrl_t ctrl,
9595+ err = 0;
9696+ stats->skipped_new_keys++;
9797+ }
9898++ else if (err && !any_uid_left (keyblock))
9999++ {
100100++ if (!silent)
101101++ log_info( _("key %s: new key but contains no user ID - skipped\n"), keystr(keyid));
102102++ err = 0;
103103++ stats->no_user_id++;
104104++ }
105105+ else if (err) /* Insert this key. */
106106+ {
107107+ /* Note: ERR can only be NO_PUBKEY or UNUSABLE_PUBKEY. */
···1616 g10/import.c | 44 +++++++++++---------------------------------
1717 1 file changed, 11 insertions(+), 33 deletions(-)
18181919+1920diff --git a/g10/import.c b/g10/import.c
2020-index 5d3162c..f9acf95 100644
2121+index cd3363fc7..8f10771db 100644
2122--- a/g10/import.c
2223+++ b/g10/import.c
2323-@@ -1788,7 +1788,6 @@ import_one_real (ctrl_t ctrl,
2424+@@ -1858,7 +1858,6 @@ import_one_real (ctrl_t ctrl,
2425 size_t an;
2526 char pkstrbuf[PUBKEY_STRING_SIZE];
2627 int merge_keys_done = 0;
···2829 KEYDB_HANDLE hd = NULL;
29303031 if (r_valid)
3131-@@ -1825,14 +1824,6 @@ import_one_real (ctrl_t ctrl,
3232- log_printf ("\n");
3232+@@ -1896,13 +1895,6 @@ import_one_real (ctrl_t ctrl,
3333 }
34343535--
3636-- if (!uidnode)
3535+3636+- if (!uidnode )
3737- {
3838- if (!silent)
3939- log_error( _("key %s: no user ID\n"), keystr_from_pk(pk));
···4343 if (screener && screener (keyblock, screener_arg))
4444 {
4545 log_error (_("key %s: %s\n"), keystr_from_pk (pk),
4646-@@ -1907,18 +1898,10 @@ import_one_real (ctrl_t ctrl,
4646+@@ -1977,18 +1969,10 @@ import_one_real (ctrl_t ctrl,
4747 }
4848 }
49495050- /* Delete invalid parts and bail out if there are no user ids left. */
5151-- if (!delete_inv_parts (ctrl, keyblock, keyid, options))
5151+- if (!delete_inv_parts (ctrl, keyblock, keyid, options, otherrevsigs))
5252- {
5353- if (!silent)
5454- {
5555-- log_error ( _("key %s: no valid user IDs\n"), keystr_from_pk(pk));
5656-- if (!opt.quiet)
5555+- log_error( _("key %s: no valid user IDs\n"), keystr_from_pk(pk));
5656+- if (!opt.quiet )
5757- log_info(_("this may be caused by a missing self-signature\n"));
5858- }
5959- stats->no_user_id++;
···6262+ /* Delete invalid parts, and note if we have any valid ones left.
6363+ * We will later abort import if this key is new but contains
6464+ * no valid uids. */
6565-+ delete_inv_parts (ctrl, keyblock, keyid, options);
6565++ delete_inv_parts (ctrl, keyblock, keyid, options, otherrevsigs);
66666767 /* Get rid of deleted nodes. */
6868 commit_kbnode (&keyblock);
6969-@@ -1927,24 +1911,11 @@ import_one_real (ctrl_t ctrl,
6969+@@ -1998,24 +1982,11 @@ import_one_real (ctrl_t ctrl,
7070 {
7171 apply_keep_uid_filter (ctrl, keyblock, import_filter.keep_uid);
7272 commit_kbnode (&keyblock);
···9191 }
92929393 /* The keyblock is valid and ready for real import. */
9494-@@ -2002,6 +1973,13 @@ import_one_real (ctrl_t ctrl,
9494+@@ -2073,6 +2044,13 @@ import_one_real (ctrl_t ctrl,
9595 err = 0;
9696 stats->skipped_new_keys++;
9797 }
+36-6
pkgs/tools/typesetting/tex/texlive/bin.nix
···3838 # http://mirrors.ctan.org/systems/doc/kpathsea/kpathsea.pdf for more
3939 # details
4040 sed -i '/^#define ST_NLINK_TRICK/d' texk/kpathsea/config.h
4141- '';
4141+ '' +
4242+ # when cross compiling, we must use himktables from PATH
4343+ # (i.e. from buildPackages.texlive.bin.core.dev)
4444+ lib.optionalString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
4545+ sed -i 's|\./himktables|himktables|' texk/web2c/Makefile.in
4646+ ''
4747+;
42484349 configureFlags = [
4450 "--with-banner-add=/nixos.org"
···75817682 inherit (common) src prePatch;
77837878- outputs = [ "out" "doc" ];
8484+ outputs = [ "out" "doc" "dev" ];
79858086 nativeBuildInputs = [
8187 pkg-config
8282- ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
8888+ ] ++ lib.optionals (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) [
8389 # configure: error: tangle was not found but is required when cross-compiling.
9090+ # dev (himktables) is used when building hitex to generate the additional source file hitables.c
8491 texlive.bin.core
9292+ texlive.bin.core.dev
8593 ];
86948795 buildInputs = [
···159167 mv "$out"/share/{man,info} "$doc"/doc
160168 '' + /* remove manpages for utils that live in texlive.texlive-scripts to avoid a conflict in buildEnv */ ''
161169 (cd "$doc"/doc/man/man1; rm {fmtutil-sys.1,fmtutil.1,mktexfmt.1,mktexmf.1,mktexpk.1,mktextfm.1,texhash.1,updmap-sys.1,updmap.1})
170170+ '' + /* install himktables in separate output for use in cross compilation */ ''
171171+ mkdir -p $dev/bin
172172+ cp texk/web2c/.libs/himktables $dev/bin/himktables
162173 '' + cleanBrokenLinks;
163174164175 setupHook = ./setup-hook.sh; # TODO: maybe texmf-nix -> texmf (and all references)
···195206196207 hardeningDisable = [ "format" ];
197208198198- inherit (core) nativeBuildInputs;
209209+ inherit (core) nativeBuildInputs depsBuildBuild;
199210 buildInputs = core.buildInputs ++ [ core cairo harfbuzz icu graphite2 libX11 ];
200211201212 configureFlags = common.configureFlags
···210221 # we use static libtexlua, because it's only used by a single binary
211222 postConfigure = let
212223 luajit = lib.optionalString withLuaJIT ",luajit";
213213- in ''
224224+ in
225225+ lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform)
226226+ # without this, the native builds attempt to use the binary
227227+ # ${target-triple}-gcc, but we need to use the wrapper script.
228228+ ''
229229+ export BUILDCC=${buildPackages.stdenv.cc}/bin/cc
230230+ ''
231231+ +
232232+ ''
214233 mkdir ./WorkDir && cd ./WorkDir
215234 for path in libs/{pplib,teckit,lua53${luajit}} texk/web2c; do
216235 (
···219238 else
220239 extraConfig=""
221240 fi
222222-241241+ '' + lib.optionalString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform)
242242+ # results of the tests performed by the configure scripts are
243243+ # toolchain-dependent, so native components and cross components cannot use
244244+ # the same cached test results.
245245+ # Disable the caching for components with native subcomponents.
246246+ ''
247247+ if [[ "$path" =~ "libs/luajit" ]] || [[ "$path" =~ "texk/web2c" ]]; then
248248+ extraConfig="$extraConfig --cache-file=/dev/null"
249249+ fi
250250+ ''
251251+ +
252252+ ''
223253 mkdir -p "$path" && cd "$path"
224254 "../../../$path/configure" $configureFlags $extraConfig
225255
+42-48
pkgs/top-level/all-packages.nix
···58825882 enableExtraPlugins = true;
58835883 };
5884588458855885- asciidoctor = callPackage ../tools/typesetting/asciidoctor {
58865886- bundlerApp = bundlerApp.override {
58875887- # asciidoc supports both ruby 2 and 3,
58885888- # but we don't want to be stuck on it:
58895889- ruby = ruby_3_1;
58905890- };
58915891- };
58855885+ asciidoctor = callPackage ../tools/typesetting/asciidoctor { };
5892588658935887 asciidoctor-with-extensions = callPackage ../tools/typesetting/asciidoctor-with-extensions { };
58945888···79207914 gnupg1orig = callPackage ../tools/security/gnupg/1.nix { };
79217915 gnupg1compat = callPackage ../tools/security/gnupg/1compat.nix { };
79227916 gnupg1 = gnupg1compat; # use config.packageOverrides if you prefer original gnupg1
79177917+79187918+ gnupg22 = callPackage ../tools/security/gnupg/22.nix {
79197919+ pinentry = if stdenv.isDarwin then pinentry_mac else pinentry-gtk2;
79207920+ libgcrypt = libgcrypt_1_8;
79217921+ };
79227922+79237923 gnupg24 = callPackage ../tools/security/gnupg/24.nix {
79247924- guiSupport = stdenv.isDarwin;
79257924 pinentry = if stdenv.isDarwin then pinentry_mac else pinentry-gtk2;
79267925 };
79277926 gnupg = gnupg24;
···84458444 hostess = callPackage ../development/tools/hostess { };
8446844584478446 hostname-debian = callPackage ../tools/networking/hostname-debian { };
84478447+84488448+ hotdoc = python3Packages.callPackage ../development/tools/hotdoc { };
8448844984498450 hotpatch = callPackage ../development/libraries/hotpatch { };
84508451···13980139811398113982 xxv = callPackage ../tools/misc/xxv { };
13982139831398313983- xvfb-run = callPackage ../tools/misc/xvfb-run { inherit (texFunctions) fontsConf; };
1398413984+ xvfb-run = callPackage ../tools/misc/xvfb-run {
1398513985+ inherit (texFunctions) fontsConf;
1398613986+1398713987+ # xvfb-run is used by a bunch of things to run tests
1398813988+ # and doesn't support hardware accelerated rendering
1398913989+ # so remove it from the rebuild heavy path for mesa
1399013990+ xorgserver = xorg.xorgserver.overrideAttrs(old: {
1399113991+ buildInputs = lib.filter (pkg: lib.getName pkg != "mesa") old.buildInputs;
1399213992+ configureFlags = old.configureFlags ++ [
1399313993+ "--disable-glamor"
1399413994+ "--disable-glx"
1399513995+ "--disable-dri"
1399613996+ "--disable-dri2"
1399713997+ "--disable-dri3"
1399813998+ ];
1399913999+ });
1400014000+ };
13984140011398514002 xvkbd = callPackage ../tools/X11/xvkbd { };
1398614003···1494314960 profiledCompiler = false;
1494414961 });
14945149621494614946- gfortran-tmp-noisystem = wrapCCWith { grossHackForStagingNext = true; cc = (gcc.cc.override {
1494714947- name = "gfortran";
1494814948- langFortran = true;
1494914949- langCC = false;
1495014950- langC = false;
1495114951- profiledCompiler = false;
1495214952- disableBootstrap = false;
1495314953- }); };
1495414954-1495514963 gfortran48 = wrapCC (gcc48.cc.override {
1495614964 name = "gfortran";
1495714965 langFortran = true;
···1543315441 julia_16-bin = callPackage ../development/compilers/julia/1.6-bin.nix { };
1543415442 julia_18-bin = callPackage ../development/compilers/julia/1.8-bin.nix { };
15435154431543615436- julia_18 = callPackage ../development/compilers/julia/1.8.nix {
1543715437- gfortran = gfortran-tmp-noisystem;
1543815438- };
1543915439- julia_19 = callPackage ../development/compilers/julia/1.9.nix {
1544015440- gfortran = gfortran-tmp-noisystem;
1544115441- };
1544415444+ julia_18 = callPackage ../development/compilers/julia/1.8.nix { };
1544515445+ julia_19 = callPackage ../development/compilers/julia/1.9.nix { };
15442154461544315447 julia-lts-bin = julia_16-bin;
1544415448 julia-stable-bin = julia_18-bin;
···1563715641 llvmPackages_latest = llvmPackages_14;
15638156421563915643 llvmPackages_rocm = recurseIntoAttrs (callPackage ../development/compilers/llvm/rocm { });
1564015640-1564115641- # temporary hack; see PR #225846
1564215642- stdenv-tmpDropB = overrideCC stdenv (wrapCCWith { tmpDropB = true; inherit (stdenv.cc) cc; });
15643156441564415645 lorri = callPackage ../tools/misc/lorri {
1564515646 inherit (darwin.apple_sdk.frameworks) CoreServices Security;
···1707817079 ruby_3_1
1707917080 ruby_3_2;
17080170811708117081- ruby = ruby_2_7;
1708217082- rubyPackages = rubyPackages_2_7;
1708217082+ ruby = ruby_3_1;
1708317083+ rubyPackages = rubyPackages_3_1;
17083170841708417085 rubyPackages_2_7 = recurseIntoAttrs ruby_2_7.gems;
1708517086 rubyPackages_3_0 = recurseIntoAttrs ruby_3_0.gems;
···21631216322163221633 libgcrypt = callPackage ../development/libraries/libgcrypt { };
21633216342163421634- libgcrypt_1_5 = callPackage ../development/libraries/libgcrypt/1.5.nix { };
2163521635+ libgcrypt_1_8 = callPackage ../development/libraries/libgcrypt/1.8.nix { };
21635216362163621637 libgdiplus = callPackage ../development/libraries/libgdiplus {
2163721638 inherit (darwin.apple_sdk.frameworks) Carbon;
···2265922660 # Default libGLU
2266022661 libGLU = mesa_glu;
22661226622266222662- # When a new patch is out, add a new mesa attribute with the exact patch version
2266322663- # Remove old mesa attributes when they're unused.
2266422664- # Try to keep the previous version around for a bit in case there are new bugs.
2266522665- mesa_22_3_7 = darwin.apple_sdk_11_0.callPackage ../development/libraries/mesa/22.3.7.nix {
2266322663+ # Keep Mesa 22.3 for now because 23.0 does not build on Darwin.
2266422664+ # FIXME: remove, also investigate why we even need Mesa on Darwin.
2266522665+ mesa_22_3 = darwin.apple_sdk_11_0.callPackage ../development/libraries/mesa/22.3.nix {
2266622666 inherit (darwin.apple_sdk_11_0.frameworks) OpenGL;
2266722667 inherit (darwin.apple_sdk_11_0.libs) Xplugin;
2266822668 };
2266922669- mesa_23_0_1 = darwin.apple_sdk_11_0.callPackage ../development/libraries/mesa/23.0.1.nix {
2266922669+ mesa_23_0 = darwin.apple_sdk_11_0.callPackage ../development/libraries/mesa/23.0.nix {
2267022670 inherit (darwin.apple_sdk_11_0.frameworks) OpenGL;
2267122671 inherit (darwin.apple_sdk_11_0.libs) Xplugin;
2267222672 };
2267322673- # Bump this immediately on patches; wait a bit for minor versions
2267422674- mesa_22 = mesa_22_3_7;
2267522675- mesa_23 = mesa_23_0_1;
2267622676- # Bump on staging only, tonnes of packages depend on it.
2267722677- # See https://github.com/NixOS/nixpkgs/issues/218232
2267822678- # Major versions should be bumped when they have proven to be reasonably stable
2267922679- # FIXME: split up libgbm properly
2268022680- # darwin: deferred until stabilized; e.g. see around:
2268122681- # https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21859
2268222682- mesa = if stdenv.isDarwin then mesa_22_3_7 else mesa_23_0_1;
2267322673+ mesa = if stdenv.isDarwin then mesa_22_3 else mesa_23_0;
22683226742268422675 mesa_glu = callPackage ../development/libraries/mesa-glu {
2268522676 inherit (darwin.apple_sdk.frameworks) ApplicationServices;
···2471124702 pkg = callPackage ../development/compilers/sbcl/2.x.nix { version = "2.3.0"; };
2471224703 faslExt = "fasl";
2471324704 };
2471424714- sbcl = sbcl_2_3_0;
2470524705+ sbcl_2_3_2 = wrapLisp {
2470624706+ pkg = callPackage ../development/compilers/sbcl/2.x.nix { version = "2.3.2"; };
2470724707+ faslExt = "fasl";
2470824708+ };
2470924709+ sbcl = sbcl_2_3_2;
24715247102471624711 sbclPackages = recurseIntoAttrs sbcl.pkgs;
2471724712···2735227347 withHomed = false;
2735327348 withHwdb = false;
2735427349 withImportd = false;
2735527355- withKmod = false;
2735627350 withLibBPF = false;
2735727351 withLibidn2 = false;
2735827352 withLocaled = false;
···3007030064 flwrap = callPackage ../applications/radio/flwrap { stdenv = gcc10StdenvCompat; };
30071300653007230066 fluidsynth = callPackage ../applications/audio/fluidsynth {
3007330073- inherit (darwin.apple_sdk.frameworks) AudioUnit CoreAudio CoreMIDI CoreServices;
3006730067+ inherit (darwin.apple_sdk.frameworks) AppKit AudioUnit CoreAudio CoreMIDI CoreServices;
3007430068 };
30075300693007630070 fmit = libsForQt5.callPackage ../applications/audio/fmit { };