From patchwork Mon Oct 23 12:36:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Hilton Chain X-Patchwork-Id: 55160 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 D7AFC27BBEA; Mon, 23 Oct 2023 13:39:30 +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=-0.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FROM_SUSPICIOUS_NTLD,MAILING_LIST_MULTI,PDS_OTHER_BAD_TLD, SPF_HELO_PASS,URIBL_BLOCKED autolearn=no 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 BECF727BBE2 for ; Mon, 23 Oct 2023 13:39:29 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1quuCs-0003JS-UM; Mon, 23 Oct 2023 08:38:55 -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 1quuCY-0003DV-Cy for guix-patches@gnu.org; Mon, 23 Oct 2023 08:38:35 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1quuCX-0001MY-T7 for guix-patches@gnu.org; Mon, 23 Oct 2023 08:38:33 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1quuD0-0007U3-Du; Mon, 23 Oct 2023 08:39:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#66701] [PATCH 01/14] gnu: clang-runtime-from-llvm: Adjust inputs for version 15 or later. Resent-From: Hilton Chain Original-Sender: "Debbugs-submit" Resent-CC: hako@ultrarare.space, guix-patches@gnu.org Resent-Date: Mon, 23 Oct 2023 12:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66701 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 66701@debbugs.gnu.org Cc: Hilton Chain , Hilton Chain X-Debbugs-Original-Xcc: Hilton Chain Received: via spool by 66701-submit@debbugs.gnu.org id=B66701.169806472128703 (code B ref 66701); Mon, 23 Oct 2023 12:39:02 +0000 Received: (at 66701) by debbugs.gnu.org; 23 Oct 2023 12:38:41 +0000 Received: from localhost ([127.0.0.1]:49338 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1quuCf-0007St-AR for submit@debbugs.gnu.org; Mon, 23 Oct 2023 08:38:41 -0400 Received: from mail.boiledscript.com ([144.168.59.46]:50318) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1quuCa-0007SW-IF for 66701@debbugs.gnu.org; Mon, 23 Oct 2023 08:38:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ultrarare.space; s=dkim; t=1698064531; 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=ty7G8JkYWufVefkHe7kclbbd+JgAr8KFxvWFpt4SVuw=; b=dqOWzqM6X/eJ1Fl0k/NfGcrLkcl7dozDxXhUXKh4gzjrJN+NJqkOaYsezXJ9ofVmY6fbmY Gq7WoInIQ7NOHNNMVL2FJ5kog89RC9XVQxqgWlpW3eQD57WMe93N6HkgWhxIge1w/AScfI bs+RkZNaL58W4ajCYXsco+M+TjZjrm3+smK0JVjONULr7N/2Z2nASU9oMnQ46/+R/na0PQ Jzm8RXcoWegR60QbKYmXYSjPN81TZW3gXHVxvjl1XVPZSENt+m1mn0E78RxSl1LDnuxacH zjE7j4ukz/ErcneUFw5Z1XSGw/Wp1dpSaIjPT0NeiGvpDPC5QApiQmPEpOfGrA== Authentication-Results: mail.boiledscript.com; auth=pass smtp.mailfrom=hako@ultrarare.space Date: Mon, 23 Oct 2023 20:36:09 +0800 Message-ID: In-Reply-To: References: MIME-Version: 1.0 X-Spamd-Bar: --- 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: , Reply-to: Hilton Chain X-ACL-Warn: , Hilton Chain via Guix-patches X-Patchwork-Original-From: Hilton Chain via Guix-patches via From: Hilton Chain 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 * gnu/packages/llvm.scm (clang-runtime-from-llvm)[native-inputs]: Add gcc-12 when version >= 15. [inputs]: Add libffi when version >= 15. (clang-runtime-15)[native-inputs,inputs]: Remove fields. Change-Id: I4b385b937edbb7a2840b998b6dd3e31a17cb556f --- gnu/packages/llvm.scm | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm index cd551f4e02..38c4047f48 100644 --- a/gnu/packages/llvm.scm +++ b/gnu/packages/llvm.scm @@ -26,6 +26,7 @@ ;;; Copyright © 2022 John Kehayias ;;; Copyright © 2022 Clément Lassieur ;;; Copyright © 2022 Zhu Zihao +;;; Copyright © 2023 Hilton Chain ;;; ;;; This file is part of GNU Guix. ;;; @@ -139,9 +140,19 @@ (define* (clang-runtime-from-llvm llvm (patches (map search-patch patches))) (llvm-monorepo (package-version llvm)))) (build-system cmake-build-system) - (native-inputs (package-native-inputs llvm)) + (native-inputs + (if (version>=? version "15") + ;; TODO: Remove this when GCC 12 is the default. + ;; libfuzzer fails to build with GCC 11 + (modify-inputs (package-native-inputs llvm) + (prepend gcc-12)) + (package-native-inputs llvm))) (inputs - (list llvm)) + (append + (list llvm) + (if (version>=? version "15") + (list libffi) + '()))) (arguments `(;; Don't use '-g' during the build to save space. #:build-type "Release" @@ -712,13 +723,7 @@ (define-public clang-runtime-15 #~(modify-phases #$phases (add-after 'unpack 'change-directory (lambda _ - (chdir "compiler-rt"))))))) - (native-inputs - (modify-inputs (package-native-inputs template) - (prepend gcc-12))) ;libfuzzer fails to build with GCC 11 - (inputs - (modify-inputs (package-inputs template) - (append libffi)))))) + (chdir "compiler-rt")))))))))) (define-public clang-runtime-14 (let ((template (clang-runtime-from-llvm llvm-14)))