Define GLEW_BUILD on windows.

This commit is contained in:
Matthew Einhorn 2015-03-18 12:45:18 -04:00
parent 77232ebd47
commit a8bea76a89
1 changed files with 9 additions and 7 deletions

View File

@ -119,7 +119,7 @@ for key in list(c_options.keys()):
# on python-for-android and kivy-ios, cython usage is external
cython_unsupported_append = '''
Please note that the following versions of Cython are not supported
at all: {}
'''.format(', '.join(map(str, CYTHON_UNSUPPORTED)))
@ -127,11 +127,11 @@ cython_unsupported_append = '''
cython_min = '''\
This version of Cython is not compatible with Kivy. Please upgrade to
at least version {0}, preferably the newest supported version {1}.
If your platform provides a Cython package, make sure you have upgraded
to the newest version. If the newest version available is still too low,
please remove it and install the newest supported Cython via pip:
pip install -I Cython=={1}{2}\
'''.format(MIN_CYTHON_STRING, MAX_CYTHON_STRING,
cython_unsupported_append if CYTHON_UNSUPPORTED else '')
@ -142,11 +142,11 @@ cython_max = '''\
you do have issues, please downgrade to a supported version. It is
best to use the newest supported version, {1}, but the minimum
supported version is {0}.
If your platform provides a Cython package, check if you can downgrade
to a supported version. Otherwise, uninstall the platform package and
install Cython via pip:
pip install -I Cython=={1}{2}\
'''.format(MIN_CYTHON_STRING, MAX_CYTHON_STRING,
cython_unsupported_append if CYTHON_UNSUPPORTED else '')
@ -155,11 +155,11 @@ cython_unsupported = '''\
This version of Cython suffers from known bugs and is unsupported.
Please install the newest supported version, {1}, if possible, but
the minimum supported version is {0}.
If your platform provides a Cython package, check if you can install
a supported version. Otherwise, uninstall the platform package and
install Cython via pip:
pip install -I Cython=={1}{2}\
'''.format(MIN_CYTHON_STRING, MAX_CYTHON_STRING,
cython_unsupported_append)
@ -238,6 +238,8 @@ class KivyBuildExt(build_ext):
config_py += '{0} = {1}\n'.format(opt, value)
debug = bool(self.debug)
print(' * debug = {0}'.format(debug))
config_h += \
'#if __USE_GLEW && defined(_WIN32)\n# define GLEW_BUILD\n#endif'
config_pxi += 'DEF DEBUG = {0}\n'.format(debug)
config_py += 'DEBUG = {0}\n'.format(debug)