mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-19 12:11:28 +00:00
stlink: add withGUI option (#124017)
This commit is contained in:
parent
34fb933665
commit
60753cefb7
|
@ -1,4 +1,13 @@
|
||||||
{ lib, stdenv, fetchFromGitHub, cmake, libusb1 }:
|
{ lib
|
||||||
|
, stdenv
|
||||||
|
, fetchFromGitHub
|
||||||
|
, cmake
|
||||||
|
, libusb1
|
||||||
|
, gtk3
|
||||||
|
, pkg-config
|
||||||
|
, wrapGAppsHook
|
||||||
|
, withGUI ? false
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
# The Darwin build of stlink explicitly refers to static libusb.
|
# The Darwin build of stlink explicitly refers to static libusb.
|
||||||
|
@ -18,8 +27,17 @@ in stdenv.mkDerivation rec {
|
||||||
sha256 = "03xypffpbp4imrczbxmq69vgkr7mbp0ps9dk815br5wwlz6vgygl";
|
sha256 = "03xypffpbp4imrczbxmq69vgkr7mbp0ps9dk815br5wwlz6vgygl";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ libusb1' ];
|
buildInputs = [
|
||||||
nativeBuildInputs = [ cmake ];
|
libusb1'
|
||||||
|
] ++ lib.optionals withGUI [
|
||||||
|
gtk3
|
||||||
|
];
|
||||||
|
nativeBuildInputs = [
|
||||||
|
cmake
|
||||||
|
] ++ lib.optionals withGUI [
|
||||||
|
pkg-config
|
||||||
|
wrapGAppsHook
|
||||||
|
];
|
||||||
|
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
"-DSTLINK_MODPROBED_DIR=${placeholder "out"}/etc/modprobe.d"
|
"-DSTLINK_MODPROBED_DIR=${placeholder "out"}/etc/modprobe.d"
|
||||||
|
|
|
@ -18055,6 +18055,7 @@ in
|
||||||
stfl = callPackage ../development/libraries/stfl { };
|
stfl = callPackage ../development/libraries/stfl { };
|
||||||
|
|
||||||
stlink = callPackage ../development/tools/misc/stlink { };
|
stlink = callPackage ../development/tools/misc/stlink { };
|
||||||
|
stlink-gui = callPackage ../development/tools/misc/stlink { withGUI = true; };
|
||||||
|
|
||||||
stegseek = callPackage ../tools/security/stegseek {};
|
stegseek = callPackage ../tools/security/stegseek {};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue