Skip to content
This repository has been archived by the owner on Oct 18, 2019. It is now read-only.

Commit

Permalink
adding distutils build script, with plenty of hacks
Browse files Browse the repository at this point in the history
  • Loading branch information
matt swanson committed Jun 7, 2010
1 parent 6bc719d commit cf15217
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
from distutils.core import setup
import py2exe
import os, sys

def find_file_in_path(filename):
for include_path in sys.path:
file_path = os.path.join(include_path, filename)
if os.path.exists(file_path):
return file_path

dlls = []
path = 'C:\Python26\Lib\site-packages\PyQt4\plugins\imageformats'
for files in os.listdir(path):
f1 = path + files
dlls.append(f1)

setup(name="StackTracker",
version="0.3",
author="Matt Swanson",
author_email="mdswanso@purdue.edu",
url="http://stackapps.com/questions/290/",
license="GNU General Public License (GPL)",
windows=[{"script": "StackTracker.py"}],
data_files = [('img', ['img/st_logo.png',
'img/stackoverflow_logo.svg',
'img/metastackoverflow_logo.svg',
'img/serverfault_logo.svg',
'img/superuser_logo.svg',
]
),
('imageformats', [
find_file_in_path("PyQt4/plugins/imageformats/qsvg4.dll"),
find_file_in_path("PyQt4/plugins/imageformats/qjpeg4.dll"),
find_file_in_path("PyQt4/plugins/imageformats/qico4.dll"),
find_file_in_path("PyQt4/plugins/imageformats/qmng4.dll"),
find_file_in_path("PyQt4/plugins/imageformats/qtiff4.dll"),
find_file_in_path("PyQt4/plugins/imageformats/qgif4.dll"),]
)
],
options={"py2exe": {"skip_archive": True,
"includes": ["sip"],
}
}
)

0 comments on commit cf15217

Please sign in to comment.