setup.py: Check that pregenerated files are available when requested
This commit is contained in:
parent
3d31901da7
commit
a575effa6b
8
setup.py
8
setup.py
|
@ -190,7 +190,13 @@ class Test(Command):
|
|||
# === use cython or pre-generated C files ===
|
||||
USE_CYTHON = False
|
||||
if os.getenv("DISABLE_CYTHON") is not None:
|
||||
USE_CYTHON = False
|
||||
if os.path.exists(os.path.join(script_path, "efl/eo/efl.eo.c")):
|
||||
USE_CYTHON = False
|
||||
else:
|
||||
sys.exit(
|
||||
"You have requested to use pregenerated files with DISABLE_CYTHON\n"
|
||||
"but the files are not available!\n"
|
||||
"Unset DISABLE_CYTHON from your build environment and try again.")
|
||||
elif os.getenv("ENABLE_CYTHON") is not None:
|
||||
USE_CYTHON = True
|
||||
elif not os.path.exists(os.path.join(script_path, "efl/eo/efl.eo.c")):
|
||||
|
|
Loading…
Reference in New Issue