Commit 930768cd authored by ahoms's avatar ahoms
Browse files

* add support for BLISSADM device server directory structure

git-svn-id: 45c4679d-1946-429d-baad-37912b19538b
parent 602116e5
#!/usr/bin/env python
import os, sys
def get_compat_os(target_dir, sub_dir=None):
cs_path = ['/csadmin/local/scripts', '/csadmin/common/scripts']
script_name = 'get_compat_os.share'
for cs_dir in cs_path:
script = cs_dir + '/' + script_name
if os.path.exists(script):
raise 'Cannot find compat os'
p = os.popen(script)
compat_os = p.readline().strip()
for os_name in compat_os.split():
path = target_dir + '/' + os_name
if sub_dir:
path += '/' + sub_dir
if os.path.exists(path):
return path
prog_name = os.path.basename(sys.argv[0])
this_dir = os.path.dirname(__file__)
server_dir = '%s/..' % this_dir
lib_dir = get_compat_os(server_dir, '/lib/' + prog_name)
from FrelonTacoCcd import FrelonServer
def main(argv):
prog_name = os.path.basename(argv[0])
pers_name = argv[1]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment