virtualenv/web/res/res_create_env.py
changeset 68 b40657713336
child 70 8e3281bcebc9
equal deleted inserted replaced
67:30c1f3f3035e 68:b40657713336
       
     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     ('JOGGING','pip', None, None),
       
    22     ('DJANGO-EXTENSIONS', 'pip', None, None),
       
    23     ('DJANGO-REGISTRATION', 'easy_install', '-Z', None),
       
    24     ('DJANGO-TAGGING', 'pip', None, None),
       
    25     ('DJANGO-PISTON', 'pip', None, None),
       
    26     ('HTTPLIB2', 'pip', None, None),
       
    27     ('OAUTH2', 'easy_install', None, None),
       
    28     ('DJANGO-OAUTH-PLUS', 'pip', None, None),
       
    29     ('PHOTOLOGUE', 'pip', None, None),
       
    30     ('MODELTRANSLATION', 'pip', None, None),
       
    31 ])
       
    32 
       
    33 if system_str == 'Windows':
       
    34     INSTALLS.extend([
       
    35     ('JCC','easy_install',None,None),
       
    36     ('PYLUCENE','easy_install',None,None),
       
    37     ('PSYCOPG2',install_psycopg2,None,None),
       
    38     ])
       
    39 else:
       
    40     INSTALLS.extend([
       
    41     ('PYLUCENE',install_pylucene,None,None),
       
    42     ('PSYCOPG2', 'pip', None, None),
       
    43     ])
       
    44 
       
    45 if system_str == "Darwin":
       
    46     INSTALLS.extend([
       
    47     ('LXML', 'pip', None, {'STATIC_DEPS': 'true', 'LIBXML2_VERSION': '2.7.8', 'LIBXSLT_VERSION': '1.1.26'}),
       
    48     ])
       
    49 else:
       
    50     INSTALLS.extend([
       
    51     ('LXML', 'pip', None, None),
       
    52     ])
       
    53 
       
    54 
       
    55 def generate_install_methods(path_locations, src_base, Logger, call_subprocess):    
       
    56     return lib_generate_install_methods(path_locations, src_base, Logger, call_subprocess, INSTALLS)