[bug#78390,electronics-team,v3] gnu: nextpnr: Add ecp5 architecture.

Message ID 8444c1502c68f285bbe4ae4cd6f355141bb7355a.1749549646.git.csantosb@inventati.org
State New
Headers
Series [bug#78390,electronics-team,v3] gnu: nextpnr: Add ecp5 architecture. |

Commit Message

Cayetano Santos June 10, 2025, 10 a.m. UTC
  Change-Id: Ia4b92f6cd1693b844b35949fdc23369e958e73c1
---

Let's concentrate in ecp5 architecture, as himbaechel support files licensing is not clear at this point.

 gnu/packages/fpga.scm | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)


base-commit: 5fd4df347e04b6cd3ce3fc91900f773a2e4824e3
--
2.49.0
  

Patch

diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm
index c46631c6cd..6bff45c782 100644
--- a/gnu/packages/fpga.scm
+++ b/gnu/packages/fpga.scm
@@ -55,6 +55,7 @@  (define-module (gnu packages fpga)
   #:use-module (gnu packages cmake)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages cpp)
+  #:use-module (gnu packages electronics)
   #:use-module (gnu packages elf)
   #:use-module (gnu packages flex)
   #:use-module (gnu packages freedesktop)
@@ -437,18 +438,20 @@  (define-public nextpnr
      (list
       #:cmake cmake                     ;CMake 3.25 or higher is required.
       #:configure-flags
-      #~(list "-DARCH=generic;ice40"    ;TODO: enable more architectures?
+      #~(list "-DARCH=generic;ice40;ecp5" ;TODO: enable more architectures?
               "-DBUILD_GUI=ON"
               "-DUSE_OPENMP=ON"
               "-DBUILD_TESTS=ON"
               (string-append "-DCURRENT_GIT_VERSION=nextpnr-" #$version)
               (string-append "-DICESTORM_INSTALL_PREFIX="
                              #$(this-package-input "icestorm"))
+              (string-append "-DTRELLIS_INSTALL_PREFIX="
+                             #$(this-package-input "prjtrellis"))
               "-DUSE_IPO=OFF")
       #:phases
       #~(modify-phases %standard-phases
           (add-after 'unpack 'unbundle-sanitizers-cmake
-            (lambda* (#:key inputs #:allow-other-keys)
+            (lambda _
               (substitute* "CMakeLists.txt"
                 ;; Use the system sanitizers-cmake module.  This is made
                 ;; necessary 'sanitizers-cmake' installing a FindPackage
@@ -465,6 +468,7 @@  (define-public nextpnr
            corrosion
            eigen
            icestorm
+           prjtrellis
            pybind11
            python
            qtbase-5