diff --git a/nix/configurations/vanadium.nix b/nix/configurations/vanadium.nix index a8e5589e..cea450f6 100644 --- a/nix/configurations/vanadium.nix +++ b/nix/configurations/vanadium.nix @@ -51,7 +51,6 @@ in ../overlays/nil.nix ../overlays/dix.nix ../overlays/eepy.nix - ../overlays/emoji-picker.nix ../overlays/calibre-no-mime.nix ../overlays/fcitx5-table-extra-taiwanese.nix diff --git a/nix/overlays/emoji-picker.nix b/nix/overlays/emoji-picker.nix deleted file mode 100644 index 0027d423..00000000 --- a/nix/overlays/emoji-picker.nix +++ /dev/null @@ -1,7 +0,0 @@ -let - sources = import ../../npins; -in - final: _: { - # `-rs` to not mask the go one in nixpkgs - emoji-picker-rs = final.callPackage (sources.emoji-picker + "/package.nix") {}; - } diff --git a/nix/packages/by-name/emoji-picker-rs/package.nix b/nix/packages/by-name/emoji-picker-rs/package.nix new file mode 100644 index 00000000..1ed436d6 --- /dev/null +++ b/nix/packages/by-name/emoji-picker-rs/package.nix @@ -0,0 +1,34 @@ +{ + rustPlatform, + python3, + pkg-config, + openssl, + libxcb, + fetchFromGitHub, +}: let + src = fetchFromGitHub { + owner = "leana8959"; + repo = "emoji-picker"; + rev = "353eee703b5d96c28333814d4413f126c86f26c2"; + hash = "sha256-ETZRqyQ5lzYA6NGOXLnxfpwb4qMMC1l7s5XA8H5s9Jw="; + }; + + cargoToml = fromTOML (builtins.readFile (src + "/Cargo.toml")); +in + rustPlatform.buildRustPackage (finalAttrs: { + name = "emoji-picker"; + version = cargoToml.package.version; + inherit src; + + cargoHash = "sha256-rJKFRWaqulnan2jtt0erj5cypSBe0Z5PiNcOXd3HCZs="; + + nativeBuildInputs = [ + python3 + pkg-config + ]; + + buildInputs = [ + openssl.dev + libxcb + ]; + }) diff --git a/npins/sources.json b/npins/sources.json index 2a821038..bd002e5a 100644 --- a/npins/sources.json +++ b/npins/sources.json @@ -62,19 +62,6 @@ "hash": "0rddwwrkbbgcdava542qg1wb3ca9d6g24l9gp4ghp55f04p55p79", "frozen": true }, - "emoji-picker": { - "type": "Git", - "repository": { - "type": "GitHub", - "owner": "leana8959", - "repo": "emoji-picker" - }, - "branch": "master", - "submodules": false, - "revision": "353eee703b5d96c28333814d4413f126c86f26c2", - "url": "https://github.com/leana8959/emoji-picker/archive/353eee703b5d96c28333814d4413f126c86f26c2.tar.gz", - "hash": "177ldizg1h4mndxmj2qclgi1p73yy6wmr3nix003d5rr4jmm2dhi" - }, "fcitx5-table-extra": { "type": "Git", "repository": {