build/python/cmake: add "windows_configure_args"

This commit is contained in:
Max Kellermann 2021-03-12 21:56:32 +01:00 committed by Max Kellermann
parent 937423dbcf
commit 0231622169
1 changed files with 6 additions and 1 deletions

View File

@ -29,14 +29,19 @@ def configure(toolchain, src, build, args=()):
class CmakeProject(Project):
def __init__(self, url, md5, installed, configure_args=[],
windows_configure_args=[],
**kwargs):
Project.__init__(self, url, md5, installed, **kwargs)
self.configure_args = configure_args
self.windows_configure_args = windows_configure_args
def configure(self, toolchain):
src = self.unpack(toolchain)
build = self.make_build_path(toolchain)
configure(toolchain, src, build, self.configure_args)
configure_args = self.configure_args
if toolchain.is_windows:
configure_args = configure_args + self.windows_configure_args
configure(toolchain, src, build, configure_args)
return build
def build(self, toolchain):