buildRustPackage: support custom cargo profiles

This commit is contained in:
André Silva 2023-09-23 19:58:14 +01:00
parent 1ff350f7b8
commit 8674922276
No known key found for this signature in database
GPG Key ID: 7C34FA12A023DC55
4 changed files with 3 additions and 4 deletions

View File

@ -62,7 +62,6 @@
assert cargoVendorDir == null && cargoLock == null
-> !(args ? cargoSha256 && args.cargoSha256 != null) && !(args ? cargoHash && args.cargoHash != null)
-> throw "cargoSha256, cargoHash, cargoVendorDir, or cargoLock must be set";
assert buildType == "release" || buildType == "debug";
let

View File

@ -17,7 +17,7 @@ cargoBuildHook() {
fi
if [ "${cargoBuildType}" != "debug" ]; then
cargoBuildProfileFlag="--${cargoBuildType}"
cargoBuildProfileFlag="--profile ${cargoBuildType}"
fi
if [ -n "${cargoBuildNoDefaultFeatures-}" ]; then

View File

@ -17,7 +17,7 @@ cargoCheckHook() {
fi
if [ "${cargoCheckType}" != "debug" ]; then
cargoCheckProfileFlag="--${cargoCheckType}"
cargoCheckProfileFlag="--profile ${cargoCheckType}"
fi
if [ -n "${cargoCheckNoDefaultFeatures-}" ]; then

View File

@ -17,7 +17,7 @@ cargoNextestHook() {
fi
if [ "${cargoCheckType}" != "debug" ]; then
cargoCheckProfileFlag="--${cargoCheckType}"
cargoCheckProfileFlag="--cargo-profile ${cargoCheckType}"
fi
if [ -n "${cargoCheckNoDefaultFeatures-}" ]; then