build/python/project: add build(), calls _build()
Prepare to add some code around the _build() call.
This commit is contained in:
parent
4f2f705dca
commit
6f278977e9
|
@ -55,7 +55,7 @@ class AutotoolsProject(MakeProject):
|
|||
subprocess.check_call(configure, cwd=build, env=toolchain.env)
|
||||
return build
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
build = self.configure(toolchain)
|
||||
if self.subdirs is not None:
|
||||
for subdir in self.subdirs:
|
||||
|
|
|
@ -12,7 +12,7 @@ class BoostProject(Project):
|
|||
name='boost', version=version,
|
||||
**kwargs)
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
src = self.unpack(toolchain)
|
||||
|
||||
# install the headers manually; don't build any library
|
||||
|
|
|
@ -53,7 +53,7 @@ class CmakeProject(Project):
|
|||
configure(toolchain, src, build, configure_args)
|
||||
return build
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
build = self.configure(toolchain)
|
||||
subprocess.check_call(['ninja', 'install'],
|
||||
cwd=build, env=toolchain.env)
|
||||
|
|
|
@ -10,7 +10,7 @@ class FfmpegProject(Project):
|
|||
self.configure_args = configure_args
|
||||
self.cppflags = cppflags
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
src = self.unpack(toolchain)
|
||||
build = self.make_build_path(toolchain)
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ class JackProject(Project):
|
|||
base='jack2-' + self.version,
|
||||
**kwargs)
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
src = self.unpack(toolchain)
|
||||
|
||||
includes = ['jack.h', 'ringbuffer.h', 'systemdeps.h', 'transport.h', 'types.h', 'weakmacros.h']
|
||||
|
|
|
@ -115,7 +115,7 @@ class MesonProject(Project):
|
|||
configure(toolchain, src, build, self.configure_args)
|
||||
return build
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
build = self.configure(toolchain)
|
||||
subprocess.check_call(['ninja', 'install'],
|
||||
cwd=build, env=toolchain.env)
|
||||
|
|
|
@ -23,7 +23,7 @@ class OpenSSLProject(MakeProject):
|
|||
'RANLIB=' + toolchain.ranlib,
|
||||
]
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
src = self.unpack(toolchain, out_of_tree=False)
|
||||
|
||||
# OpenSSL has a weird target architecture scheme with lots of
|
||||
|
|
|
@ -79,3 +79,6 @@ class Project:
|
|||
pass
|
||||
os.makedirs(path, exist_ok=True)
|
||||
return path
|
||||
|
||||
def build(self, toolchain):
|
||||
self._build(toolchain)
|
||||
|
|
|
@ -7,7 +7,7 @@ class ZlibProject(Project):
|
|||
**kwargs):
|
||||
Project.__init__(self, url, md5, installed, **kwargs)
|
||||
|
||||
def build(self, toolchain):
|
||||
def _build(self, toolchain):
|
||||
src = self.unpack(toolchain, out_of_tree=False)
|
||||
|
||||
subprocess.check_call(['/usr/bin/make', '--quiet',
|
||||
|
|
Loading…
Reference in New Issue