Skip to content
Snippets Groups Projects
Commit 208ef1d6 authored by Grégoire Kubler's avatar Grégoire Kubler
Browse files

feat : now build_type depends of AIDGE_PYTHON_BUILD_TYPE and set to release by default

parent 3e2ca28c
No related branches found
No related tags found
2 merge requests!212Version 0.3.0,!116feat/release_pip
Pipeline #46193 canceled
...@@ -46,7 +46,12 @@ class CMakeBuild(build_ext): ...@@ -46,7 +46,12 @@ class CMakeBuild(build_ext):
# used to launch setup.py to setup PythonInterp # used to launch setup.py to setup PythonInterp
python_executable = sys.executable python_executable = sys.executable
print(f"python executable :\t{python_executable}") print(f"python executable :\t{python_executable}")
compile_type = "Debug" compile_type = (
"Release"
if "AIDGE_PYTHON_BUILD_TYPE" not in os.environ
else os.environ["AIDGE_PYTHON_BUILD_TYPE"]
)
install_path = ( install_path = (
os.path.join(sys.prefix, "lib", "libAidge") os.path.join(sys.prefix, "lib", "libAidge")
if "AIDGE_INSTALL" not in os.environ if "AIDGE_INSTALL" not in os.environ
...@@ -56,7 +61,7 @@ class CMakeBuild(build_ext): ...@@ -56,7 +61,7 @@ class CMakeBuild(build_ext):
[ [
"cmake", "cmake",
str(cwd), str(cwd),
f"-DPYTHON_EXECUTABLE={sys.executable}", f"-DPYTHON_EXECUTABLE={python_executable}",
"-DTEST=OFF", "-DTEST=OFF",
f"-DCMAKE_INSTALL_PREFIX:PATH={install_path}", f"-DCMAKE_INSTALL_PREFIX:PATH={install_path}",
f"-DCMAKE_BUILD_TYPE={compile_type}", f"-DCMAKE_BUILD_TYPE={compile_type}",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment