Skip to content

Commit 9516fcd

Browse files
authored
Use find_program to get python (#1156)
1 parent de396ba commit 9516fcd

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

CMakeLists.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,11 @@ option(FIREBASE_GITHUB_ACTION_BUILD
8686
option(FIREBASE_QUICK_TEST
8787
"Enable quick tests will skip tests which requires access to the SECRET" OFF)
8888

89-
set(FIREBASE_PYTHON_EXECUTABLE "python" CACHE FILEPATH
90-
"The Python interpreter to use, such as one from a venv")
89+
find_program(FIREBASE_PYTHON_EXECUTABLE
90+
NAMES python3 python
91+
DOC "The Python interpreter to use, such as one from a venv"
92+
REQUIRED
93+
)
9194

9295
set(FIREBASE_XCODE_TARGET_FORMAT "frameworks" CACHE STRING
9396
"Format to output, 'frameworks' or 'libraries'")

0 commit comments

Comments
 (0)