We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6c4dee4 commit aba1cdeCopy full SHA for aba1cde
1 file changed
packages/react-native-node-api-cmake/src/android.ts
@@ -4,6 +4,16 @@ import path from "node:path";
4
5
import { AndroidTriplet } from "react-native-node-api-modules";
6
7
+import { isNinjaAvailable } from "./ninja.js";
8
+
9
+function getCmakeGenerator() {
10
+ if (isNinjaAvailable()) {
11
+ return "Ninja";
12
+ } else {
13
+ return "Unix Makefiles";
14
+ }
15
+}
16
17
export const DEFAULT_ANDROID_TRIPLETS = [
18
"aarch64-linux-android",
19
"armv7a-linux-androideabi",
@@ -49,9 +59,8 @@ export function getAndroidConfigureCmakeArgs({
49
59
const architecture = ANDROID_ARCHITECTURES[triplet];
50
60
51
61
return [
52
- // Use the XCode as generator for Apple platforms
53
62
"-G",
54
- "Ninja",
63
+ getCmakeGenerator(),
55
64
"--toolchain",
56
65
toolchainPath,
57
66
"-D",
0 commit comments