From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:22:37 2023 Received: (at submit) by debbugs.gnu.org; 9 Jan 2023 19:22:37 +0000 Received: from localhost ([127.0.0.1]:38199 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExjA-00076T-Ok for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:22:37 -0500 Received: from lists.gnu.org ([209.51.188.17]:53682) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExj9-00076L-Dx for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:22:35 -0500 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 1pExj9-0004lo-AO for guix-patches@gnu.org; Mon, 09 Jan 2023 14:22:35 -0500 Received: from mailout.easymail.ca ([64.68.200.34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pExj6-0001mu-PD for guix-patches@gnu.org; Mon, 09 Jan 2023 14:22:35 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 3887F67B40 for ; Mon, 9 Jan 2023 19:22:29 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo09-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo09-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Un8PBMehe-_x for ; Mon, 9 Jan 2023 19:22:28 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 326A267B3F for ; Mon, 9 Jan 2023 19:22:28 +0000 (UTC) From: Simon South To: guix-patches@gnu.org Subject: [PATCH 0/9] gnu: nextpnr-ice40: Update to 0.5. Date: Mon, 9 Jan 2023 14:22:25 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=64.68.200.34; envelope-from=simon@simonsouth.net; helo=mailout.easymail.ca X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Continuing on from issue 60429[0], here's a patch series that aims to improve the package for nextpnr-ice40, a place-and-route tool for Lattice iCE40 FPGAs, by - Adding separate packages for implot, qtimgui and sanitizers-cmake, which are currently bundled with nextpnr; - Updating its source-repository URL to use HTTPS instead of the git protocol (no longer supported by GitHub[1]); - Updating it to the modern style using gexps; - Enabling the test suite; - Fixing the version string shown by "nextpnr-ice40 --version", which should match the output of "git describe --tags --always" at build time but is currently empty; - Removing the bundled software and patching the source to use Guix packages instead; and - Updating nextpnr-ice40 itself to version 0.5. I've tested this on x86-64 (command line and GUI) and AArch64 (command line only) and everything seems fine. Note that as with Yosys, the nextpnr Web page helpfully includes a short example of using the tool[2] for testing its basic functionality. (The "blinky" folder is in the nextpnr source tree.) [0] https://issues.guix.gnu.org/60429 [1] https://github.blog/2021-09-01-improving-git-protocol-security-github/ [2] https://github.com/YosysHQ/nextpnr#getting-started -- Simon South simon@simonsouth.net Simon South (9): gnu: Add implot. gnu: Add qtimgui. gnu: Add sanitizers-cmake. gnu: nextpnr-ice40: Use HTTPS for source URL. gnu: nextpnr-ice40: Use gexps. gnu: nextpnr-ice40: Enable tests. gnu: nextpnr-ice40: Fix generated version string. gnu: nextpnr-ice40: Remove bundled software. gnu: nextpnr-ice40: Update to 0.5. gnu/packages/cmake.scm | 45 ++++++++++++++++++ gnu/packages/fpga.scm | 99 +++++++++++++++++++++++++++++++-------- gnu/packages/qt.scm | 63 +++++++++++++++++++++++++ gnu/packages/toolkits.scm | 50 ++++++++++++++++++++ 4 files changed, 238 insertions(+), 19 deletions(-) base-commit: de48bcee070b8d1ea6f3abe24be28d3b7d1aff68 -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:14 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:15 +0000 Received: from localhost ([127.0.0.1]:38208 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmg-0007DK-DL for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:14 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33168) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmd-0007CW-W3 for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:12 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id C3F24E7AF6 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VcyWcqCeBR95 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 77741E3058 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 1/9] gnu: Add implot. Date: Mon, 9 Jan 2023 14:25:55 -0500 Message-Id: <413b2f8271dcae1fa1b79a71874e1028fe826651.1673286570.git.simon@simonsouth.net> X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/toolkits.scm (implot): New variable. --- gnu/packages/toolkits.scm | 50 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/toolkits.scm b/gnu/packages/toolkits.scm index 3030e3aa49..81de853572 100644 --- a/gnu/packages/toolkits.scm +++ b/gnu/packages/toolkits.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2022 Maxim Cournoyer ;;; Copyright © 2020, 2022 Tobias Geerinckx-Rice ;;; Copyright © 2022 John Kehayias +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -141,3 +142,52 @@ (define-public imgui-1.86 (sha256 (base32 "02a7b05zrka20jhzag2jb4jl624i1m456bsv69jb9zgys2p9dv1n")))))) + +(define-public implot + (package + (name "implot") + (version "0.14") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/epezent/implot") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0kp0h5s9dh7380yink5f091ss5cwfj321n6ym87j4skcp0giiym6")))) + (build-system gnu-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (delete 'bootstrap) + (delete 'configure) + (replace 'build + ;; Build a shared library from the source code. + (lambda* (#:key inputs #:allow-other-keys) + (invoke #$(cc-for-target) "-I" (getcwd) + "-I" (search-input-directory inputs "include/imgui") + "-g" "-O2" "-fPIC" "-shared" + "-o" "libimplot.so" + "implot.cpp" + "implot_items.cpp"))) + (replace 'install + ;; Copy the library and header files to the output. + (lambda _ + (install-file "libimplot.so" (string-append #$output "/lib")) + (for-each (lambda (file-name) + (install-file file-name + (string-append #$output + "/include/implot"))) + '("implot.h" "implot_internal.h"))))) + #:tests? #f)) ; no test suite + (inputs + (list imgui)) + (home-page "https://github.com/epezent/implot") + (synopsis "Immediate-mode C++ plotting library for ImGui") + (description "ImPlot is an immediate-mode, GPU-accelerated plotting +library in C++ for the ImGui GUI library, suitable for creating real-time +visualizations or interactive plots. Like ImGui, ImPlot is self-contained and +requires only minimal code to integrate with existing applications.") + (license license:expat))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:15 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:15 +0000 Received: from localhost ([127.0.0.1]:38210 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmg-0007DM-Ub for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:15 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33186) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExme-0007CX-5c for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:13 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 01F6BE3058 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SiJlvtB0ihq8 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 91F70E4497 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 2/9] gnu: Add qtimgui. Date: Mon, 9 Jan 2023 14:25:56 -0500 Message-Id: <655b7031be0bb48f2c805e592357ffff430221ee.1673286570.git.simon@simonsouth.net> X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/qt.scm (qtimgui): New variable. --- gnu/packages/qt.scm | 63 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 6406fd5c49..7ffb52492d 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -26,6 +26,7 @@ ;;; Copyright © 2022 Foo Chuan Wei ;;; Copyright © 2022 Zhu Zihao ;;; Copyright © 2022 Petr Hodina +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -114,6 +115,7 @@ (define-module (gnu packages qt) #:use-module (gnu packages sqlite) #:use-module (gnu packages telephony) #:use-module (gnu packages tls) + #:use-module (gnu packages toolkits) #:use-module (gnu packages valgrind) #:use-module (gnu packages video) #:use-module (gnu packages vulkan) @@ -3548,6 +3550,67 @@ (define-public python-pyqt+qscintilla (description "This package contains the union of PyQt and the Qscintilla extension."))) +(define-public qtimgui + (let ((commit "48d64a715b75dee24e398f7e5b0942c2ca329334") + (revision "0")) + (package + (name "qtimgui") + (version (git-version "0.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/seanchas116/qtimgui") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0x71j8m15w003ak0d7q346rlwyvklkda9l0dwbxfx6kny3gsl11k")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags #~(list "-DQTIMGUI_BUILD_IMGUI=OFF" + "-DQTIMGUI_BUILD_IMPLOT=OFF") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "CMakeLists.txt" + ;; Disable building the examples. + (("^add_subdirectory\\(examples\\)") "")) + (substitute* "src/CMakeLists.txt" + ;; Build shared libraries, not static. + (("STATIC") "SHARED") + ;; Compile with the system imgui headers. + (("^(target_include_directories.*)\\)" _ prefix) + (string-append prefix + " " + (search-input-directory inputs + "include/imgui") + ")"))))) + (replace 'install + ;; No install target provided; manually copy the header and + ;; library files to the output. + (lambda* (#:key source #:allow-other-keys) + (for-each + (lambda (file-name) + (install-file (string-append source "/src/" file-name) + (string-append #$output "/include/qtimgui"))) + '("ImGuiRenderer.h" "QtImGui.h")) + (for-each + (lambda (file-name) + (install-file (string-append "src/" file-name) + (string-append #$output "/lib"))) + '("libqt_imgui_quick.so" "libqt_imgui_widgets.so"))))) + #:tests? #f)) ; no test suite + (inputs + (list imgui-1.86 implot qtbase-5 qtdeclarative-5)) + (home-page "https://github.com/seanchas116/qtimgui") + (synopsis "Qt backend for the ImGui GUI library") + (description "QtImGui allows the ImGui C++ GUI library to be used by Qt +applications within subclasses of @code{QOpenGLWidget} and +@code{QOpenGLWindow}.") + (license license:expat)))) + (define-public qtkeychain (package (name "qtkeychain") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:16 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:16 +0000 Received: from localhost ([127.0.0.1]:38212 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmh-0007DU-Gc for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:15 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33194) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExme-0007CY-8a for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:13 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 22AAFE7D2B for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 39-Ft1XXjsDY for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id ABAE1E6BE2 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 3/9] gnu: Add sanitizers-cmake. Date: Mon, 9 Jan 2023 14:25:57 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/cmake.scm (sanitizers-cmake): New variable. --- gnu/packages/cmake.scm | 45 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index 87fde01f63..f0d25b707d 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2019 Pierre-Moana Levesque ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2021 Ricardo Wurmus +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -32,6 +33,7 @@ (define-module (gnu packages cmake) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix utils) #:use-module (guix deprecation) @@ -422,3 +424,46 @@ (define-public emacs-cmake-mode (description "@code{cmakeos-mode} provides an Emacs major mode for editing Cmake files. It supports syntax highlighting, indenting and refilling of comments."))) + +(define-public sanitizers-cmake + (let ((commit "a6748f4f51273d86312e3d27ebe5277c9b1ff870") + (revision "0")) + (package + (name "sanitizers-cmake") + (version (git-version "0.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/arsenm/sanitizers-cmake") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0shja5qipcsxgj5v6aic9q3dik0cbahllriigwgpayv5ng3ki1ij")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list + ;; Enable the "new" behavior established by CMake policy CMP0077, + ;; which pertains to CMake's "option()" command. This is required + ;; for the package's test suite to complete successfully. + ;; Note this setting may become redundant with future versions of + ;; CMake (past 3.24.2). + "-DCMAKE_POLICY_DEFAULT_CMP0077=NEW") + #:phases + #~(modify-phases %standard-phases + ;; No install target provided; manually copy files to a suitable + ;; folder in the output. + (replace 'install + (lambda* (#:key source #:allow-other-keys) + (copy-recursively + (string-append source "/cmake") + (string-append #$output "/share/" #$name "/cmake"))))))) + (synopsis "CMake module to enable sanitizers for binary targets") + (description "@code{sanitizers-cmake} provides a module for the CMake +build system that can enable address, memory, thread and undefined-behavior +sanitizers for binary targets using flags appropriate for the compiler in +use.") + (home-page "https://github.com/arsenm/sanitizers-cmake") + (license license:expat)))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:16 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:16 +0000 Received: from localhost ([127.0.0.1]:38214 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmh-0007Db-W1 for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:16 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33204) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExme-0007Ca-FH for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:13 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 506C5E7D30 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JZ5EhfbCogl4 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id C5FAFE7CFA for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 4/9] gnu: nextpnr-ice40: Use HTTPS for source URL. Date: Mon, 9 Jan 2023 14:25:58 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Use HTTPS for URL. --- gnu/packages/fpga.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index acce5f8f82..0924c34e0c 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -283,7 +283,7 @@ (define-public nextpnr-ice40 (origin (method git-fetch) (uri (git-reference - (url "git://github.com/YosysHQ/nextpnr") + (url "https://github.com/YosysHQ/nextpnr") (commit commit))) (file-name (git-file-name name version)) (sha256 -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:17 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:17 +0000 Received: from localhost ([127.0.0.1]:38216 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmi-0007Di-A5 for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:16 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33216) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExme-0007Cc-Pk for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:14 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 99C85E7EE8 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DffWi6y6losw for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 48B02E7E7D for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 8/9] gnu: nextpnr-ice40: Remove bundled software. Date: Mon, 9 Jan 2023 14:26:02 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Add modules, snippet. [native-inputs]: Add googletest, sanitizers-cmake. [inputs]: Add imgui-1.86, pybind11, qtimgui. [arguments]: Add "patch-source" phase; reformat gently. --- gnu/packages/fpga.scm | 70 ++++++++++++++++++++++++++++++++++++++----- 1 file changed, 62 insertions(+), 8 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 7649b2bbd6..3cb96a1cd1 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2021 Andrew Miloradovsky ;;; Copyright © 2022 Christian Gelinek ;;; Copyright © 2022 jgart +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -36,10 +37,12 @@ (define-module (gnu packages fpga) #:use-module (gnu packages) #:use-module (gnu packages autotools) #:use-module (gnu packages base) + #:use-module (gnu packages cmake) #:use-module (gnu packages compression) #:use-module (gnu packages elf) #:use-module (gnu packages pkg-config) #:use-module (gnu packages tcl) + #:use-module (gnu packages toolkits) #:use-module (gnu packages readline) #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) @@ -289,23 +292,74 @@ (define-public nextpnr-ice40 (file-name (git-file-name name version)) (sha256 (base32 - "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")))) + "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")) + (modules '((guix build utils))) + (snippet + #~(begin + ;; Remove bundled source code for which Guix has packages. + ;; Note the bundled copies of json11 and python-console contain + ;; modifications, while QtPropertyBrowser appears to be + ;; abandoned and without an official source. + (with-directory-excursion "3rdparty" + (for-each delete-file-recursively + '("googletest" "imgui" "pybind11" "qtimgui" + "sanitizers-cmake"))) + + ;; Remove references to unbundled code and link against + ;; external libraries instead. + (substitute* "CMakeLists.txt" + (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") + (("^(\\s+target_link_libraries.*)( gtest_main\\))" + _ prefix suffix) + (string-append prefix " gtest" suffix))) + (substitute* "gui/CMakeLists.txt" + (("^\\s+../3rdparty/(qt)?imgui.*") "") + (("^(target_link_libraries.*)\\)" _ prefix) + (string-append prefix " imgui qt_imgui_widgets)"))))))) + (native-inputs + (list googletest sanitizers-cmake)) (inputs (list boost eigen icestorm + imgui-1.86 + pybind11 python qtbase-5 + qtimgui yosys)) (build-system cmake-build-system) (arguments - (list #:configure-flags #~(list "-DARCH=ice40" - "-DBUILD_TESTS=ON" - (string-append "-DCURRENT_GIT_VERSION=" - #$(string-take commit 8)) - (string-append "-DICEBOX_ROOT=" - #$icestorm - "/share/icebox")))) + (list + #:configure-flags + #~(list "-DARCH=ice40" + "-DBUILD_TESTS=ON" + (string-append "-DCURRENT_GIT_VERSION=" + #$(string-take commit 8)) + (string-append "-DICEBOX_ROOT=" #$icestorm "/share/icebox")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "CMakeLists.txt" + ;; Use the system sanitizers-cmake module. + (("\\$\\{CMAKE_SOURCE_DIR\\}/3rdparty/sanitizers-cmake/cmake") + (string-append #$sanitizers-cmake + "/share/sanitizers-cmake/cmake"))) + (substitute* "gui/CMakeLists.txt" + ;; Compile with system imgui and qtimgui headers. + (("^(target_include_directories.*)../3rdparty/imgui(.*)$" + _ prefix suffix) + (string-append prefix + (search-input-directory inputs + "include/imgui") + suffix)) + (("^(target_include_directories.*)../3rdparty/qtimgui/(.*)$" + _ prefix suffix) + (string-append prefix + (search-input-directory inputs + "include/qtimgui") + suffix)))))))) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:24 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:24 +0000 Received: from localhost ([127.0.0.1]:38222 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmq-0007ES-1f for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:24 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33322) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmk-0007Cq-0O for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:18 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id E31A0E7CE9 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:11 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xIo4QaU1bpZm for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:11 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 0EEA8E4497 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 6/9] gnu: nextpnr-ice40: Enable tests. Date: Mon, 9 Jan 2023 14:26:00 -0500 Message-Id: <51964922a525a03b82b8eb0256228a9d1f132c22.1673286570.git.simon@simonsouth.net> X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Enable recursive checkout. [arguments]<#:configure-flags>: Add "-DBUILD_TESTS". <#:tests?>: Remove. --- gnu/packages/fpga.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 817ebe3f6b..947fe05dd0 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -284,11 +284,12 @@ (define-public nextpnr-ice40 (method git-fetch) (uri (git-reference (url "https://github.com/YosysHQ/nextpnr") - (commit commit))) + (commit commit) + (recursive? #t))) (file-name (git-file-name name version)) (sha256 (base32 - "1fmxsywgs45g88ra7ips5s2niiiwrkyxdcy742ws18dfk2y4vi9c")))) + "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")))) (inputs (list boost eigen @@ -299,10 +300,10 @@ (define-public nextpnr-ice40 (build-system cmake-build-system) (arguments (list #:configure-flags #~(list "-DARCH=ice40" + "-DBUILD_TESTS=ON" (string-append "-DICEBOX_ROOT=" #$icestorm - "/share/icebox")) - #:tests? #f)) + "/share/icebox")))) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:24 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:24 +0000 Received: from localhost ([127.0.0.1]:38224 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmq-0007EV-Aj for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:24 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33320) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmk-0007Cp-0N for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:18 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 4C43AE7EEC for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:09 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Oj5AH1E9_MUS for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:09 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id E9FC9E7D07 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:06 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 5/9] gnu: nextpnr-ice40: Use gexps. Date: Mon, 9 Jan 2023 14:25:59 -0500 Message-Id: <3a7ade2a7100f62cf7d3e7b4a25bb7829465f404.1673286570.git.simon@simonsouth.net> X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[arguments]: Use gexps. --- gnu/packages/fpga.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 0924c34e0c..817ebe3f6b 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -298,11 +298,11 @@ (define-public nextpnr-ice40 yosys)) (build-system cmake-build-system) (arguments - `(#:configure-flags `("-DARCH=ice40" - ,(string-append "-DICEBOX_ROOT=" - (assoc-ref %build-inputs "icestorm") - "/share/icebox")) - #:tests? #f)) + (list #:configure-flags #~(list "-DARCH=ice40" + (string-append "-DICEBOX_ROOT=" + #$icestorm + "/share/icebox")) + #:tests? #f)) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:24 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:25 +0000 Received: from localhost ([127.0.0.1]:38226 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmq-0007Ec-L6 for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:24 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33324) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmk-0007D2-8e for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:19 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 09CAAE4497 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:13 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kKwasmbEly5Y for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:12 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 2905AE6BE2 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 7/9] gnu: nextpnr-ice40: Fix generated version string. Date: Mon, 9 Jan 2023 14:26:01 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[arguments]<#:configure-flags>: Add "-DCURRENT_GIT_VERSION". --- gnu/packages/fpga.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 947fe05dd0..7649b2bbd6 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -301,6 +301,8 @@ (define-public nextpnr-ice40 (arguments (list #:configure-flags #~(list "-DARCH=ice40" "-DBUILD_TESTS=ON" + (string-append "-DCURRENT_GIT_VERSION=" + #$(string-take commit 8)) (string-append "-DICEBOX_ROOT=" #$icestorm "/share/icebox")))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 09 14:26:25 2023 Received: (at 60695) by debbugs.gnu.org; 9 Jan 2023 19:26:25 +0000 Received: from localhost ([127.0.0.1]:38228 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmq-0007Ek-Uy for submit@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:25 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:33330) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pExmk-0007D3-FT for 60695@debbugs.gnu.org; Mon, 09 Jan 2023 14:26:19 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 56527E3058 for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:13 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id o_RgPV8h6UXJ for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:13 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 609B4E7CFA for <60695@debbugs.gnu.org>; Mon, 9 Jan 2023 19:26:07 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH 9/9] gnu: nextpnr-ice40: Update to 0.5. Date: Mon, 9 Jan 2023 14:26:03 -0500 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40): Update to 0.5. [arguments]<#:configure-flags>: Add "-DBUILD_GUI", "-DUSE_IPO"; update "-DCURRENT_GIT_VERSION"; rename "-DICEBOX_ROOT" to "-DICESTORM_INSTALL_PREFIX". --- gnu/packages/fpga.scm | 84 ++++++++++++++++++++++--------------------- 1 file changed, 44 insertions(+), 40 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 3cb96a1cd1..ed1323346a 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -277,45 +277,48 @@ (define-public icestorm (license license:isc)))) (define-public nextpnr-ice40 - (let [(commit "fbe486df459909065d6852a7495a212dfd2accef") - (revision "1")] + (let* ((version "0.5") + (tag (string-append "nextpnr-" version))) (package (name "nextpnr-ice40") - (version (git-version "0.0.0" revision commit)) + (version version) (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/YosysHQ/nextpnr") - (commit commit) - (recursive? #t))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")) - (modules '((guix build utils))) - (snippet - #~(begin - ;; Remove bundled source code for which Guix has packages. - ;; Note the bundled copies of json11 and python-console contain - ;; modifications, while QtPropertyBrowser appears to be - ;; abandoned and without an official source. - (with-directory-excursion "3rdparty" - (for-each delete-file-recursively - '("googletest" "imgui" "pybind11" "qtimgui" - "sanitizers-cmake"))) + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/YosysHQ/nextpnr") + (commit tag) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "119iqxxzbxq2qy8x20awf9gr0nf3y1yjmk36adsg89ly3rb9gwzk")) + (modules '((guix build utils))) + (snippet + #~(begin + ;; Remove bundled source code for which Guix has packages. + ;; Note the bundled copies of json11 and python-console contain + ;; modifications, while QtPropertyBrowser appears to be + ;; abandoned and without an official source. + ;; fpga-interchange-schema is used only by the + ;; "fpga_interchange" architecture target, which this package + ;; doesn't build. + (with-directory-excursion "3rdparty" + (for-each delete-file-recursively + '("googletest" "imgui" "pybind11" "qtimgui" + "sanitizers-cmake"))) - ;; Remove references to unbundled code and link against - ;; external libraries instead. - (substitute* "CMakeLists.txt" - (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") - (("^(\\s+target_link_libraries.*)( gtest_main\\))" - _ prefix suffix) - (string-append prefix " gtest" suffix))) - (substitute* "gui/CMakeLists.txt" - (("^\\s+../3rdparty/(qt)?imgui.*") "") - (("^(target_link_libraries.*)\\)" _ prefix) - (string-append prefix " imgui qt_imgui_widgets)"))))))) + ;; Remove references to unbundled code and link against external + ;; libraries instead. + (substitute* "CMakeLists.txt" + (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") + (("^(\\s+target_link_libraries.*)( gtest_main\\))" + _ prefix suffix) + (string-append prefix " gtest" suffix))) + (substitute* "gui/CMakeLists.txt" + (("^\\s+../3rdparty/(qt)?imgui.*") "") + (("^(target_link_libraries.*)\\)" _ prefix) + (string-append prefix " imgui qt_imgui_widgets)"))))))) (native-inputs (list googletest sanitizers-cmake)) (inputs @@ -333,10 +336,11 @@ (define-public nextpnr-ice40 (list #:configure-flags #~(list "-DARCH=ice40" + "-DBUILD_GUI=ON" "-DBUILD_TESTS=ON" - (string-append "-DCURRENT_GIT_VERSION=" - #$(string-take commit 8)) - (string-append "-DICEBOX_ROOT=" #$icestorm "/share/icebox")) + (string-append "-DCURRENT_GIT_VERSION=" #$tag) + (string-append "-DICESTORM_INSTALL_PREFIX=" #$icestorm) + "-DUSE_IPO=OFF") #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch-source @@ -361,8 +365,8 @@ (define-public nextpnr-ice40 "include/qtimgui") suffix)))))))) (synopsis "Place-and-Route tool for FPGAs") - (description "Nextpnr aims to be a vendor neutral, timing driven, -FOSS FPGA place and route tool.") + (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS +FPGA place and route tool.") (home-page "https://github.com/YosysHQ/nextpnr") (license license:expat)))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:46 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:46 +0000 Received: from localhost ([127.0.0.1]:38580 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQs-0006Mb-10 for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:46 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56704) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQq-0006Ly-1s for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:45 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id B2553E8525 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PsBDAu8JBNkz for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 8FA62E8512 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 2/9] gnu: Add qtimgui. Date: Fri, 27 Jan 2023 15:34:27 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/qt.scm (qtimgui): New variable. --- gnu/packages/qt.scm | 63 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 14fc73ef28..d513794484 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -26,6 +26,7 @@ ;;; Copyright © 2022 Foo Chuan Wei ;;; Copyright © 2022 Zhu Zihao ;;; Copyright © 2022 Petr Hodina +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -114,6 +115,7 @@ (define-module (gnu packages qt) #:use-module (gnu packages sqlite) #:use-module (gnu packages telephony) #:use-module (gnu packages tls) + #:use-module (gnu packages toolkits) #:use-module (gnu packages valgrind) #:use-module (gnu packages video) #:use-module (gnu packages vulkan) @@ -3550,6 +3552,67 @@ (define-public python-pyqt+qscintilla (description "This package contains the union of PyQt and the Qscintilla extension."))) +(define-public qtimgui + (let ((commit "48d64a715b75dee24e398f7e5b0942c2ca329334") + (revision "0")) + (package + (name "qtimgui") + (version (git-version "0.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/seanchas116/qtimgui") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0x71j8m15w003ak0d7q346rlwyvklkda9l0dwbxfx6kny3gsl11k")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags #~(list "-DQTIMGUI_BUILD_IMGUI=OFF" + "-DQTIMGUI_BUILD_IMPLOT=OFF") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "CMakeLists.txt" + ;; Disable building the examples. + (("^add_subdirectory\\(examples\\)") "")) + (substitute* "src/CMakeLists.txt" + ;; Build shared libraries, not static. + (("STATIC") "SHARED") + ;; Compile with the system imgui headers. + (("^(target_include_directories.*)\\)" _ prefix) + (string-append prefix + " " + (search-input-directory inputs + "include/imgui") + ")"))))) + (replace 'install + ;; No install target provided; manually copy the header and + ;; library files to the output. + (lambda* (#:key source #:allow-other-keys) + (for-each + (lambda (file-name) + (install-file (string-append source "/src/" file-name) + (string-append #$output "/include/qtimgui"))) + '("ImGuiRenderer.h" "QtImGui.h")) + (for-each + (lambda (file-name) + (install-file (string-append "src/" file-name) + (string-append #$output "/lib"))) + '("libqt_imgui_quick.so" "libqt_imgui_widgets.so"))))) + #:tests? #f)) ; no test suite + (inputs + (list imgui-1.86 implot qtbase-5 qtdeclarative-5)) + (home-page "https://github.com/seanchas116/qtimgui") + (synopsis "Qt backend for the ImGui GUI library") + (description "QtImGui allows the ImGui C++ GUI library to be used by Qt +applications within subclasses of @code{QOpenGLWidget} and +@code{QOpenGLWindow}.") + (license license:expat)))) + (define-public qtkeychain (package (name "qtkeychain") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:47 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:47 +0000 Received: from localhost ([127.0.0.1]:38582 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQs-0006Mo-KN for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:46 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56716) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQq-0006M1-1s for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:45 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 63883E8522 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:38 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id K4a-UkC3NOdt for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 535F2E8352 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 0/9] gnu: nextpnr-ice40: Update to 0.5. Date: Fri, 27 Jan 2023 15:34:25 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Following a comment[0] from ( on another issue, here's a v2 of this patch series that refers to package inputs appropriately using "this-package-input" and "this-package-native-input" instead of by variable name. This affects primarily patches 5 and 8, in references to icestorm and sanitizers-cmake; aside from differences in formatting resulting from these changes, the remaining patches are the same as before. I've re-tested this on AArch64 and everything appears fine. The original cover letter follows below. [0] https://lists.gnu.org/archive/html/guix-patches/2023-01/msg01230.html -- Simon South simon@simonsouth.net Continuing on from issue 60429[0], here's a patch series that aims to improve the package for nextpnr-ice40, a place-and-route tool for Lattice iCE40 FPGAs, by - Adding separate packages for implot, qtimgui and sanitizers-cmake, which are currently bundled with nextpnr; - Updating its source-repository URL to use HTTPS instead of the git protocol (no longer supported by GitHub[1]); - Updating it to the modern style using gexps; - Enabling the test suite; - Fixing the version string shown by "nextpnr-ice40 --version", which should match the output of "git describe --tags --always" at build time but is currently empty; - Removing the bundled software and patching the source to use Guix packages instead; and - Updating nextpnr-ice40 itself to version 0.5. I've tested this on x86-64 (command line and GUI) and AArch64 (command line only) and everything seems fine. Note that as with Yosys, the nextpnr Web page helpfully includes a short example of using the tool[2] for testing its basic functionality. (The "blinky" folder is in the nextpnr source tree.) [0] https://issues.guix.gnu.org/60429 [1] https://github.blog/2021-09-01-improving-git-protocol-security-github/ [2] https://github.com/YosysHQ/nextpnr#getting-started -- Simon South simon@simonsouth.net Simon South (9): gnu: Add implot. gnu: Add qtimgui. gnu: Add sanitizers-cmake. gnu: nextpnr-ice40: Use HTTPS for source URL. gnu: nextpnr-ice40: Use gexps. gnu: nextpnr-ice40: Enable tests. gnu: nextpnr-ice40: Fix generated version string. gnu: nextpnr-ice40: Remove bundled software. gnu: nextpnr-ice40: Update to 0.5. gnu/packages/cmake.scm | 45 +++++++++++++++++ gnu/packages/fpga.scm | 101 +++++++++++++++++++++++++++++++------- gnu/packages/qt.scm | 63 ++++++++++++++++++++++++ gnu/packages/toolkits.scm | 50 +++++++++++++++++++ 4 files changed, 240 insertions(+), 19 deletions(-) base-commit: 8e1cca32b938cef0812ce042c6c2e8bccb326ec7 prerequisite-patch-id: 63e61bd0fe7b4cd3b7f4b15c594172579674e67b prerequisite-patch-id: 14469ab44ea45c68c034574747dcf39f1b0d4c8c prerequisite-patch-id: 22efe5c3a9047003160bc343e7b1e12d813b5fcf prerequisite-patch-id: dfbdd64c8cb4841ee2d6d6e0498f9336de21888b prerequisite-patch-id: 033f40ecd2d1ff437359b411482b9fe57b64baf3 -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:47 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:47 +0000 Received: from localhost ([127.0.0.1]:38584 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQt-0006Mu-1M for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:47 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56714) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQq-0006Lz-2R for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:45 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 9C3E2E8352 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:38 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uAgObhCePlcg for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:38 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 03A3FE8517 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 5/9] gnu: nextpnr-ice40: Use gexps. Date: Fri, 27 Jan 2023 15:34:30 -0500 Message-Id: <474ea48b61450f18d8518e3c4bbbab13e5efe4af.1674850363.git.simon@simonsouth.net> X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[arguments]: Use gexps. --- gnu/packages/fpga.scm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index bf5ce0e516..b710bce553 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -268,11 +268,12 @@ (define-public nextpnr-ice40 yosys)) (build-system cmake-build-system) (arguments - `(#:configure-flags `("-DARCH=ice40" - ,(string-append "-DICEBOX_ROOT=" - (assoc-ref %build-inputs "icestorm") - "/share/icebox")) - #:tests? #f)) + (list #:configure-flags + #~(list "-DARCH=ice40" + (string-append "-DICEBOX_ROOT=" + #$(this-package-input "icestorm") + "/share/icebox")) + #:tests? #f)) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:57 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:57 +0000 Received: from localhost ([127.0.0.1]:38591 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR2-0006Ni-Bc for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:56 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56712) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQq-0006M0-2T for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:46 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 11A2EE8512 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:38 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id shnx5yhdFkH8 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id B2B1EE8515 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 3/9] gnu: Add sanitizers-cmake. Date: Fri, 27 Jan 2023 15:34:28 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/cmake.scm (sanitizers-cmake): New variable. --- gnu/packages/cmake.scm | 45 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index 87fde01f63..f0d25b707d 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2019 Pierre-Moana Levesque ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2021 Ricardo Wurmus +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -32,6 +33,7 @@ (define-module (gnu packages cmake) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix utils) #:use-module (guix deprecation) @@ -422,3 +424,46 @@ (define-public emacs-cmake-mode (description "@code{cmakeos-mode} provides an Emacs major mode for editing Cmake files. It supports syntax highlighting, indenting and refilling of comments."))) + +(define-public sanitizers-cmake + (let ((commit "a6748f4f51273d86312e3d27ebe5277c9b1ff870") + (revision "0")) + (package + (name "sanitizers-cmake") + (version (git-version "0.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/arsenm/sanitizers-cmake") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0shja5qipcsxgj5v6aic9q3dik0cbahllriigwgpayv5ng3ki1ij")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list + ;; Enable the "new" behavior established by CMake policy CMP0077, + ;; which pertains to CMake's "option()" command. This is required + ;; for the package's test suite to complete successfully. + ;; Note this setting may become redundant with future versions of + ;; CMake (past 3.24.2). + "-DCMAKE_POLICY_DEFAULT_CMP0077=NEW") + #:phases + #~(modify-phases %standard-phases + ;; No install target provided; manually copy files to a suitable + ;; folder in the output. + (replace 'install + (lambda* (#:key source #:allow-other-keys) + (copy-recursively + (string-append source "/cmake") + (string-append #$output "/share/" #$name "/cmake"))))))) + (synopsis "CMake module to enable sanitizers for binary targets") + (description "@code{sanitizers-cmake} provides a module for the CMake +build system that can enable address, memory, thread and undefined-behavior +sanitizers for binary targets using flags appropriate for the compiler in +use.") + (home-page "https://github.com/arsenm/sanitizers-cmake") + (license license:expat)))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:57 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:57 +0000 Received: from localhost ([127.0.0.1]:38593 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR3-0006Nk-1B for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:57 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56700) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQq-0006Lx-3o for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:45 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 6ACA5E8521 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hxAr83cfc9S2 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 6CDF4E850F for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 1/9] gnu: Add implot. Date: Fri, 27 Jan 2023 15:34:26 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/toolkits.scm (implot): New variable. --- gnu/packages/toolkits.scm | 50 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/toolkits.scm b/gnu/packages/toolkits.scm index 3030e3aa49..81de853572 100644 --- a/gnu/packages/toolkits.scm +++ b/gnu/packages/toolkits.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2022 Maxim Cournoyer ;;; Copyright © 2020, 2022 Tobias Geerinckx-Rice ;;; Copyright © 2022 John Kehayias +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -141,3 +142,52 @@ (define-public imgui-1.86 (sha256 (base32 "02a7b05zrka20jhzag2jb4jl624i1m456bsv69jb9zgys2p9dv1n")))))) + +(define-public implot + (package + (name "implot") + (version "0.14") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/epezent/implot") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0kp0h5s9dh7380yink5f091ss5cwfj321n6ym87j4skcp0giiym6")))) + (build-system gnu-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (delete 'bootstrap) + (delete 'configure) + (replace 'build + ;; Build a shared library from the source code. + (lambda* (#:key inputs #:allow-other-keys) + (invoke #$(cc-for-target) "-I" (getcwd) + "-I" (search-input-directory inputs "include/imgui") + "-g" "-O2" "-fPIC" "-shared" + "-o" "libimplot.so" + "implot.cpp" + "implot_items.cpp"))) + (replace 'install + ;; Copy the library and header files to the output. + (lambda _ + (install-file "libimplot.so" (string-append #$output "/lib")) + (for-each (lambda (file-name) + (install-file file-name + (string-append #$output + "/include/implot"))) + '("implot.h" "implot_internal.h"))))) + #:tests? #f)) ; no test suite + (inputs + (list imgui)) + (home-page "https://github.com/epezent/implot") + (synopsis "Immediate-mode C++ plotting library for ImGui") + (description "ImPlot is an immediate-mode, GPU-accelerated plotting +library in C++ for the ImGui GUI library, suitable for creating real-time +visualizations or interactive plots. Like ImGui, ImPlot is self-contained and +requires only minimal code to integrate with existing applications.") + (license license:expat))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:57 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:57 +0000 Received: from localhost ([127.0.0.1]:38595 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR3-0006Ns-Eg for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:57 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56864) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQw-0006MJ-5J for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:50 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id A8EE0E8510 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SpCC-K9NGbyD for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:38 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id CD351E8516 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:36 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 4/9] gnu: nextpnr-ice40: Use HTTPS for source URL. Date: Fri, 27 Jan 2023 15:34:29 -0500 Message-Id: <9ec251f971ba053eb336b41fd0471905241d96a5.1674850363.git.simon@simonsouth.net> X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Use HTTPS for URL. --- gnu/packages/fpga.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 45cf0e74cf..bf5ce0e516 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -253,7 +253,7 @@ (define-public nextpnr-ice40 (origin (method git-fetch) (uri (git-reference - (url "git://github.com/YosysHQ/nextpnr") + (url "https://github.com/YosysHQ/nextpnr") (commit commit))) (file-name (git-file-name name version)) (sha256 -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:58 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:58 +0000 Received: from localhost ([127.0.0.1]:38597 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR3-0006Nz-My for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:58 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56866) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQw-0006MI-5I for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:50 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id E6EB0E8513 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id rHtzuVxBD1Rc for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:39 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 1E9E8E8518 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 6/9] gnu: nextpnr-ice40: Enable tests. Date: Fri, 27 Jan 2023 15:34:31 -0500 Message-Id: <1a9d17ed3f7b4493c6dc90603497b83b8f69e125.1674850363.git.simon@simonsouth.net> X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Enable recursive checkout. [arguments]<#:configure-flags>: Add "-DBUILD_TESTS". <#:tests?>: Remove. --- gnu/packages/fpga.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index b710bce553..ae70c5e6ab 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -254,11 +254,12 @@ (define-public nextpnr-ice40 (method git-fetch) (uri (git-reference (url "https://github.com/YosysHQ/nextpnr") - (commit commit))) + (commit commit) + (recursive? #t))) (file-name (git-file-name name version)) (sha256 (base32 - "1fmxsywgs45g88ra7ips5s2niiiwrkyxdcy742ws18dfk2y4vi9c")))) + "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")))) (inputs (list boost eigen @@ -270,10 +271,10 @@ (define-public nextpnr-ice40 (arguments (list #:configure-flags #~(list "-DARCH=ice40" + "-DBUILD_TESTS=ON" (string-append "-DICEBOX_ROOT=" #$(this-package-input "icestorm") - "/share/icebox")) - #:tests? #f)) + "/share/icebox")))) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:58 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:58 +0000 Received: from localhost ([127.0.0.1]:38599 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR4-0006O6-1g for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:58 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56882) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQw-0006MO-DJ for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:51 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 21322E8515 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:41 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jgYTksGVpq8i for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:40 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 391ADE851C for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 7/9] gnu: nextpnr-ice40: Fix generated version string. Date: Fri, 27 Jan 2023 15:34:32 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[arguments]<#:configure-flags>: Add "-DCURRENT_GIT_VERSION". --- gnu/packages/fpga.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index ae70c5e6ab..60a6a143c9 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -272,6 +272,8 @@ (define-public nextpnr-ice40 (list #:configure-flags #~(list "-DARCH=ice40" "-DBUILD_TESTS=ON" + (string-append "-DCURRENT_GIT_VERSION=" + #$(string-take commit 8)) (string-append "-DICEBOX_ROOT=" #$(this-package-input "icestorm") "/share/icebox")))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:34:58 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:34:58 +0000 Received: from localhost ([127.0.0.1]:38601 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVR4-0006OE-Cq for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:58 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56916) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQw-0006MV-Kb for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:51 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id D199FE8517 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:43 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dW_lqgNfgugO for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:43 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 87D5BE850F for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 9/9] gnu: nextpnr-ice40: Update to 0.5. Date: Fri, 27 Jan 2023 15:34:34 -0500 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40): Update to 0.5. [arguments]<#:configure-flags>: Add "-DBUILD_GUI", "-DUSE_IPO"; update "-DCURRENT_GIT_VERSION"; rename "-DICEBOX_ROOT" to "-DICESTORM_INSTALL_PREFIX". --- gnu/packages/fpga.scm | 87 ++++++++++++++++++++++--------------------- 1 file changed, 45 insertions(+), 42 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 912b6cfb77..54a8d9550e 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -247,45 +247,48 @@ (define-public icestorm (license license:isc)))) (define-public nextpnr-ice40 - (let [(commit "fbe486df459909065d6852a7495a212dfd2accef") - (revision "1")] + (let* ((version "0.5") + (tag (string-append "nextpnr-" version))) (package (name "nextpnr-ice40") - (version (git-version "0.0.0" revision commit)) + (version version) (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/YosysHQ/nextpnr") - (commit commit) - (recursive? #t))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")) - (modules '((guix build utils))) - (snippet - #~(begin - ;; Remove bundled source code for which Guix has packages. - ;; Note the bundled copies of json11 and python-console contain - ;; modifications, while QtPropertyBrowser appears to be - ;; abandoned and without an official source. - (with-directory-excursion "3rdparty" - (for-each delete-file-recursively - '("googletest" "imgui" "pybind11" "qtimgui" - "sanitizers-cmake"))) + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/YosysHQ/nextpnr") + (commit tag) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "119iqxxzbxq2qy8x20awf9gr0nf3y1yjmk36adsg89ly3rb9gwzk")) + (modules '((guix build utils))) + (snippet + #~(begin + ;; Remove bundled source code for which Guix has packages. + ;; Note the bundled copies of json11 and python-console contain + ;; modifications, while QtPropertyBrowser appears to be + ;; abandoned and without an official source. + ;; fpga-interchange-schema is used only by the + ;; "fpga_interchange" architecture target, which this package + ;; doesn't build. + (with-directory-excursion "3rdparty" + (for-each delete-file-recursively + '("googletest" "imgui" "pybind11" "qtimgui" + "sanitizers-cmake"))) - ;; Remove references to unbundled code and link against - ;; external libraries instead. - (substitute* "CMakeLists.txt" - (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") - (("^(\\s+target_link_libraries.*)( gtest_main\\))" - _ prefix suffix) - (string-append prefix " gtest" suffix))) - (substitute* "gui/CMakeLists.txt" - (("^\\s+../3rdparty/(qt)?imgui.*") "") - (("^(target_link_libraries.*)\\)" _ prefix) - (string-append prefix " imgui qt_imgui_widgets)"))))))) + ;; Remove references to unbundled code and link against external + ;; libraries instead. + (substitute* "CMakeLists.txt" + (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") + (("^(\\s+target_link_libraries.*)( gtest_main\\))" + _ prefix suffix) + (string-append prefix " gtest" suffix))) + (substitute* "gui/CMakeLists.txt" + (("^\\s+../3rdparty/(qt)?imgui.*") "") + (("^(target_link_libraries.*)\\)" _ prefix) + (string-append prefix " imgui qt_imgui_widgets)"))))))) (native-inputs (list googletest sanitizers-cmake)) (inputs @@ -303,12 +306,12 @@ (define-public nextpnr-ice40 (list #:configure-flags #~(list "-DARCH=ice40" + "-DBUILD_GUI=ON" "-DBUILD_TESTS=ON" - (string-append "-DCURRENT_GIT_VERSION=" - #$(string-take commit 8)) - (string-append "-DICEBOX_ROOT=" - #$(this-package-input "icestorm") - "/share/icebox")) + (string-append "-DCURRENT_GIT_VERSION=" #$tag) + (string-append "-DICESTORM_INSTALL_PREFIX=" + #$(this-package-input "icestorm")) + "-DUSE_IPO=OFF") #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch-source @@ -334,8 +337,8 @@ (define-public nextpnr-ice40 "include/qtimgui") suffix)))))))) (synopsis "Place-and-Route tool for FPGAs") - (description "Nextpnr aims to be a vendor neutral, timing driven, -FOSS FPGA place and route tool.") + (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS +FPGA place and route tool.") (home-page "https://github.com/YosysHQ/nextpnr") (license license:expat)))) -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 27 15:35:16 2023 Received: (at 60695) by debbugs.gnu.org; 27 Jan 2023 20:35:16 +0000 Received: from localhost ([127.0.0.1]:38612 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVRL-0006QF-Tn for submit@debbugs.gnu.org; Fri, 27 Jan 2023 15:35:16 -0500 Received: from mailout.easymail.ca ([64.68.200.34]:56880) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pLVQw-0006MP-DJ for 60695@debbugs.gnu.org; Fri, 27 Jan 2023 15:34:51 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 76BDDE8516 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:41 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo08-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo08-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mzjgbAgrbKs0 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:41 +0000 (UTC) Received: from localhost.localdomain (23-233-96-72.cpe.pppoe.ca [23.233.96.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 6EB73E8524 for <60695@debbugs.gnu.org>; Fri, 27 Jan 2023 20:34:37 +0000 (UTC) From: Simon South To: 60695@debbugs.gnu.org Subject: [PATCH v2 8/9] gnu: nextpnr-ice40: Remove bundled software. Date: Fri, 27 Jan 2023 15:34:33 -0500 Message-Id: <3399249f469cb657463e213a8295c62f81d85780.1674850363.git.simon@simonsouth.net> X-Mailer: git-send-email 2.39.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 60695 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/fpga.scm (nextpnr-ice40)[source]: Add modules, snippet. [native-inputs]: Add googletest, sanitizers-cmake. [inputs]: Add imgui-1.86, pybind11, qtimgui. [arguments]: Add "patch-source" phase; reformat gently. --- gnu/packages/fpga.scm | 74 +++++++++++++++++++++++++++++++++++++------ 1 file changed, 65 insertions(+), 9 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 60a6a143c9..912b6cfb77 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2021 Andrew Miloradovsky ;;; Copyright © 2022 Christian Gelinek ;;; Copyright © 2022 jgart +;;; Copyright © 2023 Simon South ;;; ;;; This file is part of GNU Guix. ;;; @@ -36,10 +37,12 @@ (define-module (gnu packages fpga) #:use-module (gnu packages) #:use-module (gnu packages autotools) #:use-module (gnu packages base) + #:use-module (gnu packages cmake) #:use-module (gnu packages compression) #:use-module (gnu packages elf) #:use-module (gnu packages pkg-config) #:use-module (gnu packages tcl) + #:use-module (gnu packages toolkits) #:use-module (gnu packages readline) #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) @@ -259,24 +262,77 @@ (define-public nextpnr-ice40 (file-name (git-file-name name version)) (sha256 (base32 - "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")))) + "1llkrh8rk1a1xxzx54apbg49ny2jqzzl2rmbkb8188idipq568ws")) + (modules '((guix build utils))) + (snippet + #~(begin + ;; Remove bundled source code for which Guix has packages. + ;; Note the bundled copies of json11 and python-console contain + ;; modifications, while QtPropertyBrowser appears to be + ;; abandoned and without an official source. + (with-directory-excursion "3rdparty" + (for-each delete-file-recursively + '("googletest" "imgui" "pybind11" "qtimgui" + "sanitizers-cmake"))) + + ;; Remove references to unbundled code and link against + ;; external libraries instead. + (substitute* "CMakeLists.txt" + (("^\\s+add_subdirectory\\(3rdparty/googletest.*") "") + (("^(\\s+target_link_libraries.*)( gtest_main\\))" + _ prefix suffix) + (string-append prefix " gtest" suffix))) + (substitute* "gui/CMakeLists.txt" + (("^\\s+../3rdparty/(qt)?imgui.*") "") + (("^(target_link_libraries.*)\\)" _ prefix) + (string-append prefix " imgui qt_imgui_widgets)"))))))) + (native-inputs + (list googletest sanitizers-cmake)) (inputs (list boost eigen icestorm + imgui-1.86 + pybind11 python qtbase-5 + qtimgui yosys)) (build-system cmake-build-system) (arguments - (list #:configure-flags - #~(list "-DARCH=ice40" - "-DBUILD_TESTS=ON" - (string-append "-DCURRENT_GIT_VERSION=" - #$(string-take commit 8)) - (string-append "-DICEBOX_ROOT=" - #$(this-package-input "icestorm") - "/share/icebox")))) + (list + #:configure-flags + #~(list "-DARCH=ice40" + "-DBUILD_TESTS=ON" + (string-append "-DCURRENT_GIT_VERSION=" + #$(string-take commit 8)) + (string-append "-DICEBOX_ROOT=" + #$(this-package-input "icestorm") + "/share/icebox")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "CMakeLists.txt" + ;; Use the system sanitizers-cmake module. + (("\\$\\{CMAKE_SOURCE_DIR\\}/3rdparty/sanitizers-cmake/cmake") + (string-append + #$(this-package-native-input "sanitizers-cmake") + "/share/sanitizers-cmake/cmake"))) + (substitute* "gui/CMakeLists.txt" + ;; Compile with system imgui and qtimgui headers. + (("^(target_include_directories.*)../3rdparty/imgui(.*)$" + _ prefix suffix) + (string-append prefix + (search-input-directory inputs + "include/imgui") + suffix)) + (("^(target_include_directories.*)../3rdparty/qtimgui/(.*)$" + _ prefix suffix) + (string-append prefix + (search-input-directory inputs + "include/qtimgui") + suffix)))))))) (synopsis "Place-and-Route tool for FPGAs") (description "Nextpnr aims to be a vendor neutral, timing driven, FOSS FPGA place and route tool.") -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Sun Dec 22 06:49:24 2024 Received: (at 60695-done) by debbugs.gnu.org; 22 Dec 2024 11:49:24 +0000 Received: from localhost ([127.0.0.1]:49231 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tPKSZ-0007qu-Pq for submit@debbugs.gnu.org; Sun, 22 Dec 2024 06:49:23 -0500 Received: from dd30410.kasserver.com ([85.13.145.193]:51344) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tPKSX-0007ql-Ey for 60695-done@debbugs.gnu.org; Sun, 22 Dec 2024 06:49:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=scratchpost.org; s=kas202409041115; t=1734868160; bh=Sw5BOOtI2ANGMx3LlhyFsOm7RB/5zxJOuEVTRJLI4EE=; h=Subject:To:From:Date:From; b=FEDHhuDZXW1p4Z+LkCv0uT/fYvs39sjZdLwyXG8YhZOvZJzbMmiDI13dBafhT/fyY UxzGvEsb+6b2N3yUfnKQewKORhMNi4NKKnmUINDbWdpX6XHoWAcVsp5xtWpbi79Ino TnIY5l3HP/LUiHUjRIKAPSTD8TCTPNfialo9QgGgjGbNXqDr5X3OoeOQ1Ek4XalJpu QhfcJFURnaEqoNzejnNqEzN7CN2lx0wbgLBnMx/QnIiYRNc9PE4FYPa7iLTZvNaQnJ BD7dIGfyWz7kE9lgiiFhzaJIe40CZawDgeCRTJYf7orSl6KYIMn5FG+jbLRNoWGQjx UiZ72CSkeGjXw== Received: from dd30410.kasserver.com (dd0802.kasserver.com [85.13.143.1]) by dd30410.kasserver.com (Postfix) with ESMTPSA id 2C8971122265 for <60695-done@debbugs.gnu.org>; Sun, 22 Dec 2024 12:49:20 +0100 (CET) Subject: Merged nextpnr-ice40 patchset to guix master To: 60695-done@debbugs.gnu.org From: "Danny Milosavljevic" User-Agent: ALL-INKL Webmail 2.11 X-SenderIP: 213.147.164.14 MIME-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Message-Id: <20241222114920.2C8971122265@dd30410.kasserver.com> Date: Sun, 22 Dec 2024 12:49:20 +0100 (CET) X-Spamd-Bar: ++ X-Spam-Score: -0.6 (/) X-Debbugs-Envelope-To: 60695-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.6 (-)

as commits up to 8c1348e4f2adb1c6cf1ebf05b624322a138c6df5.

Thanks for the patches!

 

From unknown Sun Aug 17 22:03:29 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 19 Jan 2025 12:24:13 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator