summaryrefslogtreecommitdiff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
authorJakub Kądziołka <kuba@kadziolka.net>2020-04-29 11:08:42 +0200
committerJakub Kądziołka <kuba@kadziolka.net>2020-04-29 11:08:42 +0200
commit4035c3e3525599c3aa958d498c5bc789a4adffc3 (patch)
treee55a02215fcdb635d0504fc129526bfbf66abd14 /gnu/packages/patches
parent492b82bd4d592276e65c4b9bfbe1b679a00ff09f (diff)
parent4f0f46e4af0e342d84c5ad448258702029601e4b (diff)
downloadguix-patches-4035c3e3525599c3aa958d498c5bc789a4adffc3.tar
guix-patches-4035c3e3525599c3aa958d498c5bc789a4adffc3.tar.gz
Merge branch 'master' into staging
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/akonadi-not-relocatable.patch (renamed from gnu/packages/patches/akonadi-Revert-Make-installation-properly-relo.patch)0
-rw-r--r--gnu/packages/patches/arm-trusted-firmware-disable-hdcp.patch82
-rw-r--r--gnu/packages/patches/beancount-disable-googleapis-fonts.patch25
-rw-r--r--gnu/packages/patches/biber-sortinithash.patch1657
-rw-r--r--gnu/packages/patches/binutils-mingw-w64-deterministic.patch22
-rw-r--r--gnu/packages/patches/binutils-mingw-w64-timestamp.patch137
-rw-r--r--gnu/packages/patches/calibre-msgpack-compat.patch18
-rw-r--r--gnu/packages/patches/clang-10.0-libc-search-path.patch84
-rw-r--r--gnu/packages/patches/dbacl-include-locale.h.patch36
-rw-r--r--gnu/packages/patches/dune-istl-2.7-fix-non-mpi-tests.patch82
-rw-r--r--gnu/packages/patches/emacs-dired-toggle-sudo-emacs-26.patch49
-rw-r--r--gnu/packages/patches/emacs-telega-test-env.patch14
-rw-r--r--gnu/packages/patches/gdm-default-session.patch91
-rw-r--r--gnu/packages/patches/gnupg-default-pinentry.patch65
-rw-r--r--gnu/packages/patches/hash-extender-test-suite.patch13
-rw-r--r--gnu/packages/patches/higan-remove-march-native-flag.patch12
-rw-r--r--gnu/packages/patches/icecat-makeicecat.patch4
-rw-r--r--gnu/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch28
-rw-r--r--gnu/packages/patches/kmscon-runtime-keymap-switch.patch27
-rw-r--r--gnu/packages/patches/libqalculate-3.8.0-libcurl-ssl-fix.patch53
-rw-r--r--gnu/packages/patches/libvpx-use-after-free-in-postproc.patch34
-rw-r--r--gnu/packages/patches/mediastreamer2-srtp2.patch155
-rw-r--r--gnu/packages/patches/mingw-w64-dlltool-temp-prefix.patch26
-rw-r--r--gnu/packages/patches/mingw-w64-reproducible-gendef.patch23
-rw-r--r--gnu/packages/patches/openldap-CVE-2020-12243.patch125
-rw-r--r--gnu/packages/patches/pam-krb5-CVE-2020-10595.patch42
-rw-r--r--gnu/packages/patches/python-aiohttp-3.6.2-no-warning-fail.patch34
-rw-r--r--gnu/packages/patches/python-jedi-deleted-variables.patch38
-rw-r--r--gnu/packages/patches/python-jedi-sort-project-test.patch18
-rw-r--r--gnu/packages/patches/reprotest-support-guix.patch79
-rw-r--r--gnu/packages/patches/sdl-pango-header-guard.patch (renamed from gnu/packages/patches/sdl-pango-fix-explicit-SDLPango_CopyFTBitmapTo.patch)0
-rw-r--r--gnu/packages/patches/sdl2-mesa-compat.patch21
-rw-r--r--gnu/packages/patches/txr-shell.patch59
-rw-r--r--gnu/packages/patches/u-boot-DT-for-Pinebook-Pro.patch1132
-rw-r--r--gnu/packages/patches/u-boot-add-boe-nv140fhmn49-display.patch29
-rw-r--r--gnu/packages/patches/u-boot-gpio-keys-binding-cons.patch37
-rw-r--r--gnu/packages/patches/u-boot-leds-common-binding-con.patch115
-rw-r--r--gnu/packages/patches/u-boot-support-Pinebook-Pro-laptop.patch367
-rw-r--r--gnu/packages/patches/u-boot-video-rockchip-fix-build.patch48
-rw-r--r--gnu/packages/patches/xplanet-1.3.1-cxx11-eof.patch154
-rw-r--r--gnu/packages/patches/xplanet-1.3.1-libdisplay_DisplayOutput.cpp.patch16
-rw-r--r--gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch54
-rw-r--r--gnu/packages/patches/xplanet-1.3.1-xpUtil-Add2017LeapSecond.cpp.patch15
43 files changed, 4712 insertions, 408 deletions
diff --git a/gnu/packages/patches/akonadi-Revert-Make-installation-properly-relo.patch b/gnu/packages/patches/akonadi-not-relocatable.patch
index c3964c5c05..c3964c5c05 100644
--- a/gnu/packages/patches/akonadi-Revert-Make-installation-properly-relo.patch
+++ b/gnu/packages/patches/akonadi-not-relocatable.patch
diff --git a/gnu/packages/patches/arm-trusted-firmware-disable-hdcp.patch b/gnu/packages/patches/arm-trusted-firmware-disable-hdcp.patch
deleted file mode 100644
index edae2352d9..0000000000
--- a/gnu/packages/patches/arm-trusted-firmware-disable-hdcp.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From c7f0cd054578152a250f784bf82c8ca53aa91a02 Mon Sep 17 00:00:00 2001
-From: Ziyuan Xu <xzy.xu@rock-chips.com>
-Date: Tue, 8 Oct 2019 10:27:05 +0800
-Subject: [PATCH] plat/rockchip: cliam a macro to enable hdcp feature for DP
-
-HDCP is using a binary driver, add macro PLAT_RK_DP_HDCP to make it as
-an option.
-
-Change-Id: I54ef1a3635a28e8ae56654bd1e91dfe011520a7f
-Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
-Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
----
- plat/rockchip/rk3399/plat_sip_calls.c | 4 ++++
- plat/rockchip/rk3399/platform.mk | 11 +++++++----
- 2 files changed, 11 insertions(+), 4 deletions(-)
-
-diff --git a/plat/rockchip/rk3399/plat_sip_calls.c b/plat/rockchip/rk3399/plat_sip_calls.c
-index c2cc5b11c..ce8476c9a 100644
---- a/plat/rockchip/rk3399/plat_sip_calls.c
-+++ b/plat/rockchip/rk3399/plat_sip_calls.c
-@@ -56,17 +56,21 @@ uintptr_t rockchip_plat_sip_handler(uint32_t smc_fid,
- void *handle,
- u_register_t flags)
- {
-+#ifdef PLAT_RK_DP_HDCP
- uint64_t x5, x6;
-+#endif
-
- switch (smc_fid) {
- case RK_SIP_DDR_CFG:
- SMC_RET1(handle, ddr_smc_handler(x1, x2, x3, x4));
-+#ifdef PLAT_RK_DP_HDCP
- case RK_SIP_HDCP_CONTROL:
- SMC_RET1(handle, dp_hdcp_ctrl(x1));
- case RK_SIP_HDCP_KEY_DATA64:
- x5 = read_ctx_reg(get_gpregs_ctx(handle), CTX_GPREG_X5);
- x6 = read_ctx_reg(get_gpregs_ctx(handle), CTX_GPREG_X6);
- SMC_RET1(handle, dp_hdcp_store_key(x1, x2, x3, x4, x5, x6));
-+#endif
- default:
- ERROR("%s: unhandled SMC (0x%x)\n", __func__, smc_fid);
- SMC_RET1(handle, SMC_UNK);
-diff --git a/plat/rockchip/rk3399/platform.mk b/plat/rockchip/rk3399/platform.mk
-index 25c498da8..01577492d 100644
---- a/plat/rockchip/rk3399/platform.mk
-+++ b/plat/rockchip/rk3399/platform.mk
-@@ -57,7 +57,6 @@ BL31_SOURCES += ${RK_GIC_SOURCES} \
- ${RK_PLAT_COMMON}/aarch64/platform_common.c \
- ${RK_PLAT_COMMON}/rockchip_sip_svc.c \
- ${RK_PLAT_SOC}/plat_sip_calls.c \
-- ${RK_PLAT_SOC}/drivers/dp/cdn_dp.c \
- ${RK_PLAT_SOC}/drivers/gpio/rk3399_gpio.c \
- ${RK_PLAT_SOC}/drivers/pmu/pmu.c \
- ${RK_PLAT_SOC}/drivers/pmu/pmu_fw.c \
-@@ -89,17 +88,21 @@ $(eval $(call add_define,RK3399M0FW))
- RK3399M0PMUFW=${BUILD_M0}/${PLAT_M0}pmu.bin
- $(eval $(call add_define,RK3399M0PMUFW))
-
-+ifdef PLAT_RK_DP_HDCP
-+BL31_SOURCES += ${RK_PLAT_SOC}/drivers/dp/cdn_dp.c
-+
- HDCPFW=${RK_PLAT_SOC}/drivers/dp/hdcp.bin
- $(eval $(call add_define,HDCPFW))
-
-+${BUILD_PLAT}/bl31/cdn_dp.o: CCACHE_EXTRAFILES=$(HDCPFW)
-+${RK_PLAT_SOC}/drivers/dp/cdn_dp.c: $(HDCPFW)
-+endif
-+
- # CCACHE_EXTRAFILES is needed because ccache doesn't handle .incbin
- export CCACHE_EXTRAFILES
- ${BUILD_PLAT}/bl31/pmu_fw.o: CCACHE_EXTRAFILES=$(RK3399M0FW):$(RK3399M0PMUFW)
- ${RK_PLAT_SOC}/drivers/pmu/pmu_fw.c: $(RK3399M0FW)
-
--${BUILD_PLAT}/bl31/cdn_dp.o: CCACHE_EXTRAFILES=$(HDCPFW)
--${RK_PLAT_SOC}/drivers/dp/cdn_dp.c: $(HDCPFW)
--
- $(eval $(call MAKE_PREREQ_DIR,${BUILD_M0},${BUILD_PLAT}))
- .PHONY: $(RK3399M0FW)
- $(RK3399M0FW): | ${BUILD_M0}
---
-2.20.1
-
diff --git a/gnu/packages/patches/beancount-disable-googleapis-fonts.patch b/gnu/packages/patches/beancount-disable-googleapis-fonts.patch
new file mode 100644
index 0000000000..d0fa47b59c
--- /dev/null
+++ b/gnu/packages/patches/beancount-disable-googleapis-fonts.patch
@@ -0,0 +1,25 @@
+https://sources.debian.org/data/main/b/beancount/2.2.0-3/debian/patches/0001-Remove-fonts.googleapis.com-links-for-the-bean-web-t.patch
+
+From: Nicolas Dandrimont <nicolas@dandrimont.eu>
+Date: Tue, 1 May 2018 04:49:55 +0200
+Subject: Remove fonts.googleapis.com links for the bean-web template
+
+---
+ beancount/web/web.html | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git a/beancount/web/web.html b/beancount/web/web.html
+index 3995ce2..ec9e707 100644
+--- a/beancount/web/web.html
++++ b/beancount/web/web.html
+@@ -3,10 +3,6 @@
+ <head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+- <link href="https://fonts.googleapis.com/css?family=Roboto+Condensed:400italic,700italic,700,400" rel="stylesheet" type="text/css" />
+- <link href="https://fonts.googleapis.com/css?family=Roboto:400italic,700italic,700,400" rel="stylesheet" type="text/css" />
+- <link href='https://fonts.googleapis.com/css?family=Droid+Sans+Mono' rel='stylesheet' type='text/css' />
+-
+ <link href="/resources/web.css" rel="stylesheet" type="text/css" />
+ <title>{{title}}: {{pagetitle}}</title>
+ \ No newline at end of file
diff --git a/gnu/packages/patches/biber-sortinithash.patch b/gnu/packages/patches/biber-sortinithash.patch
new file mode 100644
index 0000000000..1f054d25e4
--- /dev/null
+++ b/gnu/packages/patches/biber-sortinithash.patch
@@ -0,0 +1,1657 @@
+This is a backport of this upstream commit to Biber 2.12:
+
+ From 6b61b4c13778cf638f82569ab9e413f09f111ba5 Mon Sep 17 00:00:00 2001
+ From: Philip Kime <Philip@kime.org.uk>
+ Date: Sat, 12 Jan 2019 17:19:51 +0100
+ Subject: [PATCH] Updated tests after U::C upgrade changed sortinit hashes
+
+It addresses test failures found with recent versions of the
+Biber dependencies.
+
+diff --git a/t/annotations.t b/t/annotations.t
+index b4f641e..c6f86c7 100644
+--- a/t/annotations.t
++++ b/t/annotations.t
+@@ -73,7 +73,7 @@ my $ann1 = q| \entry{ann1}{misc}{}
+ \strng{authorfullhash}{90ae96c82de92e36949bc64254bbde0c}
+ \field{extraname}{1}
+ \field{sortinit}{L}
+- \field{sortinithash}{2c7981aaabc885868aba60f0c09ee20f}
++ \field{sortinithash}{dad3efd0836470093a7b4a7bb756eb8c}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+ \field{title}{The Title}
+diff --git a/t/basic-misc.t b/t/basic-misc.t
+index d4664b1..a9168cc 100644
+--- a/t/basic-misc.t
++++ b/t/basic-misc.t
+@@ -97,7 +97,7 @@ my $u1 = q| \entry{u1}{misc}{}
+ \strng{authorfullhash}{b78abdc838d79b6576f2ed0021642766}
+ \field{labelalpha}{AAA\textbf{+}00}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -231,7 +231,7 @@ my $murray1 = q| \entry{murray}{article}{}
+ \strng{authorfullhash}{1572cc3fd324f560e5e71d041a6bd764}
+ \field{labelalpha}{Hos\textbf{+}98}
+ \field{sortinit}{H}
+- \field{sortinithash}{5f15a7bc777ad49ff15aa4d2831b1681}
++ \field{sortinithash}{6db6145dae8dc9e1271a8d556090b50a}
+ \true{singletitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -348,7 +348,7 @@ my $murray2 = q| \entry{murray}{article}{}
+ \strng{authorfullhash}{1572cc3fd324f560e5e71d041a6bd764}
+ \field{labelalpha}{Hos98}
+ \field{sortinit}{H}
+- \field{sortinithash}{5f15a7bc777ad49ff15aa4d2831b1681}
++ \field{sortinithash}{6db6145dae8dc9e1271a8d556090b50a}
+ \true{singletitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -389,7 +389,7 @@ my $t1 = q+ \entry{t1}{misc}{}
+ \field{extraname}{1}
+ \field{labelalpha}{Bro92}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -419,7 +419,7 @@ my $t2 = q| \entry{t2}{misc}{}
+ \field{extraname}{2}
+ \field{labelalpha}{Bro94}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -452,7 +452,7 @@ my $anon1 = q| \entry{anon1}{unpublished}{}
+ \strng{shortauthorfullhash}{9873a6cc65c553faa2b21aaad626fe4b}
+ \field{labelalpha}{XAn35}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \true{uniquework}
+ \field{labelnamesource}{shortauthor}
+@@ -491,7 +491,7 @@ my $anon2 = q| \entry{anon2}{unpublished}{}
+ \strng{shortauthorfullhash}{f64c29e89ea49402b997956610b58ef6}
+ \field{labelalpha}{YAn39}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \true{uniquework}
+ \field{labelnamesource}{shortauthor}
+@@ -526,7 +526,7 @@ my $url1 = q| \entry{url1}{misc}{}
+ \field{extraname}{4}
+ \field{labelalpha}{Ali05}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \field{extraalpha}{4}
+ \field{labelnamesource}{author}
+ \field{year}{2005}
+@@ -710,7 +710,7 @@ my $isbn1 = q| \entry{isbn1}{misc}{}
+ \field{extraname}{1}
+ \field{labelalpha}{Flu}
+ \field{sortinit}{F}
+- \field{sortinithash}{669c706c6f1fbf3b5a83d26f1d9e9e72}
++ \field{sortinithash}{fb0c0faa89eb6abae8213bf60e6799ea}
+ \field{extraalpha}{1}
+ \field{labelnamesource}{author}
+ \field{isbn}{978-0-8165-2066-4}
+@@ -735,7 +735,7 @@ my $isbn2 = q| \entry{isbn2}{misc}{}
+ \field{extraname}{2}
+ \field{labelalpha}{Flu}
+ \field{sortinit}{F}
+- \field{sortinithash}{669c706c6f1fbf3b5a83d26f1d9e9e72}
++ \field{sortinithash}{fb0c0faa89eb6abae8213bf60e6799ea}
+ \field{extraalpha}{2}
+ \field{labelnamesource}{author}
+ \field{isbn}{978-0-8165-2066-4}
+@@ -778,7 +778,7 @@ my $clone1 = q| \entry{snk1}{book}{}
+ \field{extraname}{2}
+ \field{labelalpha}{vDoe}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{extraalpha}{2}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -807,7 +807,7 @@ my $clone2 = q| \entry{clone-snk1}{book}{}
+ \field{extraname}{1}
+ \field{labelalpha}{vDoe}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{extraalpha}{1}
+ \field{labelnamesource}{author}
+ \field{addendum}{add}
+@@ -839,7 +839,7 @@ my $ent1 = q| \entry{ent1}{book}{}
+ \strng{authorfullhash}{b2536a425d549b46de5f21c4d468050a}
+ \field{labelalpha}{SdB}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -862,7 +862,7 @@ my $verb1 = q| \entry{verb1}{book}{}
+ \strng{authorfullhash}{cac5a25f503e71f5ef28f474e14007b6}
+ \field{labelalpha}{All}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \verb{verba}
+diff --git a/t/biblatexml.t b/t/biblatexml.t
+index ad9ad25..0959bfa 100644
+--- a/t/biblatexml.t
++++ b/t/biblatexml.t
+@@ -111,7 +111,7 @@ my $l1 = q| \entry{bltx1}{misc}{useprefix=false}
+ \strng{translatornamehash}{b44eba830fe9817fbe8e53c82f1cbe04}
+ \strng{translatorfullhash}{b44eba830fe9817fbe8e53c82f1cbe04}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -158,7 +158,7 @@ my $l1 = q| \entry{bltx1}{misc}{useprefix=false}
+
+ my $l2 = q| \entry{loopkey:a}{book}{}
+ \field{sortinit}{0}
+- \field{sortinithash}{168ad0c7c5ed09f1d28c6675717b5b03}
++ \field{sortinithash}{bcf7a1f4afb88b7299f988caccb80d1c}
+ \endentry
+ |;
+
+diff --git a/t/crossrefs.t b/t/crossrefs.t
+index 915b52b..b6191c6 100644
+--- a/t/crossrefs.t
++++ b/t/crossrefs.t
+@@ -82,7 +82,7 @@ my $cr1 = q| \entry{cr1}{inbook}{}
+ \strng{editornamehash}{c129df5593fdaa7475548811bfbb227d}
+ \strng{editorfullhash}{c129df5593fdaa7475548811bfbb227d}
+ \field{sortinit}{G}
+- \field{sortinithash}{5e8d2bf9d38de41b1528bd307546008f}
++ \field{sortinithash}{62eb2aa29549e4fdbd3cb154ec5711cb}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -131,7 +131,7 @@ my $cr2 = q| \entry{cr2}{inbook}{}
+ \strng{editornamehash}{c129df5593fdaa7475548811bfbb227d}
+ \strng{editorfullhash}{c129df5593fdaa7475548811bfbb227d}
+ \field{sortinit}{F}
+- \field{sortinithash}{669c706c6f1fbf3b5a83d26f1d9e9e72}
++ \field{sortinithash}{fb0c0faa89eb6abae8213bf60e6799ea}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -165,7 +165,7 @@ my $cr_m = q| \entry{cr_m}{book}{}
+ \strng{editornamehash}{c129df5593fdaa7475548811bfbb227d}
+ \strng{editorfullhash}{c129df5593fdaa7475548811bfbb227d}
+ \field{sortinit}{G}
+- \field{sortinithash}{5e8d2bf9d38de41b1528bd307546008f}
++ \field{sortinithash}{62eb2aa29549e4fdbd3cb154ec5711cb}
+ \true{crossrefsource}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+@@ -203,7 +203,7 @@ my $cr3 = q| \entry{cr3}{inbook}{}
+ \strng{editornamehash}{a1f5c22413396d599ec766725b226735}
+ \strng{editorfullhash}{a1f5c22413396d599ec766725b226735}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -248,7 +248,7 @@ my $cr4 = q| \entry{cr4}{inbook}{}
+ \strng{editornamehash}{6ea89bd4958743a20b70fe17647d6af5}
+ \strng{editorfullhash}{6ea89bd4958743a20b70fe17647d6af5}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -279,7 +279,7 @@ my $crt = q| \entry{crt}{book}{}
+ \strng{editornamehash}{a1f5c22413396d599ec766725b226735}
+ \strng{editorfullhash}{a1f5c22413396d599ec766725b226735}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+ \field{title}{Beasts of the Burbling Burns}
+@@ -315,7 +315,7 @@ my $cr6 = q| \entry{cr6}{inproceedings}{}
+ \strng{editorfullhash}{344a7f427fb765610ef96eb7bce95257}
+ \field{extraname}{2}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{uniquetitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -366,7 +366,7 @@ my $cr7 = q| \entry{cr7}{inbook}{}
+ \strng{bookauthorfullhash}{91a1dd4aeed3c4ec29ca74c4e778be5f}
+ \field{extraname}{1}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{uniquetitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -401,7 +401,7 @@ my $cr8 = q| \entry{cr8}{incollection}{}
+ \strng{authorfullhash}{3d449e56eb3ca1ae80dc99a18d689795}
+ \field{extraname}{4}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -431,7 +431,7 @@ my $xr1 = q| \entry{xr1}{inbook}{}
+ \strng{authornamehash}{e0ecc4fc668ee499d1afba44e1ac064d}
+ \strng{authorfullhash}{e0ecc4fc668ee499d1afba44e1ac064d}
+ \field{sortinit}{Z}
+- \field{sortinithash}{156173bd08b075d7295bc3e0f4735a04}
++ \field{sortinithash}{8f7b480688e809b50b6f6577b16f3db5}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -460,7 +460,7 @@ my $xr2 = q| \entry{xr2}{inbook}{}
+ \strng{authornamehash}{6afa09374ecfd6b394ce714d2d9709c7}
+ \strng{authorfullhash}{6afa09374ecfd6b394ce714d2d9709c7}
+ \field{sortinit}{I}
+- \field{sortinithash}{320bc8fe8101b9376f9f21cd507de0e8}
++ \field{sortinithash}{9417e9a1288a9371e2691d999083ed39}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -491,7 +491,7 @@ my $xrm = q| \entry{xrm}{book}{}
+ \strng{editornamehash}{809950f9b59ae207092b909a19dcb27b}
+ \strng{editorfullhash}{809950f9b59ae207092b909a19dcb27b}
+ \field{sortinit}{C}
+- \field{sortinithash}{963e9d84a3da2344e8833203de5aed05}
++ \field{sortinithash}{4c244ceae61406cdc0cc2ce1cb1ff703}
+ \true{xrefsource}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+@@ -516,7 +516,7 @@ my $xr3 = q| \entry{xr3}{inbook}{}
+ \strng{authornamehash}{9788055665b9bb4b37c776c3f6b74f16}
+ \strng{authorfullhash}{9788055665b9bb4b37c776c3f6b74f16}
+ \field{sortinit}{N}
+- \field{sortinithash}{f7242c3ed3dc50029fca1be76c497c7c}
++ \field{sortinithash}{98cf339a479c0454fe09153a08675a15}
+ \true{singletitle}
+ \true{uniquetitle}
+ \true{uniquework}
+@@ -546,7 +546,7 @@ my $xrt = q| \entry{xrt}{book}{}
+ \strng{editornamehash}{bf7d6b02f3e073913e5bfe5059508dd5}
+ \strng{editorfullhash}{bf7d6b02f3e073913e5bfe5059508dd5}
+ \field{sortinit}{K}
+- \field{sortinithash}{9fd838a31ba64d981e8f44562bd33f89}
++ \field{sortinithash}{d3edc18d54b9438a72c24c925bfb38f4}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+ \field{title}{Kings, Cork and Calculation}
+@@ -572,7 +572,7 @@ my $xr4 = q| \entry{xr4}{inbook}{}
+ \strng{authorfullhash}{7804ffef086c0c4686c235807f5cb502}
+ \field{extraname}{1}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+ \field{origyear}{1933}
+@@ -600,7 +600,7 @@ my $mxr = q| \entry{mxr}{inbook}{}
+ \strng{authorfullhash}{7804ffef086c0c4686c235807f5cb502}
+ \field{extraname}{2}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+ \field{origyear}{1933}
+@@ -625,7 +625,7 @@ my $mcr = q| \entry{mcr}{inbook}{}
+ \strng{authorfullhash}{7804ffef086c0c4686c235807f5cb502}
+ \field{extraname}{3}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+ \field{origyear}{1933}
+@@ -660,7 +660,7 @@ my $ccr1 = q| \entry{ccr2}{book}{}
+ \strng{editorfullhash}{cfee758a1c82df2e26af1985e061bb0a}
+ \field{extraname}{1}
+ \field{sortinit}{V}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \true{uniquetitle}
+ \true{uniquework}
+ \field{labelnamesource}{author}
+@@ -694,7 +694,7 @@ my $ccr2 = q| \entry{ccr3}{inbook}{}
+ \strng{editornamehash}{cfee758a1c82df2e26af1985e061bb0a}
+ \strng{editorfullhash}{cfee758a1c82df2e26af1985e061bb0a}
+ \field{sortinit}{P}
+- \field{sortinithash}{8d51b3d5b78d75b54308d706b9bbe285}
++ \field{sortinithash}{bb5b15f2db90f7aef79bb9e83defefcb}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+ \field{booktitle}{Misc etc.}
+@@ -726,7 +726,7 @@ my $ccr3 = q| \entry{ccr4}{inbook}{}
+
+ my $s1 = q| \entry{s1}{inbook}{}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{uniquetitle}
+ \field{labeltitlesource}{title}
+ \strng{crossref}{s2}
+@@ -760,7 +760,7 @@ my $xc2 = q| \entry{xc2}{inbook}{}
+ \strng{bookauthorfullhash}{1a0f7d518cccdad859a74412ef956474}
+ \field{extraname}{2}
+ \field{sortinit}{C}
+- \field{sortinithash}{963e9d84a3da2344e8833203de5aed05}
++ \field{sortinithash}{4c244ceae61406cdc0cc2ce1cb1ff703}
+ \true{xrefsource}
+ \field{labelnamesource}{author}
+ \field{booktitle}{Title}
+@@ -769,7 +769,7 @@ my $xc2 = q| \entry{xc2}{inbook}{}
+
+ my $b1 = q| \entry{b1}{inbook}{}
+ \field{sortinit}{2}
+- \field{sortinithash}{cbff857e587bcb4635511624d773949e}
++ \field{sortinithash}{ed39bb39cf854d5250e95b1c1f94f4ed}
+ \strng{crossref}{b2}
+ \field{day}{3}
+ \field{month}{3}
+@@ -803,7 +803,7 @@ my $sup1 = q| \entry{sup1}{mvbook}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{3}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{crossrefsource}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -828,7 +828,7 @@ my $sup2 = q| \entry{sup2}{book}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{1}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/datalists.t b/t/datalists.t
+index 3081cc4..4855e3d 100644
+--- a/t/datalists.t
++++ b/t/datalists.t
+@@ -187,7 +187,7 @@ my $K11 = q| \entry{K11}{book}{}
+ \strng{authornamehash}{4edc280a0ef229f9c061e3b121b17482}
+ \strng{authorfullhash}{4edc280a0ef229f9c061e3b121b17482}
+ \field{sortinit}{a}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -219,7 +219,7 @@ my $K12 = q| \entry{K12}{book}{}
+ \strng{authornamehash}{a846a485fc9cbb59b0ebeedd6ac637e4}
+ \strng{authorfullhash}{a846a485fc9cbb59b0ebeedd6ac637e4}
+ \field{sortinit}{Z}
+- \field{sortinithash}{156173bd08b075d7295bc3e0f4735a04}
++ \field{sortinithash}{8f7b480688e809b50b6f6577b16f3db5}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+diff --git a/t/dateformats.t b/t/dateformats.t
+index 6beb567..0d5072a 100644
+--- a/t/dateformats.t
++++ b/t/dateformats.t
+@@ -88,7 +88,7 @@ my $l13c = q| \entry{L13}{book}{}
+ \strng{authorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{3}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -126,7 +126,7 @@ my $l14 = q| \entry{L14}{book}{}
+ \strng{authorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{4}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{3}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -168,7 +168,7 @@ my $l15 = q| \entry{L15}{book}{}
+ \strng{authorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{12}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{4}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -201,7 +201,7 @@ my $l16 = q| \entry{L16}{proceedings}{}
+ \strng{editorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{13}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{7}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{event}
+@@ -240,7 +240,7 @@ my $l17 = q| \entry{L17}{proceedings}{}
+ \strng{editorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{5}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{4}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -299,7 +299,7 @@ my $l17c = q| \entry{L17}{proceedings}{}
+ \strng{editorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{5}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{orig}
+ \field{labelnamesource}{editor}
+@@ -357,7 +357,7 @@ my $l17e = q| \entry{L17}{proceedings}{}
+ \strng{editorfullhash}{8c77336299b25bdada7bf8038f46722f}
+ \field{extraname}{5}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{event}
+ \field{labelnamesource}{editor}
+@@ -479,7 +479,7 @@ my $era1 = q| \entry{era1}{article}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{9}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -512,7 +512,7 @@ my $era2 = q| \entry{era2}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{10}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -546,7 +546,7 @@ my $era3 = q| \entry{era3}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{11}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -580,7 +580,7 @@ my $era4 = q| \entry{era4}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{6}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -622,7 +622,7 @@ my $time1 = q| \entry{time1}{article}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{2}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -671,7 +671,7 @@ my $range1 = q| \entry{range1}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{7}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{1}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -712,7 +712,7 @@ my $range2 = q| \entry{range2}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{8}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{2}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -753,7 +753,7 @@ my $season1 = q| \entry{season1}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{1}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -785,7 +785,7 @@ my $unspec1 = q| \entry{unspec1}{inproceedings}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{4}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -838,7 +838,7 @@ my $unspec2 = q| \entry{unspec2}{article}{}
+ \strng{authorfullhash}{556c8dba145b472e6a8598d506f7cbe2}
+ \field{extraname}{3}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+diff --git a/t/encoding.t b/t/encoding.t
+index a150b4f..36d9955 100644
+--- a/t/encoding.t
++++ b/t/encoding.t
+@@ -52,7 +52,7 @@ my $encode1 = q| \entry{testŠ}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -82,7 +82,7 @@ my $encode2 = q| \entry{test1}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -112,7 +112,7 @@ my $encode3 = q| \entry{test1}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -142,7 +142,7 @@ my $encode5 = q| \entry{test}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -172,7 +172,7 @@ my $encode6 = q| \entry{test}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+@@ -202,7 +202,7 @@ my $encode7 = q| \entry{test}{book}{}
+ \strng{authorfullhash}{06a47edae2e847800cfd78323a0e6be8}
+ \field{labelalpha}{Enc99}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{labeldatesource}{year}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+diff --git a/t/names.t b/t/names.t
+index 7228042..b73f2ed 100644
+--- a/t/names.t
++++ b/t/names.t
+@@ -188,7 +188,7 @@ my $l1 = q| \entry{L1}{book}{}
+ \strng{authornamehash}{72287a68c1714cb1b9f4ab9e03a88b96}
+ \strng{authorfullhash}{72287a68c1714cb1b9f4ab9e03a88b96}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -208,7 +208,7 @@ my $l2 = q| \entry{L2}{book}{}
+ \strng{authornamehash}{2098d59d0f19a2e003ee06c1aa750d57}
+ \strng{authorfullhash}{2098d59d0f19a2e003ee06c1aa750d57}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -228,7 +228,7 @@ my $l3 = q| \entry{L3}{book}{}
+ \strng{authornamehash}{c8b06fe88bde128b25eb0b3b1cc5837c}
+ \strng{authorfullhash}{c8b06fe88bde128b25eb0b3b1cc5837c}
+ \field{sortinit}{C}
+- \field{sortinithash}{963e9d84a3da2344e8833203de5aed05}
++ \field{sortinithash}{4c244ceae61406cdc0cc2ce1cb1ff703}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -248,7 +248,7 @@ my $l4 = q| \entry{L4}{book}{}
+ \strng{authornamehash}{5ec958b850c0c2de7de7c42c84b9c419}
+ \strng{authorfullhash}{5ec958b850c0c2de7de7c42c84b9c419}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -270,7 +270,7 @@ my $l5 = q| \entry{L5}{book}{}
+ \strng{authornamehash}{c6b9d281cc1ff3f35570f76f463d4244}
+ \strng{authorfullhash}{c6b9d281cc1ff3f35570f76f463d4244}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -292,7 +292,7 @@ my $l6 = q| \entry{L6}{book}{}
+ \strng{authornamehash}{5fd24d3d1608a310ec205a6b201a5495}
+ \strng{authorfullhash}{5fd24d3d1608a310ec205a6b201a5495}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -314,7 +314,7 @@ my $l7 = q| \entry{L7}{book}{}
+ \strng{authornamehash}{98edb0b90251df22b74328d9227eceb7}
+ \strng{authorfullhash}{98edb0b90251df22b74328d9227eceb7}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -336,7 +336,7 @@ my $l8 = q| \entry{L8}{book}{}
+ \strng{authornamehash}{1211dc8dbbc191cbcab4da3c3c1fc48a}
+ \strng{authorfullhash}{1211dc8dbbc191cbcab4da3c3c1fc48a}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -356,7 +356,7 @@ my $l9 = q| \entry{L9}{book}{}
+ \strng{authornamehash}{bae61a889ab149a6deafe45333204cf0}
+ \strng{authorfullhash}{bae61a889ab149a6deafe45333204cf0}
+ \field{sortinit}{I}
+- \field{sortinithash}{320bc8fe8101b9376f9f21cd507de0e8}
++ \field{sortinithash}{9417e9a1288a9371e2691d999083ed39}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -379,7 +379,7 @@ my $l10 = q| \entry{L10}{book}{}
+ \strng{authornamehash}{37b4325752e394ddfb2fc810f6c88e27}
+ \strng{authorfullhash}{37b4325752e394ddfb2fc810f6c88e27}
+ \field{sortinit}{J}
+- \field{sortinithash}{fce5f8d0bd05e8d93f3dbe21c78897ca}
++ \field{sortinithash}{c45040a764d616897e7f5b30174d7b92}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -402,7 +402,7 @@ my $l10a = q| \entry{L10a}{book}{}
+ \strng{authornamehash}{7bf2c9d8b89a1930ee91bfddcaf20c9c}
+ \strng{authorfullhash}{7bf2c9d8b89a1930ee91bfddcaf20c9c}
+ \field{sortinit}{P}
+- \field{sortinithash}{8d51b3d5b78d75b54308d706b9bbe285}
++ \field{sortinithash}{bb5b15f2db90f7aef79bb9e83defefcb}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -427,7 +427,7 @@ my $l11 = q| \entry{L11}{book}{}
+ \strng{authornamehash}{9f48d231be68c9435fab4faca55a5caf}
+ \strng{authorfullhash}{9f48d231be68c9435fab4faca55a5caf}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -449,7 +449,7 @@ my $l12 = q| \entry{L12}{book}{}
+ \strng{authornamehash}{d7ca88c13a8f7ce1c23e920010a31f83}
+ \strng{authorfullhash}{d7ca88c13a8f7ce1c23e920010a31f83}
+ \field{sortinit}{d}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \true{uniqueprimaryauthor}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -470,7 +470,7 @@ my $l13 = q| \entry{L13}{book}{}
+ \strng{authornamehash}{227ac48bb788a658cfaa4eefc71ff0cc}
+ \strng{authorfullhash}{227ac48bb788a658cfaa4eefc71ff0cc}
+ \field{sortinit}{V}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -490,7 +490,7 @@ my $l14 = q| \entry{L14}{book}{}
+ \strng{authornamehash}{779475052c17ed56dc3be900d0dfdf87}
+ \strng{authorfullhash}{779475052c17ed56dc3be900d0dfdf87}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -513,7 +513,7 @@ my $l15 = q| \entry{L15}{book}{}
+ \strng{authorfullhash}{783c636e853e47a854ae034ebe9dde62}
+ \field{extraname}{1}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -536,7 +536,7 @@ my $l16 = q| \entry{L16}{book}{}
+ \strng{authorfullhash}{783c636e853e47a854ae034ebe9dde62}
+ \field{extraname}{2}
+ \field{sortinit}{v}
+- \field{sortinithash}{75dd7385c90b2252c3ae853a80ca853b}
++ \field{sortinithash}{02432525618c08e2b03cac47c19764af}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -557,7 +557,7 @@ my $l17 = q| \entry{L17}{book}{}
+ \strng{authorfullhash}{b51f667a3384d92ea5458ba80716bff7}
+ \field{extraname}{1}
+ \field{sortinit}{L}
+- \field{sortinithash}{2c7981aaabc885868aba60f0c09ee20f}
++ \field{sortinithash}{dad3efd0836470093a7b4a7bb756eb8c}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -578,7 +578,7 @@ my $l18 = q| \entry{L18}{book}{}
+ \strng{authorfullhash}{b51f667a3384d92ea5458ba80716bff7}
+ \field{extraname}{2}
+ \field{sortinit}{L}
+- \field{sortinithash}{2c7981aaabc885868aba60f0c09ee20f}
++ \field{sortinithash}{dad3efd0836470093a7b4a7bb756eb8c}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -598,7 +598,7 @@ my $l19 = q| \entry{L19}{book}{}
+ \strng{authornamehash}{83caa52f21f97e572dd3267bdf62978a}
+ \strng{authorfullhash}{83caa52f21f97e572dd3267bdf62978a}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -618,7 +618,7 @@ my $l19a = q| \entry{L19a}{book}{}
+ \strng{authornamehash}{0963f6904ccfeaac2770c5882a587001}
+ \strng{authorfullhash}{0963f6904ccfeaac2770c5882a587001}
+ \field{sortinit}{L}
+- \field{sortinithash}{2c7981aaabc885868aba60f0c09ee20f}
++ \field{sortinithash}{dad3efd0836470093a7b4a7bb756eb8c}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -639,7 +639,7 @@ my $l20 = q| \entry{L20}{book}{}
+ \strng{authornamehash}{5f26c2f3b33095d5b005714893f4d698}
+ \strng{authorfullhash}{5f26c2f3b33095d5b005714893f4d698}
+ \field{sortinit}{F}
+- \field{sortinithash}{669c706c6f1fbf3b5a83d26f1d9e9e72}
++ \field{sortinithash}{fb0c0faa89eb6abae8213bf60e6799ea}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -660,7 +660,7 @@ my $l21 = q| \entry{L21}{book}{}
+ \strng{authorfullhash}{4389a3c0dc7da74487b50808ba9436ad}
+ \field{extraname}{1}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -681,7 +681,7 @@ my $l22u = q| \entry{L22}{book}{}
+ \strng{authorfullhash}{e58b861545799d0eaf883402a882126e}
+ \field{extraname}{1}
+ \field{sortinit}{Š}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -703,7 +703,7 @@ my $l22 = q| \entry{L22}{book}{}
+ \strng{authorfullhash}{e58b861545799d0eaf883402a882126e}
+ \field{extraname}{1}
+ \field{sortinit}{\v{S}}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \true{uniqueprimaryauthor}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -726,7 +726,7 @@ my $l23 = q| \entry{L23}{book}{}
+ \strng{authorfullhash}{4389a3c0dc7da74487b50808ba9436ad}
+ \field{extraname}{3}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -747,7 +747,7 @@ my $l24 = q| \entry{L24}{book}{}
+ \strng{authorfullhash}{e58b861545799d0eaf883402a882126e}
+ \field{extraname}{2}
+ \field{sortinit}{Š}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -765,7 +765,7 @@ my $l25 = q| \entry{L25}{book}{}
+ \strng{authornamehash}{d7cd2c5ea0848abc3e90609558b84a45}
+ \strng{authorfullhash}{d7cd2c5ea0848abc3e90609558b84a45}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -783,7 +783,7 @@ my $l26 = q| \entry{L26}{book}{}
+ \strng{authornamehash}{8eee1dbafdbd0a4b73157e60f18b4784}
+ \strng{authorfullhash}{8eee1dbafdbd0a4b73157e60f18b4784}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -791,7 +791,7 @@ my $l26 = q| \entry{L26}{book}{}
+ # Malformed anyway but a decent test
+ my $l28 = q| \entry{L28}{book}{}
+ \field{sortinit}{0}
+- \field{sortinithash}{168ad0c7c5ed09f1d28c6675717b5b03}
++ \field{sortinithash}{bcf7a1f4afb88b7299f988caccb80d1c}
+ \warn{\item Name "Deux et al.,, O." is malformed (consecutive commas): skipping name}
+ \endentry
+ |;
+@@ -810,7 +810,7 @@ my $l29 = q| \entry{L29}{book}{}
+ \strng{authornamehash}{27ad192a3a715aa89152b2a4ee392e8c}
+ \strng{authorfullhash}{27ad192a3a715aa89152b2a4ee392e8c}
+ \field{sortinit}{U}
+- \field{sortinithash}{36a2444f5238e0dcf4bb59704df6624d}
++ \field{sortinithash}{77a6935510e008adcf5b555e7b4f0711}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -850,7 +850,7 @@ my $l31 = q| \entry{L31}{book}{}
+ \strng{translatornamehash}{29c3ff92fff79d09a8b44d2f775de0b1}
+ \strng{translatorfullhash}{29c3ff92fff79d09a8b44d2f775de0b1}
+ \field{sortinit}{\~{Z}}
+- \field{sortinithash}{156173bd08b075d7295bc3e0f4735a04}
++ \field{sortinithash}{8f7b480688e809b50b6f6577b16f3db5}
+ \true{uniqueprimaryauthor}
+ \field{labelnamesource}{author}
+ \endentry
+diff --git a/t/options.t b/t/options.t
+index 940a282..c14d694 100644
+--- a/t/options.t
++++ b/t/options.t
+@@ -100,7 +100,7 @@ my $l1 = q| \entry{L1}{book}{}
+ \strng{authornamehash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -137,7 +137,7 @@ my $l2 = q| \entry{L2}{book}{maxcitenames=3,maxbibnames=3,maxsortnames=3,maxi
+ \strng{authornamehash}{19eec87c959944d6d9c72434a42856ba}
+ \strng{authorfullhash}{19eec87c959944d6d9c72434a42856ba}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -169,7 +169,7 @@ my $l3 = q| \entry{L3}{book}{blah=10}
+ \strng{authornamehash}{490250da1f3b92580d97563dc96c6c84}
+ \strng{authorfullhash}{490250da1f3b92580d97563dc96c6c84}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+diff --git a/t/related-entries.t b/t/related-entries.t
+index 53dce64..b38ac79 100644
+--- a/t/related-entries.t
++++ b/t/related-entries.t
+@@ -56,7 +56,7 @@ my $k1 = q| \entry{key1}{article}{}
+ \strng{authorfullhash}{a517747c3d12f99244ae598910d979c5}
+ \field{extraname}{1}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -95,7 +95,7 @@ my $k2 = q| \entry{key2}{inbook}{}
+ \strng{authorfullhash}{a517747c3d12f99244ae598910d979c5}
+ \field{extraname}{2}
+ \field{sortinit}{2}
+- \field{sortinithash}{cbff857e587bcb4635511624d773949e}
++ \field{sortinithash}{ed39bb39cf854d5250e95b1c1f94f4ed}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -243,7 +243,7 @@ my $kck4 = q| \entry{caf8e34be07426ae7127c1b4829983c1}{inbook}{dataonly,useed
+
+ my $c1 = q| \entry{c1}{book}{}
+ \field{sortinit}{3}
+- \field{sortinithash}{a4b52e5432884761f50fb9571273b93e}
++ \field{sortinithash}{a37a8ef248a93c322189792c34fc68c9}
+ \field{related}{9ab62b5ef34a985438bfdf7ee0102229}
+ \endentry
+ |;
+@@ -330,7 +330,7 @@ my $un1 = q| \entry{kullback}{book}{}
+ \strng{authorfullhash}{34c5bbf9876c37127c3abe4e7d7a7198}
+ \field{extraname}{1}
+ \field{sortinit}{5}
+- \field{sortinithash}{3c19c3776b658b3558e9e2e4840c01e2}
++ \field{sortinithash}{5dd416adbafacc8226114bc0202d5fdd}
+ \field{extradatescope}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -364,7 +364,7 @@ my $un2 = q| \entry{kullback:related}{book}{}
+ \strng{authorfullhash}{34c5bbf9876c37127c3abe4e7d7a7198}
+ \field{extraname}{2}
+ \field{sortinit}{6}
+- \field{sortinithash}{57e57fb8451e7fcfa45d1e069f6d3136}
++ \field{sortinithash}{7851c86048328b027313775d8fbd2131}
+ \field{extradatescope}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/remote-files.t b/t/remote-files.t
+index c747dcd..6f4cf4d 100644
+--- a/t/remote-files.t
++++ b/t/remote-files.t
+@@ -86,7 +86,7 @@ my $cu1 = q| \entry{citeulike:8283461}{article}{}
+ \strng{authornamehash}{a700cc0bdce78f5a1f50ff6314ff6f2a}
+ \strng{authorfullhash}{094b095bbb7ac93fdd3e2eafdcec0cac}
+ \field{sortinit}{M}
+- \field{sortinithash}{cfd219b90152c06204fab207bc6c7cab}
++ \field{sortinithash}{2e5c2f51f7fa2d957f3206819bf86dc3}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+@@ -133,7 +133,7 @@ my $dl1 = q| \entry{AbdelbarH98}{article}{}
+ \strng{authornamehash}{bb887c5d0458bfb1f3f7e6afc8d1def4}
+ \strng{authorfullhash}{bb887c5d0458bfb1f3f7e6afc8d1def4}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+diff --git a/t/set-dynamic.t b/t/set-dynamic.t
+index 9ab5fdd..0846f8a 100644
+--- a/t/set-dynamic.t
++++ b/t/set-dynamic.t
+@@ -51,7 +51,7 @@ my $out = $biber->get_output_obj;
+ my $string1 = q| \entry{DynSet}{set}{}
+ \set{Dynamic1,Dynamic2,Dynamic3}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \endentry
+ |;
+
+@@ -71,7 +71,7 @@ my $string2 = q| \entry{Dynamic1}{book}{}
+ \strng{authornamehash}{252caa7921a061ca92087a1a52f15b78}
+ \strng{authorfullhash}{252caa7921a061ca92087a1a52f15b78}
+ \field{sortinit}{8}
+- \field{sortinithash}{07edf88d4ea82509b9c4b4d13f41c452}
++ \field{sortinithash}{1b24cab5087933ef0826a7cd3b99e994}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -98,7 +98,7 @@ my $string3 = q| \entry{Dynamic2}{book}{}
+ \strng{authornamehash}{894a5fe6de820f5dcce84a65581667f4}
+ \strng{authorfullhash}{894a5fe6de820f5dcce84a65581667f4}
+ \field{sortinit}{9}
+- \field{sortinithash}{1dd72ab054147731c9d824b49aba0534}
++ \field{sortinithash}{54047ffb55bdefa0694bbd554c1b11a0}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -124,7 +124,7 @@ my $string4 = q| \entry{Dynamic3}{book}{}
+ \strng{authornamehash}{fc3cc97631ceaecdde2aee6cc60ab42b}
+ \strng{authorfullhash}{fc3cc97631ceaecdde2aee6cc60ab42b}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -151,7 +151,7 @@ my $string5 = q| \entry{Dynamic3}{book}{}
+ \strng{authornamehash}{fc3cc97631ceaecdde2aee6cc60ab42b}
+ \strng{authorfullhash}{fc3cc97631ceaecdde2aee6cc60ab42b}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/set-legacy.t b/t/set-legacy.t
+index 4e56991..9d40acb 100644
+--- a/t/set-legacy.t
++++ b/t/set-legacy.t
+@@ -45,7 +45,7 @@ my $out = $biber->get_output_obj;
+ my $string1 = q| \entry{Elias1955}{set}{}
+ \set{Elias1955a,Elias1955b}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \endentry
+ |;
+
+diff --git a/t/set-static.t b/t/set-static.t
+index 1e45d4d..a6cbe73 100644
+--- a/t/set-static.t
++++ b/t/set-static.t
+@@ -47,7 +47,7 @@ my $out = $biber->get_output_obj;
+ my $string1 = q| \entry{Static1}{set}{}
+ \set{Static2,Static4,Static3}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \field{annotation}{Some notes}
+ \endentry
+ |;
+@@ -68,7 +68,7 @@ my $string2 = q| \entry{Static2}{book}{}
+ \strng{authornamehash}{43874d80d7ce68027102819f16c47df1}
+ \strng{authorfullhash}{43874d80d7ce68027102819f16c47df1}
+ \field{sortinit}{B}
+- \field{sortinithash}{276475738cc058478c1677046f857703}
++ \field{sortinithash}{8de16967003c7207dae369d874f1456e}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -94,7 +94,7 @@ my $string3 = q| \entry{Static3}{book}{}
+ \strng{authornamehash}{22dafa5cd57bb5dd7f3e3bab98fd539c}
+ \strng{authorfullhash}{22dafa5cd57bb5dd7f3e3bab98fd539c}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -119,7 +119,7 @@ my $string4 = q| \entry{Static4}{book}{}
+ \strng{authornamehash}{da80091c8cd89e5269bd55af1bd5d2fa}
+ \strng{authorfullhash}{da80091c8cd89e5269bd55af1bd5d2fa}
+ \field{sortinit}{C}
+- \field{sortinithash}{963e9d84a3da2344e8833203de5aed05}
++ \field{sortinithash}{4c244ceae61406cdc0cc2ce1cb1ff703}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -145,7 +145,7 @@ my $string5 = q| \entry{Static2}{book}{}
+ \strng{authornamehash}{43874d80d7ce68027102819f16c47df1}
+ \strng{authorfullhash}{43874d80d7ce68027102819f16c47df1}
+ \field{sortinit}{1}
+- \field{sortinithash}{2174f786c6195e7fe2ee1c229b416e29}
++ \field{sortinithash}{50c6687d7fc80f50136d75228e3c59ba}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/skips.t b/t/skips.t
+index 7c80d39..caa835f 100644
+--- a/t/skips.t
++++ b/t/skips.t
+@@ -50,7 +50,7 @@ my $set1 = q| \entry{seta}{set}{}
+ \field{labelalpha}{Doe10}
+ \field{extraalpha}{1}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \endentry
+ |;
+
+@@ -70,7 +70,7 @@ my $set2 = q| \entry{set:membera}{book}{}
+ \strng{authornamehash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -97,7 +97,7 @@ my $set3 = q| \entry{set:memberb}{book}{}
+ \strng{authornamehash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -123,7 +123,7 @@ my $set4 = q| \entry{set:memberc}{book}{}
+ \strng{authornamehash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -150,7 +150,7 @@ my $noset1 = q| \entry{noseta}{book}{}
+ \field{extraname}{3}
+ \field{labelalpha}{Doe10}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{2}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -180,7 +180,7 @@ my $noset2 = q| \entry{nosetb}{book}{}
+ \field{extraname}{4}
+ \field{labelalpha}{Doe10}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{3}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -210,7 +210,7 @@ my $noset3 = q| \entry{nosetc}{book}{}
+ \field{extraname}{5}
+ \field{labelalpha}{Doe10}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extradate}{4}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+@@ -244,7 +244,7 @@ my $sk4 = q| \entry{skip4}{article}{dataonly}
+ \strng{authornamehash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{labeldatesource}{year}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/sort-complex.t b/t/sort-complex.t
+index aa3e564..d52db08 100644
+--- a/t/sort-complex.t
++++ b/t/sort-complex.t
+@@ -123,7 +123,7 @@ my $l4 = q| \entry{L4}{book}{}
+ \field{extraname}{2}
+ \field{labelalpha}{Doe\textbf{+}95}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extraalpha}{2}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -155,7 +155,7 @@ my $l1 = q| \entry{L1}{book}{}
+ \field{extraname}{1}
+ \field{labelalpha}{Doe95}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extraalpha}{1}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -187,7 +187,7 @@ my $l2 = q| \entry{L2}{book}{}
+ \field{extraname}{3}
+ \field{labelalpha}{Doe95}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extraalpha}{3}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -219,7 +219,7 @@ my $l3 = q| \entry{L3}{book}{}
+ \field{extraname}{2}
+ \field{labelalpha}{Doe95}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extraalpha}{2}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -253,7 +253,7 @@ my $l5 = q| \entry{L5}{book}{}
+ \field{extraname}{1}
+ \field{labelalpha}{Doe\textbf{+}95}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \field{extraalpha}{1}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/tdata/full-bbl.bbl b/t/tdata/full-bbl.bbl
+index 4f168de..07c2fab 100644
+--- a/t/tdata/full-bbl.bbl
++++ b/t/tdata/full-bbl.bbl
+@@ -36,7 +36,7 @@
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{labelalpha}{\emph{A}}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -63,7 +63,7 @@
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{labelalpha}{\emph{A}}
+ \field{sortinit}{A}
+- \field{sortinithash}{d77c7cdd82ff690d4c3ef13216f92f0b}
++ \field{sortinithash}{a3dcedd53b04d1adfd5ac303ecd5e6fa}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+@@ -90,7 +90,7 @@
+ \strng{authorfullhash}{bd051a2f7a5f377e3a62581b0e0f8577}
+ \field{labelalpha}{\emph{A}}
+ \field{sortinit}{D}
+- \field{sortinithash}{2ef1bd9a78cc71eb74d7231c635177b8}
++ \field{sortinithash}{c438b3d5d027251ba63f5ed538d98af5}
+ \true{singletitle}
+ \field{labelnamesource}{author}
+ \field{labeltitlesource}{title}
+diff --git a/t/tdata/full-bblxml.bblxml b/t/tdata/full-bblxml.bblxml
+index 9eea7d1..a39a787 100644
+--- a/t/tdata/full-bblxml.bblxml
++++ b/t/tdata/full-bblxml.bblxml
+@@ -47,7 +47,7 @@
+ <bbl:field name="authorbibnamehash">860705eb8ffac6e40507746c7ede79ca</bbl:field>
+ <bbl:field name="labelalpha">Aks\textbf{+}06</bbl:field>
+ <bbl:field name="sortinit">A</bbl:field>
+- <bbl:field name="sortinithash">d77c7cdd82ff690d4c3ef13216f92f0b</bbl:field>
++ <bbl:field name="sortinithash">a3dcedd53b04d1adfd5ac303ecd5e6fa</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="indextitle">Effect of immobilization on catalytic characteristics</bbl:field>
+@@ -79,7 +79,7 @@
+ <bbl:field name="authorbibnamehash">9717d2d959a4b18727868ca7928c34b4</bbl:field>
+ <bbl:field name="labelalpha">Ang02</bbl:field>
+ <bbl:field name="sortinit">A</bbl:field>
+- <bbl:field name="sortinithash">d77c7cdd82ff690d4c3ef13216f92f0b</bbl:field>
++ <bbl:field name="sortinithash">a3dcedd53b04d1adfd5ac303ecd5e6fa</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+ <bbl:field name="annotation">A German article in a French journal. Apart from that, a typical article entry. Note the indextitle field</bbl:field>
+@@ -109,7 +109,7 @@
+ </bbl:set>
+ <bbl:field name="labelalpha">Gla61</bbl:field>
+ <bbl:field name="sortinit">G</bbl:field>
+- <bbl:field name="sortinithash">5e8d2bf9d38de41b1528bd307546008f</bbl:field>
++ <bbl:field name="sortinithash">62eb2aa29549e4fdbd3cb154ec5711cb</bbl:field>
+ <bbl:field name="annotation">A set entry with three members discussing the standard model of particle physics.</bbl:field>
+ </bbl:entry>
+ <bbl:entry key="stdmodel:glashow" type="article">
+@@ -129,7 +129,7 @@
+ <bbl:field name="authorfullhash">eb3f242602109f5bdbeb41fdd990fcc0</bbl:field>
+ <bbl:field name="authorbibnamehash">eb3f242602109f5bdbeb41fdd990fcc0</bbl:field>
+ <bbl:field name="sortinit">G</bbl:field>
+- <bbl:field name="sortinithash">5e8d2bf9d38de41b1528bd307546008f</bbl:field>
++ <bbl:field name="sortinithash">62eb2aa29549e4fdbd3cb154ec5711cb</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="journaltitle">Nucl. Phys.</bbl:field>
+@@ -168,7 +168,7 @@
+ <bbl:field name="extraname">1</bbl:field>
+ <bbl:field name="labelalpha">Knu86</bbl:field>
+ <bbl:field name="sortinit">K</bbl:field>
+- <bbl:field name="sortinithash">9fd838a31ba64d981e8f44562bd33f89</bbl:field>
++ <bbl:field name="sortinithash">d3edc18d54b9438a72c24c925bfb38f4</bbl:field>
+ <bbl:field name="extraalpha">1</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+@@ -207,7 +207,7 @@
+ <bbl:field name="extraname">2</bbl:field>
+ <bbl:field name="labelalpha">Knu86</bbl:field>
+ <bbl:field name="sortinit">K</bbl:field>
+- <bbl:field name="sortinithash">9fd838a31ba64d981e8f44562bd33f89</bbl:field>
++ <bbl:field name="sortinithash">d3edc18d54b9438a72c24c925bfb38f4</bbl:field>
+ <bbl:field name="extraalpha">2</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+@@ -236,7 +236,7 @@
+ <bbl:field name="authorbibnamehash">d52f05e0199eae563725b4165f4b2520</bbl:field>
+ <bbl:field name="labelalpha">Ree58</bbl:field>
+ <bbl:field name="sortinit">R</bbl:field>
+- <bbl:field name="sortinithash">da6b42bd3ab22fee61abed031ee405f7</bbl:field>
++ <bbl:field name="sortinithash">b9c68a358aea118dfa887b6e902414a7</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="annotation">An article entry with a series and a volume field. Note the format of the series. If the value of the series field is an integer, this number is printed as an ordinal and the string *series is appended automatically</bbl:field>
+@@ -286,7 +286,7 @@
+ <bbl:field name="editorfullhash">d0ec890e59163c24c111a08d2a4be982</bbl:field>
+ <bbl:field name="editorbibnamehash">d0ec890e59163c24c111a08d2a4be982</bbl:field>
+ <bbl:field name="sortinit">S</bbl:field>
+- <bbl:field name="sortinithash">322b1d5276f2f6c1bccdcd15920dbee6</bbl:field>
++ <bbl:field name="sortinithash">c319cff79d99c853d775f88277d4e45f</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="booksubtitle">Relativistic groups and analyticity</bbl:field>
+@@ -317,7 +317,7 @@
+ <bbl:field name="authorbibnamehash">93f17724cbd884231ef39a73755ef5bb</bbl:field>
+ <bbl:field name="labelalpha">Sho91</bbl:field>
+ <bbl:field name="sortinit">S</bbl:field>
+- <bbl:field name="sortinithash">322b1d5276f2f6c1bccdcd15920dbee6</bbl:field>
++ <bbl:field name="sortinithash">c319cff79d99c853d775f88277d4e45f</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="annotation">An article entry with series, volume, and number fields. Note the format of the series which is a localization key</bbl:field>
+@@ -353,7 +353,7 @@
+ <bbl:field name="authorfullhash">15e144c72b0b9d10db00ddc6d37a19e6</bbl:field>
+ <bbl:field name="authorbibnamehash">15e144c72b0b9d10db00ddc6d37a19e6</bbl:field>
+ <bbl:field name="sortinit">W</bbl:field>
+- <bbl:field name="sortinithash">ecb89ff85896a47dc313960773ac311d</bbl:field>
++ <bbl:field name="sortinithash">1af34bd8c148ffb32de1494636b49713</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="journaltitle">Phys. Rev. Lett.</bbl:field>
+@@ -411,7 +411,7 @@
+ <bbl:field name="authorbibnamehash">860705eb8ffac6e40507746c7ede79ca</bbl:field>
+ <bbl:field name="labelalpha">Aks\textbf{+}06</bbl:field>
+ <bbl:field name="sortinit">A</bbl:field>
+- <bbl:field name="sortinithash">d77c7cdd82ff690d4c3ef13216f92f0b</bbl:field>
++ <bbl:field name="sortinithash">a3dcedd53b04d1adfd5ac303ecd5e6fa</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="indextitle">Effect of immobilization on catalytic characteristics</bbl:field>
+@@ -443,7 +443,7 @@
+ <bbl:field name="authorbibnamehash">9717d2d959a4b18727868ca7928c34b4</bbl:field>
+ <bbl:field name="labelalpha">Ang02</bbl:field>
+ <bbl:field name="sortinit">A</bbl:field>
+- <bbl:field name="sortinithash">d77c7cdd82ff690d4c3ef13216f92f0b</bbl:field>
++ <bbl:field name="sortinithash">a3dcedd53b04d1adfd5ac303ecd5e6fa</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+ <bbl:field name="annotation">A German article in a French journal. Apart from that, a typical article entry. Note the indextitle field</bbl:field>
+@@ -473,7 +473,7 @@
+ </bbl:set>
+ <bbl:field name="labelalpha">Gla61</bbl:field>
+ <bbl:field name="sortinit">G</bbl:field>
+- <bbl:field name="sortinithash">5e8d2bf9d38de41b1528bd307546008f</bbl:field>
++ <bbl:field name="sortinithash">62eb2aa29549e4fdbd3cb154ec5711cb</bbl:field>
+ <bbl:field name="annotation">A set entry with three members discussing the standard model of particle physics.</bbl:field>
+ </bbl:entry>
+ <bbl:entry key="stdmodel:glashow" type="article">
+@@ -493,7 +493,7 @@
+ <bbl:field name="authorfullhash">eb3f242602109f5bdbeb41fdd990fcc0</bbl:field>
+ <bbl:field name="authorbibnamehash">eb3f242602109f5bdbeb41fdd990fcc0</bbl:field>
+ <bbl:field name="sortinit">G</bbl:field>
+- <bbl:field name="sortinithash">5e8d2bf9d38de41b1528bd307546008f</bbl:field>
++ <bbl:field name="sortinithash">62eb2aa29549e4fdbd3cb154ec5711cb</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="journaltitle">Nucl. Phys.</bbl:field>
+@@ -532,7 +532,7 @@
+ <bbl:field name="extraname">1</bbl:field>
+ <bbl:field name="labelalpha">Knu86</bbl:field>
+ <bbl:field name="sortinit">K</bbl:field>
+- <bbl:field name="sortinithash">9fd838a31ba64d981e8f44562bd33f89</bbl:field>
++ <bbl:field name="sortinithash">d3edc18d54b9438a72c24c925bfb38f4</bbl:field>
+ <bbl:field name="extraalpha">1</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+@@ -571,7 +571,7 @@
+ <bbl:field name="extraname">2</bbl:field>
+ <bbl:field name="labelalpha">Knu86</bbl:field>
+ <bbl:field name="sortinit">K</bbl:field>
+- <bbl:field name="sortinithash">9fd838a31ba64d981e8f44562bd33f89</bbl:field>
++ <bbl:field name="sortinithash">d3edc18d54b9438a72c24c925bfb38f4</bbl:field>
+ <bbl:field name="extraalpha">2</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">shorttitle</bbl:field>
+@@ -600,7 +600,7 @@
+ <bbl:field name="authorbibnamehash">d52f05e0199eae563725b4165f4b2520</bbl:field>
+ <bbl:field name="labelalpha">Ree58</bbl:field>
+ <bbl:field name="sortinit">R</bbl:field>
+- <bbl:field name="sortinithash">da6b42bd3ab22fee61abed031ee405f7</bbl:field>
++ <bbl:field name="sortinithash">b9c68a358aea118dfa887b6e902414a7</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="annotation">An article entry with a series and a volume field. Note the format of the series. If the value of the series field is an integer, this number is printed as an ordinal and the string *series is appended automatically</bbl:field>
+@@ -650,7 +650,7 @@
+ <bbl:field name="editorfullhash">d0ec890e59163c24c111a08d2a4be982</bbl:field>
+ <bbl:field name="editorbibnamehash">d0ec890e59163c24c111a08d2a4be982</bbl:field>
+ <bbl:field name="sortinit">S</bbl:field>
+- <bbl:field name="sortinithash">322b1d5276f2f6c1bccdcd15920dbee6</bbl:field>
++ <bbl:field name="sortinithash">c319cff79d99c853d775f88277d4e45f</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="booksubtitle">Relativistic groups and analyticity</bbl:field>
+@@ -681,7 +681,7 @@
+ <bbl:field name="authorbibnamehash">93f17724cbd884231ef39a73755ef5bb</bbl:field>
+ <bbl:field name="labelalpha">Sho91</bbl:field>
+ <bbl:field name="sortinit">S</bbl:field>
+- <bbl:field name="sortinithash">322b1d5276f2f6c1bccdcd15920dbee6</bbl:field>
++ <bbl:field name="sortinithash">c319cff79d99c853d775f88277d4e45f</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="annotation">An article entry with series, volume, and number fields. Note the format of the series which is a localization key</bbl:field>
+@@ -717,7 +717,7 @@
+ <bbl:field name="authorfullhash">15e144c72b0b9d10db00ddc6d37a19e6</bbl:field>
+ <bbl:field name="authorbibnamehash">15e144c72b0b9d10db00ddc6d37a19e6</bbl:field>
+ <bbl:field name="sortinit">W</bbl:field>
+- <bbl:field name="sortinithash">ecb89ff85896a47dc313960773ac311d</bbl:field>
++ <bbl:field name="sortinithash">1af34bd8c148ffb32de1494636b49713</bbl:field>
+ <bbl:field name="labelnamesource">author</bbl:field>
+ <bbl:field name="labeltitlesource">title</bbl:field>
+ <bbl:field name="journaltitle">Phys. Rev. Lett.</bbl:field>
+diff --git a/t/tdata/remote-files.bcf b/t/tdata/remote-files.bcf
+index c2d784b..a2a1842 100644
+--- a/t/tdata/remote-files.bcf
++++ b/t/tdata/remote-files.bcf
+@@ -1853,12 +1853,12 @@
+ <bcf:datasource type="file" datatype="bibtex">http://www.citeulike.org/bibtex/group/8082</bcf:datasource>
+ <bcf:datasource type="file" datatype="bibtex">http://people.cs.uu.nl/hansb/graphs-bib/definitions.bib</bcf:datasource>
+ <bcf:datasource type="file" datatype="bibtex">http://people.cs.uu.nl/hansb/graphs-bib/papers.bib</bcf:datasource>
+- <bcf:datasource type="file" datatype="bibtex">https://api.zotero.org/groups/9097/items/II22KQ7D?format=bibtex&amp;limit=1</bcf:datasource>
++ <bcf:datasource type="file" datatype="bibtex">https://api.zotero.org/groups/9097/items/8VITAT46?format=bibtex&amp;limit=1</bcf:datasource>
+ </bcf:bibdata>
+ <bcf:section number="0">
+ <bcf:citekey order="1">citeulike:8283461</bcf:citekey>
+ <bcf:citekey order="2">AbdelbarH98</bcf:citekey>
+- <bcf:citekey order="3">merleau-ponty_philosophe_2010</bcf:citekey>
++ <bcf:citekey order="3">crossley_politics_1994</bcf:citekey>
+ </bcf:section>
+ <!-- SORTING TEMPLATES -->
+ <bcf:sortingtemplate name="nty">
+diff --git a/t/uniqueness-nameparts.t b/t/uniqueness-nameparts.t
+index beb2e39..1fb65a8 100644
+--- a/t/uniqueness-nameparts.t
++++ b/t/uniqueness-nameparts.t
+@@ -81,7 +81,7 @@ my $un1 = q| \entry{un1}{article}{}
+ \strng{authorfullhash}{329d8f9192ea3349d700160c9ddb505d}
+ \field{labelalpha}{SmiJohSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -106,7 +106,7 @@ my $un2 = q| \entry{un2}{article}{}
+ \strng{authorfullhash}{7551114aede4ef69e4b3683039801706}
+ \field{labelalpha}{SmiJohAla}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -131,7 +131,7 @@ my $un3 = q| \entry{un3}{article}{}
+ \strng{authorfullhash}{401aebda288799a7c757526242d8c9fc}
+ \field{labelalpha}{SmiJohArt}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -156,7 +156,7 @@ my $un4 = q| \entry{un4}{article}{}
+ \strng{authorfullhash}{f6038a264619efefd49c7daac56424ca}
+ \field{labelalpha}{SmiAlaSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -181,7 +181,7 @@ my $un1a = q| \entry{un1}{article}{}
+ \strng{authorfullhash}{329d8f9192ea3349d700160c9ddb505d}
+ \field{labelalpha}{SmiJohSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -206,7 +206,7 @@ my $un2a = q| \entry{un2}{article}{}
+ \strng{authorfullhash}{7551114aede4ef69e4b3683039801706}
+ \field{labelalpha}{SmiJohAla}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -231,7 +231,7 @@ my $un3a = q| \entry{un3}{article}{}
+ \strng{authorfullhash}{401aebda288799a7c757526242d8c9fc}
+ \field{labelalpha}{SmiJohArt}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -257,7 +257,7 @@ my $un4a = q| \entry{un4}{article}{}
+ \strng{authorfullhash}{f6038a264619efefd49c7daac56424ca}
+ \field{labelalpha}{SmiAlaSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -285,7 +285,7 @@ my $un1b = q| \entry{un1}{article}{}
+ \field{extraname}{5}
+ \field{labelalpha}{SmiJohSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{5}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -311,7 +311,7 @@ my $un2b = q| \entry{un2}{article}{}
+ \strng{authorfullhash}{7551114aede4ef69e4b3683039801706}
+ \field{labelalpha}{SmiJohAla}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -336,7 +336,7 @@ my $un3b = q| \entry{un3}{article}{}
+ \strng{authorfullhash}{401aebda288799a7c757526242d8c9fc}
+ \field{labelalpha}{SmiJohArt}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{labelnamesource}{author}
+ \endentry
+ |;
+@@ -364,7 +364,7 @@ my $un4b = q| \entry{un4}{article}{}
+ \field{extraname}{1}
+ \field{labelalpha}{SmiAlaSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{1}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -393,7 +393,7 @@ my $un5 = q| \entry{un5}{article}{uniquenametemplatename=test3}
+ \field{extraname}{2}
+ \field{labelalpha}{SmiArtSim}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{2}
+ \field{labelnamesource}{author}
+ \endentry
+@@ -422,7 +422,7 @@ my $un6 = q| \entry{un6}{article}{}
+ \field{extraname}{3}
+ \field{labelalpha}{SmiArtSmy}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{3}
+ \field{labelnamesource}{author}
+ \\endentry
+@@ -451,7 +451,7 @@ my $un7 = q| \entry{un7}{article}{}
+ \field{extraname}{4}
+ \field{labelalpha}{SmiArtSme}
+ \field{sortinit}{S}
+- \field{sortinithash}{322b1d5276f2f6c1bccdcd15920dbee6}
++ \field{sortinithash}{c319cff79d99c853d775f88277d4e45f}
+ \field{extradate}{4}
+ \field{labelnamesource}{author}
+ \endentry
+diff --git a/t/xdata.t b/t/xdata.t
+index 7411b1d..73dcb8b 100644
+--- a/t/xdata.t
++++ b/t/xdata.t
+@@ -75,7 +75,7 @@ my $xd1 = q| \entry{xd1}{book}{}
+ \strng{authorfullhash}{51db4bfd331cba22959ce2d224c517cd}
+ \field{extraname}{2}
+ \field{sortinit}{E}
+- \field{sortinithash}{f615fb9c6fba11c6f962fb3fd599810e}
++ \field{sortinithash}{c554bd1a0b76ea92b9f105fe36d9c7b0}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
+@@ -107,7 +107,7 @@ my $xd2 = q| \entry{xd2}{book}{}
+ \strng{authornamehash}{68539e0ce4922cc4957c6cabf35e6fc8}
+ \strng{authorfullhash}{68539e0ce4922cc4957c6cabf35e6fc8}
+ \field{sortinit}{P}
+- \field{sortinithash}{8d51b3d5b78d75b54308d706b9bbe285}
++ \field{sortinithash}{bb5b15f2db90f7aef79bb9e83defefcb}
+ \field{extradatescope}{labelyear}
+ \field{labeldatesource}{}
+ \field{labelnamesource}{author}
diff --git a/gnu/packages/patches/binutils-mingw-w64-deterministic.patch b/gnu/packages/patches/binutils-mingw-w64-deterministic.patch
new file mode 100644
index 0000000000..3e48b87935
--- /dev/null
+++ b/gnu/packages/patches/binutils-mingw-w64-deterministic.patch
@@ -0,0 +1,22 @@
+This following patch was originally found at the debian mingw-w64 team's
+binutils repo located here:
+https://salsa.debian.org/mingw-w64-team/binutils-mingw-w64.git
+
+Invoke the following in the aforementioned repo to see the original patch:
+
+ $ git show da63f6b:debian/patches/reproducible-import-libraries.patch
+
+Description: Make DLL import libraries reproducible
+Author: Benjamin Moody <benjamin.moody@gmail.com>
+Bug-Debian: https://bugs.debian.org/915055
+
+--- a/ld/pe-dll.c
++++ b/ld/pe-dll.c
+@@ -2844,6 +2844,7 @@
+
+ bfd_set_format (outarch, bfd_archive);
+ outarch->has_armap = 1;
++ outarch->flags |= BFD_DETERMINISTIC_OUTPUT;
+
+ /* Work out a reasonable size of things to put onto one line. */
+ ar_head = make_head (outarch);
diff --git a/gnu/packages/patches/binutils-mingw-w64-timestamp.patch b/gnu/packages/patches/binutils-mingw-w64-timestamp.patch
new file mode 100644
index 0000000000..b785043b62
--- /dev/null
+++ b/gnu/packages/patches/binutils-mingw-w64-timestamp.patch
@@ -0,0 +1,137 @@
+This following patch was originally found at the debian mingw-w64 team's
+binutils repo located here:
+https://salsa.debian.org/mingw-w64-team/binutils-mingw-w64.git
+
+Invoke the following in the aforementioned repo to see the original patch:
+
+ $ git show da63f6b:debian/patches/specify-timestamp.patch
+
+Description: Allow the PE timestamp to be specified
+Author: Stephen Kitt <skitt@debian.org>
+
+--- a/bfd/peXXigen.c
++++ b/bfd/peXXigen.c
+@@ -70,6 +70,9 @@
+ #include <wctype.h>
+ #endif
+
++#include <errno.h>
++#include <limits.h>
++
+ /* NOTE: it's strange to be including an architecture specific header
+ in what's supposed to be general (to PE/PEI) code. However, that's
+ where the definitions are, and they don't vary per architecture
+@@ -879,10 +882,38 @@
+
+ /* Use a real timestamp by default, unless the no-insert-timestamp
+ option was chosen. */
+- if ((pe_data (abfd)->insert_timestamp))
+- H_PUT_32 (abfd, time (0), filehdr_out->f_timdat);
+- else
++ if (pe_data (abfd)->insert_timestamp) {
++ time_t now;
++ char *source_date_epoch;
++ unsigned long long epoch;
++ char *endptr;
++
++ now = time(NULL);
++ source_date_epoch = getenv("SOURCE_DATE_EPOCH");
++ if (source_date_epoch) {
++ errno = 0;
++ epoch = strtoull(source_date_epoch, &endptr, 10);
++ if ((errno == ERANGE && (epoch == ULLONG_MAX || epoch == 0))
++ || (errno != 0 && epoch == 0)) {
++ _bfd_error_handler("Environment variable $SOURCE_DATE_EPOCH: strtoull: %s\n",
++ strerror(errno));
++ } else if (endptr == source_date_epoch) {
++ _bfd_error_handler("Environment variable $SOURCE_DATE_EPOCH: No digits were found: %s\n",
++ endptr);
++ } else if (*endptr != '\0') {
++ _bfd_error_handler("Environment variable $SOURCE_DATE_EPOCH: Trailing garbage: %s\n",
++ endptr);
++ } else if (epoch > ULONG_MAX) {
++ _bfd_error_handler("Environment variable $SOURCE_DATE_EPOCH: value must be smaller than or equal to: %lu but was found to be: %llu\n",
++ ULONG_MAX, epoch);
++ } else {
++ now = epoch;
++ }
++ }
++ H_PUT_32 (abfd, now, filehdr_out->f_timdat);
++ } else {
+ H_PUT_32 (abfd, 0, filehdr_out->f_timdat);
++ }
+
+ PUT_FILEHDR_SYMPTR (abfd, filehdr_in->f_symptr,
+ filehdr_out->f_symptr);
+--- a/ld/pe-dll.c
++++ b/ld/pe-dll.c
+@@ -26,6 +26,8 @@
+ #include "filenames.h"
+ #include "safe-ctype.h"
+
++#include <errno.h>
++#include <limits.h>
+ #include <time.h>
+
+ #include "ld.h"
+@@ -1202,8 +1204,36 @@
+
+ memset (edata_d, 0, edata_sz);
+
+- if (pe_data (abfd)->insert_timestamp)
+- H_PUT_32 (abfd, time (0), edata_d + 4);
++ if (pe_data (abfd)->insert_timestamp) {
++ time_t now;
++ char *source_date_epoch;
++ unsigned long long epoch;
++ char *endptr;
++
++ now = time(NULL);
++ source_date_epoch = getenv("SOURCE_DATE_EPOCH");
++ if (source_date_epoch) {
++ errno = 0;
++ epoch = strtoull(source_date_epoch, &endptr, 10);
++ if ((errno == ERANGE && (epoch == ULLONG_MAX || epoch == 0))
++ || (errno != 0 && epoch == 0)) {
++ einfo("Environment variable $SOURCE_DATE_EPOCH: strtoull: %s\n",
++ strerror(errno));
++ } else if (endptr == source_date_epoch) {
++ einfo("Environment variable $SOURCE_DATE_EPOCH: No digits were found: %s\n",
++ endptr);
++ } else if (*endptr != '\0') {
++ einfo("Environment variable $SOURCE_DATE_EPOCH: Trailing garbage: %s\n",
++ endptr);
++ } else if (epoch > ULONG_MAX) {
++ einfo("Environment variable $SOURCE_DATE_EPOCH: value must be smaller than or equal to: %lu but was found to be: %llu\n",
++ ULONG_MAX, epoch);
++ } else {
++ now = epoch;
++ }
++ }
++ H_PUT_32 (abfd, now, edata_d + 4);
++ }
+
+ if (pe_def_file->version_major != -1)
+ {
+--- a/ld/emultempl/pe.em
++++ b/ld/emultempl/pe.em
+@@ -303,7 +303,7 @@
+ OPTION_USE_NUL_PREFIXED_IMPORT_TABLES},
+ {"no-leading-underscore", no_argument, NULL, OPTION_NO_LEADING_UNDERSCORE},
+ {"leading-underscore", no_argument, NULL, OPTION_LEADING_UNDERSCORE},
+- {"insert-timestamp", no_argument, NULL, OPTION_INSERT_TIMESTAMP},
++ {"insert-timestamp", optional_argument, NULL, OPTION_INSERT_TIMESTAMP},
+ {"no-insert-timestamp", no_argument, NULL, OPTION_NO_INSERT_TIMESTAMP},
+ #ifdef DLL_SUPPORT
+ /* getopt allows abbreviations, so we do this to stop it
+--- a/ld/emultempl/pep.em
++++ b/ld/emultempl/pep.em
+@@ -321,7 +321,7 @@
+ {"no-bind", no_argument, NULL, OPTION_NO_BIND},
+ {"wdmdriver", no_argument, NULL, OPTION_WDM_DRIVER},
+ {"tsaware", no_argument, NULL, OPTION_TERMINAL_SERVER_AWARE},
+- {"insert-timestamp", no_argument, NULL, OPTION_INSERT_TIMESTAMP},
++ {"insert-timestamp", optional_argument, NULL, OPTION_INSERT_TIMESTAMP},
+ {"no-insert-timestamp", no_argument, NULL, OPTION_NO_INSERT_TIMESTAMP},
+ {"build-id", optional_argument, NULL, OPTION_BUILD_ID},
+ {NULL, no_argument, NULL, 0}
diff --git a/gnu/packages/patches/calibre-msgpack-compat.patch b/gnu/packages/patches/calibre-msgpack-compat.patch
new file mode 100644
index 0000000000..9920103bea
--- /dev/null
+++ b/gnu/packages/patches/calibre-msgpack-compat.patch
@@ -0,0 +1,18 @@
+Fix deserialization with msgpack 1.0.
+
+Patch copied from upstream source repository:
+https://github.com/kovidgoyal/calibre/commit/0ff41ac64994ec11b7859fc004c94d08769e3af3
+
+diff --git a/src/calibre/utils/serialize.py b/src/calibre/utils/serialize.py
+index f5d560c468..c35ae53849 100644
+--- a/src/calibre/utils/serialize.py
++++ b/src/calibre/utils/serialize.py
+@@ -110,7 +110,7 @@ def msgpack_decoder(code, data):
+ def msgpack_loads(dump, use_list=True):
+ # use_list controls whether msgpack arrays are unpacked as lists or tuples
+ import msgpack
+- return msgpack.unpackb(dump, ext_hook=msgpack_decoder, raw=False, use_list=use_list)
++ return msgpack.unpackb(dump, ext_hook=msgpack_decoder, raw=False, use_list=use_list, strict_map_key=False)
+
+
+ def json_loads(data):
diff --git a/gnu/packages/patches/clang-10.0-libc-search-path.patch b/gnu/packages/patches/clang-10.0-libc-search-path.patch
new file mode 100644
index 0000000000..966e40b93c
--- /dev/null
+++ b/gnu/packages/patches/clang-10.0-libc-search-path.patch
@@ -0,0 +1,84 @@
+Clang attempts to guess file names based on the OS and distro (yes!),
+but unfortunately, that doesn't work for us.
+
+This patch makes it easy to insert libc's $libdir so that Clang passes the
+correct absolute file name of crt1.o etc. to 'ld'. It also disables all
+the distro-specific stuff and removes the hard-coded FHS directory names
+to make sure Clang also works on non-Guix systems.
+
+diff --git a/lib/Driver/ToolChains/Linux.cpp b/lib/Driver/ToolChains/Linux.cpp
+index bff1ab10..79e1477e 100644
+--- a/lib/Driver/ToolChains/Linux.cpp
++++ b/lib/Driver/ToolChains/Linux.cpp
+@@ -240,6 +240,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ .str());
+ }
+
++// Comment out the distro-specific tweaks so that they don't bite when
++// using Guix on a foreign distro.
++#if 0
+ Distro Distro(D.getVFS(), Triple);
+
+ if (Distro.IsAlpineLinux() || Triple.isAndroid()) {
+@@ -306,6 +309,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+
+ if (IsAndroid || Distro.IsOpenSUSE())
+ ExtraOpts.push_back("--enable-new-dtags");
++#endif // Guix
+
+ // The selection of paths to try here is designed to match the patterns which
+ // the GCC driver itself uses, as this is part of the GCC-compatible driver.
+@@ -363,7 +367,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ // the cross. Note that GCC does include some of these directories in some
+ // configurations but this seems somewhere between questionable and simply
+ // a bug.
+- if (StringRef(LibPath).startswith(SysRoot)) {
++ if (0) {
+ addPathIfExists(D, LibPath + "/" + MultiarchTriple, Paths);
+ addPathIfExists(D, LibPath + "/../" + OSLibDir, Paths);
+ }
+@@ -382,6 +386,8 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ addPathIfExists(D, SysRoot + "/lib/" + MultiarchTriple, Paths);
+ addPathIfExists(D, SysRoot + "/lib/../" + OSLibDir, Paths);
+
++// This requires the commented distro tweaks above.
++#if 0
+ if (IsAndroid) {
+ // Android sysroots contain a library directory for each supported OS
+ // version as well as some unversioned libraries in the usual multiarch
+@@ -410,10 +416,15 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ addPathIfExists(D, SysRoot + "/" + OSLibDir + "/" + ABIName, Paths);
+ addPathIfExists(D, SysRoot + "/usr/" + OSLibDir + "/" + ABIName, Paths);
+ }
++#endif
+
+ // Try walking via the GCC triple path in case of biarch or multiarch GCC
+ // installations with strange symlinks.
+ if (GCCInstallation.isValid()) {
++
++// The following code would end up adding things like
++// "/usr/lib/x86_64-unknown-linux-gnu/../../lib64" to the search path.
++#if 0
+ addPathIfExists(D,
+ SysRoot + "/usr/lib/" + GCCInstallation.getTriple().str() +
+ "/../../" + OSLibDir,
+@@ -426,6 +437,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ BiarchSibling.gccSuffix(),
+ Paths);
+ }
++#endif
+
+ // See comments above on the multilib variant for details of why this is
+ // included even from outside the sysroot.
+@@ -450,8 +462,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ if (StringRef(D.Dir).startswith(SysRoot))
+ addPathIfExists(D, D.Dir + "/../lib", Paths);
+
+- addPathIfExists(D, SysRoot + "/lib", Paths);
+- addPathIfExists(D, SysRoot + "/usr/lib", Paths);
++ // Add libc's lib/ directory to the search path, so that crt1.o, crti.o,
++ // and friends can be found.
++ addPathIfExists(D, "@GLIBC_LIBDIR@", Paths);
+ }
+
+ ToolChain::CXXStdlibType Linux::GetDefaultCXXStdlibType() const {
diff --git a/gnu/packages/patches/dbacl-include-locale.h.patch b/gnu/packages/patches/dbacl-include-locale.h.patch
new file mode 100644
index 0000000000..40d5d0aa44
--- /dev/null
+++ b/gnu/packages/patches/dbacl-include-locale.h.patch
@@ -0,0 +1,36 @@
+From: Tobias Geerinckx-Rice <me@tobias.gr>
+Date: Sat, 11 Apr 2020 03:02:04 +0200
+Subject: [PATCH] gnu: dbacl: Include <locale.h> in dbacl.h.
+
+Copied verbatim[0] from Debian.
+
+[0]: https://sources.debian.org/data/main/d/dbacl/1.14.1-2/debian/patches/05-locale-h.patch
+
+Description: Add missing <locale.h> include in dbacl.h
+Author: Fabian Wolff <fabi.wolff@arcor.de>
+Bug-Debian: https://bugs.debian.org/916182
+Last-Update: 2019-08-25
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/src/dbacl.h
++++ b/src/dbacl.h
+@@ -21,6 +21,8 @@
+ #ifndef DBACL_H
+ #define DBACL_H
+
++#include <locale.h>
++
+ #ifdef HAVE_CONFIG_H
+ #undef HAVE_CONFIG_H
+ #include "config.h"
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -28,7 +28,7 @@
+ # stuff_SOURCES = stuff.c stuff.h fram.c stuff-lexer.l stuff-parser.y stuff-parser.h probs.c util.c util.h $(PUBDOM)
+ # stuff_LDADD = @LEXLIB@
+
+-AM_CFLAGS = -funsigned-char -std=c99 -Wall -pedantic $(CFLAGSIEEE) -O3
++AM_CFLAGS = -funsigned-char -std=c99 -D_XOPEN_SOURCE=700 -Wall -pedantic $(CFLAGSIEEE) -O3
+ AM_YFLAGS = -d
+
+ CLEANFILES = mailcross mailtoe mailfoot
diff --git a/gnu/packages/patches/dune-istl-2.7-fix-non-mpi-tests.patch b/gnu/packages/patches/dune-istl-2.7-fix-non-mpi-tests.patch
new file mode 100644
index 0000000000..ee2bb8f676
--- /dev/null
+++ b/gnu/packages/patches/dune-istl-2.7-fix-non-mpi-tests.patch
@@ -0,0 +1,82 @@
+Fix build of dune-istl's tests
+
+Patch copied from upstream source repository:
+
+https://gitlab.dune-project.org/core/dune-istl/-/commit/9eee3462df5a64881c08574f9291e76db398de0a
+
+From 9eee3462df5a64881c08574f9291e76db398de0a Mon Sep 17 00:00:00 2001
+From: Felix Gruber <felgru@posteo.net>
+Date: Sat, 4 Apr 2020 15:27:09 +0200
+Subject: [PATCH] make tests succeed when MPI is disabled
+
+When MPI is not available or explicitly disabled with the CMake build
+option -DCMAKE_IDSABLE_FIND_PACKAGE_MPI=TRUE, some tests were unable to
+build.
+
+The tests created from solverfactorytest.cc.in and part of
+scalarproductstest.cc use Dune::OwnerOverlapCopyCommunication which is
+defined behind `#if HAVE_MPI` and is thus not available in a non-MPI
+build. I've thus disabled those tests when MPI is unavailable.
+
+The matrixmarkettest did not work without MPI, as it contained some code
+using the wrong template parameters when HAVE_MPI was not set. Those
+template paramters have been fixed now.
+
+I've confirmed, that after my changes `make build_tests` succeeds to
+build all tests and that those tests run without failure.
+---
+ dune/istl/test/CMakeLists.txt | 3 ++-
+ dune/istl/test/matrixmarkettest.cc | 2 +-
+ dune/istl/test/scalarproductstest.cc | 2 ++
+ 3 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/dune/istl/test/CMakeLists.txt b/dune/istl/test/CMakeLists.txt
+index ffd87969..2c7b2387 100644
+--- a/dune/istl/test/CMakeLists.txt
++++ b/dune/istl/test/CMakeLists.txt
+@@ -77,7 +77,8 @@ set(DUNE_TEST_FACTORY_BLOCK_SIZES
+ function(add_factory_test BLOCK)
+ STRING(REGEX REPLACE "[^a-zA-Z0-9]" "" BLOCK_CLEAN ${BLOCK})
+ configure_file(solverfactorytest.cc.in solverfactorytest_${BLOCK_CLEAN}.cc)
+- dune_add_test(SOURCES ${CMAKE_CURRENT_BINARY_DIR}/solverfactorytest_${BLOCK_CLEAN}.cc)
++ dune_add_test(SOURCES ${CMAKE_CURRENT_BINARY_DIR}/solverfactorytest_${BLOCK_CLEAN}.cc
++ CMAKE_GUARD HAVE_MPI)
+ endfunction(add_factory_test)
+
+ foreach(FIELD_TYPE ${DUNE_TEST_FACTORY_FIELD_TYPES})
+diff --git a/dune/istl/test/matrixmarkettest.cc b/dune/istl/test/matrixmarkettest.cc
+index b335afe6..ce30e8ae 100644
+--- a/dune/istl/test/matrixmarkettest.cc
++++ b/dune/istl/test/matrixmarkettest.cc
+@@ -52,7 +52,7 @@ int testMatrixMarket(int N)
+ storeMatrixMarket(mat, std::string("testmat"), comm);
+ storeMatrixMarket(bv, std::string("testvec"), comm, false);
+ #else
+- typedef Dune::MatrixAdapter<BCRSMat,BVector,BVector> Operator;
++ typedef Dune::MatrixAdapter<Matrix,Vector,Vector> Operator;
+ Operator op(mat);
+ op.apply(bv, cv);
+
+diff --git a/dune/istl/test/scalarproductstest.cc b/dune/istl/test/scalarproductstest.cc
+index 452b1d89..f46ce2a9 100644
+--- a/dune/istl/test/scalarproductstest.cc
++++ b/dune/istl/test/scalarproductstest.cc
+@@ -115,6 +115,7 @@ int main(int argc, char** argv)
+ scalarProductTest<ScalarProduct, Vector>(scalarProduct,numBlocks);
+ }
+
++#if HAVE_MPI
+ // Test the ParallelScalarProduct class
+ {
+ using Vector = BlockVector<FieldVector<double,BlockSize> >;
+@@ -139,6 +140,7 @@ int main(int argc, char** argv)
+ ScalarProduct scalarProduct(communicator,SolverCategory::nonoverlapping);
+ scalarProductTest<ScalarProduct, Vector>(scalarProduct,numBlocks);
+ }
++#endif
+
+ return t.exit();
+ }
+--
+2.25.1
+
diff --git a/gnu/packages/patches/emacs-dired-toggle-sudo-emacs-26.patch b/gnu/packages/patches/emacs-dired-toggle-sudo-emacs-26.patch
deleted file mode 100644
index d979b113d0..0000000000
--- a/gnu/packages/patches/emacs-dired-toggle-sudo-emacs-26.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 3c0f4b27a079b90dc632f5061a81ce28cef24801 Mon Sep 17 00:00:00 2001
-From: eryx67 <eryx67@gmail.com>
-Date: Thu, 29 Nov 2018 10:30:20 +0500
-Subject: [PATCH] fix for latest emacs
-
----
- dired-toggle-sudo.el | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
-
-diff --git a/dired-toggle-sudo.el b/dired-toggle-sudo.el
-index 386921b..fe5898e 100644
---- a/dired-toggle-sudo.el
-+++ b/dired-toggle-sudo.el
-@@ -37,17 +37,20 @@
- unless SUDO-USER is provided."
- (let* (;; Handle the case of local files. `tramp-dissect-file-name' does
- ;; not raise an error anymore.
-- (path (if (tramp-tramp-file-p path) path (concat "/:" path)))
-+ ;;(path (if (tramp-tramp-file-p path) path (concat "/-::" path)))
- (file-vec (or (ignore-errors (tramp-dissect-file-name
- path))
- (tramp-dissect-file-name
-- (concat "/:" path) 1)))
-+ (concat "/-::" path) 1)))
- (method (tramp-file-name-method file-vec))
- (user (tramp-file-name-user file-vec))
- (host (tramp-file-name-host file-vec))
-+ (domain (tramp-file-name-domain file-vec))
-+ (port (tramp-file-name-port file-vec))
- (localname (expand-file-name
- (tramp-file-name-localname file-vec))))
-- (when (string= system-name host)
-+ (when (or (string= (system-name) host)
-+ (string= "-" host))
- (setq host nil))
- (cond
- ;; remote directory -> sudo
-@@ -67,7 +70,7 @@ unless SUDO-USER is provided."
- (setq method "sudo" user sudo-user)))
- (replace-regexp-in-string
- "^/:/" "/"
-- (tramp-make-tramp-file-name method user host localname))))
-+ (tramp-make-tramp-file-name method domain user host port localname))))
-
- (defun dired-toggle-sudo-find (fname)
- "Create a new buffer for file name FNAME."
---
-2.22.0
-
diff --git a/gnu/packages/patches/emacs-telega-test-env.patch b/gnu/packages/patches/emacs-telega-test-env.patch
new file mode 100644
index 0000000000..75fe2e12fc
--- /dev/null
+++ b/gnu/packages/patches/emacs-telega-test-env.patch
@@ -0,0 +1,14 @@
+Test Emacs environment on startup.
+
+Patch by Diego N. Barbato
+
+--- a/telega.el 2020-02-07 17:07:18.549970090 +0100
++++ b/telega.el 2020-02-07 17:10:08.383499765 +0100
+@@ -82,6 +82,7 @@
+ "Start telegramming.
+ If prefix ARG is given, then will not pop to telega root buffer."
+ (interactive "P")
++ (telega-test-env t)
+ (telega--create-hier)
+
+ (unless (telega-server-live-p)
diff --git a/gnu/packages/patches/gdm-default-session.patch b/gnu/packages/patches/gdm-default-session.patch
new file mode 100644
index 0000000000..4839a04de4
--- /dev/null
+++ b/gnu/packages/patches/gdm-default-session.patch
@@ -0,0 +1,91 @@
+This patch ensures '.desktop' files are picked up in the system profile
+and not in the directories listed in $XDG_DATA_DIRS. The latter includes
+'gnome-session.desktop', which should be used if it's in
+/run/current-system/profile, and only then.
+
+Fixes <https://bugs.gnu.org/37831>.
+
+diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
+index 6a116a8..02c1458 100644
+--- a/daemon/gdm-session.c
++++ b/daemon/gdm-session.c
+@@ -348,24 +348,18 @@ get_system_session_dirs (GdmSession *self)
+ GArray *search_array = NULL;
+ char **search_dirs;
+ int i;
+- const gchar * const *system_data_dirs = g_get_system_data_dirs ();
+
+ static const char *x_search_dirs[] = {
+ "/etc/X11/sessions/",
+ DMCONFDIR "/Sessions/",
+ DATADIR "/gdm/BuiltInSessions/",
+- DATADIR "/xsessions/",
++ "/run/current-system/profile/share/xsessions/"
+ };
+
+ static const char *wayland_search_dir = DATADIR "/wayland-sessions/";
+
+ search_array = g_array_new (TRUE, TRUE, sizeof (char *));
+
+- for (i = 0; system_data_dirs[i]; i++) {
+- gchar *dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
+- g_array_append_val (search_array, dir);
+- }
+-
+ g_array_append_vals (search_array, x_search_dirs, G_N_ELEMENTS (x_search_dirs));
+
+ #ifdef ENABLE_WAYLAND_SUPPORT
+@@ -373,16 +367,7 @@ get_system_session_dirs (GdmSession *self)
+ #ifdef ENABLE_USER_DISPLAY_SERVER
+ g_array_prepend_val (search_array, wayland_search_dir);
+
+- for (i = 0; system_data_dirs[i]; i++) {
+- gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
+- g_array_insert_val (search_array, i, dir);
+- }
+ #else
+- for (i = 0; system_data_dirs[i]; i++) {
+- gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
+- g_array_append_val (search_array, dir);
+- }
+-
+ g_array_append_val (search_array, wayland_search_dir);
+ #endif
+ }
+diff --git a/libgdm/gdm-sessions.c b/libgdm/gdm-sessions.c
+index afbc5c0..bb5e3e6 100644
+--- a/libgdm/gdm-sessions.c
++++ b/libgdm/gdm-sessions.c
+@@ -238,19 +238,11 @@ collect_sessions (void)
+ "/etc/X11/sessions/",
+ DMCONFDIR "/Sessions/",
+ DATADIR "/gdm/BuiltInSessions/",
+- DATADIR "/xsessions/",
+- NULL
++ "/run/current-system/profile/share/xsessions/"
+ };
+
+ xorg_search_array = g_array_new (TRUE, TRUE, sizeof (char *));
+
+- const gchar * const *system_data_dirs = g_get_system_data_dirs ();
+-
+- for (i = 0; system_data_dirs[i]; i++) {
+- session_dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
+- g_array_append_val (xorg_search_array, session_dir);
+- }
+-
+ g_array_append_vals (xorg_search_array, xorg_search_dirs, G_N_ELEMENTS (xorg_search_dirs));
+
+ #ifdef ENABLE_WAYLAND_SUPPORT
+@@ -261,11 +253,6 @@ collect_sessions (void)
+
+ wayland_search_array = g_array_new (TRUE, TRUE, sizeof (char *));
+
+- for (i = 0; system_data_dirs[i]; i++) {
+- session_dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
+- g_array_append_val (wayland_search_array, session_dir);
+- }
+-
+ g_array_append_vals (wayland_search_array, wayland_search_dirs, G_N_ELEMENTS (wayland_search_dirs));
+ #endif
+
diff --git a/gnu/packages/patches/gnupg-default-pinentry.patch b/gnu/packages/patches/gnupg-default-pinentry.patch
new file mode 100644
index 0000000000..a8ed613565
--- /dev/null
+++ b/gnu/packages/patches/gnupg-default-pinentry.patch
@@ -0,0 +1,65 @@
+Make GnuPG automatically find a pinentry installed by Guix. Try using
+$HOME or, if that variable is not set, use the system password database,
+or fall back to looking in "/".
+
+More information:
+
+https://bugs.gnu.org/24076
+
+diff --git a/common/homedir.c b/common/homedir.c
+index 4b6e46e88..f7ae68ba5 100644
+--- a/common/homedir.c
++++ b/common/homedir.c
+@@ -33,6 +33,7 @@
+ #include <errno.h>
+ #include <fcntl.h>
+ #include <unistd.h>
++#include <pwd.h>
+
+ #ifdef HAVE_W32_SYSTEM
+ #include <winsock2.h> /* Due to the stupid mingw64 requirement to
+@@ -67,6 +68,10 @@
+ * gnupg_homedir and gnupg_set_homedir. Malloced. */
+ static char *the_gnupg_homedir;
+
++/* The user's home directory. Used in Guix to help GnuPG find the
++ * pinentry. */
++static char *the_user_homedir;
++
+ /* Flag indicating that home directory is not the default one. */
+ static byte non_default_homedir;
+
+@@ -509,6 +514,25 @@ gnupg_homedir (void)
+ return the_gnupg_homedir;
+ }
+
++/* Return the user's home directory */
++const char *
++user_homedir (void)
++{
++ const char *dir;
++ dir = getenv("HOME");
++ if (dir == NULL)
++ {
++ struct passwd *pw = NULL;
++ pw = getpwuid (getuid ());
++ if (pw != NULL)
++ dir = pw->pw_dir;
++ else
++ dir = "/";
++ }
++ if (!the_user_homedir)
++ the_user_homedir = make_absfilename (dir, NULL);
++ return the_user_homedir;
++}
+
+ /* Return whether the home dir is the default one. */
+ int
+@@ -971,6 +995,7 @@ get_default_pinentry_name (int reset)
+ } names[] = {
+ /* The first entry is what we return in case we found no
+ other pinentry. */
++ { user_homedir, "/.guix-profile/bin/pinentry" },
+ { gnupg_bindir, DIRSEP_S "pinentry" EXEEXT_S },
+ #ifdef HAVE_W32_SYSTEM
+ /* Try Gpg4win directory (with bin and without.) */
diff --git a/gnu/packages/patches/hash-extender-test-suite.patch b/gnu/packages/patches/hash-extender-test-suite.patch
deleted file mode 100644
index 59de52dad4..0000000000
--- a/gnu/packages/patches/hash-extender-test-suite.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-Make the test suite exit with a non-zero exit code if some tests failed.
-Pull request pending upstream: https://github.com/iagox86/hash_extender/pull/13
---- a/test.c
-+++ b/test.c
-@@ -79,5 +79,9 @@ void test_report(void)
- printf("TESTS PASSED: %d / %d [%2.4f%%]\n", tests_passed, tests_run, 100 * (float)tests_passed / tests_run);
- printf("--------------------------------------------------------------------------------\n");
- }
-+
-+ if (tests_passed != tests_run) {
-+ exit(1);
-+ }
- }
diff --git a/gnu/packages/patches/higan-remove-march-native-flag.patch b/gnu/packages/patches/higan-remove-march-native-flag.patch
deleted file mode 100644
index 30d4cdd061..0000000000
--- a/gnu/packages/patches/higan-remove-march-native-flag.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Remove -march=native from build flags.
-
---- a/higan/GNUmakefile
-+++ b/higan/GNUmakefile
-@@ -26,7 +26,6 @@
- flags += -fopenmp
- link += -fopenmp
- ifeq ($(binary),application)
-- flags += -march=native
- link += -Wl,-export-dynamic
- link += -lX11 -lXext
- else ifeq ($(binary),library)
diff --git a/gnu/packages/patches/icecat-makeicecat.patch b/gnu/packages/patches/icecat-makeicecat.patch
index a90d7fdee8..c2c59ec855 100644
--- a/gnu/packages/patches/icecat-makeicecat.patch
+++ b/gnu/packages/patches/icecat-makeicecat.patch
@@ -25,7 +25,7 @@ index 8be2362..48716f2 100755
-wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz.asc
-gpg --recv-keys --keyserver keyserver.ubuntu.com 14F26682D0916CDD81E37B6D61B7B526D98F0353
-gpg --verify firefox-${FFVERSION}esr.source.tar.xz.asc
--echo -n 2428213ceb75cb6772b3044d9c14870d1ae5b0161379aeb29248650e13761c9f firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c -
+-echo -n ad3ea069c3d23aab360ad04ff4d0f5e556d3538f7dd4eae0690c4e9241537570 firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c -
-
-echo Extracting Firefox tarball
-tar -xf firefox-${FFVERSION}esr.source.tar.xz
@@ -37,7 +37,7 @@ index 8be2362..48716f2 100755
+# wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz.asc
+# gpg --recv-keys --keyserver keyserver.ubuntu.com 14F26682D0916CDD81E37B6D61B7B526D98F0353
+# gpg --verify firefox-${FFVERSION}esr.source.tar.xz.asc
-+# echo -n 2428213ceb75cb6772b3044d9c14870d1ae5b0161379aeb29248650e13761c9f firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c -
++# echo -n ad3ea069c3d23aab360ad04ff4d0f5e556d3538f7dd4eae0690c4e9241537570 firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c -
+#
+# echo Extracting Firefox tarball
+# tar -xf firefox-${FFVERSION}esr.source.tar.xz
diff --git a/gnu/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch b/gnu/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch
new file mode 100644
index 0000000000..32dfd7b856
--- /dev/null
+++ b/gnu/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch
@@ -0,0 +1,28 @@
+--- /dev/null
++++ b/gnu/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch
+@@ -0,0 +1,22 @@
++Fix one of upstream non-determinism, tracked here:
++
++https://github.com/JuliaLang/julia/issues/34115
++https://github.com/JuliaLang/julia/issues/25900
++
++
++Patch by Nicoló Balzarotti <nicolo@nixo.xyz>.
++
++--- a/base/loading.jl
+++++ b/base/loading.jl
++@@ -807,7 +807,10 @@
++ path = normpath(joinpath(dirname(prev), _path))
++ end
++ if _track_dependencies[]
++- push!(_require_dependencies, (mod, path, mtime(path)))
+++ push!(_require_dependencies,
+++ (mod, path,
+++ haskey(ENV, "SOURCE_DATE_EPOCH") ?
+++ parse(Float64, ENV["SOURCE_DATE_EPOCH"]) : mtime(path)))
++ end
++ return path, prev
++ end
+--
+2.26.0
+
diff --git a/gnu/packages/patches/kmscon-runtime-keymap-switch.patch b/gnu/packages/patches/kmscon-runtime-keymap-switch.patch
index 656c76fa40..deb5688daf 100644
--- a/gnu/packages/patches/kmscon-runtime-keymap-switch.patch
+++ b/gnu/packages/patches/kmscon-runtime-keymap-switch.patch
@@ -1,14 +1,5 @@
-From 360d44d67e7be46108bec982ff2e79b89f04a9a3 Mon Sep 17 00:00:00 2001
-From: Mathieu Othacehe <m.othacehe@gmail.com>
-Date: Thu, 15 Nov 2018 14:34:40 +0900
-Subject: [PATCH] add runtime keymap switch support.
-
----
- src/pty.c | 23 ++++++++++-
- src/uterm_input.c | 2 +
- src/uterm_input_internal.h | 5 +++
- src/uterm_input_uxkb.c | 83 ++++++++++++++++++++++++++++++++++++++
- 4 files changed, 111 insertions(+), 2 deletions(-)
+By Mathieu Othacehe <m.othacehe@gmail.com>.
+Modified by Florian Pelz <pelzflorian@pelzflorian.de>.
diff --git a/src/pty.c b/src/pty.c
index 1443f4a..f64cb5b 100644
@@ -124,7 +115,7 @@ index 04e6cc9..ec44459 100644
uint16_t key_state,
uint16_t code);
diff --git a/src/uterm_input_uxkb.c b/src/uterm_input_uxkb.c
-index 925c755..4760972 100644
+index 925c755..5d5c22e 100644
--- a/src/uterm_input_uxkb.c
+++ b/src/uterm_input_uxkb.c
@@ -31,6 +31,9 @@
@@ -137,7 +128,7 @@ index 925c755..4760972 100644
#include <xkbcommon/xkbcommon.h>
#include "shl_hook.h"
#include "shl_llog.h"
-@@ -178,6 +181,86 @@ static void timer_event(struct ev_timer *timer, uint64_t num, void *data)
+@@ -178,6 +181,87 @@ static void timer_event(struct ev_timer *timer, uint64_t num, void *data)
shl_hook_call(dev->input->hook, dev->input, &dev->repeat_event);
}
@@ -145,11 +136,11 @@ index 925c755..4760972 100644
+{
+ struct uterm_input_dev *dev = data;
+ char in;
-+ char keymap[3][255];
++ char keymap[4][255];
+ int pos = 0;
+ int curr_keymap = 0;
+ int ret;
-+ char *model, *layout, *variant;
++ char *model, *layout, *variant, *options;
+
+ if (!(mask & EV_READABLE))
+ return;
@@ -159,6 +150,7 @@ index 925c755..4760972 100644
+ model = keymap[0];
+ layout = keymap[1];
+ variant = keymap[2];
++ options = keymap[3];
+
+ do {
+ ret = read(dev->rupdate_fd, &in, sizeof(in));
@@ -175,7 +167,7 @@ index 925c755..4760972 100644
+
+ llog_info(dev->input, "HANDLER CALLED %s|%s|%s\n",
+ model, layout, variant);
-+ uxkb_desc_init(dev->input, model, layout, variant, NULL, NULL);
++ uxkb_desc_init(dev->input, model, layout, variant, options, NULL);
+
+ dev->state = xkb_state_new(dev->input->keymap);
+ if (!dev->state) {
@@ -224,6 +216,3 @@ index 925c755..4760972 100644
int uxkb_dev_init(struct uterm_input_dev *dev)
{
int ret;
---
-2.17.1
-
diff --git a/gnu/packages/patches/libqalculate-3.8.0-libcurl-ssl-fix.patch b/gnu/packages/patches/libqalculate-3.8.0-libcurl-ssl-fix.patch
new file mode 100644
index 0000000000..b638963874
--- /dev/null
+++ b/gnu/packages/patches/libqalculate-3.8.0-libcurl-ssl-fix.patch
@@ -0,0 +1,53 @@
+Author: R Veera Kumar 2020 <vkor@vkten.in>
+Desc:
+ 1) Fixes download of exchange rates by specifying SSL CA certificates bundle
+ file while using libcurl (Since libcurl in guix is compiled without using
+ a default CA cert bundle file)
+ 2) Like above fix for using https site in another case
+
+diff -uNr libqalculate-3.8.0/libqalculate/Calculator-definitions.cc libqalculate-3.8.0.new/libqalculate/Calculator-definitions.cc
+--- libqalculate-3.8.0/libqalculate/Calculator-definitions.cc 2020-02-16 15:08:29.000000000 +0530
++++ libqalculate-3.8.0.new/libqalculate/Calculator-definitions.cc 2020-04-17 21:27:36.386039369 +0530
+@@ -3610,6 +3610,7 @@
+ curl = curl_easy_init();
+ if(!curl) {return false;}
+ curl_easy_setopt(curl, CURLOPT_URL, getExchangeRatesUrl(1).c_str());
++ curl_easy_setopt(curl, CURLOPT_CAINFO, getenv("SSL_CERT_FILE"));
+ curl_easy_setopt(curl, CURLOPT_TIMEOUT, timeout);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, &sbuffer);
+@@ -3663,6 +3664,7 @@
+
+ sbuffer = "";
+ curl_easy_setopt(curl, CURLOPT_URL, getExchangeRatesUrl(2).c_str());
++ curl_easy_setopt(curl, CURLOPT_CAINFO, getenv("SSL_CERT_FILE"));
+ curl_easy_setopt(curl, CURLOPT_TIMEOUT, timeout);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, &sbuffer);
+@@ -3687,6 +3689,7 @@
+
+ sbuffer = "";
+ curl_easy_setopt(curl, CURLOPT_URL, getExchangeRatesUrl(3).c_str());
++ curl_easy_setopt(curl, CURLOPT_CAINFO, getenv("SSL_CERT_FILE"));
+ curl_easy_setopt(curl, CURLOPT_TIMEOUT, timeout);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, &sbuffer);
+@@ -3710,6 +3713,7 @@
+
+ sbuffer = "";
+ curl_easy_setopt(curl, CURLOPT_URL, getExchangeRatesUrl(4).c_str());
++ curl_easy_setopt(curl, CURLOPT_CAINFO, getenv("SSL_CERT_FILE"));
+ curl_easy_setopt(curl, CURLOPT_TIMEOUT, (timeout > 4 && n <= 0) ? 4 : timeout);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, &sbuffer);
+diff -uNr libqalculate-3.8.0/libqalculate/util.cc libqalculate-3.8.0.new/libqalculate/util.cc
+--- libqalculate-3.8.0/libqalculate/util.cc 2019-12-14 22:56:45.000000000 +0530
++++ libqalculate-3.8.0.new/libqalculate/util.cc 2020-04-17 21:12:17.259674572 +0530
+@@ -769,6 +769,7 @@
+ curl = curl_easy_init();
+ if(!curl) {return -1;}
+ curl_easy_setopt(curl, CURLOPT_URL, "https://qalculate.github.io/CURRENT_VERSIONS");
++ curl_easy_setopt(curl, CURLOPT_CAINFO, getenv("SSL_CERT_FILE"));
+ curl_easy_setopt(curl, CURLOPT_TIMEOUT, timeout);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_data);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, &sbuffer);
diff --git a/gnu/packages/patches/libvpx-use-after-free-in-postproc.patch b/gnu/packages/patches/libvpx-use-after-free-in-postproc.patch
deleted file mode 100644
index 04f2a953b7..0000000000
--- a/gnu/packages/patches/libvpx-use-after-free-in-postproc.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 52add5896661d186dec284ed646a4b33b607d2c7 Mon Sep 17 00:00:00 2001
-From: Jerome Jiang <jianj@google.com>
-Date: Wed, 23 May 2018 15:43:00 -0700
-Subject: [PATCH] VP8: Fix use-after-free in postproc.
-
-The pointer in vp8 postproc refers to show_frame_mi which is only
-updated on show frame. However, when there is a no-show frame which also
-changes the size (thus new frame buffers allocated), show_frame_mi is
-not updated with new frame buffer memory.
-
-Change the pointer in postproc to mi which is always updated.
-
-Bug: 842265
-Change-Id: I33874f2112b39f74562cba528432b5f239e6a7bd
----
- vp8/common/postproc.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/vp8/common/postproc.c b/vp8/common/postproc.c
-index d67ee8a57..8c292d616 100644
---- a/vp8/common/postproc.c
-+++ b/vp8/common/postproc.c
-@@ -65,7 +65,7 @@ void vp8_deblock(VP8_COMMON *cm, YV12_BUFFER_CONFIG *source,
- double level = 6.0e-05 * q * q * q - .0067 * q * q + .306 * q + .0065;
- int ppl = (int)(level + .5);
-
-- const MODE_INFO *mode_info_context = cm->show_frame_mi;
-+ const MODE_INFO *mode_info_context = cm->mi;
- int mbr, mbc;
-
- /* The pixel thresholds are adjusted according to if or not the macroblock
---
-2.19.0
-
diff --git a/gnu/packages/patches/mediastreamer2-srtp2.patch b/gnu/packages/patches/mediastreamer2-srtp2.patch
new file mode 100644
index 0000000000..f6d494facb
--- /dev/null
+++ b/gnu/packages/patches/mediastreamer2-srtp2.patch
@@ -0,0 +1,155 @@
+From 97903498364ae2596e790cb2c2ce9ac76c04d64a Mon Sep 17 00:00:00 2001
+From: Danmei Chen <danmei.chen@belledonne-communications.com>
+Date: Fri, 19 Jan 2018 10:04:07 +0100
+Subject: [PATCH] add compability with srtp2
+
+---
+ cmake/FindSRTP.cmake | 24 ++++++++++++++++++++----
+ src/CMakeLists.txt | 1 +
+ src/crypto/ms_srtp.c | 10 ++--------
+ src/utils/srtp_prefix.h | 41 +++++++++++++++++++++++++++++++++++++++++
+ 4 files changed, 64 insertions(+), 12 deletions(-)
+ create mode 100644 src/utils/srtp_prefix.h
+
+diff --git a/cmake/FindSRTP.cmake b/cmake/FindSRTP.cmake
+index 988b846a..f720ce7e 100644
+--- a/cmake/FindSRTP.cmake
++++ b/cmake/FindSRTP.cmake
+@@ -31,20 +31,36 @@ set(_SRTP_ROOT_PATHS
+ )
+
+ find_path(SRTP_INCLUDE_DIRS
+- NAMES srtp/srtp.h
++ NAMES srtp2/srtp.h
+ HINTS _SRTP_ROOT_PATHS
+ PATH_SUFFIXES include
+ )
+
+ if(SRTP_INCLUDE_DIRS)
+ set(HAVE_SRTP_SRTP_H 1)
+-endif()
+-
+-find_library(SRTP_LIBRARIES
++ set(SRTP_VERSION 2)
++ find_library(SRTP_LIBRARIES
++ NAMES srtp2
++ HINTS ${_SRTP_ROOT_PATHS}
++ PATH_SUFFIXES bin lib
++ )
++else()
++ find_path(SRTP_INCLUDE_DIRS
++ NAMES srtp/srtp.h
++ HINTS _SRTP_ROOT_PATHS
++ PATH_SUFFIXES include
++ )
++ if(SRTP_INCLUDE_DIRS)
++ set(HAVE_SRTP_SRTP_H 1)
++ set(SRTP_VERSION 1)
++ endif()
++ find_library(SRTP_LIBRARIES
+ NAMES srtp
+ HINTS ${_SRTP_ROOT_PATHS}
+ PATH_SUFFIXES bin lib
+ )
++endif()
++
+
+ include(FindPackageHandleStandardArgs)
+ find_package_handle_standard_args(SRTP
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index da429764..c46faa62 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -183,6 +183,7 @@ set(VOIP_SOURCE_FILES_C
+ utils/pcap_sender.c
+ utils/pcap_sender.h
+ utils/stream_regulator.c
++ utils/srtp_prefix.h
+ voip/audioconference.c
+ voip/audiostream.c
+ voip/bandwidthcontroller.c
+diff --git a/src/crypto/ms_srtp.c b/src/crypto/ms_srtp.c
+index 5a510c99..67810316 100644
+--- a/src/crypto/ms_srtp.c
++++ b/src/crypto/ms_srtp.c
+@@ -25,6 +25,7 @@
+ #include "mediastreamer2/ms_srtp.h"
+ #include "mediastreamer2/mediastream.h"
+
++
+ #ifdef HAVE_SRTP
+
+ /*srtp defines all this stuff*/
+@@ -34,13 +35,7 @@
+ #undef PACKAGE_TARNAME
+ #undef PACKAGE_VERSION
+
+-#if defined(MS2_WINDOWS_PHONE)
+-// Windows phone doesn't use make install
+-#include <srtp.h>
+-#else
+-#include <srtp/srtp.h>
+-#endif
+-
++#include "srtp_prefix.h"
+
+ #include "ortp/b64.h"
+
+@@ -352,7 +347,6 @@ int ms_srtp_init(void)
+ srtp_init_done++;
+ }else{
+ ms_fatal("Couldn't initialize SRTP library: %d.", st);
+- err_reporting_init("mediastreamer2");
+ }
+ }else srtp_init_done++;
+ return (int)st;
+diff --git a/src/utils/srtp_prefix.h b/src/utils/srtp_prefix.h
+new file mode 100644
+index 00000000..68bde496
+--- /dev/null
++++ b/src/utils/srtp_prefix.h
+@@ -0,0 +1,41 @@
++/*
++ mediastreamer2 library - modular sound and video processing and streaming
++ Copyright (C) 2006-2014 Belledonne Communications, Grenoble
++
++ This 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.
++
++ This 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 this library; if not, write to the Free Software
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++*/
++#ifndef __SRTP2_H__
++#define __SRTP2_H__
++
++#if defined(MS2_WINDOWS_PHONE)
++// Windows phone doesn't use make install
++#include <srtp.h>
++#elif SRTP_VERSION==1
++#include <srtp/srtp.h>
++#else
++#include <srtp2/srtp.h>
++#define err_status_t srtp_err_status_t
++#define err_status_ok srtp_err_status_ok
++#define crypto_policy_t srtp_crypto_policy_t
++#define crypto_policy_set_aes_cm_256_hmac_sha1_80 srtp_crypto_policy_set_aes_cm_256_hmac_sha1_80
++#define crypto_policy_set_aes_cm_128_hmac_sha1_32 srtp_crypto_policy_set_aes_cm_128_hmac_sha1_32
++#define crypto_policy_set_aes_cm_128_null_auth srtp_crypto_policy_set_aes_cm_128_null_auth
++#define crypto_policy_set_null_cipher_hmac_sha1_80 srtp_crypto_policy_set_null_cipher_hmac_sha1_80
++#define crypto_policy_set_aes_cm_128_hmac_sha1_80 srtp_crypto_policy_set_aes_cm_128_hmac_sha1_80
++#define crypto_policy_set_aes_cm_256_hmac_sha1_32 srtp_crypto_policy_set_aes_cm_256_hmac_sha1_32
++#define ssrc_t srtp_ssrc_t
++#endif
++
++#endif
+--
+2.21.0
+
diff --git a/gnu/packages/patches/mingw-w64-dlltool-temp-prefix.patch b/gnu/packages/patches/mingw-w64-dlltool-temp-prefix.patch
new file mode 100644
index 0000000000..432cafc162
--- /dev/null
+++ b/gnu/packages/patches/mingw-w64-dlltool-temp-prefix.patch
@@ -0,0 +1,26 @@
+This following patch was originally found at the debian mingw-w64 team's
+mingw-w64 repo located here:
+https://salsa.debian.org/mingw-w64-team/mingw-w64.git
+
+Invoke the following in the aforementioned repo to see the original patch:
+
+ $ git show 4974e2c:debian/patches/dlltool-temp-prefix.patch
+
+Description: Specify dlltool's temp prefix
+Author: Stephen Kitt <steve@sk2.org>
+
+By default dlltool uses its pid for the object files it generates.
+Enforcing its temp prefix allows the files it generates to be
+reproducible.
+
+--- a/mingw-w64-crt/Makefile.am
++++ b/mingw-w64-crt/Makefile.am
+@@ -36,7 +36,7 @@
+ DTDEF32=$(GENLIB) $(DLLTOOLFLAGS32) $(AM_DLLTOOLFLAGS)
+ DTDEF64=$(GENLIB) $(DLLTOOLFLAGS64) $(AM_DLLTOOLFLAGS)
+ else
+- AM_DLLTOOLFLAGS=-k --as=$(AS) --output-lib $@
++ AM_DLLTOOLFLAGS=-k --as=$(AS) --output-lib $@ --temp-prefix $$(basename $@ .a)
+ DLLTOOLFLAGSARM32=-m arm
+ DLLTOOLFLAGSARM64=-m arm64
+ DLLTOOLFLAGS32=--as-flags=--32 -m i386
diff --git a/gnu/packages/patches/mingw-w64-reproducible-gendef.patch b/gnu/packages/patches/mingw-w64-reproducible-gendef.patch
new file mode 100644
index 0000000000..ee676af7a0
--- /dev/null
+++ b/gnu/packages/patches/mingw-w64-reproducible-gendef.patch
@@ -0,0 +1,23 @@
+This following patch was originally found at the debian mingw-w64 team's
+mingw-w64 repo located here:
+https://salsa.debian.org/mingw-w64-team/mingw-w64.git
+
+Invoke the following in the aforementioned repo to see the original patch:
+
+ $ git show 4974e2c:debian/patches/reproducible-gendef.patch
+
+Description: Drop __DATE__ from gendef
+Author: Stephen Kitt <skitt@debian.org>
+
+This allows gendef to be built reproducibly.
+
+--- a/mingw-w64-tools/gendef/src/gendef.c
++++ b/mingw-w64-tools/gendef/src/gendef.c
+@@ -196,7 +196,6 @@
+ " By default, the output files are named after their DLL counterparts\n"
+ " gendef MYDLL.DLL Produces MYDLL.def\n"
+ " gendef - MYDLL.DLL Prints the exports to stdout\n");
+- fprintf (stderr, "\nBuilt on %s\n", __DATE__);
+ fprintf (stderr, "\nReport bugs to <mingw-w64-public@lists.sourceforge.net>\n");
+ exit (0);
+ }
diff --git a/gnu/packages/patches/openldap-CVE-2020-12243.patch b/gnu/packages/patches/openldap-CVE-2020-12243.patch
new file mode 100644
index 0000000000..6321998198
--- /dev/null
+++ b/gnu/packages/patches/openldap-CVE-2020-12243.patch
@@ -0,0 +1,125 @@
+From 98464c11df8247d6a11b52e294ba5dd4f0380440 Mon Sep 17 00:00:00 2001
+From: Howard Chu <hyc@openldap.org>
+Date: Thu, 16 Apr 2020 01:08:19 +0100
+Subject: [PATCH] ITS#9202 limit depth of nested filters
+
+Using a hardcoded limit for now; no reasonable apps
+should ever run into it.
+---
+ servers/slapd/filter.c | 41 ++++++++++++++++++++++++++++++++---------
+ 1 file changed, 32 insertions(+), 9 deletions(-)
+
+diff --git a/servers/slapd/filter.c b/servers/slapd/filter.c
+index 3252cf2a7..ed57bbd7b 100644
+--- a/servers/slapd/filter.c
++++ b/servers/slapd/filter.c
+@@ -37,11 +37,16 @@
+ const Filter *slap_filter_objectClass_pres;
+ const struct berval *slap_filterstr_objectClass_pres;
+
++#ifndef SLAPD_MAX_FILTER_DEPTH
++#define SLAPD_MAX_FILTER_DEPTH 5000
++#endif
++
+ static int get_filter_list(
+ Operation *op,
+ BerElement *ber,
+ Filter **f,
+- const char **text );
++ const char **text,
++ int depth );
+
+ static int get_ssa(
+ Operation *op,
+@@ -80,12 +85,13 @@ filter_destroy( void )
+ return;
+ }
+
+-int
+-get_filter(
++static int
++get_filter0(
+ Operation *op,
+ BerElement *ber,
+ Filter **filt,
+- const char **text )
++ const char **text,
++ int depth )
+ {
+ ber_tag_t tag;
+ ber_len_t len;
+@@ -126,6 +132,11 @@ get_filter(
+ *
+ */
+
++ if( depth > SLAPD_MAX_FILTER_DEPTH ) {
++ *text = "filter nested too deeply";
++ return SLAPD_DISCONNECT;
++ }
++
+ tag = ber_peek_tag( ber, &len );
+
+ if( tag == LBER_ERROR ) {
+@@ -221,7 +232,7 @@ get_filter(
+
+ case LDAP_FILTER_AND:
+ Debug( LDAP_DEBUG_FILTER, "AND\n", 0, 0, 0 );
+- err = get_filter_list( op, ber, &f.f_and, text );
++ err = get_filter_list( op, ber, &f.f_and, text, depth+1 );
+ if ( err != LDAP_SUCCESS ) {
+ break;
+ }
+@@ -234,7 +245,7 @@ get_filter(
+
+ case LDAP_FILTER_OR:
+ Debug( LDAP_DEBUG_FILTER, "OR\n", 0, 0, 0 );
+- err = get_filter_list( op, ber, &f.f_or, text );
++ err = get_filter_list( op, ber, &f.f_or, text, depth+1 );
+ if ( err != LDAP_SUCCESS ) {
+ break;
+ }
+@@ -248,7 +259,7 @@ get_filter(
+ case LDAP_FILTER_NOT:
+ Debug( LDAP_DEBUG_FILTER, "NOT\n", 0, 0, 0 );
+ (void) ber_skip_tag( ber, &len );
+- err = get_filter( op, ber, &f.f_not, text );
++ err = get_filter0( op, ber, &f.f_not, text, depth+1 );
+ if ( err != LDAP_SUCCESS ) {
+ break;
+ }
+@@ -311,10 +322,22 @@ get_filter(
+ return( err );
+ }
+
++int
++get_filter(
++ Operation *op,
++ BerElement *ber,
++ Filter **filt,
++ const char **text )
++{
++ return get_filter0( op, ber, filt, text, 0 );
++}
++
++
+ static int
+ get_filter_list( Operation *op, BerElement *ber,
+ Filter **f,
+- const char **text )
++ const char **text,
++ int depth )
+ {
+ Filter **new;
+ int err;
+@@ -328,7 +351,7 @@ get_filter_list( Operation *op, BerElement *ber,
+ tag != LBER_DEFAULT;
+ tag = ber_next_element( ber, &len, last ) )
+ {
+- err = get_filter( op, ber, new, text );
++ err = get_filter0( op, ber, new, text, depth );
+ if ( err != LDAP_SUCCESS )
+ return( err );
+ new = &(*new)->f_next;
+--
+2.26.2
+
diff --git a/gnu/packages/patches/pam-krb5-CVE-2020-10595.patch b/gnu/packages/patches/pam-krb5-CVE-2020-10595.patch
new file mode 100644
index 0000000000..4ca061230f
--- /dev/null
+++ b/gnu/packages/patches/pam-krb5-CVE-2020-10595.patch
@@ -0,0 +1,42 @@
+Fix CVE-2020-10595:
+
+https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-10595
+
+Patch copied from upstream advisory:
+
+https://seclists.org/oss-sec/2020/q1/128
+
+diff --git a/prompting.c b/prompting.c
+index e985d95..d81054f 100644
+--- a/prompting.c
++++ b/prompting.c
+@@ -314,26 +314,27 @@ pamk5_prompter_krb5(krb5_context context UNUSED, void *data, const char *name,
+ /*
+ * Reuse pam_prompts as a starting index and copy the data into the reply
+ * area of the krb5_prompt structs.
+ */
+ pam_prompts = 0;
+ if (name != NULL && !args->silent)
+ pam_prompts++;
+ if (banner != NULL && !args->silent)
+ pam_prompts++;
+ for (i = 0; i < num_prompts; i++, pam_prompts++) {
+- size_t len;
++ size_t len, allowed;
+
+ if (resp[pam_prompts].resp == NULL)
+ goto cleanup;
+ len = strlen(resp[pam_prompts].resp);
+- if (len > prompts[i].reply->length)
++ allowed = prompts[i].reply->length;
++ if (allowed == 0 || len > allowed - 1)
+ goto cleanup;
+
+ /*
+ * The trailing nul is not included in length, but other applications
+ * expect it to be there. Therefore, we copy one more byte than the
+ * actual length of the password, but set length to just the length of
+ * the password.
+ */
+ memcpy(prompts[i].reply->data, resp[pam_prompts].resp, len + 1);
+ prompts[i].reply->length = (unsigned int) len;
diff --git a/gnu/packages/patches/python-aiohttp-3.6.2-no-warning-fail.patch b/gnu/packages/patches/python-aiohttp-3.6.2-no-warning-fail.patch
new file mode 100644
index 0000000000..6cdddefd50
--- /dev/null
+++ b/gnu/packages/patches/python-aiohttp-3.6.2-no-warning-fail.patch
@@ -0,0 +1,34 @@
+Do not fail test on runtime warning like: RuntimeWarning: coroutine 'noop2' was
+never awaited. This could be related to
+https://github.com/aio-libs/aiohttp/commit/60f01cca36b9f9d8d35dd351384eaae2f8fd0d4b,
+which does not fix this issue though.
+
+--- a/aiohttp/pytest_plugin.py 2019-10-09 18:52:31.000000000 +0200
++++ b/aiohttp/pytest_plugin.py 2020-03-05 08:35:48.230396025 +0100
+@@ -120,15 +120,6 @@
+ """
+ with warnings.catch_warnings(record=True) as _warnings:
+ yield
+- rw = ['{w.filename}:{w.lineno}:{w.message}'.format(w=w)
+- for w in _warnings # type: ignore
+- if w.category == RuntimeWarning]
+- if rw:
+- raise RuntimeError('{} Runtime Warning{},\n{}'.format(
+- len(rw),
+- '' if len(rw) == 1 else 's',
+- '\n'.join(rw)
+- ))
+
+
+ @contextlib.contextmanager
+--- a/tests/test_pytest_plugin.py 2020-03-05 09:26:58.502284893 +0100
++++ a/tests/test_pytest_plugin.py 2020-03-05 09:27:06.074284619 +0100
+@@ -170,7 +170,7 @@
+ expected_outcomes = (
+ {'failed': 0, 'passed': 2}
+ if IS_PYPY and bool(os.environ.get('PYTHONASYNCIODEBUG'))
+- else {'failed': 1, 'passed': 1}
++ else {'failed': 0, 'passed': 2}
+ )
+ """Under PyPy "coroutine 'foobar' was never awaited" does not happen."""
+ result.assert_outcomes(**expected_outcomes)
diff --git a/gnu/packages/patches/python-jedi-deleted-variables.patch b/gnu/packages/patches/python-jedi-deleted-variables.patch
deleted file mode 100644
index 53bdc05cde..0000000000
--- a/gnu/packages/patches/python-jedi-deleted-variables.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-Fix test failure in some environments, including Guix.
-
-Taken from upstream:
-https://github.com/davidhalter/jedi/commit/bec87f7ff82b0731713c6520a14c213341b4cecf
-
-diff --git a/test/completion/basic.py b/test/completion/basic.py
-index b40068179..3ff919ca6 100644
---- a/test/completion/basic.py
-+++ b/test/completion/basic.py
-@@ -209,11 +209,11 @@ def global_as_import():
-
- deleted_var = 3
- del deleted_var
--#? int()
-+#?
- deleted_var
--#? ['deleted_var']
-+#? []
- deleted_var
--#! ['deleted_var = 3']
-+#! []
- deleted_var
-
- # -----------------
-diff --git a/test/test_api/test_full_name.py b/test/test_api/test_full_name.py
-index 4fdb861b0..6858b6ca8 100644
---- a/test/test_api/test_full_name.py
-+++ b/test/test_api/test_full_name.py
-@@ -112,7 +112,8 @@ def test_os_path(Script):
-
- def test_os_issues(Script):
- """Issue #873"""
-- assert [c.name for c in Script('import os\nos.nt''').complete()] == ['nt']
-+ # nt is not found, because it's deleted
-+ assert [c.name for c in Script('import os\nos.nt''').complete()] == []
-
-
- def test_param_name(Script):
diff --git a/gnu/packages/patches/python-jedi-sort-project-test.patch b/gnu/packages/patches/python-jedi-sort-project-test.patch
new file mode 100644
index 0000000000..b2d602dfe6
--- /dev/null
+++ b/gnu/packages/patches/python-jedi-sort-project-test.patch
@@ -0,0 +1,18 @@
+Sort the result of file system traversal to avoid test failure on different
+file systems.
+
+Taken from upstream:
+https://github.com/davidhalter/jedi/commit/7ff76bb7d0d94514e17cd1647f4ffaf533dd55f5
+
+diff --git a/test/test_api/test_project.py b/test/test_api/test_project.py
+--- a/test/test_api/test_project.py
++++ b/test/test_api/test_project.py
+@@ -135,7 +135,7 @@ def test_search(string, full_names, kwargs, skip_pre_python36):
+ defs = project.complete_search(string, **kwargs)
+ else:
+ defs = project.search(string, **kwargs)
+- assert [('stub:' if d.is_stub() else '') + d.full_name for d in defs] == full_names
++ assert sorted([('stub:' if d.is_stub() else '') + d.full_name for d in defs]) == full_names
+
+
+ @pytest.mark.parametrize(
diff --git a/gnu/packages/patches/reprotest-support-guix.patch b/gnu/packages/patches/reprotest-support-guix.patch
deleted file mode 100644
index 621c4e3359..0000000000
--- a/gnu/packages/patches/reprotest-support-guix.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From 31bd4fe777cbff3ebca74115e5735a8b8f584fa7 Mon Sep 17 00:00:00 2001
-From: Vagrant Cascadian <vagrant@reproducible-builds.org>
-Date: Thu, 6 Feb 2020 23:17:58 -0800
-Subject: [PATCH] Add support for GNU Guix.
-
----
- reprotest/lib/adt_testbed.py | 2 ++
- reprotest/lib/system_interface/guix.py | 39 ++++++++++++++++++++++++++
- 2 files changed, 41 insertions(+)
- create mode 100644 reprotest/lib/system_interface/guix.py
-
-diff --git a/reprotest/lib/adt_testbed.py b/reprotest/lib/adt_testbed.py
-index ef704d6..60bf763 100644
---- a/reprotest/lib/adt_testbed.py
-+++ b/reprotest/lib/adt_testbed.py
-@@ -40,6 +40,7 @@ import urllib.parse
- from reprotest.lib.system_interface.debian import DebianInterface
- from reprotest.lib.system_interface.arch import ArchInterface
- from reprotest.lib.system_interface.fedora import FedoraInterface
-+from reprotest.lib.system_interface.guix import GuixInterface
- from reprotest.lib import adtlog
- from reprotest.lib import VirtSubproc
-
-@@ -47,6 +48,7 @@ SYSTEM_INTERFACES = {
- 'debian': DebianInterface,
- 'arch': ArchInterface,
- 'fedora': FedoraInterface,
-+ 'guix': GuixInterface,
- }
-
- timeouts = {
-diff --git a/reprotest/lib/system_interface/guix.py b/reprotest/lib/system_interface/guix.py
-new file mode 100644
-index 0000000..2b06104
---- /dev/null
-+++ b/reprotest/lib/system_interface/guix.py
-@@ -0,0 +1,39 @@
-+# adt_testbed.py is part of autopkgtest
-+# autopkgtest is a tool for testing Debian binary packages. The
-+# system_interface module is an addition for reprotest to make
-+# this module distro-agnostic
-+#
-+# autopkgtest is Copyright (C) 2006-2015 Canonical Ltd.
-+# the system_interface module is Copyright (C) 2017 Santiago Torres-Arias
-+#
-+# This program 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 2 of the License, or
-+# (at your option) any later version.
-+#
-+# This program 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 this program; if not, write to the Free Software
-+# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+#
-+# See the file CREDITS for a full list of credits information (often
-+# installed as /usr/share/doc/autopkgtest/CREDITS).
-+import subprocess
-+
-+from . import SystemInterface
-+
-+class GuixInterface(SystemInterface):
-+ """
-+ SystemInterface implementation for GNU Guix hosts. Contains commands that
-+ are specific to the GNU Guix toolchain.
-+ """
-+
-+ def get_arch(self):
-+ return ['uname', '-m']
-+
-+ def can_query_packages(self):
-+ return False
---
-2.20.1
-
diff --git a/gnu/packages/patches/sdl-pango-fix-explicit-SDLPango_CopyFTBitmapTo.patch b/gnu/packages/patches/sdl-pango-header-guard.patch
index 3d4b10cc10..3d4b10cc10 100644
--- a/gnu/packages/patches/sdl-pango-fix-explicit-SDLPango_CopyFTBitmapTo.patch
+++ b/gnu/packages/patches/sdl-pango-header-guard.patch
diff --git a/gnu/packages/patches/sdl2-mesa-compat.patch b/gnu/packages/patches/sdl2-mesa-compat.patch
deleted file mode 100644
index 8182e582e7..0000000000
--- a/gnu/packages/patches/sdl2-mesa-compat.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Do not include GLES header when OpenGL headers are already included.
-
-Taken from upstream:
-https://hg.libsdl.org/SDL/rev/369b01006eb2
-
-diff -r 4cbaffd0083b -r 369b01006eb2 src/video/SDL_video.c
---- a/src/video/SDL_video.c Fri Oct 11 06:18:24 2019 +0200
-+++ b/src/video/SDL_video.c Sat Oct 12 18:47:56 2019 +0200
-@@ -37,9 +37,9 @@
- #include "SDL_opengl.h"
- #endif /* SDL_VIDEO_OPENGL */
-
--#if SDL_VIDEO_OPENGL_ES
-+#if SDL_VIDEO_OPENGL_ES && !SDL_VIDEO_OPENGL
- #include "SDL_opengles.h"
--#endif /* SDL_VIDEO_OPENGL_ES */
-+#endif /* SDL_VIDEO_OPENGL_ES && !SDL_VIDEO_OPENGL */
-
- /* GL and GLES2 headers conflict on Linux 32 bits */
- #if SDL_VIDEO_OPENGL_ES2 && !SDL_VIDEO_OPENGL
-
diff --git a/gnu/packages/patches/txr-shell.patch b/gnu/packages/patches/txr-shell.patch
deleted file mode 100644
index a4abb73eac..0000000000
--- a/gnu/packages/patches/txr-shell.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-Use the current shell instead of trying to find another one and
-failing to do so.
-
-diff --git a/configure b/configure
-index f1adb919..7891b4dc 100755
---- a/configure
-+++ b/configure
-@@ -26,28 +26,6 @@
- # OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
--#
--# The #!/bin/sh might be some legacy piece of crap,
--# not even up to 1990 POSIX.2 spec. So the first step
--# is to look for a better shell in some known places
--# and re-execute ourselves with that interpreter.
--#
--
--if test x$txr_shell = x ; then
-- for shell in /bin/bash /usr/bin/bash /usr/xpg4/bin/sh ; do
-- if test -x $shell ; then
-- txr_shell=$shell
-- break
-- fi
-- done
-- if test x$txr_shell = x ; then
-- echo "No known POSIX shell found: falling back on /bin/sh, which may not work"
-- txr_shell=/bin/sh
-- fi
-- export txr_shell
-- exec $txr_shell $0 ${@+"$@"}
--fi
--
- set -u
-
- #
-@@ -190,13 +168,6 @@ while [ $# -gt 0 ] ; do
- exit 1
- fi
-
-- eval "var_exists=\${$var+y}"
--
-- if [ "$var_exists" != y ] ; then
-- printf "$0: nonexistent option: '%s'\n" "$1"
-- exit 1
-- fi
--
- eval "$var='$val'"
-
- eval "var_given_exists=\${${var}_given+y}"
-@@ -208,6 +179,8 @@ while [ $# -gt 0 ] ; do
- shift
- done
-
-+txr_shell=$CONFIG_SHELL
-+
- #
- # If --help was given (or --help=<nonempty> or help=<nonempty>) then
- # print help and exit. The termination status is failed, to indicate
diff --git a/gnu/packages/patches/u-boot-DT-for-Pinebook-Pro.patch b/gnu/packages/patches/u-boot-DT-for-Pinebook-Pro.patch
new file mode 100644
index 0000000000..f88d12f1e2
--- /dev/null
+++ b/gnu/packages/patches/u-boot-DT-for-Pinebook-Pro.patch
@@ -0,0 +1,1132 @@
+From b128c2e0b480ee992fabe554d19cd471efb11095 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 20:27:35 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420192736.962307-5-pbrobinson@gmail.com/
+Subject: [PATCH 4/5] arm: dts: rockchip: Add initial DT for Pinebook Pro
+
+Sync initial support for Pinebook Pro device tree from Linux 5.7-rc1.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+---
+ arch/arm/dts/Makefile | 1 +
+ arch/arm/dts/rk3399-pinebook-pro.dts | 1096 ++++++++++++++++++++++++++
+ 2 files changed, 1097 insertions(+)
+ create mode 100644 arch/arm/dts/rk3399-pinebook-pro.dts
+
+diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
+index 820ee9733a..885bf0ef58 100644
+--- a/arch/arm/dts/Makefile
++++ b/arch/arm/dts/Makefile
+@@ -125,6 +125,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
+ rk3399-nanopi-m4.dtb \
+ rk3399-nanopi-neo4.dtb \
+ rk3399-orangepi.dtb \
++ rk3399-pinebook-pro.dtb \
+ rk3399-puma-ddr1333.dtb \
+ rk3399-puma-ddr1600.dtb \
+ rk3399-puma-ddr1866.dtb \
+diff --git a/arch/arm/dts/rk3399-pinebook-pro.dts b/arch/arm/dts/rk3399-pinebook-pro.dts
+new file mode 100644
+index 0000000000..294d21bf45
+--- /dev/null
++++ b/arch/arm/dts/rk3399-pinebook-pro.dts
+@@ -0,0 +1,1096 @@
++// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
++/*
++ * Copyright (c) 2017 Fuzhou Rockchip Electronics Co., Ltd.
++ * Copyright (c) 2018 Akash Gajjar <Akash_Gajjar@mentor.com>
++ * Copyright (c) 2020 Tobias Schramm <t.schramm@manjaro.org>
++ */
++
++/dts-v1/;
++#include <dt-bindings/input/gpio-keys.h>
++#include <dt-bindings/input/linux-event-codes.h>
++#include <dt-bindings/pwm/pwm.h>
++#include <dt-bindings/usb/pd.h>
++#include <dt-bindings/leds/common.h>
++#include "rk3399.dtsi"
++#include "rk3399-opp.dtsi"
++
++/ {
++ model = "Pine64 Pinebook Pro";
++ compatible = "pine64,pinebook-pro", "rockchip,rk3399";
++
++ chosen {
++ stdout-path = "serial2:1500000n8";
++ };
++
++ backlight: edp-backlight {
++ compatible = "pwm-backlight";
++ power-supply = <&vcc_12v>;
++ pwms = <&pwm0 0 740740 0>;
++ };
++
++ edp_panel: edp-panel {
++ compatible = "boe,nv140fhmn49";
++ backlight = <&backlight>;
++ enable-gpios = <&gpio1 RK_PA0 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&panel_en_gpio>;
++ power-supply = <&vcc3v3_panel>;
++
++ ports {
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ port@0 {
++ reg = <0>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ panel_in_edp: endpoint@0 {
++ reg = <0>;
++ remote-endpoint = <&edp_out_panel>;
++ };
++ };
++ };
++ };
++
++ /*
++ * Use separate nodes for gpio-keys to allow for selective deactivation
++ * of wakeup sources via sysfs without disabling the whole key
++ */
++ gpio-key-lid {
++ compatible = "gpio-keys";
++ pinctrl-names = "default";
++ pinctrl-0 = <&lidbtn_gpio>;
++
++ lid {
++ debounce-interval = <20>;
++ gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_LOW>;
++ label = "Lid";
++ linux,code = <SW_LID>;
++ linux,input-type = <EV_SW>;
++ wakeup-event-action = <EV_ACT_DEASSERTED>;
++ wakeup-source;
++ };
++ };
++
++ gpio-key-power {
++ compatible = "gpio-keys";
++ pinctrl-names = "default";
++ pinctrl-0 = <&pwrbtn_gpio>;
++
++ power {
++ debounce-interval = <20>;
++ gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>;
++ label = "Power";
++ linux,code = <KEY_POWER>;
++ wakeup-source;
++ };
++ };
++
++ leds {
++ compatible = "gpio-leds";
++ pinctrl-names = "default";
++ pinctrl-0 = <&pwrled_gpio &slpled_gpio>;
++
++ green-led {
++ color = <LED_COLOR_ID_GREEN>;
++ default-state = "on";
++ function = LED_FUNCTION_POWER;
++ gpios = <&gpio0 RK_PB3 GPIO_ACTIVE_HIGH>;
++ label = "green:power";
++ };
++
++ red-led {
++ color = <LED_COLOR_ID_RED>;
++ default-state = "off";
++ function = LED_FUNCTION_STANDBY;
++ gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>;
++ label = "red:standby";
++ panic-indicator;
++ retain-state-suspended;
++ };
++ };
++
++ /* Power sequence for SDIO WiFi module */
++ sdio_pwrseq: sdio-pwrseq {
++ compatible = "mmc-pwrseq-simple";
++ clocks = <&rk808 1>;
++ clock-names = "ext_clock";
++ pinctrl-names = "default";
++ pinctrl-0 = <&wifi_enable_h_gpio>;
++ post-power-on-delay-ms = <100>;
++ power-off-delay-us = <500000>;
++
++ /* WL_REG_ON on module */
++ reset-gpios = <&gpio0 RK_PB2 GPIO_ACTIVE_LOW>;
++ };
++
++ /* Audio components */
++ es8316-sound {
++ compatible = "simple-audio-card";
++ pinctrl-names = "default";
++ pinctrl-0 = <&hp_det_gpio>;
++ simple-audio-card,name = "rockchip,es8316-codec";
++ simple-audio-card,format = "i2s";
++ simple-audio-card,mclk-fs = <256>;
++
++ simple-audio-card,widgets =
++ "Microphone", "Mic Jack",
++ "Headphone", "Headphones",
++ "Speaker", "Speaker";
++ simple-audio-card,routing =
++ "MIC1", "Mic Jack",
++ "Headphones", "HPOL",
++ "Headphones", "HPOR",
++ "Speaker Amplifier INL", "HPOL",
++ "Speaker Amplifier INR", "HPOR",
++ "Speaker", "Speaker Amplifier OUTL",
++ "Speaker", "Speaker Amplifier OUTR";
++
++ simple-audio-card,hp-det-gpio = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>;
++ simple-audio-card,aux-devs = <&speaker_amp>;
++ simple-audio-card,pin-switches = "Speaker";
++
++ simple-audio-card,cpu {
++ sound-dai = <&i2s1>;
++ };
++
++ simple-audio-card,codec {
++ sound-dai = <&es8316>;
++ };
++ };
++
++ speaker_amp: speaker-amplifier {
++ compatible = "simple-audio-amplifier";
++ enable-gpios = <&gpio4 RK_PD3 GPIO_ACTIVE_HIGH>;
++ sound-name-prefix = "Speaker Amplifier";
++ VCC-supply = <&pa_5v>;
++ };
++
++ /* Power tree */
++ /* Root power source */
++ vcc_sysin: vcc-sysin {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc_sysin";
++ regulator-always-on;
++ regulator-boot-on;
++ };
++
++ /* Regulators supplied by vcc_sysin */
++ /* LCD backlight supply */
++ vcc_12v: vcc-12v {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc_12v";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <12000000>;
++ regulator-max-microvolt = <12000000>;
++ vin-supply = <&vcc_sysin>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* Main 3.3 V supply */
++ vcc3v3_sys: wifi_bat: vcc3v3-sys {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc3v3_sys";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <3300000>;
++ regulator-max-microvolt = <3300000>;
++ vin-supply = <&vcc_sysin>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ };
++ };
++
++ /* 5 V USB power supply */
++ vcc5v0_usb: pa_5v: vcc5v0-usb-regulator {
++ compatible = "regulator-fixed";
++ enable-active-high;
++ gpio = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&pwr_5v_gpio>;
++ regulator-name = "vcc5v0_usb";
++ regulator-always-on;
++ regulator-min-microvolt = <5000000>;
++ regulator-max-microvolt = <5000000>;
++ vin-supply = <&vcc_sysin>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* RK3399 logic supply */
++ vdd_log: vdd-log {
++ compatible = "pwm-regulator";
++ pwms = <&pwm2 0 25000 1>;
++ regulator-name = "vdd_log";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <800000>;
++ regulator-max-microvolt = <1400000>;
++ vin-supply = <&vcc_sysin>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ };
++ };
++
++ /* Regulators supplied by vcc3v3_sys */
++ /* 0.9 V supply, always on */
++ vcc_0v9: vcc-0v9 {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc_0v9";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <900000>;
++ regulator-max-microvolt = <900000>;
++ vin-supply = <&vcc3v3_sys>;
++ };
++
++ /* S3 1.8 V supply, switched by vcc1v8_s3 */
++ vcca1v8_s3: vcc1v8-s3 {
++ compatible = "regulator-fixed";
++ regulator-name = "vcca1v8_s3";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1800000>;
++ regulator-max-microvolt = <1800000>;
++ vin-supply = <&vcc3v3_sys>;
++ };
++
++ /* micro SD card power */
++ vcc3v0_sd: vcc3v0-sd {
++ compatible = "regulator-fixed";
++ enable-active-high;
++ gpio = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&sdmmc0_pwr_h_gpio>;
++ regulator-name = "vcc3v0_sd";
++ regulator-always-on;
++ regulator-min-microvolt = <3000000>;
++ regulator-max-microvolt = <3000000>;
++ vin-supply = <&vcc3v3_sys>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* LCD panel power, called VCC3V3_S0 in schematic */
++ vcc3v3_panel: vcc3v3-panel {
++ compatible = "regulator-fixed";
++ enable-active-high;
++ gpio = <&gpio1 RK_PC6 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&lcdvcc_en_gpio>;
++ regulator-name = "vcc3v3_panel";
++ regulator-always-on;
++ regulator-min-microvolt = <3300000>;
++ regulator-max-microvolt = <3300000>;
++ regulator-enable-ramp-delay = <100000>;
++ vin-supply = <&vcc3v3_sys>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* M.2 adapter power, switched by vcc1v8_s3 */
++ vcc3v3_ssd: vcc3v3-ssd {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc3v3_ssd";
++ regulator-min-microvolt = <3300000>;
++ regulator-max-microvolt = <3300000>;
++ vin-supply = <&vcc3v3_sys>;
++ };
++
++ /* Regulators supplied by vcc5v0_usb */
++ /* USB 3 port power supply regulator */
++ vcc5v0_otg: vcc5v0-otg {
++ compatible = "regulator-fixed";
++ enable-active-high;
++ gpio = <&gpio4 RK_PD2 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&vcc5v0_host_en_gpio>;
++ regulator-name = "vcc5v0_otg";
++ regulator-always-on;
++ regulator-min-microvolt = <5000000>;
++ regulator-max-microvolt = <5000000>;
++ vin-supply = <&vcc5v0_usb>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* Regulators supplied by vcc5v0_usb */
++ /* Type C port power supply regulator */
++ vbus_5vout: vbus_typec: vbus-5vout {
++ compatible = "regulator-fixed";
++ enable-active-high;
++ gpio = <&gpio1 RK_PA3 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&vcc5v0_typec0_en_gpio>;
++ regulator-name = "vbus_5vout";
++ regulator-min-microvolt = <5000000>;
++ regulator-max-microvolt = <5000000>;
++ vin-supply = <&vcc5v0_usb>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ /* Regulators supplied by vcc_1v8 */
++ /* Primary 0.9 V LDO */
++ vcca0v9_s3: vcca0v9-s3 {
++ compatible = "regulator-fixed";
++ regulator-name = "vcc0v9_s3";
++ regulator-min-microvolt = <5000000>;
++ regulator-max-microvolt = <5000000>;
++ vin-supply = <&vcc_1v8>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ };
++ };
++
++ mains_charger: dc-charger {
++ compatible = "gpio-charger";
++ charger-type = "mains";
++ gpios = <&gpio4 RK_PD0 GPIO_ACTIVE_LOW>;
++
++ /* Also triggered by USB charger */
++ pinctrl-names = "default";
++ pinctrl-0 = <&dc_det_gpio>;
++ };
++};
++
++&cdn_dp {
++ status = "okay";
++};
++
++&cpu_b0 {
++ cpu-supply = <&vdd_cpu_b>;
++};
++
++&cpu_b1 {
++ cpu-supply = <&vdd_cpu_b>;
++};
++
++&cpu_l0 {
++ cpu-supply = <&vdd_cpu_l>;
++};
++
++&cpu_l1 {
++ cpu-supply = <&vdd_cpu_l>;
++};
++
++&cpu_l2 {
++ cpu-supply = <&vdd_cpu_l>;
++};
++
++&cpu_l3 {
++ cpu-supply = <&vdd_cpu_l>;
++};
++
++&edp {
++ force-hpd;
++ pinctrl-names = "default";
++ pinctrl-0 = <&edp_hpd>;
++ status = "okay";
++
++ ports {
++ edp_out: port@1 {
++ reg = <1>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ edp_out_panel: endpoint@0 {
++ reg = <0>;
++ remote-endpoint = <&panel_in_edp>;
++ };
++ };
++ };
++};
++
++&emmc_phy {
++ status = "okay";
++};
++
++&gpu {
++ mali-supply = <&vdd_gpu>;
++ status = "okay";
++};
++
++&hdmi_sound {
++ status = "okay";
++};
++
++&i2c0 {
++ clock-frequency = <400000>;
++ i2c-scl-falling-time-ns = <4>;
++ i2c-scl-rising-time-ns = <168>;
++ status = "okay";
++
++ rk808: pmic@1b {
++ compatible = "rockchip,rk808";
++ reg = <0x1b>;
++ #clock-cells = <1>;
++ clock-output-names = "xin32k", "rk808-clkout2";
++ interrupt-parent = <&gpio3>;
++ interrupts = <10 IRQ_TYPE_LEVEL_LOW>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&pmic_int_l_gpio>;
++ rockchip,system-power-controller;
++ wakeup-source;
++
++ vcc1-supply = <&vcc_sysin>;
++ vcc2-supply = <&vcc_sysin>;
++ vcc3-supply = <&vcc_sysin>;
++ vcc4-supply = <&vcc_sysin>;
++ vcc6-supply = <&vcc_sysin>;
++ vcc7-supply = <&vcc_sysin>;
++ vcc8-supply = <&vcc3v3_sys>;
++ vcc9-supply = <&vcc_sysin>;
++ vcc10-supply = <&vcc_sysin>;
++ vcc11-supply = <&vcc_sysin>;
++ vcc12-supply = <&vcc3v3_sys>;
++ vcc13-supply = <&vcc_sysin>;
++ vcc14-supply = <&vcc_sysin>;
++
++ regulators {
++ /* rk3399 center logic supply */
++ vdd_center: DCDC_REG1 {
++ regulator-name = "vdd_center";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <750000>;
++ regulator-max-microvolt = <1350000>;
++ regulator-ramp-delay = <6001>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vdd_cpu_l: DCDC_REG2 {
++ regulator-name = "vdd_cpu_l";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <750000>;
++ regulator-max-microvolt = <1350000>;
++ regulator-ramp-delay = <6001>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vcc_ddr: DCDC_REG3 {
++ regulator-name = "vcc_ddr";
++ regulator-always-on;
++ regulator-boot-on;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ };
++ };
++
++ vcc_1v8: vcc_wl: DCDC_REG4 {
++ regulator-name = "vcc_1v8";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1800000>;
++ regulator-max-microvolt = <1800000>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ regulator-suspend-microvolt = <1800000>;
++ };
++ };
++
++ /* not used */
++ LDO_REG1 {
++ };
++
++ /* not used */
++ LDO_REG2 {
++ };
++
++ vcc1v8_pmupll: LDO_REG3 {
++ regulator-name = "vcc1v8_pmupll";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1800000>;
++ regulator-max-microvolt = <1800000>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ regulator-suspend-microvolt = <1800000>;
++ };
++ };
++
++ vcc_sdio: LDO_REG4 {
++ regulator-name = "vcc_sdio";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1800000>;
++ regulator-max-microvolt = <3000000>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ regulator-suspend-microvolt = <3000000>;
++ };
++ };
++
++ vcca3v0_codec: LDO_REG5 {
++ regulator-name = "vcca3v0_codec";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <3000000>;
++ regulator-max-microvolt = <3000000>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vcc_1v5: LDO_REG6 {
++ regulator-name = "vcc_1v5";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1500000>;
++ regulator-max-microvolt = <1500000>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ regulator-suspend-microvolt = <1500000>;
++ };
++ };
++
++ vcca1v8_codec: LDO_REG7 {
++ regulator-name = "vcca1v8_codec";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <1800000>;
++ regulator-max-microvolt = <1800000>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vcc_3v0: LDO_REG8 {
++ regulator-name = "vcc_3v0";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <3000000>;
++ regulator-max-microvolt = <3000000>;
++
++ regulator-state-mem {
++ regulator-on-in-suspend;
++ regulator-suspend-microvolt = <3000000>;
++ };
++ };
++
++ vcc3v3_s3: SWITCH_REG1 {
++ regulator-name = "vcc3v3_s3";
++ regulator-always-on;
++ regulator-boot-on;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vcc3v3_s0: SWITCH_REG2 {
++ regulator-name = "vcc3v3_s0";
++ regulator-always-on;
++ regulator-boot-on;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++ };
++ };
++
++ vdd_cpu_b: regulator@40 {
++ compatible = "silergy,syr827";
++ reg = <0x40>;
++ fcs,suspend-voltage-selector = <1>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&vsel1_gpio>;
++ regulator-name = "vdd_cpu_b";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <712500>;
++ regulator-max-microvolt = <1500000>;
++ regulator-ramp-delay = <1000>;
++ vin-supply = <&vcc_1v8>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++
++ vdd_gpu: regulator@41 {
++ compatible = "silergy,syr828";
++ reg = <0x41>;
++ fcs,suspend-voltage-selector = <1>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&vsel2_gpio>;
++ regulator-name = "vdd_gpu";
++ regulator-always-on;
++ regulator-boot-on;
++ regulator-min-microvolt = <712500>;
++ regulator-max-microvolt = <1500000>;
++ regulator-ramp-delay = <1000>;
++ vin-supply = <&vcc_1v8>;
++
++ regulator-state-mem {
++ regulator-off-in-suspend;
++ };
++ };
++};
++
++&i2c1 {
++ clock-frequency = <100000>;
++ i2c-scl-falling-time-ns = <4>;
++ i2c-scl-rising-time-ns = <168>;
++ status = "okay";
++
++ es8316: es8316@11 {
++ compatible = "everest,es8316";
++ reg = <0x11>;
++ clocks = <&cru SCLK_I2S_8CH_OUT>;
++ clock-names = "mclk";
++ #sound-dai-cells = <0>;
++ };
++};
++
++&i2c3 {
++ i2c-scl-falling-time-ns = <15>;
++ i2c-scl-rising-time-ns = <450>;
++ status = "okay";
++};
++
++&i2c4 {
++ i2c-scl-falling-time-ns = <20>;
++ i2c-scl-rising-time-ns = <600>;
++ status = "okay";
++
++ fusb0: fusb30x@22 {
++ compatible = "fcs,fusb302";
++ reg = <0x22>;
++ fcs,int_n = <&gpio1 RK_PA2 GPIO_ACTIVE_HIGH>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&fusb0_int_gpio>;
++ vbus-supply = <&vbus_typec>;
++
++ connector {
++ compatible = "usb-c-connector";
++ data-role = "host";
++ label = "USB-C";
++ op-sink-microwatt = <1000000>;
++ power-role = "dual";
++ sink-pdos =
++ <PDO_FIXED(5000, 2500, PDO_FIXED_USB_COMM)>;
++ source-pdos =
++ <PDO_FIXED(5000, 1400, PDO_FIXED_USB_COMM)>;
++ try-power-role = "sink";
++
++ ports {
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ port@0 {
++ reg = <0>;
++
++ usbc_hs: endpoint {
++ remote-endpoint =
++ <&u2phy0_typec_hs>;
++ };
++ };
++
++ port@1 {
++ reg = <1>;
++
++ usbc_ss: endpoint {
++ remote-endpoint =
++ <&tcphy0_typec_ss>;
++ };
++ };
++
++ port@2 {
++ reg = <2>;
++
++ usbc_dp: endpoint {
++ remote-endpoint =
++ <&tcphy0_typec_dp>;
++ };
++ };
++ };
++ };
++ };
++};
++
++&i2s1 {
++ #sound-dai-cells = <0>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&i2s_8ch_mclk_gpio>, <&i2s1_2ch_bus>;
++ rockchip,capture-channels = <8>;
++ rockchip,playback-channels = <8>;
++ status = "okay";
++};
++
++&io_domains {
++ audio-supply = <&vcc_3v0>;
++ gpio1830-supply = <&vcc_3v0>;
++ sdmmc-supply = <&vcc_sdio>;
++ status = "okay";
++};
++
++&pcie_phy {
++ status = "okay";
++};
++
++&pcie0 {
++ bus-scan-delay-ms = <1000>;
++ ep-gpios = <&gpio2 RK_PD4 GPIO_ACTIVE_HIGH>;
++ max-link-speed = <2>;
++ num-lanes = <4>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&pcie_clkreqn_cpm>;
++ vpcie0v9-supply = <&vcca0v9_s3>;
++ vpcie1v8-supply = <&vcca1v8_s3>;
++ vpcie3v3-supply = <&vcc3v3_ssd>;
++ status = "okay";
++};
++
++&pinctrl {
++ buttons {
++ pwrbtn_gpio: pwrbtn-gpio {
++ rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++
++ lidbtn_gpio: lidbtn-gpio {
++ rockchip,pins = <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ dc-charger {
++ dc_det_gpio: dc-det-gpio {
++ rockchip,pins = <4 RK_PD0 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ es8316 {
++ hp_det_gpio: hp-det-gpio {
++ rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ fusb302x {
++ fusb0_int_gpio: fusb0-int-gpio {
++ rockchip,pins = <1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ i2s1 {
++ i2s_8ch_mclk_gpio: i2s-8ch-mclk-gpio {
++ rockchip,pins = <4 RK_PA0 1 &pcfg_pull_none>;
++ };
++ };
++
++ lcd-panel {
++ lcdvcc_en_gpio: lcdvcc-en-gpio {
++ rockchip,pins = <1 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ panel_en_gpio: panel-en-gpio {
++ rockchip,pins = <1 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ lcd_panel_reset_gpio: lcd-panel-reset-gpio {
++ rockchip,pins = <4 RK_PD6 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ leds {
++ pwrled_gpio: pwrled_gpio {
++ rockchip,pins = <0 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ slpled_gpio: slpled_gpio {
++ rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++ };
++
++ pmic {
++ pmic_int_l_gpio: pmic-int-l-gpio {
++ rockchip,pins = <3 RK_PB2 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++
++ vsel1_gpio: vsel1-gpio {
++ rockchip,pins = <1 RK_PC1 RK_FUNC_GPIO &pcfg_pull_down>;
++ };
++
++ vsel2_gpio: vsel2-gpio {
++ rockchip,pins = <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>;
++ };
++ };
++
++ sdcard {
++ sdmmc0_pwr_h_gpio: sdmmc0-pwr-h-gpio {
++ rockchip,pins = <0 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ };
++
++ sdio-pwrseq {
++ wifi_enable_h_gpio: wifi-enable-h-gpio {
++ rockchip,pins = <0 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++ };
++
++ usb-typec {
++ vcc5v0_typec0_en_gpio: vcc5v0-typec0-en-gpio {
++ rockchip,pins = <1 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>;
++ };
++ };
++
++ usb2 {
++ pwr_5v_gpio: pwr-5v-gpio {
++ rockchip,pins = <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ vcc5v0_host_en_gpio: vcc5v0-host-en-gpio {
++ rockchip,pins = <4 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++ };
++
++ wireless-bluetooth {
++ bt_wake_gpio: bt-wake-gpio {
++ rockchip,pins = <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ bt_host_wake_gpio: bt-host-wake-gpio {
++ rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++
++ bt_reset_gpio: bt-reset-gpio {
++ rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>;
++ };
++ };
++};
++
++&pmu_io_domains {
++ pmu1830-supply = <&vcc_3v0>;
++ status = "okay";
++};
++
++&pwm0 {
++ status = "okay";
++};
++
++&pwm2 {
++ status = "okay";
++};
++
++&saradc {
++ vref-supply = <&vcca1v8_s3>;
++ status = "okay";
++};
++
++&sdmmc {
++ bus-width = <4>;
++ cap-mmc-highspeed;
++ cap-sd-highspeed;
++ cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_LOW>;
++ disable-wp;
++ pinctrl-names = "default";
++ pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_bus4>;
++ sd-uhs-sdr104;
++ vmmc-supply = <&vcc3v0_sd>;
++ vqmmc-supply = <&vcc_sdio>;
++ status = "okay";
++};
++
++&sdio0 {
++ bus-width = <4>;
++ cap-sd-highspeed;
++ cap-sdio-irq;
++ keep-power-in-suspend;
++ mmc-pwrseq = <&sdio_pwrseq>;
++ non-removable;
++ pinctrl-names = "default";
++ pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
++ sd-uhs-sdr104;
++ status = "okay";
++};
++
++&sdhci {
++ bus-width = <8>;
++ mmc-hs200-1_8v;
++ non-removable;
++ status = "okay";
++};
++
++&spi1 {
++ max-freq = <10000000>;
++ status = "okay";
++
++ spiflash: flash@0 {
++ compatible = "jedec,spi-nor";
++ reg = <0>;
++ m25p,fast-read;
++ spi-max-frequency = <10000000>;
++ };
++};
++
++&tcphy0 {
++ status = "okay";
++};
++
++&tcphy0_dp {
++ port {
++ tcphy0_typec_dp: endpoint {
++ remote-endpoint = <&usbc_dp>;
++ };
++ };
++};
++
++&tcphy0_usb3 {
++ port {
++ tcphy0_typec_ss: endpoint {
++ remote-endpoint = <&usbc_ss>;
++ };
++ };
++};
++
++&tcphy1 {
++ status = "okay";
++};
++
++&tsadc {
++ /* tshut mode 0:CRU 1:GPIO */
++ rockchip,hw-tshut-mode = <1>;
++ /* tshut polarity 0:LOW 1:HIGH */
++ rockchip,hw-tshut-polarity = <1>;
++ status = "okay";
++};
++
++&u2phy0 {
++ status = "okay";
++
++ u2phy0_otg: otg-port {
++ status = "okay";
++ };
++
++ u2phy0_host: host-port {
++ phy-supply = <&vcc5v0_otg>;
++ status = "okay";
++ };
++
++ port {
++ u2phy0_typec_hs: endpoint {
++ remote-endpoint = <&usbc_hs>;
++ };
++ };
++};
++
++&u2phy1 {
++ status = "okay";
++
++ u2phy1_otg: otg-port {
++ status = "okay";
++ };
++
++ u2phy1_host: host-port {
++ phy-supply = <&vcc5v0_otg>;
++ status = "okay";
++ };
++};
++
++&uart0 {
++ pinctrl-names = "default";
++ pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
++ uart-has-rtscts;
++ status = "okay";
++
++ bluetooth {
++ compatible = "brcm,bcm4345c5";
++ clocks = <&rk808 1>;
++ clock-names = "lpo";
++ device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
++ host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
++ max-speed = <1500000>;
++ pinctrl-names = "default";
++ pinctrl-0 = <&bt_host_wake_gpio &bt_wake_gpio &bt_reset_gpio>;
++ shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
++ vbat-supply = <&wifi_bat>;
++ vddio-supply = <&vcc_wl>;
++ };
++};
++
++&uart2 {
++ status = "okay";
++};
++
++&usb_host0_ehci {
++ status = "okay";
++};
++
++&usb_host0_ohci {
++ status = "okay";
++};
++
++&usb_host1_ehci {
++ status = "okay";
++};
++
++&usb_host1_ohci {
++ status = "okay";
++};
++
++&usbdrd3_0 {
++ status = "okay";
++};
++
++&usbdrd_dwc3_0 {
++ dr_mode = "host";
++ status = "okay";
++};
++
++&usbdrd3_1 {
++ status = "okay";
++};
++
++&usbdrd_dwc3_1 {
++ dr_mode = "host";
++ status = "okay";
++};
++
++&vopb {
++ status = "okay";
++};
++
++&vopb_mmu {
++ status = "okay";
++};
++
++&vopl {
++ status = "okay";
++};
++
++&vopl_mmu {
++ status = "okay";
++};
+--
+2.20.1
+
diff --git a/gnu/packages/patches/u-boot-add-boe-nv140fhmn49-display.patch b/gnu/packages/patches/u-boot-add-boe-nv140fhmn49-display.patch
new file mode 100644
index 0000000000..c359522967
--- /dev/null
+++ b/gnu/packages/patches/u-boot-add-boe-nv140fhmn49-display.patch
@@ -0,0 +1,29 @@
+From 00978950fed39b6104b6b4f141450a66cc3400fa Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 20:27:32 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420192736.962307-2-pbrobinson@gmail.com/
+Subject: [PATCH 1/5] video: simple_panel: add boe,nv140fhmn49 display
+
+add "boe,nv140fhmn49" display to compatible node.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+Cc: Anatolij Gustschin <agust@denx.de>
+---
+ drivers/video/simple_panel.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/drivers/video/simple_panel.c b/drivers/video/simple_panel.c
+index c3c0e84732..5722811117 100644
+--- a/drivers/video/simple_panel.c
++++ b/drivers/video/simple_panel.c
+@@ -105,6 +105,7 @@ static const struct udevice_id simple_panel_ids[] = {
+ { .compatible = "auo,b133xtn01" },
+ { .compatible = "auo,b116xw03" },
+ { .compatible = "auo,b133htn01" },
++ { .compatible = "boe,nv140fhmn49" },
+ { .compatible = "lg,lb070wv8" },
+ { }
+ };
+--
+2.20.1
+
diff --git a/gnu/packages/patches/u-boot-gpio-keys-binding-cons.patch b/gnu/packages/patches/u-boot-gpio-keys-binding-cons.patch
new file mode 100644
index 0000000000..aec33a7023
--- /dev/null
+++ b/gnu/packages/patches/u-boot-gpio-keys-binding-cons.patch
@@ -0,0 +1,37 @@
+From 451bd72bf966df7518682cb748a804634ea19424 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 20:27:33 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420192736.962307-3-pbrobinson@gmail.com/
+Subject: [PATCH 2/5] dt-bindings: input: adopt Linux gpio-keys binding
+ constants
+
+Sync the gpio-keys input bindings from linux 5.7-rc1.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+---
+ include/dt-bindings/input/gpio-keys.h | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+ create mode 100644 include/dt-bindings/input/gpio-keys.h
+
+diff --git a/include/dt-bindings/input/gpio-keys.h b/include/dt-bindings/input/gpio-keys.h
+new file mode 100644
+index 0000000000..8962df79e7
+--- /dev/null
++++ b/include/dt-bindings/input/gpio-keys.h
+@@ -0,0 +1,13 @@
++/* SPDX-License-Identifier: GPL-2.0 */
++/*
++ * This header provides constants for gpio keys bindings.
++ */
++
++#ifndef _DT_BINDINGS_GPIO_KEYS_H
++#define _DT_BINDINGS_GPIO_KEYS_H
++
++#define EV_ACT_ANY 0x00 /* asserted or deasserted */
++#define EV_ACT_ASSERTED 0x01 /* asserted */
++#define EV_ACT_DEASSERTED 0x02 /* deasserted */
++
++#endif /* _DT_BINDINGS_GPIO_KEYS_H */
+--
+2.20.1
+
diff --git a/gnu/packages/patches/u-boot-leds-common-binding-con.patch b/gnu/packages/patches/u-boot-leds-common-binding-con.patch
new file mode 100644
index 0000000000..837408120b
--- /dev/null
+++ b/gnu/packages/patches/u-boot-leds-common-binding-con.patch
@@ -0,0 +1,115 @@
+From 282b6ca04abbe1302d04caa05be5fc5afb127141 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 20:27:34 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420192736.962307-4-pbrobinson@gmail.com/
+Subject: [PATCH 3/5] dt-bindings: leds: adopt Linux leds common binding
+ constants
+
+Sync the common leds bindings from linux 5.7-rc1.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+---
+ include/dt-bindings/leds/common.h | 91 +++++++++++++++++++++++++++++++
+ 1 file changed, 91 insertions(+)
+ create mode 100644 include/dt-bindings/leds/common.h
+
+diff --git a/include/dt-bindings/leds/common.h b/include/dt-bindings/leds/common.h
+new file mode 100644
+index 0000000000..0ce7dfc00d
+--- /dev/null
++++ b/include/dt-bindings/leds/common.h
+@@ -0,0 +1,91 @@
++/* SPDX-License-Identifier: GPL-2.0 */
++/*
++ * This header provides macros for the common LEDs device tree bindings.
++ *
++ * Copyright (C) 2015, Samsung Electronics Co., Ltd.
++ * Author: Jacek Anaszewski <j.anaszewski@samsung.com>
++ *
++ * Copyright (C) 2019 Jacek Anaszewski <jacek.anaszewski@gmail.com>
++ * Copyright (C) 2020 Pavel Machek <pavel@ucw.cz>
++ */
++
++#ifndef __DT_BINDINGS_LEDS_H
++#define __DT_BINDINGS_LEDS_H
++
++/* External trigger type */
++#define LEDS_TRIG_TYPE_EDGE 0
++#define LEDS_TRIG_TYPE_LEVEL 1
++
++/* Boost modes */
++#define LEDS_BOOST_OFF 0
++#define LEDS_BOOST_ADAPTIVE 1
++#define LEDS_BOOST_FIXED 2
++
++/* Standard LED colors */
++#define LED_COLOR_ID_WHITE 0
++#define LED_COLOR_ID_RED 1
++#define LED_COLOR_ID_GREEN 2
++#define LED_COLOR_ID_BLUE 3
++#define LED_COLOR_ID_AMBER 4
++#define LED_COLOR_ID_VIOLET 5
++#define LED_COLOR_ID_YELLOW 6
++#define LED_COLOR_ID_IR 7
++#define LED_COLOR_ID_MAX 8
++
++/* Standard LED functions */
++/* Keyboard LEDs, usually it would be input4::capslock etc. */
++/* Obsolete equivalent: "shift-key-light" */
++#define LED_FUNCTION_CAPSLOCK "capslock"
++#define LED_FUNCTION_SCROLLLOCK "scrolllock"
++#define LED_FUNCTION_NUMLOCK "numlock"
++/* Obsolete equivalents: "tpacpi::thinklight" (IBM/Lenovo Thinkpads),
++ "lp5523:kb{1,2,3,4,5,6}" (Nokia N900) */
++#define LED_FUNCTION_KBD_BACKLIGHT "kbd_backlight"
++
++/* System LEDs, usually found on system body.
++ platform::mute (etc) is sometimes seen, :mute would be better */
++#define LED_FUNCTION_POWER "power"
++#define LED_FUNCTION_DISK "disk"
++
++/* Obsolete: "platform:*:charging" (allwinner sun50i) */
++#define LED_FUNCTION_CHARGING "charging"
++/* Used RGB notification LEDs common on phones.
++ Obsolete equivalents: "status-led:{red,green,blue}" (Motorola Droid 4),
++ "lp5523:{r,g,b}" (Nokia N900) */
++#define LED_FUNCTION_STATUS "status"
++
++#define LED_FUNCTION_MICMUTE "micmute"
++#define LED_FUNCTION_MUTE "mute"
++
++/* Miscelleaus functions. Use functions above if you can. */
++#define LED_FUNCTION_ACTIVITY "activity"
++#define LED_FUNCTION_ALARM "alarm"
++#define LED_FUNCTION_BACKLIGHT "backlight"
++#define LED_FUNCTION_BLUETOOTH "bluetooth"
++#define LED_FUNCTION_BOOT "boot"
++#define LED_FUNCTION_CPU "cpu"
++#define LED_FUNCTION_DEBUG "debug"
++#define LED_FUNCTION_DISK_ACTIVITY "disk-activity"
++#define LED_FUNCTION_DISK_ERR "disk-err"
++#define LED_FUNCTION_DISK_READ "disk-read"
++#define LED_FUNCTION_DISK_WRITE "disk-write"
++#define LED_FUNCTION_FAULT "fault"
++#define LED_FUNCTION_FLASH "flash"
++#define LED_FUNCTION_HEARTBEAT "heartbeat"
++#define LED_FUNCTION_INDICATOR "indicator"
++#define LED_FUNCTION_LAN "lan"
++#define LED_FUNCTION_MAIL "mail"
++#define LED_FUNCTION_MTD "mtd"
++#define LED_FUNCTION_PANIC "panic"
++#define LED_FUNCTION_PROGRAMMING "programming"
++#define LED_FUNCTION_RX "rx"
++#define LED_FUNCTION_SD "sd"
++#define LED_FUNCTION_STANDBY "standby"
++#define LED_FUNCTION_TORCH "torch"
++#define LED_FUNCTION_TX "tx"
++#define LED_FUNCTION_USB "usb"
++#define LED_FUNCTION_WAN "wan"
++#define LED_FUNCTION_WLAN "wlan"
++#define LED_FUNCTION_WPS "wps"
++
++#endif /* __DT_BINDINGS_LEDS_H */
+--
+2.20.1
+
diff --git a/gnu/packages/patches/u-boot-support-Pinebook-Pro-laptop.patch b/gnu/packages/patches/u-boot-support-Pinebook-Pro-laptop.patch
new file mode 100644
index 0000000000..c6f91fa65a
--- /dev/null
+++ b/gnu/packages/patches/u-boot-support-Pinebook-Pro-laptop.patch
@@ -0,0 +1,367 @@
+From 60381e4add64dddbd07e78248b2b0f819eb2776e Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 20:27:36 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420192736.962307-6-pbrobinson@gmail.com/
+Subject: [PATCH 5/5] Add initial support for the Pinebook Pro laptop from
+ Pine64.
+
+Specification:
+- Rockchip RK3399
+- 4GB Dual-Channel LPDDR4
+- eMMC socket
+- mSD card slot
+- 128Mbit (16Mb) SPI Flash
+- AP6256 for 11AC WiFi + BT5
+- 14 inch 1920*1080 eDP MiPi display
+- Camera
+- USB 3.0, 2.0 ports
+- Type-C port with alt-mode display (DP 1.2) and 15W charge
+- DC 5V/3A
+- optional PCIe slot for NVMe SSD drive
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+---
+ arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi | 43 ++++++++++
+ arch/arm/mach-rockchip/rk3399/Kconfig | 8 ++
+ board/pine64/pinebook-pro-rk3399/Kconfig | 15 ++++
+ board/pine64/pinebook-pro-rk3399/MAINTAINERS | 8 ++
+ board/pine64/pinebook-pro-rk3399/Makefile | 1 +
+ .../pinebook-pro-rk3399/pinebook-pro-rk3399.c | 76 +++++++++++++++++
+ configs/pinebook-pro-rk3399_defconfig | 84 +++++++++++++++++++
+ include/configs/pinebook-pro-rk3399.h | 29 +++++++
+ 8 files changed, 264 insertions(+)
+ create mode 100644 arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi
+ create mode 100644 board/pine64/pinebook-pro-rk3399/Kconfig
+ create mode 100644 board/pine64/pinebook-pro-rk3399/MAINTAINERS
+ create mode 100644 board/pine64/pinebook-pro-rk3399/Makefile
+ create mode 100644 board/pine64/pinebook-pro-rk3399/pinebook-pro-rk3399.c
+ create mode 100644 configs/pinebook-pro-rk3399_defconfig
+ create mode 100644 include/configs/pinebook-pro-rk3399.h
+
+diff --git a/arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi b/arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi
+new file mode 100644
+index 0000000000..1a2e24d3ef
+--- /dev/null
++++ b/arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi
+@@ -0,0 +1,43 @@
++// SPDX-License-Identifier: GPL-2.0+
++/*
++ * Copyright (C) 2019 Peter Robinson <pbrobinson at gmail.com>
++ */
++
++#include "rk3399-u-boot.dtsi"
++#include "rk3399-sdram-lpddr4-100.dtsi"
++
++/ {
++ aliases {
++ spi0 = &spi1;
++ };
++
++ chosen {
++ u-boot,spl-boot-order = "same-as-spl", &sdhci, &sdmmc;
++ };
++};
++
++&i2c0 {
++ u-boot,dm-pre-reloc;
++};
++
++&rk808 {
++ u-boot,dm-pre-reloc;
++};
++
++&sdhci {
++ max-frequency = <25000000>;
++ u-boot,dm-pre-reloc;
++};
++
++&sdmmc {
++ max-frequency = <20000000>;
++ u-boot,dm-pre-reloc;
++};
++
++&spiflash {
++ u-boot,dm-pre-reloc;
++};
++
++&vdd_log {
++ regulator-init-microvolt = <950000>;
++};
+diff --git a/arch/arm/mach-rockchip/rk3399/Kconfig b/arch/arm/mach-rockchip/rk3399/Kconfig
+index 927bb62a9f..254b9c5b4d 100644
+--- a/arch/arm/mach-rockchip/rk3399/Kconfig
++++ b/arch/arm/mach-rockchip/rk3399/Kconfig
+@@ -19,6 +19,13 @@ config TARGET_EVB_RK3399
+ with full function and physical connectors support like Type-C ports,
+ USB.0 host ports, LVDS, JTAG, MAC, SD card, HDMI, USB-to-serial...
+
++config TARGET_PINEBOOK_PRO_RK3399
++ bool "Pinebook Pro"
++ help
++ Pinebook Pro is a laptop based on the Rockchip rk3399 SoC
++ with 4Gb RAM, onboard eMMC, USB-C, a USB3 and USB2 port,
++ 1920*1080 screen and all the usual laptop features.
++
+ config TARGET_PUMA_RK3399
+ bool "Theobroma Systems RK3399-Q7 (Puma)"
+ help
+@@ -144,6 +151,7 @@ endif # BOOTCOUNT_LIMIT
+
+ source "board/firefly/roc-pc-rk3399/Kconfig"
+ source "board/google/gru/Kconfig"
++source "board/pine64/pinebook-pro-rk3399/Kconfig"
+ source "board/pine64/rockpro64_rk3399/Kconfig"
+ source "board/rockchip/evb_rk3399/Kconfig"
+ source "board/theobroma-systems/puma_rk3399/Kconfig"
+diff --git a/board/pine64/pinebook-pro-rk3399/Kconfig b/board/pine64/pinebook-pro-rk3399/Kconfig
+new file mode 100644
+index 0000000000..3bb7ca448e
+--- /dev/null
++++ b/board/pine64/pinebook-pro-rk3399/Kconfig
+@@ -0,0 +1,15 @@
++if TARGET_PINEBOOK_PRO_RK3399
++
++config SYS_BOARD
++ default "pinebook-pro-rk3399"
++
++config SYS_VENDOR
++ default "pine64"
++
++config SYS_CONFIG_NAME
++ default "pinebook-pro-rk3399"
++
++config BOARD_SPECIFIC_OPTIONS
++ def_bool y
++
++endif
+diff --git a/board/pine64/pinebook-pro-rk3399/MAINTAINERS b/board/pine64/pinebook-pro-rk3399/MAINTAINERS
+new file mode 100644
+index 0000000000..7153eaf2e0
+--- /dev/null
++++ b/board/pine64/pinebook-pro-rk3399/MAINTAINERS
+@@ -0,0 +1,8 @@
++PINEBOOK_PRO
++M: Peter Robinson <pbrobinson at gmail.com>
++S: Maintained
++F: board/pine64/rk3399-pinebook-pro/
++F: include/configs/rk3399-pinebook-pro.h
++F: arch/arm/dts/rk3399-pinebook-pro.dts
++F: arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi
++F: configs/pinebook-pro-rk3399_defconfig
+diff --git a/board/pine64/pinebook-pro-rk3399/Makefile b/board/pine64/pinebook-pro-rk3399/Makefile
+new file mode 100644
+index 0000000000..2f692a12a6
+--- /dev/null
++++ b/board/pine64/pinebook-pro-rk3399/Makefile
+@@ -0,0 +1 @@
++obj-y += pinebook-pro-rk3399.o
+diff --git a/board/pine64/pinebook-pro-rk3399/pinebook-pro-rk3399.c b/board/pine64/pinebook-pro-rk3399/pinebook-pro-rk3399.c
+new file mode 100644
+index 0000000000..01421cbac2
+--- /dev/null
++++ b/board/pine64/pinebook-pro-rk3399/pinebook-pro-rk3399.c
+@@ -0,0 +1,76 @@
++/*
++ * (C) Copyright 2016 Rockchip Electronics Co., Ltd
++ * (C) Copyright 2020 Peter Robinson <pbrobinson at gmail.com>
++ *
++ * SPDX-License-Identifier: GPL-2.0+
++ */
++
++#include <common.h>
++#include <dm.h>
++#include <syscon.h>
++#include <asm/io.h>
++#include <asm/arch-rockchip/clock.h>
++#include <asm/arch-rockchip/grf_rk3399.h>
++#include <asm/arch-rockchip/hardware.h>
++#include <asm/arch-rockchip/misc.h>
++#include <power/regulator.h>
++
++#define GRF_IO_VSEL_BT565_SHIFT 0
++#define PMUGRF_CON0_VSEL_SHIFT 8
++
++#ifndef CONFIG_SPL_BUILD
++int board_early_init_f(void)
++{
++ struct udevice *regulator;
++ int ret;
++
++ ret = regulator_get_by_platname("vcc5v0_usb", &regulator);
++ if (ret) {
++ debug("%s vcc5v0_usb init fail! ret %d\n", __func__, ret);
++ goto out;
++ }
++
++ ret = regulator_set_enable(regulator, true);
++ if (ret)
++ debug("%s vcc5v0-host-en-gpio set fail! ret %d\n", __func__, ret);
++
++out:
++ return 0;
++}
++#endif
++
++#ifdef CONFIG_MISC_INIT_R
++static void setup_iodomain(void)
++{
++ struct rk3399_grf_regs *grf =
++ syscon_get_first_range(ROCKCHIP_SYSCON_GRF);
++ struct rk3399_pmugrf_regs *pmugrf =
++ syscon_get_first_range(ROCKCHIP_SYSCON_PMUGRF);
++
++ /* BT565 is in 1.8v domain */
++ rk_setreg(&grf->io_vsel, 1 << GRF_IO_VSEL_BT565_SHIFT);
++
++ /* Set GPIO1 1.8v/3.0v source select to PMU1830_VOL */
++ rk_setreg(&pmugrf->soc_con0, 1 << PMUGRF_CON0_VSEL_SHIFT);
++}
++
++int misc_init_r(void)
++{
++ const u32 cpuid_offset = 0x7;
++ const u32 cpuid_length = 0x10;
++ u8 cpuid[cpuid_length];
++ int ret;
++
++ setup_iodomain();
++
++ ret = rockchip_cpuid_from_efuse(cpuid_offset, cpuid_length, cpuid);
++ if (ret)
++ return ret;
++
++ ret = rockchip_cpuid_set(cpuid, cpuid_length);
++ if (ret)
++ return ret;
++
++ return ret;
++}
++#endif
+diff --git a/configs/pinebook-pro-rk3399_defconfig b/configs/pinebook-pro-rk3399_defconfig
+new file mode 100644
+index 0000000000..0e9f0ec250
+--- /dev/null
++++ b/configs/pinebook-pro-rk3399_defconfig
+@@ -0,0 +1,84 @@
++CONFIG_ARM=y
++CONFIG_ARCH_ROCKCHIP=y
++CONFIG_SYS_TEXT_BASE=0x00200000
++CONFIG_ENV_OFFSET=0x3F8000
++CONFIG_ROCKCHIP_RK3399=y
++CONFIG_RAM_RK3399_LPDDR4=y
++CONFIG_NR_DRAM_BANKS=1
++CONFIG_TARGET_PINEBOOK_PRO_RK3399=y
++CONFIG_BAUDRATE=1500000
++CONFIG_DEBUG_UART=y
++CONFIG_DEBUG_UART_SHIFT=2
++CONFIG_DEBUG_UART_BASE=0xFF1A0000
++CONFIG_DEBUG_UART_CLOCK=24000000
++CONFIG_SPL_SPI_SUPPORT=y
++CONFIG_SPL_SPI_FLASH_SUPPORT=y
++CONFIG_SPL_MTD_SUPPORT=y
++CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-pinebook-pro.dtb"
++CONFIG_MISC_INIT_R=y
++CONFIG_DISPLAY_BOARDINFO_LATE=y
++# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
++CONFIG_SPL_STACK_R=y
++CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
++CONFIG_TPL=y
++CONFIG_SPL_OF_CONTROL=y
++CONFIG_DEFAULT_DEVICE_TREE="rk3399-pinebook-pro"
++CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
++CONFIG_SYS_RELOC_GD_ENV_ADDR=y
++CONFIG_CMD_BOOTZ=y
++CONFIG_CMD_GPIO=y
++CONFIG_CMD_GPT=y
++CONFIG_CMD_I2C=y
++CONFIG_CMD_MMC=y
++CONFIG_CMD_MTDPARTS=y
++CONFIG_CMD_PMIC=y
++CONFIG_CMD_REGULATOR=y
++# CONFIG_CMD_SETEXPR is not set
++CONFIG_CMD_SF=y
++CONFIG_CMD_TIME=y
++CONFIG_CMD_USB=y
++CONFIG_ROCKCHIP_GPIO=y
++CONFIG_SYS_I2C_ROCKCHIP=y
++CONFIG_BOOTDELAY=3
++CONFIG_LED=y
++CONFIG_LED_GPIO=y
++CONFIG_MISC=y
++CONFIG_ROCKCHIP_EFUSE=y
++CONFIG_MMC_DW=y
++CONFIG_MMC_DW_ROCKCHIP=y
++CONFIG_MMC_SDHCI=y
++CONFIG_MMC_SDHCI_SDMA=y
++CONFIG_MMC_SDHCI_ROCKCHIP=y
++CONFIG_ROCKCHIP_SPI=y
++CONFIG_SF_DEFAULT_SPEED=20000000
++CONFIG_SPI_FLASH=y
++CONFIG_SPI_FLASH_GIGADEVICE=y
++CONFIG_SPI_FLASH_WINBOND=y
++CONFIG_DM_ETH=y
++CONFIG_PMIC_RK8XX=y
++CONFIG_DM_PMIC_FAN53555=y
++CONFIG_REGULATOR_PWM=y
++CONFIG_REGULATOR_RK8XX=y
++CONFIG_PWM_ROCKCHIP=y
++CONFIG_SYSRESET=y
++CONFIG_USB=y
++CONFIG_USB_XHCI_HCD=y
++CONFIG_USB_XHCI_DWC3=y
++# CONFIG_USB_XHCI_ROCKCHIP is not set
++CONFIG_USB_EHCI_HCD=y
++CONFIG_USB_EHCI_GENERIC=y
++CONFIG_USB_DWC3=y
++CONFIG_ROCKCHIP_USB2_PHY=y
++CONFIG_USB_HOST_ETHER=y
++CONFIG_USB_ETHER_ASIX=y
++CONFIG_USB_ETHER_RTL8152=y
++CONFIG_USB_KEYBOARD=y
++CONFIG_USE_TINY_PRINTF=y
++CONFIG_SPL_TINY_MEMSET=y
++CONFIG_ERRNO_STR=y
++CONFIG_DM_VIDEO=y
++CONFIG_VIDEO_BPP16=y
++CONFIG_VIDEO_BPP32=y
++CONFIG_DISPLAY=y
++CONFIG_VIDEO_ROCKCHIP=y
++CONFIG_DISPLAY_ROCKCHIP_EDP=y
+diff --git a/include/configs/pinebook-pro-rk3399.h b/include/configs/pinebook-pro-rk3399.h
+new file mode 100644
+index 0000000000..423d742a79
+--- /dev/null
++++ b/include/configs/pinebook-pro-rk3399.h
+@@ -0,0 +1,29 @@
++/*
++ * Copyright (C) 2016 Rockchip Electronics Co., Ltd
++ * Copyright (C) 2020 Peter Robinson <pbrobinson at gmail.com>
++ *
++ * SPDX-License-Identifier: GPL-2.0+
++ */
++
++#ifndef __PINEBOOK_PRO_RK3399_H
++#define __PINEBOOK_PRO_RK3399_H
++
++#define ROCKCHIP_DEVICE_SETTINGS \
++ "stdin=serial,usbkbd\0" \
++ "stdout=serial,vidconsole\0" \
++ "stderr=serial,vidconsole\0"
++
++#include <configs/rk3399_common.h>
++
++#if defined(CONFIG_ENV_IS_IN_MMC)
++#define CONFIG_SYS_MMC_ENV_DEV 0
++#elif defined(CONFIG_ENV_IS_IN_SPI_FLASH)
++#define CONFIG_ENV_SECT_SIZE (8 * 1024)
++#endif
++
++#undef CONFIG_SYS_SPI_U_BOOT_OFFS
++#define CONFIG_SYS_SPI_U_BOOT_OFFS 1024 * 512
++
++#define SDRAM_BANK_SIZE (2UL << 30)
++
++#endif
+--
+2.20.1
+
diff --git a/gnu/packages/patches/u-boot-video-rockchip-fix-build.patch b/gnu/packages/patches/u-boot-video-rockchip-fix-build.patch
new file mode 100644
index 0000000000..ca2be8dc22
--- /dev/null
+++ b/gnu/packages/patches/u-boot-video-rockchip-fix-build.patch
@@ -0,0 +1,48 @@
+From ecc69ec25df07e1ce63d7add6b235b37673ed608 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Mon, 20 Apr 2020 19:18:25 +0100
+Origin: https://patchwork.ozlabs.org/project/uboot/patch/20200420181825.935797-1-pbrobinson@gmail.com/
+Subject: [PATCH 6/6] drivers: video: rockchip: fix building eDP and LVDS
+ drivers
+
+The rk_edp.c and rk_lvds.c files reference rk_setreg which is declared in
+hardware.h so include it so the drivers build. Adjust rk_lvds.c so
+includes are in alphabetical order while updating.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+Reviewed-by: Anatolij Gustschin <agust@denx.de>
+---
+ drivers/video/rockchip/rk_edp.c | 1 +
+ drivers/video/rockchip/rk_lvds.c | 3 ++-
+ 2 files changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/video/rockchip/rk_edp.c b/drivers/video/rockchip/rk_edp.c
+index 8703df0ec0..cf84b886e7 100644
+--- a/drivers/video/rockchip/rk_edp.c
++++ b/drivers/video/rockchip/rk_edp.c
+@@ -18,6 +18,7 @@
+ #include <asm/arch-rockchip/clock.h>
+ #include <asm/arch-rockchip/edp_rk3288.h>
+ #include <asm/arch-rockchip/grf_rk3288.h>
++#include <asm/arch-rockchip/hardware.h>
+ #include <dt-bindings/clock/rk3288-cru.h>
+
+ #define MAX_CR_LOOP 5
+diff --git a/drivers/video/rockchip/rk_lvds.c b/drivers/video/rockchip/rk_lvds.c
+index cf5c0439b1..79e24baf53 100644
+--- a/drivers/video/rockchip/rk_lvds.c
++++ b/drivers/video/rockchip/rk_lvds.c
+@@ -13,8 +13,9 @@
+ #include <asm/gpio.h>
+ #include <asm/io.h>
+ #include <asm/arch-rockchip/clock.h>
+-#include <asm/arch-rockchip/lvds_rk3288.h>
+ #include <asm/arch-rockchip/grf_rk3288.h>
++#include <asm/arch-rockchip/hardware.h>
++#include <asm/arch-rockchip/lvds_rk3288.h>
+ #include <dt-bindings/clock/rk3288-cru.h>
+ #include <dt-bindings/video/rk3288.h>
+
+--
+2.20.1
+
diff --git a/gnu/packages/patches/xplanet-1.3.1-cxx11-eof.patch b/gnu/packages/patches/xplanet-1.3.1-cxx11-eof.patch
new file mode 100644
index 0000000000..b4d5850f75
--- /dev/null
+++ b/gnu/packages/patches/xplanet-1.3.1-cxx11-eof.patch
@@ -0,0 +1,154 @@
+Author: Eric Bavier Date: 2020-01-13
+Url: https://notabug.org/bavier/guix-bavier/raw/master/bavier/patches/
++xplanet-cxx11-eof.patch
+
+diff --git a/src/libannotate/addArcs.cpp b/src/libannotate/addArcs.cpp
+index 2ee06c0..4fdb343 100644
+--- a/src/libannotate/addArcs.cpp
++++ b/src/libannotate/addArcs.cpp
+@@ -258,7 +258,7 @@ addArcs(PlanetProperties *planetProperties, Planet *planet,
+ {
+ ifstream inFile(arcFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline (line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline (line, MAX_LINE_LENGTH, '\n').eof())
+ readArcFile(line, planet, view, projection,
+ planetProperties, annotationMap);
+
+@@ -292,7 +292,7 @@ addArcs(View *view, multimap<double, Annotation *> &annotationMap)
+ {
+ ifstream inFile(arcFile.c_str());
+ char *line = new char[256];
+- while (inFile.getline (line, 256, '\n') != NULL)
++ while (!inFile.getline (line, 256, '\n').eof())
+ readArcFile(line, NULL, view, NULL, NULL, annotationMap);
+
+ inFile.close();
+diff --git a/src/libannotate/addMarkers.cpp b/src/libannotate/addMarkers.cpp
+index dde51c1..b641e6a 100644
+--- a/src/libannotate/addMarkers.cpp
++++ b/src/libannotate/addMarkers.cpp
+@@ -429,7 +429,7 @@ addMarkers(PlanetProperties *planetProperties, Planet *planet,
+ {
+ ifstream inFile(markerFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline (line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline (line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ unsigned char color[3];
+ memcpy(color, planetProperties->MarkerColor(), 3);
+@@ -475,7 +475,7 @@ addMarkers(View *view, const int width, const int height,
+ {
+ ifstream inFile(markerFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline (line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline (line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ unsigned char color[3];
+ memcpy(color, options->Color(), 3);
+diff --git a/src/libannotate/addSatellites.cpp b/src/libannotate/addSatellites.cpp
+index 2634339..6d9d378 100644
+--- a/src/libannotate/addSatellites.cpp
++++ b/src/libannotate/addSatellites.cpp
+@@ -488,10 +488,10 @@ loadSatelliteVector(PlanetProperties *planetProperties)
+ {
+ ifstream inFile(tleFile.c_str());
+ char lines[3][80];
+- while (inFile.getline(lines[0], 80) != NULL)
++ while (!inFile.getline(lines[0], 80).eof())
+ {
+- if ((inFile.getline(lines[1], 80) == NULL)
+- || (inFile.getline(lines[2], 80) == NULL))
++ if ((inFile.getline(lines[1], 80).eof())
++ || (inFile.getline(lines[2], 80).eof()))
+ {
+ ostringstream errStr;
+ errStr << "Malformed TLE file (" << tleFile << ")?\n";
+@@ -542,7 +542,7 @@ addSatellites(PlanetProperties *planetProperties, Planet *planet,
+ {
+ ifstream inFile(satFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline (line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline (line, MAX_LINE_LENGTH, '\n').eof())
+ readSatelliteFile(line, planet, view, projection,
+ planetProperties, annotationMap);
+
+diff --git a/src/libannotate/addSpiceObjects.cpp b/src/libannotate/addSpiceObjects.cpp
+index 67b752c..eeadf6e 100644
+--- a/src/libannotate/addSpiceObjects.cpp
++++ b/src/libannotate/addSpiceObjects.cpp
+@@ -524,7 +524,7 @@ processSpiceKernels(const bool load)
+ {
+ ifstream inFile(kernelFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ int ii = 0;
+ while (isDelimiter(line[ii]))
+@@ -576,7 +576,7 @@ addSpiceObjects(map<double, Planet *> &planetsFromSunMap,
+ {
+ ifstream inFile(spiceFile.c_str());
+ char *line = new char[MAX_LINE_LENGTH];
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ readSpiceFile(line, planetsFromSunMap, view, projection,
+ annotationMap);
+ inFile.close();
+diff --git a/src/libmultiple/RayleighScattering.cpp b/src/libmultiple/RayleighScattering.cpp
+index d885173..1be8ece 100644
+--- a/src/libmultiple/RayleighScattering.cpp
++++ b/src/libmultiple/RayleighScattering.cpp
+@@ -369,7 +369,7 @@ RayleighScattering::readConfigFile(string configFile)
+
+ diskTemplate_.clear();
+ limbTemplate_.clear();
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ int i = 0;
+ while (isDelimiter(line[i]))
+@@ -439,7 +439,7 @@ RayleighScattering::readBlock(ifstream &inFile,
+ values.clear();
+
+ char line[MAX_LINE_LENGTH];
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ int i = 0;
+ while (isDelimiter(line[i]))
+@@ -470,7 +470,7 @@ RayleighScattering::readValue(ifstream &inFile,
+ double &value)
+ {
+ char line[MAX_LINE_LENGTH];
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ int i = 0;
+ while (isDelimiter(line[i]))
+diff --git a/src/libmultiple/drawStars.cpp b/src/libmultiple/drawStars.cpp
+index ff07c49..aabdfed 100644
+--- a/src/libmultiple/drawStars.cpp
++++ b/src/libmultiple/drawStars.cpp
+@@ -41,7 +41,7 @@ drawStars(DisplayBase *display, View *view)
+ ifstream inFile(starMap.c_str());
+
+ char line[MAX_LINE_LENGTH];
+- while (inFile.getline(line, MAX_LINE_LENGTH, '\n') != NULL)
++ while (!inFile.getline(line, MAX_LINE_LENGTH, '\n').eof())
+ {
+ if (line[0] == '#') continue;
+
+diff --git a/src/readConfig.cpp b/src/readConfig.cpp
+index cc1964f..4650527 100644
+--- a/src/readConfig.cpp
++++ b/src/readConfig.cpp
+@@ -550,7 +550,7 @@ readConfigFile(string configFile, PlanetProperties *planetProperties[])
+
+ ifstream inFile(configFile.c_str());
+ char *line = new char[256];
+- while (inFile.getline(line, 256, '\n') != NULL)
++ while (!inFile.getline(line, 256, '\n').eof())
+ readConfig(line, planetProperties);
+
+ // This condition will only be true if [default] is the only
diff --git a/gnu/packages/patches/xplanet-1.3.1-libdisplay_DisplayOutput.cpp.patch b/gnu/packages/patches/xplanet-1.3.1-libdisplay_DisplayOutput.cpp.patch
new file mode 100644
index 0000000000..bf52b0ca27
--- /dev/null
+++ b/gnu/packages/patches/xplanet-1.3.1-libdisplay_DisplayOutput.cpp.patch
@@ -0,0 +1,16 @@
+Origin: $NetBSD: patch-src_libdisplay_DisplayOutput.cpp,v 1.1 2019/11/16 17:36:28 ng0 Exp $
+
+Modified by: R Veera Kumar <vkor@vkten.in> 2020-03-28; change to patch -p1
+
+diff -uNr xplanet-1.3.1/src/libdisplay/DisplayOutput.cpp xplanet-1.3.1.new/src/libdisplay/DisplayOutput.cpp
+--- xplanet-1.3.1/src/libdisplay/DisplayOutput.cpp 2013-02-17 01:07:47.000000000 +0530
++++ xplanet-1.3.1.new/src/libdisplay/DisplayOutput.cpp 2020-03-28 22:08:44.432499170 +0530
+@@ -51,7 +51,7 @@
+ string outputFilename = options->OutputBase();
+ int startIndex = options->OutputStartIndex();
+ int stopIndex = options->NumTimes() + startIndex - 1;
+- if (stopIndex > 1)
++ if (stopIndex > 0)
+ {
+ const int digits = (int) (log10((double) stopIndex) + 1);
+ char buffer[64];
diff --git a/gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch b/gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch
new file mode 100644
index 0000000000..58efc906dc
--- /dev/null
+++ b/gnu/packages/patches/xplanet-1.3.1-libimage_gif.c.patch
@@ -0,0 +1,54 @@
+Origin: $NetBSD: patch-src_libimage_gif.c,v 1.4 2019/11/16 17:36:28 ng0 Exp $
+
+Modified by: R Veera Kumar <vkor@vkten.in> 2020-03-28; change to patch -p1
+
+diff -uNr xplanet-1.3.1/src/libimage/gif.c xplanet-1.3.1.new/src/libimage/gif.c
+--- xplanet-1.3.1/src/libimage/gif.c 2013-02-17 01:07:47.000000000 +0530
++++ xplanet-1.3.1.new/src/libimage/gif.c 2020-03-28 22:15:24.444309199 +0530
+@@ -21,7 +21,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+-
++#include <stdbool.h>
+ #include <gif_lib.h>
+
+ /*
+@@ -178,8 +178,12 @@
+ *BufferP++ = ColorMapEntry->Blue;
+ }
+ }
+-
++
++#if GIFLIB_MAJOR >= 5
++ if (DGifCloseFile(GifFile, NULL) == GIF_ERROR) {
++#else
+ if (DGifCloseFile(GifFile) == GIF_ERROR) {
++#endif
+ return(0);
+ }
+
+@@ -493,7 +497,11 @@
+ static void QuitGifError(GifFileType *GifFile)
+ {
+ fprintf(stderr, "Error writing GIF file\n");
++#if GIFLIB_MAJOR >= 5
++ if (GifFile != NULL) EGifCloseFile(GifFile, NULL);
++#else
+ if (GifFile != NULL) EGifCloseFile(GifFile);
++#endif
+ }
+
+ int
+@@ -589,7 +597,11 @@
+ Ptr += width;
+ }
+
++#if GIFLIB_MAJOR >= 5
++ if (EGifCloseFile(GifFile, NULL) == GIF_ERROR)
++#else
+ if (EGifCloseFile(GifFile) == GIF_ERROR)
++#endif
+
+ {
+ QuitGifError(GifFile);
diff --git a/gnu/packages/patches/xplanet-1.3.1-xpUtil-Add2017LeapSecond.cpp.patch b/gnu/packages/patches/xplanet-1.3.1-xpUtil-Add2017LeapSecond.cpp.patch
new file mode 100644
index 0000000000..a47623fa00
--- /dev/null
+++ b/gnu/packages/patches/xplanet-1.3.1-xpUtil-Add2017LeapSecond.cpp.patch
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_xpUtil-Add2017LeapSecond.cpp,v 1.1 2019/11/16 17:36:28 ng0 Exp $
+
+Modified by: R Veera Kumar <vkor@vkten.in> 2020-03-28; change to patch -p1
+
+diff -uNr xplanet-1.3.1/src/xpUtil.cpp xplanet-1.3.1.new/src/xpUtil.cpp
+--- xplanet-1.3.1/src/xpUtil.cpp 2016-03-12 08:36:47.000000000 +0530
++++ xplanet-1.3.1.new/src/xpUtil.cpp 2020-03-28 22:19:10.629891166 +0530
+@@ -434,6 +434,7 @@
+ if (jd >= toJulian(2009, 1, 1, 0, 0, 0)) delta_at++; // 34
+ if (jd >= toJulian(2012, 7, 1, 0, 0, 0)) delta_at++; // 35
+ if (jd >= toJulian(2015, 7, 1, 0, 0, 0)) delta_at++; // 36
++ if (jd >= toJulian(2017, 1, 1, 0, 0, 0)) delta_at++; // 37
+
+ const double J2000 = toJulian(2000, 1, 1, 12, 0, 0);
+ const double m = m0 + m1 * (jd - J2000) * 86400;