glycin-loaders: Fix cross (#434878)
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
ninja,
|
||||
pkg-config,
|
||||
rustc,
|
||||
rustPlatform,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
@@ -39,6 +40,8 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
finalAttrs.passthru.glycinPathsPatch
|
||||
];
|
||||
|
||||
cargoVendorDir = "vendor";
|
||||
|
||||
nativeBuildInputs = [
|
||||
cargo
|
||||
gettext # for msgfmt
|
||||
@@ -47,6 +50,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
ninja
|
||||
pkg-config
|
||||
rustc
|
||||
rustPlatform.cargoSetupHook
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
@@ -68,6 +72,13 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace loaders/meson.build \
|
||||
--replace-fail "cargo_target_dir / rust_target / loader," "cargo_target_dir / '${stdenv.hostPlatform.rust.cargoShortTarget}' / rust_target / loader,"
|
||||
'';
|
||||
|
||||
env.CARGO_BUILD_TARGET = stdenv.hostPlatform.rust.rustcTargetSpec;
|
||||
|
||||
passthru = {
|
||||
updateScript = gnome.updateScript {
|
||||
attrPath = "glycin-loaders";
|
||||
|
||||
Reference in New Issue
Block a user