From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 6K4nFO+R/F8oGwAA0tVLHw (envelope-from ) for ; Mon, 11 Jan 2021 17:59:11 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id aHgUEO+R/F/lVAAAbx9fmQ (envelope-from ) for ; Mon, 11 Jan 2021 17:59: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 A66BA9403CB for ; Mon, 11 Jan 2021 17:59:10 +0000 (UTC) Received: from localhost ([::1]:34034 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kz1TB-0000AV-LP for larch@yhetil.org; Mon, 11 Jan 2021 12:59:09 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:32930) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kz1T4-00008S-1p for guix-patches@gnu.org; Mon, 11 Jan 2021 12:59:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:46646) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kz1T3-0006jB-RG for guix-patches@gnu.org; Mon, 11 Jan 2021 12:59:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kz1T3-0000th-Qp for guix-patches@gnu.org; Mon, 11 Jan 2021 12:59:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#45744] [PATCH] gnu: Add libx86emu. Resent-From: Vincent Legoll Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 11 Jan 2021 17:59:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 45744 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 45744@debbugs.gnu.org X-Debbugs-Original-To: Guix Patches Received: via spool by submit@debbugs.gnu.org id=B.16103879403441 (code B ref -1); Mon, 11 Jan 2021 17:59:01 +0000 Received: (at submit) by debbugs.gnu.org; 11 Jan 2021 17:59:00 +0000 Received: from localhost ([127.0.0.1]:58192 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kz1T1-0000tR-MM for submit@debbugs.gnu.org; Mon, 11 Jan 2021 12:58:59 -0500 Received: from lists.gnu.org ([209.51.188.17]:56176) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kz1Sz-0000tK-WE for submit@debbugs.gnu.org; Mon, 11 Jan 2021 12:58:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:32918) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kz1Sz-0008V8-Lt for guix-patches@gnu.org; Mon, 11 Jan 2021 12:58:57 -0500 Received: from mail-lj1-x233.google.com ([2a00:1450:4864:20::233]:42760) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kz1Sx-0006if-NB for guix-patches@gnu.org; Mon, 11 Jan 2021 12:58:57 -0500 Received: by mail-lj1-x233.google.com with SMTP id y22so140774ljn.9 for ; Mon, 11 Jan 2021 09:58:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=9yRfZU5pVY/WUy9j59pRp31xS2uRPFbOu3wB6qFPF/4=; b=dTFEqLc6bgmRgVV2P4dNpXkuJ1oS/u9gQ6bwmOeffUwIW7J7ETV+sf34FXqEVmp5tn FkP5bFpqqFcrn7dTEnxbDTXTLsby2av9+hiVdzB4w6+BbFwTUotKsTjBjgq6V4HbAaMJ KbSU+p5EAKI+SDHkHtRteXr6vxjDkBIJKbpuFugGB9rZJOekO4ckht+7RG7QOKoKBnWv ze0blG3IJvzv5HrIfD3J8+SlQpr4qMLTdTP/ULlsQj7VcdrXb7VavIk1m9FMbzkqmrxr 97MuAcpkYAoqTbnxsomV7JemECTdt+/mpAUeA5Z+5hwhUxz3R3OI8T79klgQ3xEYzTld rSUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=9yRfZU5pVY/WUy9j59pRp31xS2uRPFbOu3wB6qFPF/4=; b=IfodRGuyfcXllryjFpr6MRUdE8f94ACPSRNny7cThxpFuxMGQXamC+Ms8SsdVE7PLM kVq+Q4mR+qHhgiKcmkvojQr8bo0h6Ols/hm0WRI0lwkli4FCS78Taivgw2c1K4ZWS9WE I8QBLCL2URmEP+vzZjjOxsNzMrdTcPIEJb0TXyluYOMld+iJstgA1llPJYqUkC0uEydr 2nFq/6amVV4djXC2ecxPAHt9ci9bZzdf+PErVw4H/SWuBQVkM+Vu8fFdDDQe/axqr8h3 EHyQ9OzNcZkXI0hRSQDqkoHpFLH/bXjifkgjFotyMgGUGGdn78TAagXWE0CjYwol6Y53 hZSw== X-Gm-Message-State: AOAM533gaL4iWy7JBM1euD/lD+vzU73CJUSPr+k+0j9CoQYtQFlPQH3v RAszveVGG8PfkACBAFW5ebB59w5U8VqecVAcgvhSDdV0 X-Google-Smtp-Source: ABdhPJzwJ980zsDLXAj4gt+TJjmeEkj35qsEeaI67aWRpxL/VPVnEr1jhgKWh3HOjFrFgCioM8X9L7B1oa/xJgsmpB4= X-Received: by 2002:a2e:9246:: with SMTP id v6mr264975ljg.221.1610387932875; Mon, 11 Jan 2021 09:58:52 -0800 (PST) MIME-Version: 1.0 References: <20210109144256.2209-1-vincent.legoll@gmail.com> In-Reply-To: <20210109144256.2209-1-vincent.legoll@gmail.com> From: Vincent Legoll Date: Mon, 11 Jan 2021 18:58:41 +0100 Message-ID: Content-Type: text/plain; charset="UTF-8" Received-SPF: pass client-ip=2a00:1450:4864:20::233; envelope-from=vincent.legoll@gmail.com; helo=mail-lj1-x233.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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-Spam-Score: -1.25 Authentication-Results: aspmx1.migadu.com; dkim=fail (headers rsa verify failed) header.d=gmail.com header.s=20161025 header.b=dTFEqLc6; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.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: A66BA9403CB X-Spam-Score: -1.25 X-Migadu-Scanner: scn1.migadu.com X-TUID: Sby6lsiuCy/9 Hello, Please disregard this patch, I'll followup with an updated (better) one On Sat, Jan 9, 2021 at 3:43 PM Vincent Legoll wrote: > > * gnu/packages/emulators.scm (libx86emu): New variable. > --- > gnu/packages/emulators.scm | 48 ++++++++++++++++++++++++++++++++++++++ > 1 file changed, 48 insertions(+) > > diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm > index 1d94090f48..4b76dcef79 100644 > --- a/gnu/packages/emulators.scm > +++ b/gnu/packages/emulators.scm > @@ -72,6 +72,7 @@ > #:use-module (gnu packages music) > #:use-module (gnu packages ncurses) > #:use-module (gnu packages networking) > + #:use-module (gnu packages perl) > #:use-module (gnu packages pkg-config) > #:use-module (gnu packages pulseaudio) > #:use-module (gnu packages python) > @@ -591,6 +592,53 @@ and Game Boy Color games.") > ;; BSD-3, and "discord-rpc" is Expat. > (license (list license:mpl2.0 license:lgpl2.1+ license:bsd-3 license:expat)))) > > +(define-public libx86emu > + (package > + (name "libx86emu") > + (version "3.1") > + (source > + (origin > + (method git-fetch) > + (uri (git-reference > + (url "https://github.com/wfeldt/libx86emu") > + (commit version))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 "104xqc6nj9rpi7knl3dfqvasf087hlz2n5yndb1iycw35a6j509b")))) > + (build-system gnu-build-system) > + (native-inputs > + `(("nasm" ,nasm) > + ("perl" ,perl))) ; for the `./test/prepare_test' script > + (arguments > + `(#:phases > + (modify-phases %standard-phases > + (add-after 'unpack 'version-file > + (lambda _ > + (invoke "chmod" "-x" "./git2log") ; we are not in a full git repository > + (with-output-to-file "./VERSION" ; emulate what git2log would have done > + (lambda _ > + (display ,version))) > + #t)) > + (replace 'check > + (lambda _ > + (invoke "make" "test"))) > + (replace 'install > + (lambda* (#:key outputs #:allow-other-keys) > + (invoke "make" "install" > + (string-append "DESTDIR=" (assoc-ref outputs "out")) > + (string-append "LIBDIR=" (assoc-ref outputs "out") "/usr/lib")) ; avoid using `ldd /bin/sh' to choose between 32 and 64 bits libdir > + #t)) > + (delete 'configure)))) > + (home-page "https://github.com/wfeldt/libx86emu") > + (synopsis "x86 emulation library") > + (description "libx86emu is a small library to emulate x86 instructions. The > +focus here is not a complete emulation (use qemu for this) but to cover enough > +for typical firmware blobs. At the moment 'regular' 32-bit instructions are > +covered together with basic protected mode support. Not done are fpu, mmx, or > +any of the other instruction set extensions.") > + (license (license:non-copyleft > + "https://github.com/wfeldt/libx86emu/blob/master/LICENSE")))) > + > (define-public sameboy > (package > (name "sameboy") > -- > 2.30.0 > -- Vincent Legoll