From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 0DY7ImmsV1+1XwAA0tVLHw (envelope-from ) for ; Tue, 08 Sep 2020 16:08:09 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id YDMmHmmsV18vUgAAB5/wlQ (envelope-from ) for ; Tue, 08 Sep 2020 16:08:09 +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 025BC940876 for ; Tue, 8 Sep 2020 16:08:09 +0000 (UTC) Received: from localhost ([::1]:51442 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kFgAC-0000KS-06 for larch@yhetil.org; Tue, 08 Sep 2020 12:08:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36798) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kFg3L-00048c-67 for guix-patches@gnu.org; Tue, 08 Sep 2020 12:01:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:44597) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kFg3K-0004dY-Pz for guix-patches@gnu.org; Tue, 08 Sep 2020 12:01:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kFg3K-0005S9-Om for guix-patches@gnu.org; Tue, 08 Sep 2020 12:01:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#43183] [PATCH v3 2/4] gnu: Add guile-machine-code. Resent-From: Martin Becze Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 08 Sep 2020 16:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43183 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 43183@debbugs.gnu.org Cc: Martin Becze Received: via spool by 43183-submit@debbugs.gnu.org id=B43183.159958082918826 (code B ref 43183); Tue, 08 Sep 2020 16:01:02 +0000 Received: (at 43183) by debbugs.gnu.org; 8 Sep 2020 16:00:29 +0000 Received: from localhost ([127.0.0.1]:56136 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kFg2n-0004tB-7B for submit@debbugs.gnu.org; Tue, 08 Sep 2020 12:00:29 -0400 Received: from mx1.riseup.net ([198.252.153.129]:43400) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kFg2l-0004rM-NC for 43183@debbugs.gnu.org; Tue, 08 Sep 2020 12:00:28 -0400 Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4Bm8xM6WZZzFpB3 for <43183@debbugs.gnu.org>; Tue, 8 Sep 2020 09:00:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1599580827; bh=hotGRYs7et2A45rlqAT0Q1N9Z1/CGPwd2WumFota7eI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GWTuaVxA4Tz3YIPPENGfEcSG1Usk2bQChM4cbZF5pGzNjTO6YapLfiyiii9MWEB1S Xj60eTyzung+9Wx1yeuZU5XRviRMeKIxvEZAQSgXTBIQpidSTtUpIuzLFo5gr7FgQS 3ibvVWF1QtBbyNxErX2i0+2HdPsra7Q+hbe59Nzo= X-Riseup-User-ID: 550BCFA1599FE79BD98523A78425EDD0E8159B799D0204B44E48E4AC46DCFFA0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4Bm8xM1qvdz8trb; Tue, 8 Sep 2020 09:00:07 -0700 (PDT) From: Martin Becze Date: Tue, 8 Sep 2020 10:59:44 -0500 Message-Id: <20200908155946.2322-3-mjbecze@riseup.net> In-Reply-To: <20200908155946.2322-1-mjbecze@riseup.net> References: <20200903150243.27796-1-mjbecze@riseup.net> <20200908155946.2322-1-mjbecze@riseup.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.7 (-) 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-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=riseup.net header.s=squak header.b=GWTuaVxA; dmarc=fail reason="SPF not aligned (relaxed)" header.from=riseup.net (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-Spam-Score: 5.09 X-TUID: 4N4rfvhkVW30 * gnu/packages/guile-xyz.scm (guile-machine-code): New variable. --- gnu/packages/guile-xyz.scm | 48 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index e1c763faef..7c8a417a14 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -3911,3 +3911,51 @@ more objects or strings, represented by a Json object or an IRI.") "This is an R6RS library for working with packed byte structures. It is similar to struct in Python or pack and unpack in Perl.") (license license:expat))) + +(define-public guile-machine-code + (package + (name "guile-machine-code") + (version "2.1.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/weinholt/machine-code.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0wzj3caj2jypzyjqfkfqkvr3kkbjabsnhldv9kvnx9w9qnria5yd")))) + (build-system guile-build-system) + (arguments + `(#:compile-flags '("--r6rs" "-Wunbound-variable" "-Warity-mismatch") + #:modules ((guix build guile-build-system) + (guix build utils) + (srfi srfi-26) + (ice-9 ftw)) + #:phases (modify-phases %standard-phases + (add-before 'build 'move-sls-files + (lambda _ + ;; Move files under a struct/ directory to reflect the + ;; module hierarchy. + (define dst-folder "machine-code") + (define (target file) + (string-append dst-folder "/" file)) + (define files + (scandir "." (negate (cut member <> '("." ".."))))) + (mkdir dst-folder) + (for-each (lambda (file) + (rename-file file (target file))) + files) + #t))))) + (native-inputs + `(("guile" ,guile-3.0))) + (propagated-inputs + `(("guile-struct-pack" ,guile-struct-pack))) + (home-page "https://github.com/weinholt/machine-code") + (synopsis "Tools that relate to machine code and object formats") + (description + "This project is about the development of tools that relate to machine +code and object formats; for all architectures. Here you'll find libraries for +working with binary code: assembly, disassembly, instruction tables, object +formats and related areas.") + (license license:expat))) -- 2.28.0