jamesren | 6b8e806 | 2010-04-21 21:07:12 +0000 | [diff] [blame] | 1 | #!/usr/bin/python |
2 | # | ||||
3 | # Find the GWT installation and print its location to stdout. | ||||
4 | |||||
5 | import os, sys | ||||
6 | |||||
7 | DEFAULT_GWT = '/usr/local/lib/gwt' | ||||
8 | |||||
9 | site_gwt = os.path.abspath(os.path.join( | ||||
10 | os.path.dirname(__file__), '..', '..', 'site-packages', 'gwt')) | ||||
11 | |||||
12 | if os.path.isdir(site_gwt): | ||||
13 | print site_gwt | ||||
14 | sys.exit(0) | ||||
15 | |||||
16 | if not os.path.isdir(DEFAULT_GWT): | ||||
17 | sys.stderr.write('(%s): GWT not installed?\n' % __file__) | ||||
18 | |||||
19 | print DEFAULT_GWT | ||||
20 |