virtualenv/web/res/res_create_env.py
author cavaliet
Wed, 16 Apr 2014 17:22:05 +0200
changeset 65 ac0c11fc869e
parent 31 df2ca7a612ac
child 137 02e81a3fc99b
permissions -rwxr-xr-x
update ldt, remove tagging for taggit
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     1
import platform
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     2
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     3
from lib_create_env import lib_generate_install_methods
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     4
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     5
system_str = platform.system()
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     6
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     7
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     8
INSTALLS = [ #(key,method, option_str, dict_extra_env)
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
     9
    'LXML',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    10
    'PSYCOPG2',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    11
    #'MYSQL',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    12
    'SOUTH',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    13
    'PIL', 
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    14
    'DJANGO',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    15
    'DJANGO-EXTENSIONS',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    16
    'DJANGO-REGISTRATION',
65
ac0c11fc869e update ldt, remove tagging for taggit
cavaliet
parents: 31
diff changeset
    17
    'DJANGO-TAGGIT',
ac0c11fc869e update ldt, remove tagging for taggit
cavaliet
parents: 31
diff changeset
    18
    'DJANGO-TAGGIT-TEMPLATETAGS',
2
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    19
    'HTTPLIB2',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    20
    'OAUTH2',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    21
    'SETUPTOOLS_HG',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    22
    'DJANGO-OAUTH-PLUS',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    23
    'OPENID',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    24
    'DJANGO_OPENID_CONSUMER',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    25
    'SOCIAL_AUTH',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    26
    'DJANGO_GUARDIAN',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    27
    'SORL_THUMBNAIL',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    28
    'HAYSTACK',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    29
    'REQUESTS',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    30
    'SIMPLEJSON',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    31
    'PYELASTICSEARCH',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    32
    'WHOOSH',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    33
    'MIMEPARSE',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    34
    'SIX',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    35
    'PYTHON-DATEUTIL',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    36
    'PYYAML',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    37
    'PYTHON-DIGEST',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    38
    'DEFUSEDXML',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    39
    'DJANGO-TASTYPIE',
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    40
    'DJANGO-CHUNCKED-UPLOADS',
31
df2ca7a612ac enhance ref_text filter and update venv with ldt
cavaliet
parents: 2
diff changeset
    41
    'LDT',
2
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    42
]
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    43
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    44
if system_str == "Linux":
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    45
    INSTALLS.insert(2, 'DISTRIBUTE')
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    46
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    47
OPTIONS_TO_ADD = ['clear', 'type_install=local', 'unzip_setuptools']
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    48
if system_str != 'Linux':
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    49
    OPTIONS_TO_ADD.append('use_distribute')
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    50
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    51
def generate_install_methods(path_locations, src_base, Logger, call_subprocess):    
bafbf72652b9 virtualenv first commit and structure for spel app
cavaliet
parents:
diff changeset
    52
    return lib_generate_install_methods(path_locations, src_base, Logger, call_subprocess, INSTALLS, OPTIONS_TO_ADD)