Unverified Commit 6de69b29 authored by Matt Sturgeon's avatar Matt Sturgeon Committed by GitHub
Browse files

delfin: fix cross compilation (#437748)

parents 3d44f607 b1914596
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -37,6 +37,12 @@ stdenv.mkDerivation rec {
    hash = "sha256-zZc2+0oskptpWZE4fyVcR4QHxqzpj71GXMXNXMK4an0=";
  };

  postPatch = ''
    substituteInPlace delfin/meson.build --replace-fail \
      "'delfin' / rust_target / meson.project_name()" \
      "'delfin' / '${stdenv.hostPlatform.rust.cargoShortTarget}' / rust_target / meson.project_name()"
  '';

  nativeBuildInputs = [
    appstream
    desktop-file-utils
@@ -62,6 +68,9 @@ stdenv.mkDerivation rec {
    (lib.mesonOption "profile" "release")
  ];

  # For https://codeberg.org/avery42/delfin/src/commit/820b466bfd47f71c12e9b2cabb698e8f78942f41/delfin/meson.build#L47-L48
  env.CARGO_BUILD_TARGET = stdenv.hostPlatform.rust.rustcTargetSpec;

  passthru.updateScript = gitUpdater {
    rev-prefix = "v";
  };