Skip to content

Commit

Permalink
Added conditional verification to python executable.
Browse files Browse the repository at this point in the history
Summary:
Added conditional verification to python executable to search for python instead of python3 on Windows.

This code without this modification is searching for python as python3.exe in Windows, but in the OS, python is installed as python.exe, what cause an incorrect python not found.

Issue: facebook/proxygen#499

X-link: facebook/proxygen#500

Reviewed By: kvtsoy

Differential Revision: D62987053

Pulled By: afrind

fbshipit-source-id: fb21d711483b350d0b86b481cf876c95b82334e0
  • Loading branch information
bmarques1995 authored and facebook-github-bot committed Sep 18, 2024
1 parent 24b346d commit 3988dee
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion third-party/proxygen/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,12 @@ set(PROXYGEN_GENERATED_ROOT ${CMAKE_CURRENT_BINARY_DIR}/generated)
file(MAKE_DIRECTORY ${PROXYGEN_GENERATED_ROOT})

# Build-time program requirements.
find_program(PROXYGEN_PYTHON python3)
if(WIN32)
find_program(PROXYGEN_PYTHON python)
else()
find_program(PROXYGEN_PYTHON python3)
endif()

if(NOT PROXYGEN_PYTHON)
message(FATAL_ERROR "python is required for the proxygen build")
endif()
Expand Down

0 comments on commit 3988dee

Please sign in to comment.