annotate setup.py @ 103:257de12e58c4

Added windows build support to setup.py.
author Atul Varma <varmaa@toolness.com>
date Sat, 15 Aug 2009 17:38:03 -0700
parents e455f0f00e98
children 9d4cd0803df5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
25
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
1 #! /usr/bin/env python
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
2
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
3 import os
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
4 import sys
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
5
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
6 if __name__ == '__main__':
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
7 # This code is run if we're executed directly from the command-line.
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
8
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
9 myfile = os.path.abspath(__file__)
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
10 mydir = os.path.dirname(myfile)
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
11 sys.path.insert(0, os.path.join(mydir, 'python-modules'))
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
12
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
13 args = sys.argv[1:]
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
14 if not args:
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
15 args = ['help']
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
16
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
17 # Have paver run this very file as its pavement script.
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
18 args = ['-f', myfile] + args
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
19
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
20 import paver.tasks
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
21 paver.tasks.main(args)
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
22 sys.exit(0)
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
23
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
24 # This code is run if we're executed as a pavement script by paver.
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
25
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
26 import os
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
27 import subprocess
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
28 import shutil
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
29 import sys
49
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
30 import webbrowser
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
31 import urllib
25
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
32
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
33 from paver.easy import *
101
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
34 from paver.setuputils import setup
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
35 from distutils.core import Extension
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
36
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
37 SOURCE_FILES = ['pymonkey.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
38 'utils.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
39 'object.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
40 'function.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
41 'undefined.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
42 'context.cpp',
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
43 'runtime.cpp']
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
44
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
45 SPIDERMONKEY_DIR = os.path.abspath(os.path.join('spidermonkey', 'obj'))
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
46
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
47 if not os.path.exists(SPIDERMONKEY_DIR):
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
48 print('WARNING: Spidermonkey objdir not found at %s.' % SPIDERMONKEY_DIR)
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
49 print('Some build tasks may not run properly.\n')
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
50
103
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
51 setup_options = dict(
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
52 name='pymonkey',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
53 version='0.0.1',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
54 description='Access SpiderMonkey from Python',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
55 author='Atul Varma',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
56 author_email='atul@mozilla.com',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
57 url='http://www.toolness.com'
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
58 )
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
59
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
60 ext_options = dict(
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
61 include_dirs = [os.path.join(SPIDERMONKEY_DIR, 'dist', 'include')],
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
62 library_dirs = [SPIDERMONKEY_DIR]
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
63 )
101
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
64
103
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
65 if sys.platform == 'win32':
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
66 # MSVC can't find the js_static.lib SpiderMonkey library, even though
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
67 # it exists and distutils is trying to tell it to link to it, so
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
68 # we'll just link to the DLL on Windows platforms and install
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
69 # it in a place where Windows can find it at runtime.
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
70 ext_options['libraries'] = ['js3250']
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
71 ext_options['define_macros'] = [('XP_WIN', 1)]
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
72 # TODO: This is almost certainly not the ideal way to distribute
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
73 # a DLL used by a C extension module.
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
74 setup_options['data_files'] = [
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
75 ('Lib\\site-packages', [os.path.join(SPIDERMONKEY_DIR,
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
76 'js3250.dll')])
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
77 ]
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
78 else:
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
79 ext_options['libraries'] = ['js_static']
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
80
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
81 setup_options['ext_modules'] = [Extension('pymonkey',
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
82 SOURCE_FILES,
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
83 **ext_options)]
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
84
257de12e58c4 Added windows build support to setup.py.
Atul Varma <varmaa@toolness.com>
parents: 102
diff changeset
85 setup(**setup_options)
25
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
86
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
87 @task
49
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
88 def docs(options):
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
89 """Open the Pymonkey documentation in your web browser."""
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
90
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
91 url = os.path.abspath(os.path.join("docs", "rendered", "index.html"))
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
92 url = urllib.pathname2url(url)
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
93 webbrowser.open(url)
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
94
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
95 @task
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
96 def build_docs(options):
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
97 """Build the Pymonkey documentation (requires Sphinx)."""
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
98
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
99 retval = subprocess.call(["sphinx-build",
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
100 "-b", "html",
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
101 os.path.join("docs", "src"),
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
102 os.path.join("docs", "rendered")])
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
103 if retval:
51
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
104 sys.exit(retval)
49
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
105
7401af070bb8 Moved README to Sphinx documentation. Keeping the rendered docs in the repository so that they can be viewed via HG and locally by people who don't have Sphinx installed.
Atul Varma <varmaa@toolness.com>
parents: 37
diff changeset
106 @task
101
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
107 def test(options):
ca94f99ad55d Merged setup.py into manage.py.
Atul Varma <varmaa@toolness.com>
parents: 96
diff changeset
108 """Test the Pymonkey Python C extension."""
25
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
109
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
110 print "Running test suite."
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
111
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
112 new_env = {}
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
113 new_env.update(os.environ)
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
114
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
115 result = subprocess.call(
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
116 [sys.executable,
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
117 "test_pymonkey.py"],
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
118 env = new_env
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
119 )
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
120
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
121 if result:
3c2151124cee Converted pavement.py to manage.py and added a README.
Atul Varma <varmaa@toolness.com>
parents:
diff changeset
122 sys.exit(result)
51
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
123
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
124 print "Running doctests."
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
125
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
126 # We have to add our current directory to the python path so that
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
127 # our doctests can find the pymonkey module.
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
128 new_env['PYTHONPATH'] = os.path.abspath('.')
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
129 retval = subprocess.call(["sphinx-build",
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
130 "-b", "doctest",
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
131 os.path.join("docs", "src"),
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
132 "_doctest_output"],
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
133 env = new_env)
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
134 if retval:
fabd3f2271fa Added some basic, incomplete docs on the pymonkey module, which include a doctest that's run when pymonkey is built.
Atul Varma <varmaa@toolness.com>
parents: 49
diff changeset
135 sys.exit(retval)