1 from distutils.core import setup
6 sys.stderr.write("Cannot import py2exe")
10 """The p2exe option will create an exe that needs Microsoft Visual C++ 2008 Redistributable Package.
11 python setup.py py2exe
12 You can also build a zip executable with
13 python setup.py bdist --format=zip
18 # If run without args, build executables
19 if len(sys.argv) == 1:
20 sys.argv.append("py2exe")
22 # os.chdir(os.path.dirname(os.path.abspath(sys.argv[0]))) # conflict with wine-py2exe.sh
23 #sys.path.append('./youtube_dl')
30 "dll_excludes": ['w9xpopen.exe']
34 "script":"./youtube_dl/__main__.py",
35 "dest_base": "youtube-dl",
38 init_file = open('./youtube_dl/__init__.py')
41 version = subprocess.checkoutput(["git", "describe", "--abbrev=0", "--tags"])
45 setup(name='youtube-dl',
47 description='Small command-line program to download videos from YouTube.com and other video sites',
48 url='https://github.com/rg3/youtube-dl',
49 packages=['youtube_dl'],
52 options = {"py2exe": options},
57 shutil.rmtree("build")