gnvim: fix install phase with Rust with custom target
This commit is contained in:
parent
f2ed6d87a4
commit
de6283bebf
@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
|
|||||||
|
|
||||||
# The default build script tries to get the version through Git, so we
|
# The default build script tries to get the version through Git, so we
|
||||||
# replace it
|
# replace it
|
||||||
prePatch = ''
|
postPatch = ''
|
||||||
cat << EOF > build.rs
|
cat << EOF > build.rs
|
||||||
use std::env;
|
use std::env;
|
||||||
use std::fs::File;
|
use std::fs::File;
|
||||||
@ -31,13 +31,13 @@ rustPlatform.buildRustPackage rec {
|
|||||||
f.write_all(b"const VERSION: &str = \"${version}\";").unwrap();
|
f.write_all(b"const VERSION: &str = \"${version}\";").unwrap();
|
||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
# Install the binary ourselves, since the Makefile doesn't have the path
|
||||||
|
# containing the target architecture
|
||||||
|
sed -e "/target\/release/d" -i Makefile
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildPhase = ''
|
postInstall = ''
|
||||||
make build
|
|
||||||
'';
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
make install PREFIX="${placeholder "out"}"
|
make install PREFIX="${placeholder "out"}"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user