openocd-rp2040: use libgpiod_1 instead of duplicated expressions

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
This commit is contained in:
Otavio Salvador 2023-11-19 23:33:46 -03:00
parent 20414d1a40
commit ca81640aaf

View File

@ -1,7 +1,6 @@
{ lib
, stdenv
, fetchgit
, fetchurl
, pkg-config
, hidapi
, libftdi1
@ -12,7 +11,7 @@
, automake
, texinfo
, git
, libgpiod
, libgpiod_1
}:
stdenv.mkDerivation {
@ -42,13 +41,7 @@ stdenv.mkDerivation {
]
++
# tracking issue for v2 api changes https://sourceforge.net/p/openocd/tickets/306/
lib.optional stdenv.isLinux (libgpiod.overrideAttrs (old: rec {
version = "1.6.4";
src = fetchurl {
url = "https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/snapshot/libgpiod-${version}.tar.gz";
sha256 = "sha256-gp1KwmjfB4U2CdZ8/H9HbpqnNssqaKYwvpno+tGXvgo=";
};
}));
lib.optional stdenv.isLinux libgpiod_1;
configurePhase = ''
SKIP_SUBMODULE=1 ./bootstrap