LLNL / ygm

Other
31 stars 22 forks source link

Find pyarrow module automatically for Arrow and Parquet #241

Closed KIwabuchi closed 3 months ago

KIwabuchi commented 3 months ago

This PR adds an additional way to find Arrow and Parquet (described as step 3 below). Here is how Arrow and Parquet are searched once this PR is merged:

  1. If PIP_PYARROW_ROOT is set, try to find Arrow and Parquet installed along with pyarrow by PIP

  2. If Arrow or Parquet is not found, try to find Arrow and Parquet using CMake's find_package()

  3. If Arrow or Parquet is not found still:

    1. Try to find a Python 3 interpreter on the system using CMake's FindPython3 module.

    2. If Python 3 interpreter is found, try to find a pyarrow module by executing a Python 3 script.

    3. If the pyarrow module is found, assign its location to PIP_PYARROW_ROOT (assuming the pyarrow module is installed by PIP) and execute step 1 again.

KIwabuchi commented 3 months ago

@rogerpearce @steiltre This PR is ready for review.

KIwabuchi commented 3 months ago

Close this PR as more features were added and need to create a new PR.