Skip to content

Commit

Permalink
Fix mismatched cargoDeps in nix and update attribute syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
nakoo committed Aug 15, 2024
1 parent bd1cc92 commit 10f35e1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
16 changes: 8 additions & 8 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,20 @@ let
deps = import ./nix/deps.nix { pkgs = pkgs; };
kimeVersion = builtins.readFile ./VERSION;
testArgs = if debug then "" else "--release";
inherit (pkgs) llvmPackages_18 rustPlatform qt5;
in
with pkgs;
llvmPackages_18.stdenv.mkDerivation rec {
llvmPackages_18.stdenv.mkDerivation (finalAttrs: {
name = "kime";
src = ./.;
buildInputs = deps.kimeBuildInputs;
nativeBuildInputs = deps.kimeNativeBuildInputs ++ [ rustPlatform.cargoSetupHook ];
version = kimeVersion;
cargoDeps = rustPlatform.fetchCargoTarball {
inherit src;
#sha256 = "0000000000000000000000000000000000000000000000000000";
sha256 = "sha256-hlTxyaE/300CBGIJtFzIh6CT5PcmmqWt8CN428sr2U8=";
inherit (finalAttrs) src;
#hash = "0000000000000000000000000000000000000000000000000000";
hash = "sha256-2MG6xigiKdvQX8PR457d6AXswTRPRJBPERvZqemjv24=";
};
LIBCLANG_PATH = "${pkgs.llvmPackages_18.libclang.lib}/lib";
LIBCLANG_PATH = "${llvmPackages_18.libclang.lib}/lib";
dontUseCmakeConfigure = true;
dontWrapQtApps = true;
buildPhase = if debug then "bash scripts/build.sh -ad" else "bash scripts/build.sh -ar";
Expand All @@ -30,12 +30,12 @@ llvmPackages_18.stdenv.mkDerivation rec {
KIME_ICON_DIR=share/icons \
KIME_LIB_DIR=lib \
KIME_DOC_DIR=share/doc/kime \
KIME_QT5_DIR=lib/qt-${pkgs.qt5.qtbase.version} \
KIME_QT5_DIR=lib/qt-${qt5.qtbase.version} \
bash scripts/install.sh "$out"
'';
doCheck = true;
checkPhase = ''
cargo test ${testArgs}
'';
}
})

1 change: 1 addition & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Breaking

### Improve
- Fix mismatched cargoDeps in nix and update attribute syntax **[@nakoo]**

## 3.1.1

Expand Down

0 comments on commit 10f35e1

Please sign in to comment.