fix fails install if modified OUTPUT variable

This commit is contained in:
Dimitris Zlatanidis 2015-01-27 05:02:39 +02:00
parent 768f3a5aa9
commit 9efa62e0f5
3 changed files with 12 additions and 4 deletions

View file

@ -212,3 +212,11 @@ class MetaData(object):
# computer architecture
arch = os.uname()[4]
# get sbo OUTPUT enviroment variable
try:
output = os.environ['OUTPUT']
except KeyError:
output = tmp
if not output.endswith('/'):
output = output + '/'

View file

@ -300,7 +300,7 @@ class SBoInstall(object):
Search for binary packages in /tmp directory
'''
binary = []
for search in find_package(prgnam, _m.tmp):
for search in find_package(prgnam, _m.output):
if "_SBo" in search:
binary.append(search)
return binary
@ -342,7 +342,7 @@ class SBoInstall(object):
BuildPackage(script, sources, _m.build_path).build()
binary_list = self.search_in_tmp(prgnam)
try:
binary = (_m.tmp + max(binary_list)).split()
binary = (_m.output + max(binary_list)).split()
except ValueError:
build_FAILED(sbo_url, prgnam)
sys.exit(0)

View file

@ -213,11 +213,11 @@ class SBoNetwork(object):
directory.
'''
binary_list = []
for search in find_package(prgnam, _m.tmp):
for search in find_package(prgnam, _m.output):
if "_SBo" in search:
binary_list.append(search)
try:
binary = (_m.tmp + max(binary_list)).split()
binary = (_m.output + max(binary_list)).split()
except ValueError:
build_FAILED(self.sbo_url, prgnam)
sys.exit(0)