diff options
| author | IllusionMan1212 <hisham.abourgheba@gmail.com> | 2025-04-04 05:22:04 +0200 |
|---|---|---|
| committer | IllusionMan1212 <hisham.abourgheba@gmail.com> | 2025-04-04 05:22:04 +0200 |
| commit | 7c26024920d3fe684edc66016f71db28e1f7542b (patch) | |
| tree | ddb92e6f132a45996e31314eb5987fa561ebf56c /src/build_settings.cpp | |
| parent | 7d041cb2b8ae54f25086a52da62cecf2db254553 (diff) | |
fix: strip trailing slashes for android keystore and jarsigner paths
The `system()` call on linux was failing to execute the `jarsigner` command because its path had a trailing slash
Diffstat (limited to 'src/build_settings.cpp')
| -rw-r--r-- | src/build_settings.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/build_settings.cpp b/src/build_settings.cpp index 1f5aba254..8339b111a 100644 --- a/src/build_settings.cpp +++ b/src/build_settings.cpp @@ -1574,6 +1574,8 @@ gb_internal void init_android_values(bool with_sdk) { bc->ODIN_ANDROID_JAR_SIGNER = normalize_path(permanent_allocator(), make_string_c(gb_get_env("ODIN_ANDROID_JAR_SIGNER", permanent_allocator())), NIX_SEPARATOR_STRING); + // Strip trailing slash so system() call doesn't fail. + bc->ODIN_ANDROID_JAR_SIGNER = substring(bc->ODIN_ANDROID_JAR_SIGNER, 0, bc->ODIN_ANDROID_JAR_SIGNER.len - 1); if (with_sdk) { if (bc->ODIN_ANDROID_SDK.len == 0) { gb_printf_err("Error: ODIN_ANDROID_SDK not set, which is required for -build-mode:executable for -subtarget:android"); |