7 license_file = '/data/tmpsalome/salome/prerequis/install/LICENSE/dlim8.var.sh'
8 if os.path.exists(license_file):
10 env.add_comment("Set DISTENE License")
11 env.set('DISTENE_LICENSE_FILE', 'Use global envvar: DLIM8VAR')
12 env.set('DISTENE_LICENCE_FILE_FOR_MGCLEANER', license_file)
13 env.set('DISTENE_LICENCE_FILE_FOR_YAMS', license_file)
15 if os.access(license_file, os.R_OK):
16 lines = open(license_file, "r").readlines()
18 if line[:8] == "DLIM8VAR":
19 # line is: DLIM8VAR="<key>"\n
20 key = line.strip().split('=')[1]
21 key = key.strip().strip('"')
22 env.set("DLIM8VAR", key)