From: George Sapkin Date: Mon, 11 May 2026 14:50:26 +0000 (+0200) Subject: libftdi1: add version check override X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=8e2717f6b68d6c2acfcdcd49b6ee868acc88a11a;p=openwrt-packages.git libftdi1: add version check override Add explicit ftdi_eeprom version and a matching version check override. Signed-off-by: George Sapkin --- diff --git a/libs/libftdi1/Makefile b/libs/libftdi1/Makefile index 09688603b..33713c665 100644 --- a/libs/libftdi1/Makefile +++ b/libs/libftdi1/Makefile @@ -1,4 +1,3 @@ -# # Copyright (C) 2014-2017 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. @@ -9,7 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=libftdi1 PKG_VERSION:=1.5 -PKG_RELEASE:=2 +PKG_FTDI_EEPROM_VERSION:=0.17 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://www.intra2net.com/en/developer/libftdi/download/ @@ -35,7 +35,7 @@ endef define Package/libftdi1/description libFTDI - FTDI USB driver with bitbang mode - libFTDI is an open source library to talk to FTDI chips: FT232BM, FT245BM, FT2232C, FT2232H, FT4232H, FT2232D and FT245R, including the popular bitbang mode. + libFTDI is an open source library to talk to FTDI chips: FT232BM, FT245BM, FT2232C, FT2232H, FT4232H, FT2232D and FT245R, including the popular bitbang mode. The library is linked with your program in userspace, no kernel driver required. endef @@ -45,6 +45,7 @@ define Package/ftdi_eeprom DEPENDS:=+confuse +libftdi1 TITLE:=Tool for reading/erasing/flashing FTDI USB chip eeproms URL:=https://www.intra2net.com/en/developer/libftdi/ + VERSION:=$(PKG_FTDI_EEPROM_VERSION)-r$(PKG_RELEASE) endef define Package/ftdi_eeprom/description diff --git a/libs/libftdi1/test-version.sh b/libs/libftdi1/test-version.sh new file mode 100755 index 000000000..9f102a024 --- /dev/null +++ b/libs/libftdi1/test-version.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +# shellckeck shell=busybox + +case "$PKG_NAME" in +ftdi_eeprom) + ftdi_eeprom --version 2>&1 | grep -F "$PKG_VERSION" + ;; + +libftdi1) + exit 0 + ;; + +*) + echo "Untested package: $PKG_NAME" >&2 + exit 1 + ;; +esac