Commit 32b7417b authored by Sebastien Petitdemange's avatar Sebastien Petitdemange
Browse files

Fixed a small bug in init script

parent f67f5f21
...@@ -33,20 +33,22 @@ for d in csadmin_dirs: ...@@ -33,20 +33,22 @@ for d in csadmin_dirs:
break break
if get_os is not None: if get_os is not None:
compat_plat = os.popen(get_os).readline().strip() compat_plat = os.popen(get_os).readline().strip()
plat = None if compat_plat:
compat_plat_list = compat_plat.split() plat = None
for aux_plat in compat_plat_list: compat_plat_list = compat_plat.split()
if aux_plat.strip() in os.listdir(root_name): for aux_plat in compat_plat_list:
plat = aux_plat if aux_plat.strip() in os.listdir(root_name):
break plat = aux_plat
if plat is None: break
raise ImportError, ('Could not find Lima directory for %s ' if plat is None:
'(nor compat. %s) platform(s) at %s' % raise ImportError, ('Could not find Lima directory for %s '
(compat_plat_list[0], '(nor compat. %s) platform(s) at %s' %
compat_plat_list[1:], root_name)) (compat_plat_list[0],
lima_plat = os.path.join(root_name, plat) compat_plat_list[1:], root_name))
__path__.insert(0, lima_plat) lima_plat = os.path.join(root_name, plat)
__path__.insert(0, lima_plat)
else:
get_os = None
# This mandatory variable is systematically overwritten by 'make install' # This mandatory variable is systematically overwritten by 'make install'
os.environ['LIMA_LINK_STRICT_VERSION'] = 'MINOR' os.environ['LIMA_LINK_STRICT_VERSION'] = 'MINOR'
......
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