示例#1
0
}
manifest = manifest_template % manifest_properties

# Create a list of all files to include along side the executable being built
# in the dist directory tree.  Each element of the data_files list is a tuple
# consisting of a path (relative to dist\) and a list of files in that path.
data_files = []

# Add resource files that need to reside in the same directory as the image.
data_files.append( ('.', [os.path.join(here, 'LICENSE.txt')]) )
data_files.append( ('.', [os.path.join(here, 'README.rst')]) )
data_files.append( ('.', [os.path.join(here, 'bin', 'refl1d_launch.bat')]) )
data_files.append( ('.', [os.path.join(here, 'extra', 'refl1d.ico')]) )

# Add application specific data files from the refl1d\refl1d-data folder.
data_files += bumps.data_files()

# Add data files from the matplotlib\mpl-data folder and its subfolders.
# For matploblib prior to version 0.99 see the examples at the end of the file.
data_files += matplotlib.get_py2exe_datafiles()

# Add data files from the periodictable\xsf folder.
data_files += periodictable.data_files()

# Add example directories and their files.  An empty directory is ignored.
# Note that Inno Setup will determine where these files will be placed such as
# C:\My Documents\... instead of the installation folder.
for path in glob.glob(os.path.join('examples', '*')):
    if os.path.isdir(path):
        for file in glob.glob(os.path.join(path, '*.*')):
            data_files.append( (path, [file]) )
示例#2
0
import refl1d
import bumps
import periodictable

NAME = 'Refl1D'
# Until we figure out why packages=... doesn't work reliably,
# use py2app_main with explicit imports of everything we
# might need.
#SCRIPT = 'py2app_main.py'
SCRIPT = 'bin/refl1d_gui.py'
VERSION = refl1d.__version__
ICON = 'extra/refl1d.icns'
ID = 'Refl1D'
COPYRIGHT = 'This program is public domain'
DATA_FILES = bumps.data_files() + periodictable.data_files()

plist = dict(CFBundleIconFile=ICON,
             CFBundleName=NAME,
             CFBundleShortVersionString=' '.join([NAME, VERSION]),
             CFBundleGetInfoString=NAME,
             CFBundleExecutable=NAME,
             CFBundleIdentifier='gov.nist.ncnr.%s' % ID,
             NSHumanReadableCopyright=COPYRIGHT)

app_data = dict(script=SCRIPT, plist=plist)
py2app_opt = dict(argv_emulation=True,
                  packages=packages,
                  includes=includes,
                  excludes=excludes,
                  iconfile=ICON,
示例#3
0
import refl1d
import bumps
import periodictable

NAME = 'Refl1D'
# Until we figure out why packages=... doesn't work reliably,
# use py2app_main with explicit imports of everything we
# might need.
#SCRIPT = 'py2app_main.py'
SCRIPT = 'bin/refl1d_gui.py'
VERSION = refl1d.__version__
ICON = 'extra/refl1d.icns'
ID = 'Refl1D'
COPYRIGHT = 'This program is public domain'
DATA_FILES = bumps.data_files() + periodictable.data_files()

plist = dict(
    CFBundleIconFile            = ICON,
    CFBundleName                = NAME,
    CFBundleShortVersionString  = ' '.join([NAME, VERSION]),
    CFBundleGetInfoString       = NAME,
    CFBundleExecutable          = NAME,
    CFBundleIdentifier          = 'gov.nist.ncnr.%s' % ID,
    NSHumanReadableCopyright    = COPYRIGHT
)


app_data = dict(script=SCRIPT, plist=plist)
py2app_opt = dict(argv_emulation=True,
                  packages=packages,
示例#4
0
}
manifest = manifest_template % manifest_properties

# Create a list of all files to include along side the executable being built
# in the dist directory tree.  Each element of the data_files list is a tuple
# consisting of a path (relative to dist\) and a list of files in that path.
data_files = []

# Add resource files that need to reside in the same directory as the image.
data_files.append(('.', [os.path.join(here, 'LICENSE.txt')]))
data_files.append(('.', [os.path.join(here, 'README.rst')]))
data_files.append(('.', [os.path.join(here, 'bin', 'refl1d_launch.bat')]))
data_files.append(('.', [os.path.join(here, 'extra', 'refl1d.ico')]))

# Add application specific data files from the refl1d\refl1d-data folder.
data_files += bumps.data_files()

# Add data files from the matplotlib\mpl-data folder and its subfolders.
# For matploblib prior to version 0.99 see the examples at the end of the file.
data_files += matplotlib.get_py2exe_datafiles()

# Add data files from the periodictable\xsf folder.
data_files += periodictable.data_files()

# Add example directories and their files.  An empty directory is ignored.
# Note that Inno Setup will determine where these files will be placed such as
# C:\My Documents\... instead of the installation folder.
for path in glob.glob(os.path.join('examples', '*')):
    if os.path.isdir(path):
        for file in glob.glob(os.path.join(path, '*.*')):
            data_files.append((path, [file]))