※上記の広告は60日以上更新のないWIKIに表示されています。更新することで広告が下部へ移動します。

#!/usr/bin/env python
# -*- coding: utf-8 -*-
 
from distutils.core import setup
import py2exe
import os
import glob
 
script_file = 'fullscrpyglet.py'
icon_file = 'res/app.ico'
 
# add res/*.*
res_files = []
for fn in os.listdir('res'):
    fn = os.path.join('res', fn)
    if os.path.isfile(fn):
        res_files.append(fn)
 
py2exe_options = {"compressed"   : 1,
                  "optimize"     : 2,
                  "bundle_files" : 2,
#                   "includes": ["ctypes", "logging"],
#                   "packages": ['pyglet'],
#                   "excludes": ["pyglet"],
                  }
 
dll_files = [
             # "avbin.pyo",
             ]
 
setup(
      console=[{"script" : script_file , "icon_resources" : [(1, icon_file)]}],
 
      options={"py2exe": py2exe_options},
 
      # zipfile=None,
 
      data_files=[('res', res_files),
                  ('.', glob.glob('*.dll')),
                  ('.', glob.glob('*.pyd')),
                  ('.', dll_files)],
)