def build(self, rebuild=False, target=None,
              coverity=False, env=None):
        timer = ui.timer("make %s" % self.name)
        timer.start()

        cmd = []
        if coverity:
            # So that we raise before creating the coverity directory
            qisys.command.find_program("cov-build", raises=True)
            cov_dir = os.path.join(self.build_directory, "coverity")
            qisys.sh.mkdir(cov_dir)
            cmd += ["cov-build", "--dir", cov_dir]

        cmd += ["cmake", "--build", self.build_directory,
                         "--config", self.build_type]

        if target:
            cmd += ["--target", target]

        if rebuild:
            cmd += ["--clean-first"]
        cmd += [ "--" ]
        cmd += self.parse_num_jobs(self.build_config.num_jobs)

        if not env:
            build_env = self.build_env.copy()
        else:
            build_env = env
        build_env = self.fix_env(build_env)
        if self.verbose_make:
            if self.cmake_generator:
                if "Makefiles" in self.cmake_generator:
                    build_env["VERBOSE"] = "1"
                if self.cmake_generator == "Ninja":
                    cmd.append("-v")
        try:
            qisys.command.call(cmd, env=build_env)
        except qisys.command.CommandFailedException:
            raise qibuild.build.BuildFailed(self)

        timer.stop()
        # We need to call generate_qitest_json() here because
        # `qibuild make` may have caused a re-run of cmake
        self.generate_qitest_json()
Create a new ZipLibraryPackage.
dataset/ETHPy150Open aldebaran/qibuild/python/qibuild/project.py/BuildProject.build--crossover with--dataset/ETHPy150Open google/apis-client-generator/src/googleapis/codegen/filesys/zip_library_package.py/ZipLibraryPackage.__init__