From patchwork Thu Mar 30 12:31:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jelle Licht X-Patchwork-Id: 48800 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 4678617183; Thu, 30 Mar 2023 13:33:36 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 64FA717152 for ; Thu, 30 Mar 2023 13:33:35 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1phrSx-0001JB-AI; Thu, 30 Mar 2023 08:33:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1phrSq-0001Gp-4L for guix-patches@gnu.org; Thu, 30 Mar 2023 08:33:15 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1phrSn-0001rR-2F for guix-patches@gnu.org; Thu, 30 Mar 2023 08:33:11 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1phrSm-00031Z-UM for guix-patches@gnu.org; Thu, 30 Mar 2023 08:33:08 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#59188] [PATCH v6 18/19] gnu: node-lts: Update to 18.15.0. Resent-From: jlicht@fsfe.org Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 30 Mar 2023 12:33:08 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59188 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 59188@debbugs.gnu.org Cc: Hilton Chain Received: via spool by 59188-submit@debbugs.gnu.org id=B59188.168017958311528 (code B ref 59188); Thu, 30 Mar 2023 12:33:08 +0000 Received: (at 59188) by debbugs.gnu.org; 30 Mar 2023 12:33:03 +0000 Received: from localhost ([127.0.0.1]:56052 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1phrSg-0002za-PZ for submit@debbugs.gnu.org; Thu, 30 Mar 2023 08:33:03 -0400 Received: from mail1.fsfe.org ([217.69.89.151]:52490) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1phrSc-0002z2-7X for 59188@debbugs.gnu.org; Thu, 30 Mar 2023 08:32:58 -0400 From: jlicht@fsfe.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fsfe.org; s=2021100501; t=1680179576; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SmRKRq0Pii5qfXVPQdBRbm6gMohwd3y+oH05dT+UZEA=; b=iwRq1HtB2WYXd1ZHashgqE6O9XEhpAXJspDxpWVI3dg6+wtTiYaBqtVu5NkhJXBqjxJTOi 4bioMoDHJNktPhlknvLVn6PPn1vGVlY4WaFzWHMOcwOm1ZeUNIdsnEdfgvRujIx8qs+mCK z4WUi8pO+THxTySj6KNC5Cj9gwR0V6M= Date: Thu, 30 Mar 2023 14:31:49 +0200 Message-Id: <5a889a04e8cf03299ee4f43d9cf1718a98e334a5.1680179491.git.jlicht@fsfe.org> In-Reply-To: References: MIME-Version: 1.0 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+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches From: Hilton Chain * gnu/packages/node.scm (node-lts): Update to 18.15.0. [snippet]: Keep file deps/openssl/nodejs-openssl.cnf. [arguments]<#:configure-flags>: Enable v8 snapshot compression. <#:phases>: Adjust problematic tests to delete accordingly. Patch additional file with hardcoded references to /bin/sh. [native-inputs,inputs]: Replace openssl-1.1 with openssl. --- (no changes since v1) gnu/packages/node.scm | 40 ++++++++++++++++++++++++++++------------ 1 file changed, 28 insertions(+), 12 deletions(-) diff --git a/gnu/packages/node.scm b/gnu/packages/node.scm index f613844a13..a9c4f463c8 100644 --- a/gnu/packages/node.scm +++ b/gnu/packages/node.scm @@ -11,6 +11,7 @@ ;;; Copyright © 2021 Simon Tournier ;;; Copyright © 2021 Guillaume Le Vaillant ;;; Copyright © 2021, 2022 Philip McGrath +;;; Copyright © 2022 Hilton Chain ;;; ;;; This file is part of GNU Guix. ;;; @@ -737,23 +738,28 @@ (define-public llhttp-bootstrap (define-public node-lts (package (inherit node) - (version "14.19.3") + (version "18.15.0") (source (origin (method url-fetch) (uri (string-append "https://nodejs.org/dist/v" version - "/node-v" version ".tar.xz")) + "/node-v" version ".tar.gz")) (sha256 (base32 - "15691j5zhiikyamiwwd7f282g6d9acfhq91nrwx54xya38gmpx2w")) + "0axc4jl71wjjhwzpdc3xg607r32554d0h0lmvb65p0f8ycz4qp6n")) (modules '((guix build utils))) (snippet `(begin + ;; openssl.cnf is required for build. + (for-each delete-file-recursively + (find-files "deps/openssl" + (lambda (file stat) + (if (string-contains file "nodejs-openssl.cnf") + #f #t)))) ;; Remove bundled software, where possible (for-each delete-file-recursively '("deps/cares" "deps/icu-small" "deps/nghttp2" - "deps/openssl" "deps/zlib")) (substitute* "Makefile" ;; Remove references to bundled software. @@ -769,7 +775,9 @@ (define-public node-lts "--shared-openssl" "--shared-zlib" "--shared-brotli" - "--with-intl=system-icu")) + "--with-intl=system-icu" + ;;Needed for correct snapshot checksums + "--v8-enable-snapshot-compression")) ((#:phases phases) `(modify-phases ,phases (replace 'set-bootstrap-host-rpath @@ -802,23 +810,31 @@ (define-public node-lts libuv "/lib:" zlib "/lib" "'],")))))) + (add-after 'patch-hardcoded-program-references + 'patch-additional-hardcoded-program-references + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "test/parallel/test-stdin-from-file-spawn.js" + (("'/bin/sh'") (string-append + "'" (search-input-file inputs "/bin/sh") + "'"))))) (replace 'delete-problematic-tests (lambda* (#:key inputs #:allow-other-keys) ;; FIXME: These tests fail in the build container, but they don't ;; seem to be indicative of real problems in practice. (for-each delete-file - '("test/parallel/test-cluster-master-error.js" - "test/parallel/test-cluster-master-kill.js")) + '("test/parallel/test-cluster-primary-error.js" + "test/parallel/test-cluster-primary-kill.js")) ;; These require a DNS resolver. (for-each delete-file '("test/parallel/test-dns.js" - "test/parallel/test-dns-lookupService-promises.js")) + "test/parallel/test-dns-lookupService-promises.js" + "test/parallel/test-net-socket-connect-without-cb.js" + "test/parallel/test-tcp-wrap-listen.js")) ;; These tests require networking. (for-each delete-file - '("test/parallel/test-https-agent-unref-socket.js" - "test/parallel/test-corepack-yarn-install.js")) + '("test/parallel/test-https-agent-unref-socket.js")) ;; This test is timing-sensitive, and fails sporadically on ;; slow, busy, or even very fast machines. @@ -868,7 +884,7 @@ (define-public node-lts icu4c-71 libuv-for-node `(,nghttp2 "lib") - openssl-1.1 + openssl zlib ;; Regular build-time dependencies. perl @@ -885,7 +901,7 @@ (define-public node-lts llhttp-bootstrap brotli `(,nghttp2 "lib") - openssl-1.1 + openssl zlib)))) (define-public libnode