from setuputils import get_environment_option from setuputils import get_cli_option try: from Cython.Distutils.build_ext import new_build_ext as build_ext except ImportError: from setuptools.command.build_ext import build_ext ############################################################################## # - Dependencies include and lib folder setup -------------------------------- install_requires = ['cython'] cuda_home = get_environment_option("CUDA_HOME") clean_artifacts = get_cli_option('clean') single_gpu_build = get_cli_option('--singlegpu') if not cuda_home: cuda_home = ( os.popen('echo "$(dirname $(dirname $(which nvcc)))"').read().strip()) print("-- Using nvcc to detect CUDA, found at " + str(cuda_home)) cuda_include_dir = os.path.join(cuda_home, "include") cuda_lib_dir = os.path.join(cuda_home, "lib64") ############################################################################## # - Clean target ------------------------------------------------------------- if clean_artifacts: print("-- Cleaning all Python and Cython build artifacts...")
from setuputils import get_cli_option from setuputils import use_raft_package import versioneer from cython_build_ext import cython_build_ext install_requires = ['numba', 'cython'] ############################################################################## # - Print of build options used by setup.py -------------------------------- cuda_home = get_environment_option("CUDA_HOME") libcuml_path = get_environment_option('CUML_BUILD_PATH') raft_path = get_environment_option('RAFT_PATH') clean_artifacts = get_cli_option('clean') ############################################################################## # - Dependencies include and lib folder setup -------------------------------- if not cuda_home: nvcc_path = shutil.which('nvcc') if (not nvcc_path): raise FileNotFoundError("nvcc not found.") cuda_home = str(Path(nvcc_path).parent.parent) print("-- Using nvcc to detect CUDA, found at " + str(cuda_home)) cuda_include_dir = os.path.join(cuda_home, "include") cuda_lib_dir = os.path.join(cuda_home, "lib64")