setup.py: Add env variable USE_CYTHON for compilation from pyx sources
pyx source files are now used only when USE_CYTHON is set to 1 or the C source files have not yet been pre-compiled. Only efl.eo.c is checked for this so if you cancel an initial build make sure to enable USE_CYTHON when re-starting the build. The pyx sources will now be included in the source tarball.
This commit is contained in:
parent
7f0dba10c7
commit
927320a247
8
INSTALL
8
INSTALL
|
@ -26,7 +26,9 @@
|
|||
-----------------------
|
||||
|
||||
Once EFL is built and installed in your desired destination, proceed with
|
||||
building the wrapper.
|
||||
building the wrapper. If you downloaded a tarball with pre-generated
|
||||
C sources you can proceed to use those, or force distutils to use pyx
|
||||
sources by setting the environment variable USE_CYTHON to 1.
|
||||
|
||||
|
||||
* BUILDING WITH GCC/G++ (Linux, OS X, etc.)
|
||||
|
@ -41,6 +43,10 @@
|
|||
|
||||
python setup.py build -c mingw32
|
||||
|
||||
* FORCING PYX SOURCES FOR BUILD
|
||||
|
||||
env USE_CYTHON=1 python setup.py build
|
||||
|
||||
|
||||
|
||||
3. INSTALLATION:
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
include README INSTALL COPYING COPYING.LESSER AUTHORS changes.html
|
||||
recursive-include efl *.c *.h
|
||||
include README.rst INSTALL COPYING COPYING.LESSER AUTHORS changes.html
|
||||
recursive-include efl *.c *.h *.pyx *.pxi
|
||||
graft include
|
||||
graft tests
|
||||
recursive-exclude tests *.pyc
|
||||
graft examples
|
||||
|
|
6
setup.py
6
setup.py
|
@ -84,7 +84,11 @@ def pkg_config(name, require, min_vers=None):
|
|||
|
||||
|
||||
# use cython or pre-generated c files
|
||||
if os.path.exists(os.path.join(script_path, "efl", "eo", "efl.eo.pyx")):
|
||||
|
||||
if os.getenv("USE_CYTHON") or \
|
||||
not os.path.exists(
|
||||
os.path.join(script_path, "efl", "eo", "efl.eo.c")
|
||||
):
|
||||
|
||||
module_suffix = ".pyx"
|
||||
|
||||
|
|
Loading…
Reference in New Issue