The code.ill.fr has been recreated and upgraded with the latest version this weekend, If you encounter any problem please inform the Helpdesk.

build.py 1.28 KB
Newer Older
1
# coding=utf-8
2

3
import os
4
5
import sys

6
7
8
if sys.platform.startswith('darwin'):
    from setuptools import setup

Jamie Hall's avatar
Jamie Hall committed
9
    version = os.environ['VERSION_NAME']
eric pellegrini's avatar
eric pellegrini committed
10
    project_dir = os.environ['CI_PROJECT_DIR']
11

eric pellegrini's avatar
eric pellegrini committed
12
    APP = [os.path.join(project_dir,'Scripts','mdanse_gui')]
13

14
15
    PLIST = {
        u'CFBundleName': u'MDANSE',
16
        u'CFBundleShortVersionString': version,
17
        u'CFBundleVersion': version,
18
        u'CFBundleIdentifier': u'eu.ill.MDANSE-'+version,
19
        u'LSApplicationCategoryType': u'public.app-category.science'
20
21
    }
    OPTIONS = {
22
        'argv_emulation': False,# has to be False otherwise triggers problems with wxPython which lose some events that are captured by OS
eric pellegrini's avatar
eric pellegrini committed
23
        'iconfile': os.path.join(project_dir,'MDANSE','GUI','Icons','mdanse.icns'),
24
25
        'excludes': 'PyQt4',
		'matplotlib_backends': '-',
26
        'optimize': '1',
27
        'plist': PLIST,
eric pellegrini's avatar
eric pellegrini committed
28
29
        'bdist_base': os.environ['CI_TEMP_BUILD_DIR'],
        'dist_dir': os.path.join(os.environ['CI_TEMP_DIR'],'dist'),
30
        'graph': False,
31
        'xref': False,
32
        'packages' : ["MDANSE","MMTK","Scientific","matplotlib"]
33
34
35
    }

    setup(
36
        name='MDANSE',
37
38
39
40
41
        app=APP,
        options={'py2app': OPTIONS},
        setup_requires=['py2app']
    )
else:
42
    print 'No build_app implementation for your system.'