Merge pull request #281437 from bmanuel/kanata_darwin
kanata: add support for darwin platforms
This commit is contained in:
commit
a23739720f
2 changed files with 18 additions and 3 deletions
|
@ -2553,6 +2553,12 @@
|
|||
githubId = 52386117;
|
||||
name = "Blusk";
|
||||
};
|
||||
bmanuel = {
|
||||
name = "Benjamin Manuel";
|
||||
email = "ben@benmanuel.com";
|
||||
github = "bmanuel";
|
||||
githubId = 3662307;
|
||||
};
|
||||
bmilanov = {
|
||||
name = "Biser Milanov";
|
||||
email = "bmilanov11+nixpkgs@gmail.com";
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
{ lib
|
||||
{ stdenv
|
||||
, lib
|
||||
, darwin
|
||||
, rustPlatform
|
||||
, fetchFromGitHub
|
||||
, withCmd ? false
|
||||
|
@ -17,8 +19,15 @@ rustPlatform.buildRustPackage rec {
|
|||
|
||||
cargoHash = "sha256-IzgVF6SHJjOB48VehQ5taD5iWQXFKLcVBWTEl3ArkGQ=";
|
||||
|
||||
buildInputs = lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.IOKit ];
|
||||
|
||||
buildFeatures = lib.optional withCmd "cmd";
|
||||
|
||||
# Workaround for https://github.com/nixos/nixpkgs/issues/166205
|
||||
env = lib.optionalAttrs stdenv.cc.isClang {
|
||||
NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}";
|
||||
};
|
||||
|
||||
postInstall = ''
|
||||
install -Dm 444 assets/kanata-icon.svg $out/share/icons/hicolor/scalable/apps/kanata.svg
|
||||
'';
|
||||
|
@ -27,8 +36,8 @@ rustPlatform.buildRustPackage rec {
|
|||
description = "A tool to improve keyboard comfort and usability with advanced customization";
|
||||
homepage = "https://github.com/jtroo/kanata";
|
||||
license = licenses.lgpl3Only;
|
||||
maintainers = with maintainers; [ linj ];
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ bmanuel linj ];
|
||||
platforms = platforms.unix;
|
||||
mainProgram = "kanata";
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue