Russell Gallop | b9e15b2 | 2015-04-02 15:01:53 +0000 | [diff] [blame] | 1 | """For use on Windows. Run with: |
| 2 | python.exe setup.py py2exe |
| 3 | """ |
Serge Guelton | b748c0e | 2018-12-18 16:07:37 +0000 | [diff] [blame] | 4 | from __future__ import absolute_import, division, print_function |
Russell Gallop | b9e15b2 | 2015-04-02 15:01:53 +0000 | [diff] [blame] | 5 | from distutils.core import setup |
| 6 | try: |
| 7 | import py2exe |
| 8 | except ImportError: |
| 9 | import platform |
| 10 | import sys |
| 11 | if platform.system() == 'Windows': |
Serge Guelton | c0ebe77 | 2018-12-18 08:36:33 +0000 | [diff] [blame] | 12 | print("Could not find py2exe. Please install then run setup.py py2exe.") |
Russell Gallop | b9e15b2 | 2015-04-02 15:01:53 +0000 | [diff] [blame] | 13 | raise |
| 14 | else: |
Serge Guelton | c0ebe77 | 2018-12-18 08:36:33 +0000 | [diff] [blame] | 15 | print("setup.py only required on Windows.") |
Russell Gallop | b9e15b2 | 2015-04-02 15:01:53 +0000 | [diff] [blame] | 16 | sys.exit(1) |
| 17 | |
| 18 | setup( |
| 19 | console=['check_cfc.py'], |
| 20 | name="Check CFC", |
| 21 | description='Check Compile Flow Consistency' |
| 22 | ) |