File tree Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -146,6 +146,12 @@ else()
146
146
set (DESKTOP OFF )
147
147
endif ()
148
148
149
+ # Define the Python executable before including the subprojects
150
+ find_program (FIREBASE_PYTHON_EXECUTABLE
151
+ NAMES python3 python
152
+ REQUIRED
153
+ )
154
+
149
155
include (FindPkgConfig )
150
156
include (android_dependencies )
151
157
include (build_universal )
Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ function(build_aar LIBRARY_NAME LIBRARY_TARGET PROGUARD_TARGET
45
45
46
46
add_custom_command (
47
47
OUTPUT "${OUTPUT_AAR} "
48
- COMMAND python "${FIREBASE_SOURCE_DIR} /aar_builder/build_aar.py"
48
+ COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${FIREBASE_SOURCE_DIR} /aar_builder/build_aar.py"
49
49
"--output_file=${OUTPUT_AAR} "
50
50
"--library_file=$<TARGET_FILE:${LIBRARY_TARGET} >"
51
51
"--architecture=${ANDROID_ABI} "
Original file line number Diff line number Diff line change @@ -202,13 +202,13 @@ macro(firebase_swig_add_library name)
202
202
OUTPUT ${UNITY_SWIG_CS_FIX_FILE}
203
203
DEPENDS ${UNITY_SWIG_CS_GEN_FILE}
204
204
COMMAND
205
- python
205
+ ${FIREBASE_PYTHON_EXECUTABLE}
206
206
${CMAKE_CURRENT_LIST_DIR} /../swig_commenter.py
207
207
--input=\" ${all_cpp_header_files} \"
208
208
--output=\" ${UNITY_SWIG_CS_GEN_FILE} \"
209
209
--namespace_prefix=\" Firebase\"
210
210
COMMAND
211
- python
211
+ ${FIREBASE_PYTHON_EXECUTABLE}
212
212
${FIREBASE_SWIG_FIX_PY}
213
213
--language=csharp
214
214
--in_file=\" ${UNITY_SWIG_CS_GEN_FILE} \"
@@ -233,7 +233,7 @@ macro(firebase_swig_add_library name)
233
233
OUTPUT ${UNITY_SWIG_CPP_FIX_FILE}
234
234
DEPENDS ${UNITY_SWIG_CPP_GEN_FILE}
235
235
COMMAND
236
- python
236
+ ${FIREBASE_PYTHON_EXECUTABLE}
237
237
${FIREBASE_SWIG_FIX_PY}
238
238
--language=cpp
239
239
--in_file=\" ${UNITY_SWIG_CPP_GEN_FILE} \"
You can’t perform that action at this time.
0 commit comments