bin_dir option is added to the spec file

This commit is contained in:
Jabba Laci 2016-01-24 19:45:55 +01:00
parent 83a44887b5
commit 38f80ab5e4

View file

@ -130,6 +130,7 @@ class Buildozer(object):
except:
pass
self.builddir = self.config.getdefault('buildozer', 'builddir', None)
self.bin_apk_dir = self.config.getdefault('buildozer', 'bin_dir', None)
self.targetname = None
self.target = None
@ -417,17 +418,18 @@ class Buildozer(object):
self.mkdir(self.global_buildozer_dir)
self.mkdir(self.global_cache_dir)
# create local dir
specdir = dirname(self.specfilename)
if self.builddir:
specdir = self.builddir
# create local .buildozer/ dir
self.mkdir(self.buildozer_dir)
# create local bin/ dir
self.mkdir(self.bin_dir)
self.mkdir(join(specdir, '.buildozer'))
self.mkdir(join(specdir, 'bin'))
self.mkdir(self.applibs_dir)
self.state = JsonStore(join(self.buildozer_dir, 'state.db'))
if self.targetname:
specdir = dirname(self.specfilename)
if self.builddir:
specdir = self.builddir
target = self.targetname
self.mkdir(join(self.global_platform_dir, target, 'platform'))
self.mkdir(join(specdir, '.buildozer', target, 'platform'))
@ -818,8 +820,8 @@ class Buildozer(object):
@property
def bin_dir(self):
if self.builddir:
return join(self.builddir, 'bin')
if self.bin_apk_dir:
return join(self.bin_apk_dir, 'bin')
return join(self.root_dir, 'bin')
@property