Skip to content

Commit

Permalink
Merge pull request #222 from thinking-tower/bugfix/python-installatio…
Browse files Browse the repository at this point in the history
…n-on-macos

Set PYTHON_INCLUDE_DIR and PYTHON_LIBRARY during installation
  • Loading branch information
axsaucedo authored May 27, 2021
2 parents a3d8b78 + dc9b3f4 commit dccbe4a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import os
import re
import sys
import platform
import sys
import sysconfig
import subprocess

from setuptools import setup, Extension
Expand Down Expand Up @@ -43,7 +44,10 @@ def build_extension(self, ext):
'-DKOMPUTE_OPT_BUILD_PYTHON=1',
'-DKOMPUTE_OPT_ENABLE_SPDLOG=0',
'-DKOMPUTE_OPT_REPO_SUBMODULE_BUILD=1',
'-DPYTHON_EXECUTABLE=' + sys.executable]
'-DPYTHON_EXECUTABLE=' + sys.executable,
'-DPYTHON_INCLUDE_DIR=' + sysconfig.get_path('include'),
'-DPYTHON_LIBRARY=' + sysconfig.get_path('stdlib'),
]

cfg = 'Debug' if self.debug else 'Release'
build_args = ['--config', cfg]
Expand Down

0 comments on commit dccbe4a

Please sign in to comment.