<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - honor Python2_EXECUTABLE and Python3_EXECUTABLE when they are passed to cmake"
   href="https://bugs.llvm.org/show_bug.cgi?id=48180">48180</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>honor Python2_EXECUTABLE and Python3_EXECUTABLE when they are passed to cmake
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>compiler-rt
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>11.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>compiler-rt
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>rr.underwood94@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>CMake's find_package(Python3) and find_package(Python2) packages have a
PYTHON_EXECUTABLE, Python2_EXECUTABLE, and Python3_EXECUTABLE cmake variables
which control which version of python is built against.  As far as I can tell,
the rest of LLVM honors these variables. This can cause the build process to
fail when  if the automatically selected version of Python can't run due to
modifications of LD_LIBRARY_PATH when using spack.  The corresponding Spack
issue is <a href="https://github.com/spack/spack/issues/19908">https://github.com/spack/spack/issues/19908</a>

I believe an appropriate fix is to add the variables to the list of
PASSTHROUGH_VARIABLES in cmake/Modules/AddCompilerRT.cmake, and this fix worked
for me.

This bug affects distributions like Gentoo and package managers like Spack
which allow for combinatorial versioning.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>