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()
146146 set (DESKTOP OFF )
147147endif ()
148148
149+ # Define the Python executable before including the subprojects
150+ find_program (FIREBASE_PYTHON_EXECUTABLE
151+ NAMES python3 python
152+ REQUIRED
153+ )
154+
149155include (FindPkgConfig)
150156include (android_dependencies)
151157include (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
4545
4646 add_custom_command (
4747 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"
4949 "--output_file=${OUTPUT_AAR} "
5050 "--library_file=$<TARGET_FILE:${LIBRARY_TARGET} >"
5151 "--architecture=${ANDROID_ABI} "
Original file line number Diff line number Diff line change @@ -202,13 +202,13 @@ macro(firebase_swig_add_library name)
202202 OUTPUT ${UNITY_SWIG_CS_FIX_FILE}
203203 DEPENDS ${UNITY_SWIG_CS_GEN_FILE}
204204 COMMAND
205- python
205+ ${FIREBASE_PYTHON_EXECUTABLE}
206206 ${CMAKE_CURRENT_LIST_DIR} /../swig_commenter.py
207207 --input =\"${all_cpp_header_files} \"
208208 --output =\"${UNITY_SWIG_CS_GEN_FILE} \"
209209 --namespace_prefix=\"Firebase\"
210210 COMMAND
211- python
211+ ${FIREBASE_PYTHON_EXECUTABLE}
212212 ${FIREBASE_SWIG_FIX_PY}
213213 --language =csharp
214214 --in_file=\"${UNITY_SWIG_CS_GEN_FILE} \"
@@ -233,7 +233,7 @@ macro(firebase_swig_add_library name)
233233 OUTPUT ${UNITY_SWIG_CPP_FIX_FILE}
234234 DEPENDS ${UNITY_SWIG_CPP_GEN_FILE}
235235 COMMAND
236- python
236+ ${FIREBASE_PYTHON_EXECUTABLE}
237237 ${FIREBASE_SWIG_FIX_PY}
238238 --language =cpp
239239 --in_file=\"${UNITY_SWIG_CPP_GEN_FILE} \"
You can’t perform that action at this time.
0 commit comments