Extract default build env to unix shell

This commit is contained in:
crazywhalecc
2025-06-09 10:24:06 +08:00
parent 9babe7f1d2
commit 123cc92756
29 changed files with 166 additions and 196 deletions

View File

@@ -17,11 +17,10 @@ trait onig
{
[,,$destdir] = SEPARATED_PATH;
shell()->cd($this->source_dir)
->setEnv(['CFLAGS' => $this->getLibExtraCFlags() ?: $this->builder->arch_c_flags, 'LDFLAGS' => $this->getLibExtraLdFlags(), 'LIBS' => $this->getLibExtraLibs()])
->execWithEnv('./configure --enable-static --disable-shared --prefix=')
->execWithEnv('make clean')
->execWithEnv("make -j{$this->builder->concurrency}")
shell()->cd($this->source_dir)->initLibBuildEnv($this)
->exec('./configure --enable-static --disable-shared --prefix=')
->exec('make clean')
->exec("make -j{$this->builder->concurrency}")
->exec("make install DESTDIR={$destdir}");
$this->patchPkgconfPrefix(['oniguruma.pc']);
}