Remove accidental duplication (and overwriting) of definition of args passed to cythonize
This commit is contained in:
parent
df6d718d34
commit
d7caee04b4
20
setup.py
20
setup.py
|
@ -39,26 +39,6 @@ else:
|
|||
).stdout.split()[0][2:]] # get the first argument which is the library path
|
||||
|
||||
|
||||
if platform.system() == 'Windows':
|
||||
compiler_args = ['/std:c++20']
|
||||
compiler_and_linker_args = []
|
||||
if 'NATCAP_INVEST_GDAL_LIB_PATH' not in os.environ:
|
||||
raise RuntimeError(
|
||||
'env variable NATCAP_INVEST_GDAL_LIB_PATH is not defined. '
|
||||
'This env variable is required when building on Windows. If '
|
||||
'using conda to manage your gdal installation, you may set '
|
||||
'NATCAP_INVEST_GDAL_LIB_PATH="$CONDA_PREFIX/Library".')
|
||||
library_dirs = [f'{os.environ["NATCAP_INVEST_GDAL_LIB_PATH"]}/lib']
|
||||
include_dirs.append(f'{os.environ["NATCAP_INVEST_GDAL_LIB_PATH"]}/include')
|
||||
else:
|
||||
compiler_args = [subprocess.run(
|
||||
['gdal-config', '--cflags'], capture_output=True, text=True
|
||||
).stdout.strip()]
|
||||
compiler_and_linker_args = ['-std=c++20']
|
||||
library_dirs = [subprocess.run(
|
||||
['gdal-config', '--libs'], capture_output=True, text=True
|
||||
).stdout.split()[0][2:]] # get the first argument which is the library path
|
||||
|
||||
class build_py(_build_py):
|
||||
"""Command to compile translation message catalogs before building."""
|
||||
|
||||
|
|
Loading…
Reference in New Issue