From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id SDi+FkLB+V+QCwAA0tVLHw (envelope-from ) for ; Sat, 09 Jan 2021 14:44:18 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id +DaMEkLB+V9UQgAA1q6Kng (envelope-from ) for ; Sat, 09 Jan 2021 14:44:18 +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 BEBEE940483 for ; Sat, 9 Jan 2021 14:44:17 +0000 (UTC) Received: from localhost ([::1]:34968 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kyFTU-0005ED-Ou for larch@yhetil.org; Sat, 09 Jan 2021 09:44:16 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44368) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kyFTG-0005Dv-W8 for guix-patches@gnu.org; Sat, 09 Jan 2021 09:44:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:39870) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kyFTF-00028C-V3 for guix-patches@gnu.org; Sat, 09 Jan 2021 09:44:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kyFTF-0007Bt-TN for guix-patches@gnu.org; Sat, 09 Jan 2021 09:44: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: Sat, 09 Jan 2021 14:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 45744 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 45744@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.161020339327575 (code B ref -1); Sat, 09 Jan 2021 14:44:01 +0000 Received: (at submit) by debbugs.gnu.org; 9 Jan 2021 14:43:13 +0000 Received: from localhost ([127.0.0.1]:51416 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyFSS-0007Ah-U8 for submit@debbugs.gnu.org; Sat, 09 Jan 2021 09:43:13 -0500 Received: from lists.gnu.org ([209.51.188.17]:57168) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyFSR-0007AZ-3K for submit@debbugs.gnu.org; Sat, 09 Jan 2021 09:43:11 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44264) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kyFSQ-00055D-SC for guix-patches@gnu.org; Sat, 09 Jan 2021 09:43:10 -0500 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]:43392) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kyFSN-0001oU-DR for guix-patches@gnu.org; Sat, 09 Jan 2021 09:43:10 -0500 Received: by mail-wr1-x430.google.com with SMTP id y17so11743935wrr.10 for ; Sat, 09 Jan 2021 06:43:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=HYuCleAl/9lB1wMazhrFdOW7QJeHCVS9J//nkH5rnVA=; b=m/ooPGJ7T9lGZGV4E8GoKRnfKnu/kSlRmy3+WEZLjDQBbqooc7yuGgXi+phfNuePEv BYSbTG1Ymg7v5xkv+HUJEoVZ4Yzq8MObq1BQ0iERB14k/g/u9B4vWwlLQLTgb7bPviSF 5QZSkmQTo/G5XlIxr8YtFmCFKYGvtMBzhpGOot4kNGXbqpJdumu88vTE8TUyrqoE9z3I BcDGR4gbBBJrDZKLbx4bPqGVCvzI45tENs1R812ojcK36NA5S0VpSDfhs36CpglOiqJc tf7+hkQtOBvuu8nV5+VEhey6UbStVbbdcMkqSOmPcFzIN3C296Ek1tYyc8pyNVEE3Tn5 zyUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=HYuCleAl/9lB1wMazhrFdOW7QJeHCVS9J//nkH5rnVA=; b=Z2W1LtF64W55aIMu/MVakWfJ95y4NrLgfWy30rnQmDIDl5/Q3PZyXqJz4TZ1gBXmbF kisIdn3vcC0hEUy14EI0OlveJ00qEyHjdGKdS4AnXHY/MTRfwkUf0KeHNgpch2zAMOye +DCGihj2PD8oJNYr3EKn73x9TEP8F3+5ZchIldu5ZwFiIBfBYhfaDKymWdPH5eNsCXLB +Ddx3lKnGCVC9sRttmbGv+Qma4+Cuaph1+gDADaqx64TkeOX3RYsaJ16zwRN5byv3lRN 2oTKEjBAtJgAe+Dgruy8UL56jsPF15KgBFsrhjJtAu6TfDeVmjX0vhe7ksmLUuZDIRBf SnfA== X-Gm-Message-State: AOAM532Gt6Wf5d3GFrGRmhrHZ/zLQtHuuUxET56YwFVS0xVGSIFSvrOc HAE1FOL5StVac3po5K8uYmEz1a+sg10= X-Google-Smtp-Source: ABdhPJzhubbj0ifXBEpXaUAOEg/Ad8mUI4krNIXFXdhd7Gpu5XSIc+tp4BNjj3PKYCySlukfKX/Rug== X-Received: by 2002:adf:ebc2:: with SMTP id v2mr8400040wrn.88.1610203385881; Sat, 09 Jan 2021 06:43:05 -0800 (PST) Received: from localhost.localdomain (se167-1-82-242-148-1.fbx.proxad.net. [82.242.148.1]) by smtp.gmail.com with ESMTPSA id e17sm17579158wrw.84.2021.01.09.06.43.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 09 Jan 2021 06:43:05 -0800 (PST) From: Vincent Legoll Date: Sat, 9 Jan 2021 15:42:56 +0100 Message-Id: <20210109144256.2209-1-vincent.legoll@gmail.com> X-Mailer: git-send-email 2.30.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=vincent.legoll@gmail.com; helo=mail-wr1-x430.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: , Cc: Vincent Legoll Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: 2.75 Authentication-Results: aspmx1.migadu.com; dkim=fail (headers rsa verify failed) header.d=gmail.com header.s=20161025 header.b=m/ooPGJ7; 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: BEBEE940483 X-Spam-Score: 2.75 X-Migadu-Scanner: scn0.migadu.com X-TUID: TpRvxwAFmKJl * 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