~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to setup.py

  • Committer: mattgiuca
  • Date: 2008-02-05 07:57:23 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:422
setup.py: Needs to copy the "lib" directory into the jail. Now does this and
also adds /opt/ivle/lib to ivle.pth INSIDE the jail.

Show diffs side-by-side

added added

removed removed

Lines of Context:
646
646
    action_chmod_x('jail/opt/ivle/scripts/python-console', dry)
647
647
    action_chmod_x('jail/opt/ivle/scripts/fileservice', dry)
648
648
    
 
649
    # Also copy the IVLE lib directory into the jail
 
650
    # This is necessary for running certain scripts
 
651
    action_copylist(install_list.list_lib, 'jail/opt/ivle', dry)
649
652
 
650
653
    # Compile .py files into .pyc or .pyo files
651
654
    compileall.compile_dir('www', quiet=True)
 
655
    compileall.compile_dir('lib', quiet=True)
652
656
    compileall.compile_dir('console', quiet=True)
 
657
    compileall.compile_dir('jail/opt/ivle/lib', quiet=True)
 
658
 
 
659
    # Set up ivle.pth inside the jail
 
660
    # Need to set /opt/ivle/lib to be on the import path
 
661
    ivle_pth = \
 
662
        "jail/usr/lib/python%s/site-packages/ivle.pth" % PYTHON_VERSION
 
663
    f = open(ivle_pth, 'w')
 
664
    f.write('/opt/ivle/lib\n')
 
665
    f.close()
653
666
 
654
667
    return 0
655
668