[Buildroot] [PATCH 29/29 v2] package/fx2lafw: new package

Yann E. MORIN yann.morin.1998 at free.fr
Wed Apr 9 20:03:44 UTC 2025


fx2lafw (FX2 logic analyser firmware) is a set of firmware files for
FX2- or FX2L-based logic analysers. It is developped by the Sigrok
project.

The latest release, 0.1.7, is more than 5 years old now, and no longer
builds with recent sdcc versions (starting with 4.2.3). The git tree has
fixes for those build failures. Rather than backport the 4 commits of
interest, just use the git tree directly: it contains another unrelated
fix, a few documentation changes, and two new firmwares. Also, given the
git tree has not been touched since early 2024, and given the frequency
of releases before that, don't wait to get those two new firmwares.

fx2lafw bundles fx2lib. Usually, we'd avoid using a bundled version, but
in this case, it is an old version, and anyway fx2lafw can't use a
pre-installed version. The probability that another package would use
fx2lib is extra slim as well; if we eventually get one, the chances it
also bundles its own copy are also relatively high. And finally, fx2lib
runs on a separate microcontroller, not on the target's main CPU, so it
can't be shared to any "real target" package. There is no reason to
expand the efforts to unbundle it.

sigrok.org's IPv6 is unresponsive, and as it is the first one tried when
connecting, this causes a huge delay when fetching; indeed, our git
backend does at least three git-fetch, each timing out after ~135s, for
a total of ~400s, plus the time of download (which is fortunately rather
small for this package). So, force use of IPv4.

Signed-off-by: Yann E. MORIN <yann.morin.1998 at free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
---
 DEVELOPERS                   |  1 +
 package/Config.in            |  1 +
 package/fx2lafw/Config.in    | 11 +++++++++++
 package/fx2lafw/fx2lafw.hash |  5 +++++
 package/fx2lafw/fx2lafw.mk   | 21 +++++++++++++++++++++
 5 files changed, 39 insertions(+)
 create mode 100644 package/fx2lafw/Config.in
 create mode 100644 package/fx2lafw/fx2lafw.hash
 create mode 100644 package/fx2lafw/fx2lafw.mk

diff --git a/DEVELOPERS b/DEVELOPERS
index b4250a5dbf..ccc1f0c61a 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -3439,6 +3439,7 @@ F:	package/gloox/
 F:	package/tpm2-pkcs11/
 
 N:	Yann E. MORIN <yann.morin.1998 at free.fr>
+F:	package/fx2lafw/
 F:	package/sdcc/
 
 N:	Yann E. MORIN <yann.morin at orange.com>
diff --git a/package/Config.in b/package/Config.in
index 28bdae9c1b..9e2e63b144 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -445,6 +445,7 @@ menu "Firmware"
 	source "package/armbian-firmware/Config.in"
 	source "package/b43-firmware/Config.in"
 	source "package/brcmfmac_sdio-firmware-rpi/Config.in"
+	source "package/fx2lafw/Config.in"
 	source "package/linux-firmware/Config.in"
 	source "package/murata-cyw-fw/Config.in"
 	source "package/nxp-bt-wifi-firmware/Config.in"
diff --git a/package/fx2lafw/Config.in b/package/fx2lafw/Config.in
new file mode 100644
index 0000000000..675750d114
--- /dev/null
+++ b/package/fx2lafw/Config.in
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_FX2LAFW
+	bool "fx2lafw"
+	select BR2_PACKAGE_HOST_SDCC
+	select BR2_PACKAGE_HOST_SDCC_DEV_LIB
+	select BR2_PACKAGE_HOST_SDCC_MCS51
+	help
+	  fx2lafw is an open-source firmware for Cypress FX2 chips which
+	  makes them usable as simple logic analyzer and/or oscilloscope
+	  hardware.
+
+	  https://sigrok.org/wiki/Fx2lafw
diff --git a/package/fx2lafw/fx2lafw.hash b/package/fx2lafw/fx2lafw.hash
new file mode 100644
index 0000000000..d5709c0284
--- /dev/null
+++ b/package/fx2lafw/fx2lafw.hash
@@ -0,0 +1,5 @@
+# Locally computed
+sha256  8efa8c555384a463a50a0d8ff12dbe718308132fdcf0db0d45b1cadb0868f52f  fx2lafw-0f2d3242ffb5582e5b9a018ed9ae9812d517a56e-git4.tar.gz
+sha256  5081618178f9a8946720f37b898fb502a06d470092dbeb64041fa988a45aab8c  README
+sha256  ab15fd526bd8dd18a9e77ebc139656bf4d33e97fc7238cd11bf60e2b9b8666c6  COPYING
+sha256  dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551  COPYING.LESSER
diff --git a/package/fx2lafw/fx2lafw.mk b/package/fx2lafw/fx2lafw.mk
new file mode 100644
index 0000000000..0368208d85
--- /dev/null
+++ b/package/fx2lafw/fx2lafw.mk
@@ -0,0 +1,21 @@
+################################################################################
+#
+# fx2lafw
+#
+################################################################################
+
+FX2LAFW_VERSION = 0f2d3242ffb5582e5b9a018ed9ae9812d517a56e
+FX2LAFW_SITE = git://sigrok.org/sigrok-firmware-fx2lafw
+
+# The IPv6 is unresponsive, causing huge delays during download, so force IPv4
+FX2LAFW_DL_OPTS = -4
+
+FX2LAFW_LICENSE = GPL-2.0-or-later, LGPL-2.1-or-later (fx2lib)
+FX2LAFW_LICENSE_FILES = README COPYING COPYING.LESSER
+
+FX2LAFW_DEPENDENCIES = host-sdcc
+
+# Straight our of git tree
+FX2LAFW_AUTORECONF = YES
+
+$(eval $(autotools-package))
-- 
2.47.0



More information about the buildroot mailing list