mirror of
https://github.com/boostorg/python.git
synced 2026-01-22 05:22:45 +00:00
- Added files to create a binary distribution
[SVN r18106]
This commit is contained in:
2
pyste/dist/.cvsignore
vendored
Normal file
2
pyste/dist/.cvsignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*.zip
|
||||
*.pyc
|
||||
29
pyste/dist/create_build.py
vendored
Normal file
29
pyste/dist/create_build.py
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
import os
|
||||
import sys
|
||||
import shutil
|
||||
from zipfile import ZipFile, ZIP_DEFLATED
|
||||
|
||||
def main():
|
||||
# create exe
|
||||
status = os.system('python setup.py py2exe >& build.log')
|
||||
if status != 0:
|
||||
raise RuntimeError, 'Error creating EXE'
|
||||
|
||||
# create distribution
|
||||
import pyste
|
||||
version = pyste.__VERSION__
|
||||
zip = ZipFile('pyste-%s.zip' % version, 'w', ZIP_DEFLATED)
|
||||
# include the base files
|
||||
dist_dir = 'dist/pyste'
|
||||
for basefile in os.listdir(dist_dir):
|
||||
zip.write(os.path.join(dist_dir, basefile), basefile)
|
||||
zip.close()
|
||||
# cleanup
|
||||
os.remove('build.log')
|
||||
shutil.rmtree('build')
|
||||
shutil.rmtree('dist')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
sys.path.append('../src')
|
||||
main()
|
||||
4
pyste/dist/setup.py
vendored
Normal file
4
pyste/dist/setup.py
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
from distutils.core import setup
|
||||
import py2exe
|
||||
|
||||
setup(name='pyste', scripts=['../src/pyste.py'])
|
||||
Reference in New Issue
Block a user