mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-12 03:56:17 +03:00
Merge pull request #194254 from oxalica/pkg/canokey-qemu
This commit is contained in:
commit
6b58d8b8ac
35
pkgs/applications/virtualization/qemu/canokey-qemu.nix
Normal file
35
pkgs/applications/virtualization/qemu/canokey-qemu.nix
Normal file
@ -0,0 +1,35 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
cmake,
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "canokey-qemu";
|
||||
version = "unstable-2022-06-23";
|
||||
rev = "b70af31229f1858089c3366f71b8d771de4a1e84";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "canokeys";
|
||||
repo = "canokey-qemu";
|
||||
inherit rev;
|
||||
fetchSubmodules = true;
|
||||
hash = "sha256-VJb59K/skx+DhoJs5qGUu070hAjQZC2Z6hAMXuX0bMw=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace canokey-core/CMakeLists.txt \
|
||||
--replace "COMMAND git describe --always --tags --long --abbrev=8 --dirty >>" "COMMAND echo '$rev' >>"
|
||||
'';
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/canokeys/canokey-qemu";
|
||||
description = "CanoKey QEMU Virt Card";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ oxalica ];
|
||||
};
|
||||
}
|
@ -26,6 +26,7 @@
|
||||
, smbdSupport ? false, samba
|
||||
, tpmSupport ? true
|
||||
, uringSupport ? stdenv.isLinux, liburing
|
||||
, canokeySupport ? false, canokey-qemu
|
||||
, hostCpuOnly ? false
|
||||
, hostCpuTargets ? (if hostCpuOnly
|
||||
then (lib.optional stdenv.isx86_64 "i386-softmmu"
|
||||
@ -79,7 +80,8 @@ stdenv.mkDerivation rec {
|
||||
++ lib.optionals virglSupport [ virglrenderer ]
|
||||
++ lib.optionals libiscsiSupport [ libiscsi ]
|
||||
++ lib.optionals smbdSupport [ samba ]
|
||||
++ lib.optionals uringSupport [ liburing ];
|
||||
++ lib.optionals uringSupport [ liburing ]
|
||||
++ lib.optionals canokeySupport [ canokey-qemu ];
|
||||
|
||||
dontUseMesonConfigure = true; # meson's configurePhase isn't compatible with qemu build
|
||||
|
||||
@ -161,7 +163,8 @@ stdenv.mkDerivation rec {
|
||||
++ lib.optional tpmSupport "--enable-tpm"
|
||||
++ lib.optional libiscsiSupport "--enable-libiscsi"
|
||||
++ lib.optional smbdSupport "--smbd=${samba}/bin/smbd"
|
||||
++ lib.optional uringSupport "--enable-linux-io-uring";
|
||||
++ lib.optional uringSupport "--enable-linux-io-uring"
|
||||
++ lib.optional canokeySupport "--enable-canokey";
|
||||
|
||||
dontWrapGApps = true;
|
||||
|
||||
|
@ -30868,6 +30868,8 @@ with pkgs;
|
||||
|
||||
qemu-utils = callPackage ../applications/virtualization/qemu/utils.nix {};
|
||||
|
||||
canokey-qemu = callPackage ../applications/virtualization/qemu/canokey-qemu.nix { };
|
||||
|
||||
wrapQemuBinfmtP = callPackage ../applications/virtualization/qemu/binfmt-p-wrapper.nix { };
|
||||
|
||||
qgroundcontrol = libsForQt5.callPackage ../applications/science/robotics/qgroundcontrol { };
|
||||
|
Loading…
Reference in New Issue
Block a user