|
68
|
1 |
import platform |
|
|
2 |
|
|
|
3 |
from lib_create_env import lib_generate_install_methods, install_pylucene, install_psycopg2 |
|
|
4 |
|
|
|
5 |
system_str = platform.system() |
|
|
6 |
|
|
|
7 |
|
|
|
8 |
if system_str == 'Linux': |
|
|
9 |
INSTALLS = [ |
|
|
10 |
('DISTRIBUTE', 'pip', None, None), |
|
|
11 |
] |
|
|
12 |
else: |
|
|
13 |
INSTALLS = [] |
|
|
14 |
|
|
|
15 |
|
|
|
16 |
INSTALLS.extend([ #(key,method, option_str, dict_extra_env) |
|
|
17 |
('SETUPTOOLS-HG', 'pip', None, None), |
|
|
18 |
('MYSQL', 'pip', None, None), |
|
|
19 |
('PIL', 'easy_install', None, None), |
|
|
20 |
('DJANGO','pip', None, None), |
|
|
21 |
('DJANGO-EXTENSIONS', 'pip', None, None), |
|
|
22 |
('DJANGO-REGISTRATION', 'easy_install', '-Z', None), |
|
|
23 |
('DJANGO-TAGGING', 'pip', None, None), |
|
|
24 |
('DJANGO-PISTON', 'pip', None, None), |
|
|
25 |
('HTTPLIB2', 'pip', None, None), |
|
|
26 |
('OAUTH2', 'easy_install', None, None), |
|
|
27 |
('DJANGO-OAUTH-PLUS', 'pip', None, None), |
|
70
|
28 |
('OPENID', 'pip', None, None), |
|
|
29 |
('DJANGO_OPENID_CONSUMER', 'pip', None, None), |
|
|
30 |
('SOCIAL_AUTH', 'easy_install', None, None), |
|
68
|
31 |
('PHOTOLOGUE', 'pip', None, None), |
|
|
32 |
('MODELTRANSLATION', 'pip', None, None), |
|
|
33 |
]) |
|
|
34 |
|
|
|
35 |
if system_str == 'Windows': |
|
|
36 |
INSTALLS.extend([ |
|
|
37 |
('JCC','easy_install',None,None), |
|
70
|
38 |
('PSYCOPG2',install_psycopg2,None,None), |
|
68
|
39 |
('PYLUCENE','easy_install',None,None), |
|
|
40 |
]) |
|
|
41 |
else: |
|
|
42 |
INSTALLS.extend([ |
|
|
43 |
('PYLUCENE',install_pylucene,None,None), |
|
|
44 |
('PSYCOPG2', 'pip', None, None), |
|
|
45 |
]) |
|
|
46 |
|
|
|
47 |
if system_str == "Darwin": |
|
|
48 |
INSTALLS.extend([ |
|
72
|
49 |
('LXML', 'easy_install', None, {'STATIC_DEPS': 'true', 'LIBXML2_VERSION': '2.7.8', 'LIBXSLT_VERSION': '1.1.26', 'LIBICONV_VERSION': '1.13.1'}), |
|
68
|
50 |
]) |
|
70
|
51 |
elif system_str == "Windows": |
|
|
52 |
INSTALLS.extend([ |
|
|
53 |
('LXML', 'easy_install', None, None), |
|
|
54 |
]) |
|
68
|
55 |
else: |
|
|
56 |
INSTALLS.extend([ |
|
|
57 |
('LXML', 'pip', None, None), |
|
|
58 |
]) |
|
|
59 |
|
|
|
60 |
|
|
|
61 |
def generate_install_methods(path_locations, src_base, Logger, call_subprocess): |
|
|
62 |
return lib_generate_install_methods(path_locations, src_base, Logger, call_subprocess, INSTALLS) |