From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id yFkICJI+x2ILBwAAbAwnHQ (envelope-from ) for ; Thu, 07 Jul 2022 22:14:10 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id KIwDB5I+x2IsUAAAG6o9tA (envelope-from ) for ; Thu, 07 Jul 2022 22:14:10 +0200 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 A84101ECF4 for ; Thu, 7 Jul 2022 22:14:09 +0200 (CEST) Received: from localhost ([::1]:41548 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o9Xt2-0007Jy-Aj for larch@yhetil.org; Thu, 07 Jul 2022 16:14:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41458) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o9Xsw-0007Iy-HH for guix-patches@gnu.org; Thu, 07 Jul 2022 16:14:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:35913) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o9Xsw-0005oD-8l for guix-patches@gnu.org; Thu, 07 Jul 2022 16:14:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1o9Xsw-0007nX-4N for guix-patches@gnu.org; Thu, 07 Jul 2022 16:14:02 -0400 Subject: bug#53834: [PATCH] gnu: Add cproc. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-To: guix-patches@gnu.org Resent-Date: Thu, 07 Jul 2022 20:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 53834 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: "(unmatched-parenthesis" Cc: 53834-done@debbugs.gnu.org Mail-Followup-To: 53834@debbugs.gnu.org, maxim.cournoyer@gmail.com, jgart@dismail.de Received: via spool by 53834-done@debbugs.gnu.org id=D53834.165722478829899 (code D ref 53834); Thu, 07 Jul 2022 20:14:01 +0000 Received: (at 53834-done) by debbugs.gnu.org; 7 Jul 2022 20:13:08 +0000 Received: from localhost ([127.0.0.1]:58041 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o9Xs3-0007mB-Pl for submit@debbugs.gnu.org; Thu, 07 Jul 2022 16:13:08 -0400 Received: from mail-qt1-f174.google.com ([209.85.160.174]:43813) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o9Xs0-0007lg-SH for 53834-done@debbugs.gnu.org; Thu, 07 Jul 2022 16:13:06 -0400 Received: by mail-qt1-f174.google.com with SMTP id c13so24412926qtq.10 for <53834-done@debbugs.gnu.org>; Thu, 07 Jul 2022 13:13:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=D7hBFUxzuAeThH6/63iSYflwf3gCb1qop4FDVeWBdJo=; b=kans8hrUuuoqphqyLclC0LPC2eCvIx0OvqDJFcj1rwJ1KGUJyQ61nNwcpgvTniXxG4 pZUPGl66DrrpvAUNHstKqhsCmYrX87PW06U2enD7HN6vz7LnZb4ANQjERWccfi4ZrmEj aMWNyzI7Yvf3/ClGXJO0CnSoUZ5DCdhs7yAdhQN2s6yvo+dd9R4CSQS8E9NoszL0hcIz q2vXxk7HZ8ZK9r3vhOOF9ymOfc1NZqFvOLjDatrIxw2XlzH9Oexeru1LIx5b9StpUkv5 GwhFqd4lBAyi42j4YqPyw/pNe9hlt0z9GI7qwp7xgdpHJS7t49qoyfX58LYAaj6WtgH2 StJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=D7hBFUxzuAeThH6/63iSYflwf3gCb1qop4FDVeWBdJo=; b=AH0ZOonvuGJdcMAVBC217PjNPfTfKxyyA4mTKK+wJMBXXkmgN93k3PFzquBvQXstaa AUAFARnydT2rMzIhBSA5TEKR1CZA9LNc4ow1ZFU4dhBJVtKFMf9B4MUvnIgwLu1FxtG2 /Lb8017IVHzG9Xp1Ir6DhgjuA1x4UJcU0Fg37cM1PK9l4GeRFVfvbCnRtH5On0G/44a1 EX0XrsN7l+1jbIdG61DJAQwThli5QtS6NmL2PeKZkxn0vzWnYc37+PZ6zYMaw1VM6QDc zHuADB45fyq6Sk2XhcOPvu/nIWW8C89zifM7OpNsszfiuRPWsiDkmwlhhwh2w1gu6XN5 r3Dg== X-Gm-Message-State: AJIora9jsPXa/aXQu4KoXUdIpBEYiZ0QK7hKlZlZhn6GJpV8ko7CXmqM MgLHw4t8aYGMlSnmrLGr+KyjrjRbB1e7VTsE X-Google-Smtp-Source: AGRyM1tRBi+1t/5b3V2i/Fy8iL3LZajsEyU9i/nqgHNzQh68hBp3W8CbydsZTLrD0rq/EnT9w+Eovw== X-Received: by 2002:a05:6214:c6c:b0:470:a31c:c8c9 with SMTP id t12-20020a0562140c6c00b00470a31cc8c9mr42169708qvj.113.1657224778797; Thu, 07 Jul 2022 13:12:58 -0700 (PDT) Received: from hurd (dsl-153-127.b2b2c.ca. [66.158.153.127]) by smtp.gmail.com with ESMTPSA id bq9-20020a05620a468900b006af6f0893c6sm21999974qkb.91.2022.07.07.13.12.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Jul 2022 13:12:58 -0700 (PDT) From: Maxim Cournoyer References: <20220207011414.28849-1-jgart@dismail.de> <20220508202500.10449-1-paren@disroot.org> Date: Thu, 07 Jul 2022 16:12:57 -0400 In-Reply-To: <20220508202500.10449-1-paren@disroot.org> (paren@disroot.org's message of "Sun, 8 May 2022 21:25:00 +0100") Message-ID: <875yk8y94m.fsf_-_@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain 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 X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1657224849; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-to: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=D7hBFUxzuAeThH6/63iSYflwf3gCb1qop4FDVeWBdJo=; b=sn8GifidiSe/EcPSzROKzXFcaCyRJe6Vir9kIWPbbKwWH6dt5FhNZ7/4r9JcqWgxRtzD93 nG0PtlcZe3NTQWgWItvOOTvt/VUOoEyjOkXAAiIu8yj41mnidobYZgvq4iAfkk5JBhFKBa IVGxi06bayWLP8HFXZR5huVZlOedyuRKVkygirZOkgvMpENT5IToG9R92DUX9rWrxI/8U3 /XIPeqePZbSLJShuRZ4QP/FL0IPZ6lnx84TpwBN+PgF+82NoQzxRLoYctPE+BOcmqA2wqe l9kRhi8fgJPueuruLf0+Tp260TpuzRIupsc+2vmxEP/52M09+Yt5IpJeXboDlQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1657224849; a=rsa-sha256; cv=none; b=ltUNjA062UQUHLQlsiwH6C2djuKJEwV0gb8V5b/HCktttSsYOsWbKAQPlhYF2p5wjRVtJx cBS7NGSamqdJLN5DRsKBUQWaePGZF5qiv9BzwGsmsTPQhp/eyiH/Ltwtk8jD0a7DRKTnf2 KfLCgrwkKReGwgnRvnvqIIXTTDza3ZNBigra54nb37Mie62WL8wRsDTydUEbpBqYHgCVDV zom1FkQDcUQwqAnRfCJ7T/T78b5phBT5QFC72TXMNbSGCKpVhKT9Xa/MZS0srQTLhKI7Qe BWaZkHIai/edXJ2OUsPidZFyD1g+cMmLem/1rKvOnivbiwbw2+e7mBwNBGPY2A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=kans8hrU; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 5.95 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=kans8hrU; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: A84101ECF4 X-Spam-Score: 5.95 X-Migadu-Scanner: scn0.migadu.com X-TUID: x1twLz6gdEQM Hello! "(unmatched-parenthesis" writes: > * gnu/packages/c.scm (cproc): New variable. > > Signed-off-by: (unmatched-parenthesis > --- > This improved patch fixes some style nits. > > Thanks to lilyp for pointing them out on #guix! > > gnu/packages/c.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 46 insertions(+) > > diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm > index c9a25eb801..216ddfef88 100644 > --- a/gnu/packages/c.scm > +++ b/gnu/packages/c.scm > @@ -47,6 +47,7 @@ (define-module (gnu packages c) > #:use-module (gnu packages bison) > #:use-module (gnu packages check) > #:use-module (gnu packages flex) > + #:use-module (gnu packages gcc) > #:use-module (gnu packages perl) > #:use-module (gnu packages texinfo) > #:use-module (gnu packages guile) > @@ -1108,3 +1109,48 @@ (define-public qbe > language as input.") > (home-page "https://c9x.me/compile/") > (license license:expat)))) > + > +(define-public cproc > + (let ((commit "70fe9ef1810cc6c05bde9eb0970363c35fa7e802") > + (revision "1")) > + (package > + (name "cproc") > + (version (git-version "0.0" revision commit)) > + (source > + (origin > + (method git-fetch) > + (uri (git-reference > + (url "https://git.sr.ht/~mcf/cproc") > + (commit commit))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 "1qmgzll7z7mn587azkj4cizyyd8ii6iznfxpc66ja08140sbn9yx")))) > + (build-system gnu-build-system) > + (arguments > + (list #:make-flags > + #~(list (string-append "CC=" #$(cc-for-target)) > + (string-append "PREFIX=" #$output)) > + #:phases > + #~(modify-phases %standard-phases > + (replace 'configure > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (let ((out (assoc-ref outputs "out")) > + (gcc-lib (assoc-ref inputs "gcc:lib")) > + (host-system #$(nix-system->gnu-triplet (%current-system))) > + (target-system > + #$(nix-system->gnu-triplet (or (%current-target-system) > + (%current-system))))) > + (invoke "./configure" > + (string-append "--prefix=" out) > + (string-append "--host=" host-system) > + (string-append "--target=" target-system) > + (string-append "--with-ld=" #$(ld-for-target)) > + (string-append "--with-gcc-libdir=" gcc-lib)))))))) > + (inputs `(("qbe" ,qbe) > + ("gcc:lib" ,gcc "lib"))) > + (supported-systems (list "x86_64-linux" "aarch64-linux")) > + (synopsis "Simple C11 compiler backed by QBE") > + (description "@code{cproc} is a C compiler using QBE as a backend, supporting most of C11 > +along with some GCC and C2x extensions.") > + (home-page "https://sr.ht/~mcf/cproc") > + (license license:expat)))) Well done! I've adjusted slightly the source to fit under 80 columns, and push as 96eb2337b5c3d43c99979222633987a8e45df4b9. Thank you! Maxim