From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 6Ad2CDPqi2El/QAAgWs5BA (envelope-from ) for ; Wed, 10 Nov 2021 16:50:11 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id mHkcBDPqi2FADwAAbx9fmQ (envelope-from ) for ; Wed, 10 Nov 2021 15:50:11 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 80B38D9AE for ; Wed, 10 Nov 2021 16:50:09 +0100 (CET) Received: from localhost ([::1]:60176 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mkprU-00061v-KY for larch@yhetil.org; Wed, 10 Nov 2021 10:50:08 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44552) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mkprO-00061m-AC for guix-patches@gnu.org; Wed, 10 Nov 2021 10:50:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:55749) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mkprO-0007fr-1P for guix-patches@gnu.org; Wed, 10 Nov 2021 10:50:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mkprN-0008GL-SI for guix-patches@gnu.org; Wed, 10 Nov 2021 10:50:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#51747] Acknowledgement ([PATCH]: gnu: nix: Update to 2.4. ) Resent-From: Zhu Zihao Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 10 Nov 2021 15:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51747 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 51747@debbugs.gnu.org Received: via spool by 51747-submit@debbugs.gnu.org id=B51747.163655937131715 (code B ref 51747); Wed, 10 Nov 2021 15:50:01 +0000 Received: (at 51747) by debbugs.gnu.org; 10 Nov 2021 15:49:31 +0000 Received: from localhost ([127.0.0.1]:39062 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mkpqk-0008FH-Ph for submit@debbugs.gnu.org; Wed, 10 Nov 2021 10:49:31 -0500 Received: from mail-m975.mail.163.com ([123.126.97.5]:47698) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mkpqd-0008Ez-RU for 51747@debbugs.gnu.org; Wed, 10 Nov 2021 10:49:21 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-ID:MIME-Version; bh=dJWL7 TZUqAiAQbZcR6NfBuEhrRhcr7iZpk0LwwS0BzU=; b=JTGmFNFR+ZjIfRx65uzh8 5F1V/WnOKr72VZv5U0K+zUT/V946qmsMlmx7+5Fw84W3/YpJn1Dn1VNxKJJbZppu xZ5cnADmhTfpXRox7+Am2Ar4n+0sfAKBqCLnAydADmE6UDUlEf6QwLBnKnqknnhL bp9qy/QUZmfcZ4JOyaAh6g= Received: from asus-laptop (unknown [112.95.110.50]) by smtp5 (Coremail) with SMTP id HdxpCgAXYOz06Yth3I94JA--.6553S2; Wed, 10 Nov 2021 23:49:09 +0800 (CST) References: <86sfw4chme.fsf@163.com> <864k8kcdzu.fsf@163.com> User-agent: mu4e 1.6.9; emacs 27.2 From: Zhu Zihao Date: Wed, 10 Nov 2021 23:47:12 +0800 In-reply-to: <864k8kcdzu.fsf@163.com> Message-ID: <861r3oau4u.fsf@163.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-CM-TRANSID: HdxpCgAXYOz06Yth3I94JA--.6553S2 X-Coremail-Antispam: 1Uf129KBjDUn29KB7ZKAUJUUUUU529EdanIXcx71UUUUU7v73 VFW2AGmfu7bjvjm3AaLaJ3UbIYCTnIWIevJa73UjIFyTuYvjxUevtZUUUUU X-Originating-IP: [112.95.110.50] X-CM-SenderInfo: pdoosuxxwbztlvw6il2tof0z/xtbBLxNHr1UMOyEArAABs6 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1636559410; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=dJWL7TZUqAiAQbZcR6NfBuEhrRhcr7iZpk0LwwS0BzU=; b=uXGy9r3rL1VPObBFK1gnGraMebqrIOGWIa2LLwB6dWxNq3pwvlnWKx+OTBsHPIrr3W4/p6 0yWCQ4At/9jZumIwyuFPd0gu+IjFbumubZH3cjaoCWbMnjCgYQpMOxaJJ32zCa0tZxeNzh +TtTudEGmfmHzNf1B0Oz5w3U4C+UOFZd+cMsYvV/e4eEcJ6YSBOrPdw44UK0kVAultE6Q5 v6PvDsja6LLQPtXvlC37sQzXQ9omxQoBZqXX5CRGf5mSl42AGQsAYkLPxdmYNX7ojfZFjC L6shrpIAT88ewaltt53ghKfp8hRns4xJu9RrRDbFrf1fpjePnyjaGob+xeSzvw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1636559410; a=rsa-sha256; cv=none; b=ZdPMSGEUq2tJXsjWPb7YBhLccWQBlVWJb4cq+Mc0ybq1aeuQ6GmX2mjX+5JX7mx+iu1u+D zyHDJcypCvT8xR6WijO850KDIHRLR6LP5jy/NHp284u+JDleoIO6J5yiQxobBPpmKEu5S2 71Z92TuPmbkuALFmiK02SNrWJzQAAEQPmfh6Y7YbcYpCXaGuVyPk2oBInI2SFiJbfQqzww O1E8Af7ySxZo+Evh+4FWrvK8wlMP24jj3oGg7oMd5B7DMu9N8VaAWYcF6Ap5cOywamOz8O XoaVfSvIzw2/3KJdhqzGNft5NtlTR4HiU8EXxA0nc5+EVTRdm1TLM6bNsjT/6Q== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=163.com header.s=s110527 header.b=JTGmFNFR; dmarc=fail reason="SPF not aligned (relaxed)" header.from=163.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -3.42 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=163.com header.s=s110527 header.b=JTGmFNFR; dmarc=fail reason="SPF not aligned (relaxed)" header.from=163.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 80B38D9AE X-Spam-Score: -3.42 X-Migadu-Scanner: scn0.migadu.com X-TUID: ITvOIA59oT7w --=-=-= Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" --==-=-= Content-Type: text/plain My local source repo is not up-to-date :(, Update to resolve the conflict with newest master. --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iIsEARYIADMWIQTUepyLKuOQW1Y9kTW+QrNSqfaCHwUCYYvp8RUcYWxsX2J1dF9s YXN0QDE2My5jb20ACgkQvkKzUqn2gh/ydAD/W0J+8w8Zr6FFM9lKDb3oOTRw95UO 8zqTG0YEJ0vPI0ABAJlMxgtCWdebe0oBbXIzMMyWlGALjbCC9tF75hJt4qoF =s053 -----END PGP SIGNATURE----- --==-=-=-- --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-gnu-lowdown-Generate-position-independent-code.patch >From 369b3cc29ac306d3b2ff9df38163be6d31b0b12b Mon Sep 17 00:00:00 2001 From: Zhu Zihao Date: Wed, 10 Nov 2021 23:36:20 +0800 Subject: [PATCH 1/3] gnu: lowdown: Generate position-independent code. * gnu/packages/markup.scm (lowdown)[arguments]: Use -fPIC. --- gnu/packages/markup.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/markup.scm b/gnu/packages/markup.scm index 06e653a1c9..474b5343e9 100644 --- a/gnu/packages/markup.scm +++ b/gnu/packages/markup.scm @@ -138,7 +138,9 @@ (define-public lowdown (let ((out (assoc-ref outputs "out"))) (invoke "./configure" (string-append "PREFIX=" out) - (string-append "MANDIR=" out "/share/man")))))))) + (string-append "MANDIR=" out "/share/man")))))) + ;; The shared library of Nix is linked with lowdown's static archive. + #:make-flags '("CFLAGS=-fPIC"))) (native-inputs `(("which" ,which))) (home-page "https://kristaps.bsd.lv/lowdown/") -- 2.33.1 --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: inline; filename=0002-gnu-Add-libcpuid.patch Content-Transfer-Encoding: quoted-printable >From 032740ed0e85dc20f49133358b1206c4a56efcec Mon Sep 17 00:00:00 2001 From: Zhu Zihao Date: Wed, 10 Nov 2021 23:37:24 +0800 Subject: [PATCH 2/3] gnu: Add libcpuid. * gnu/packages/hardware.scm (libcpuid): New variable. --- gnu/packages/hardware.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm index 2bf3576d5a..fd7de013ef 100644 --- a/gnu/packages/hardware.scm +++ b/gnu/packages/hardware.scm @@ -8,6 +8,7 @@ ;;; Copyright =C2=A9 2021 Petr Hodina ;;; Copyright =C2=A9 2021 Raghav Gururajan ;;; Copyright =C2=A9 2021 Vinicius Monego +;;; Copyright =C2=A9 2021 Zhu Zihao ;;; ;;; This file is part of GNU Guix. ;;; @@ -834,3 +835,22 @@ (define-public tpm2-tss libtss2-esys, libtss2-sys, libtss2-mu, libtss2-tcti-device, libtss2-tcti-s= wtpm and libtss2-tcti-mssim.") (license license:bsd-2))) + +(define-public libcpuid + (package + (name "libcpuid") + (version "0.5.1") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/anrieff/libcpuid/releases/d= ownload/v" + version "/libcpuid-" version ".tar.gz")) + (sha256 + (base32 "1nksdqk2w1c56lkrjcvh3nss9vq454j81j3yq14lwdn4x8bvmwfr")))) + (build-system gnu-build-system) + (supported-systems '("x86_64-linux" "i686-linux")) + (home-page "https://libcpuid.sourceforge.net/") + (synopsis "Small library for x86 CPU detection and feature extraction") + (description "Libcpuid is a small C library to get vendor, model, bran= ding +string, code name and other information from x86 CPU.") + (license license:bsd-2))) --=20 2.33.1 --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: inline; filename=0003-gnu-nix-Update-to-2.4.patch Content-Transfer-Encoding: quoted-printable >From a41118f1b3ddc3d26036f84161a91accd9d98968 Mon Sep 17 00:00:00 2001 From: Zhu Zihao Date: Wed, 10 Nov 2021 23:37:53 +0800 Subject: [PATCH 3/3] gnu: nix: Update to 2.4. * gnu/packages/package-management.scm (nix): Update to 2.4. [source]: Switch to Github repository since upstream no longer provides tarball. [native-inputs]: Add autoconf, autoconf-archive, automake, bison, flex, gcc, googletest, jq, libtool [inputs]: Add libarchive, libcpuid, lowdown, zlib. * gnu/packages/patches/nix-dont-build-html-doc.diff: New file. * gnu/local.mk(dist_patch_DATA): Add corresponding entry. --- gnu/local.mk | 1 + gnu/packages/package-management.scm | 67 +++++++++++++------ .../patches/nix-dont-build-html-doc.diff | 26 +++++++ 3 files changed, 74 insertions(+), 20 deletions(-) create mode 100644 gnu/packages/patches/nix-dont-build-html-doc.diff diff --git a/gnu/local.mk b/gnu/local.mk index 05258ac054..c32d2ba297 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1527,6 +1527,7 @@ dist_patch_DATA =3D \ %D%/packages/patches/nettle-3.5-check-_pkcs1_sec_decrypt-msg-len.patch \ %D%/packages/patches/nettle-3.5-CVE-2021-3580-pt1.patch \ %D%/packages/patches/nettle-3.5-CVE-2021-3580-pt2.patch \ + %D%/packages/patches/nix-dont-build-html-doc.diff \ %D%/packages/patches/nfs4-acl-tools-0.3.7-fixpaths.patch \ %D%/packages/patches/ngircd-handle-zombies.patch \ %D%/packages/patches/ngless-unliftio.patch \ diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-man= agement.scm index 12c689e9e2..a30eea4d62 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -19,6 +19,7 @@ ;;; Copyright =C2=A9 2020 Vincent Legoll ;;; Copyright =C2=A9 2021 Ivan Gankevich ;;; Copyright =C2=A9 2021 Maxim Cournoyer +;;; Copyright =C2=A9 2021 Zhu Zihao ;;; ;;; This file is part of GNU Guix. ;;; @@ -60,6 +61,8 @@ (define-module (gnu packages package-management) #:use-module (gnu packages dbm) #:use-module (gnu packages docbook) #:use-module (gnu packages file) + #:use-module (gnu packages flex) + #:use-module (gnu packages gcc) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) @@ -68,12 +71,14 @@ (define-module (gnu packages package-management) #:use-module (gnu packages gtk) #:use-module (gnu packages guile) #:use-module (gnu packages guile-xyz) + #:use-module (gnu packages hardware) #:use-module (gnu packages hurd) #:use-module (gnu packages less) #:use-module (gnu packages libedit) #:use-module (gnu packages linux) #:use-module (gnu packages lisp) #:use-module (gnu packages man) + #:use-module (gnu packages markup) #:use-module (gnu packages nettle) #:use-module (gnu packages networking) #:use-module (gnu packages ninja) @@ -593,14 +598,18 @@ (define-public current-guix (define-public nix (package (name "nix") - (version "2.3.16") - (source (origin - (method url-fetch) - (uri (string-append "https://releases.nixos.org/nix/nix-" - version "/nix-" version ".tar.xz")) - (sha256 - (base32 - "1g5aqavr6i3c1xln53w1pdh1kvlxrpnknb105m4jbd85kyv83rky")))) + (version "2.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "http://github.com/NixOS/nix") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1abgfw5ndqklm0x533li32l4azifz3f6lhaxm6s74b704043r7m2")) + (patches + (search-patches "nix-dont-build-html-doc.diff")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--sysconfdir=3D/etc" "--enable-gc") @@ -616,18 +625,36 @@ (define-public nix (string-append "sysconfdir=3D" etc) (string-append "profiledir=3D" etc "/profile.d") make-flags))))))) - (native-inputs `(("pkg-config" ,pkg-config))) - (inputs `(("boost" ,boost) - ("brotli" ,brotli) - ("bzip2" ,bzip2) - ("curl" ,curl) - ("editline" ,editline) - ("libgc" ,libgc) - ("libseccomp" ,libseccomp) - ("libsodium" ,libsodium) - ("openssl" ,openssl) - ("sqlite" ,sqlite) - ("xz" ,xz))) + (native-inputs + `(("autoconf" ,autoconf) + ("autoconf-archive" ,autoconf-archive) + ("automake" ,automake) + ("bison" ,bison) + ("flex" ,flex) + ("gcc" ,gcc-9) ;non-trivial designated initialize= rs + ("googletest" ,googletest) + ("jq" ,jq) + ("libtool" ,libtool) + ("pkg-config" ,pkg-config))) + (inputs + `(("boost" ,boost) + ("brotli" ,brotli) + ("bzip2" ,bzip2) + ("curl" ,curl) + ("editline" ,editline) + ("libarchive" ,libarchive) + ,@(if (string-prefix? "x86_64" (or (%current-target-system) + (%current-system))) + `(("libcpuid" ,libcpuid)) + '()) + ("libgc" ,libgc) + ("libseccomp" ,libseccomp) + ("libsodium" ,libsodium) + ("lowdown" ,lowdown) + ("openssl" ,openssl) + ("sqlite" ,sqlite) + ("xz" ,xz) + ("zlib" ,zlib))) (home-page "https://nixos.org/nix/") (synopsis "The Nix package manager") (description diff --git a/gnu/packages/patches/nix-dont-build-html-doc.diff b/gnu/packag= es/patches/nix-dont-build-html-doc.diff new file mode 100644 index 0000000000..79142bc215 --- /dev/null +++ b/gnu/packages/patches/nix-dont-build-html-doc.diff @@ -0,0 +1,26 @@ +"--enable-doc-gen" configure flag will enable HTML document generation tha= t requires mdbook. +We can't simply disable it because we need manpages. + +Author: Zhu Zihao + +diff --git a/doc/manual/local.mk b/doc/manual/local.mk +index e43d9f2fb..c323d1847 100644 +--- a/doc/manual/local.mk ++++ b/doc/manual/local.mk +@@ -69,8 +69,6 @@ $(d)/builtins.json: $(bindir)/nix + $(trace-gen) $(dummy-env) NIX_PATH=3Dnix/corepkgs=3Dcorepkgs $(bindir)/n= ix __dump-builtins > $@.tmp + @mv $@.tmp $@ +=20 +-# Generate the HTML manual. +-install: $(docdir)/manual/index.html +=20 + # Generate 'nix' manpages. + install: $(mandir)/man1/nix3-manpages +@@ -94,7 +92,5 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/comman= d-ref/new-cli + done + @touch $@ +=20 +-$(docdir)/manual/index.html: $(MANUAL_SRCS) $(d)/book.toml $(d)/custom.cs= s $(d)/src/SUMMARY.md $(d)/src/command-ref/new-cli $(d)/src/command-ref/con= f-file.md $(d)/src/expressions/builtins.md $(call rwildcard, $(d)/src, *.md) +- $(trace-gen) RUST_LOG=3Dwarn mdbook build doc/manual -d $(DESTDIR)$(docd= ir)/manual +=20 + endif --=20 2.33.1 --=-=-= Content-Type: text/plain -- Retrieve my PGP public key: gpg --recv-keys D47A9C8B2AE3905B563D9135BE42B352A9F6821F Zihao --=-=-=--