def create_executable():
 dist = Distribution()
 name = 'spyder'
 ver = spyder.__version__
 try:
  imp.find_module('PyQt4')
  python_qt = 'pyqt'
 except ImportError:
  python_qt = 'pyside'
 dist.setup(name='Spyder', version=ver, script='spyder/spyder.py', description='Scientific PYthon Development EnviRonment', target_name=('%s.exe' % name), icon=('%s.ico' % name), target_dir=('%s-win32-%s-sa-%s' % (name, python_qt, ver)))
 spyder.add_to_distribution(dist)
 dist.add_modules('matplotlib', 'h5py', 'scipy.io', 'guidata', 'pygments')
 try:
  import guiqwt
  dist.add_modules('guiqwt')
 except ImportError:
  pass
 dist.includes += ['spyder.scientific_startup', 'spyder.widgets.externalshell.sitecustomize']
 dist.excludes += ['sphinx', 'zmq', 'IPython']
 if osp.isfile('Spyderdoc.chm'):
  dist.add_data_file('Spyderdoc.chm')
 dist.add_data_file(osp.join('rope', 'base', 'default_config.py'))
 dist.build('cx_Freeze')

def create_executable ( ) : dist = Distribution ( ) name = 'spyder' ver = spyder . __version__ try : imp . find_module ( 'PyQt4' ) python_qt = 'pyqt' except ImportError : python_qt = 'pyside' dist . setup ( name = 'Spyder' , version = ver , script = 'spyder/spyder.py' , description = 'Scientific PYthon Development EnviRonment' , target_name = ( '%s.exe' % name ) , icon = ( '%s.ico' % name ) , target_dir = ( '%s-win32-%s-sa-%s' % ( name , python_qt , ver ) ) ) spyder . add_to_distribution ( dist ) dist . add_modules ( 'matplotlib' , 'h5py' , 'scipy.io' , 'guidata' , 'pygments' ) try : import guiqwt dist . add_modules ( 'guiqwt' ) except ImportError : pass dist . includes += [ 'spyder.scientific_startup' , 'spyder.widgets.externalshell.sitecustomize' ] dist . excludes += [ 'sphinx' , 'zmq' , 'IPython' ] if osp . isfile ( 'Spyderdoc.chm' ) : dist . add_data_file ( 'Spyderdoc.chm' ) dist . add_data_file ( osp . join ( 'rope' , 'base' , 'default_config.py' ) ) dist . build ( 'cx_Freeze' )
build executable using guidata .