mirror of https://github.com/BOINC/boinc.git
18 lines
570 B
Python
18 lines
570 B
Python
# $Id$
|
|
|
|
# This module prepends boinc/py/ to the python system path
|
|
|
|
# configure generates boinc/*/boinc_path_config.py from
|
|
# boinc/py/Boinc/boinc_path_config.py.in (in all directories that contain
|
|
# python scripts, so that they can directly import path_config.py)
|
|
|
|
import sys, os
|
|
|
|
TOP_BUILD_DIR = "@TOP_BUILD_DIR@"
|
|
TOP_SOURCE_DIR = "@TOP_SOURCE_DIR@"
|
|
TOP_SOURCE_DIR = os.environ.get('TOP_SOURCE_DIR') or TOP_SOURCE_DIR
|
|
|
|
sys.path.insert(0, os.path.join(TOP_SOURCE_DIR, 'py'))
|
|
if TOP_BUILD_DIR != TOP_SOURCE_DIR:
|
|
sys.path.insert(0, os.path.join(TOP_BUILD_DIR, 'py'))
|