summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2024-10-18 19:05:17 +0200
committerFabian Groffen <grobian@gentoo.org>2024-10-18 19:05:17 +0200
commit5ca865f9415a2ed358b125ce2757225e59f0f4b1 (patch)
treecfc02a8899ed4ff6c30bfa30e40d23d308d00796 /sys-apps
parentdev-ruby/rspec-expectations: Stabilize 3.13.3 arm, #941665 (diff)
downloadgentoo-5ca865f9415a2ed358b125ce2757225e59f0f4b1.tar.gz
gentoo-5ca865f9415a2ed358b125ce2757225e59f0f4b1.tar.bz2
gentoo-5ca865f9415a2ed358b125ce2757225e59f0f4b1.zip
sys-apps/flashrom-1.4.0: version bump
Closes: https://bugs.gentoo.org/941759 Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'sys-apps')
-rw-r--r--sys-apps/flashrom/Manifest1
-rw-r--r--sys-apps/flashrom/flashrom-1.4.0.ebuild142
2 files changed, 143 insertions, 0 deletions
diff --git a/sys-apps/flashrom/Manifest b/sys-apps/flashrom/Manifest
index 9814b3053ebe..82a8cc568293 100644
--- a/sys-apps/flashrom/Manifest
+++ b/sys-apps/flashrom/Manifest
@@ -1 +1,2 @@
DIST flashrom-v1.3.0.tar.bz2 489782 BLAKE2B e6d2284d83171b003b434251f060fa44edf32ecfd3d397bd4ba39b74c6a0b5c9d1659b703dd6b632b63aa4bf27d08c8aeece72920199712c6a4ae160b2eb3a8a SHA512 73b6e00bd3bc66c98d4ad53966a65b19d3d92f07d7b210d69e041d6f5788605b9791a9bf7aec0a52e13d19fcb62c4bdaf4bab9f805fc31468393ca313129a77b
+DIST v1.4.0.tar.gz 1223536 BLAKE2B 6ff3a1a8a29187e841009319995028dd7dab0ac6d08587ae8d23b19736ca9fd34fe2378620515a4e21c587862f60131d1b9d593e09d4a06ca3632d215791c106 SHA512 356a0e6d42981f0eff18a9b19ee1df3aed182437737fe01ddbe5757b34a99ffd729b7bfbf0a419df76bf4109fa12975176a7ccaf58b598d60e574150dfc7b7ce
diff --git a/sys-apps/flashrom/flashrom-1.4.0.ebuild b/sys-apps/flashrom/flashrom-1.4.0.ebuild
new file mode 100644
index 000000000000..2a8d993c93fa
--- /dev/null
+++ b/sys-apps/flashrom/flashrom-1.4.0.ebuild
@@ -0,0 +1,142 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit meson
+
+DESCRIPTION="Utility for reading, writing, erasing and verifying flash ROM chips"
+HOMEPAGE="https://www.flashrom.org/"
+SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
+
+# The defaults should match the upstream "default" flags in meson.build
+IUSE_PROGRAMMERS="
+ atahpt
+ atapromise
+ +atavia
+ +buspirate-spi
+ +ch341a-spi
+ +dediprog
+ +developerbox-spi
+ +digilent-spi
+ +dirtyjtag-spi
+ +drkaiser
+ +dummy
+ +ft2232-spi
+ +gfxnvidia
+ +internal
+ +it8212
+ jlink-spi
+ +linux-mtd
+ +linux-spi
+ mediatek-i2c-spi
+ mstarddc-spi
+ +nic3com
+ +nicintel
+ +nicintel-eeprom
+ +nicintel-spi
+ nicnatsemi
+ +nicrealtek
+ +ogp-spi
+ parade-lspcon
+ +pickit2-spi
+ +pony-spi
+ +raiden-debug-spi
+ +rayer-spi
+ realtek-mst-i2c-spi
+ +satamv
+ +satasii
+ +serprog
+ +stlinkv3-spi
+ +usbblaster-spi"
+IUSE="${IUSE_PROGRAMMERS} +internal-dmi test tools"
+
+RESTRICT="!test? ( test )"
+
+COMMON="atahpt? ( sys-apps/pciutils )
+ atapromise? ( sys-apps/pciutils )
+ atavia? ( sys-apps/pciutils )
+ ch341a-spi? ( virtual/libusb:1 )
+ dediprog? ( virtual/libusb:1 )
+ developerbox-spi? ( virtual/libusb:1 )
+ digilent-spi? ( virtual/libusb:1 )
+ dirtyjtag-spi? ( virtual/libusb:1 )
+ drkaiser? ( sys-apps/pciutils )
+ ft2232-spi? ( dev-embedded/libftdi:1= )
+ gfxnvidia? ( sys-apps/pciutils )
+ internal? ( sys-apps/pciutils )
+ it8212? ( sys-apps/pciutils )
+ jlink-spi? ( dev-embedded/libjaylink )
+ nic3com? ( sys-apps/pciutils )
+ nicintel? ( sys-apps/pciutils )
+ nicintel-eeprom? ( sys-apps/pciutils )
+ nicintel-spi? ( sys-apps/pciutils )
+ nicnatsemi? ( sys-apps/pciutils )
+ nicrealtek? ( sys-apps/pciutils )
+ ogp-spi? ( sys-apps/pciutils )
+ pickit2-spi? ( virtual/libusb:1 )
+ raiden-debug-spi? ( virtual/libusb:1 )
+ satamv? ( sys-apps/pciutils )
+ satasii? ( sys-apps/pciutils )
+ stlinkv3-spi? ( virtual/libusb:1 )
+ usbblaster-spi? ( dev-embedded/libftdi:1= )"
+RDEPEND="${COMMON}
+ !internal-dmi? ( sys-apps/dmidecode )"
+DEPEND="${COMMON}
+ sys-apps/diffutils
+ linux-mtd? ( sys-kernel/linux-headers )
+ linux-spi? ( sys-kernel/linux-headers )
+ mediatek-i2c-spi? ( sys-kernel/linux-headers )
+ mstarddc-spi? ( sys-kernel/linux-headers )
+ parade-lspcon? ( sys-kernel/linux-headers )
+ realtek-mst-i2c-spi? ( sys-kernel/linux-headers )"
+BDEPEND="test? ( dev-util/cmocka )"
+
+DOCS=( README.rst doc/ )
+
+src_prepare() {
+ default
+ if use elibc_musl ; then
+ # skip failing test #908539
+ sed -i -e 's/-DCONFIG_LINUX_MTD=1/-UCONFIG_LINUX_MTD/' \
+ meson.build || die
+ fi
+
+ # enable warnings
+ sed -i \
+ -e 's:^warning_flags = \[:warning_flags = \[ '"'-Wall'"' \]\nno = \[:' \
+ meson.build || die
+}
+
+src_configure() {
+ local programmers="$(printf '%s,' $(for flag in ${IUSE_PROGRAMMERS//+/}; do usev ${flag}; done))"
+ programmers="${programmers%,}"
+ programmers="${programmers//-/_}"
+ local emesonargs=(
+ -Dclassic_cli="enabled"
+ -Dprogrammer="${programmers}"
+ -Dman-pages="disabled"
+ -Ddocumentation="disabled"
+ $(meson_feature test tests)
+ $(meson_feature tools ich_descriptors_tool)
+ )
+ meson_src_configure
+}
+
+src_install() {
+ meson_src_install
+
+ # Upstream requires libflashrom.a to be present at build time
+ # because the classic CLI executable uses internal symbols from that
+ # library. Therefore, we let it be built but keep it out of the
+ # installed tree.
+ find "${ED}" -name '*.a' -delete || die
+
+ if use tools; then
+ dosbin "${BUILD_DIR}"/util/ich_descriptors_tool/ich_descriptors_tool
+ fi
+}