refactor to pkg-config and add some add-on libs for gd

This commit is contained in:
crazywhalecc
2023-04-29 18:59:47 +08:00
parent ea055afd3c
commit 8df4ade754
83 changed files with 1001 additions and 1520 deletions

View File

@@ -34,7 +34,6 @@ class libpng extends LinuxLibraryBase
*/
public function build()
{
// 不同架构的专属优化
$optimizations = match ($this->builder->arch) {
'x86_64' => '--enable-intel-sse ',
'arm64' => '--enable-arm-neon ',
@@ -52,7 +51,7 @@ class libpng extends LinuxLibraryBase
'--disable-shared ' .
'--enable-static ' .
'--enable-hardware-optimizations ' .
'--with-zlib-prefix=' . BUILD_ROOT_PATH . ' ' .
'--with-zlib-prefix="' . BUILD_ROOT_PATH . '" ' .
$optimizations .
'--prefix='
)
@@ -61,5 +60,6 @@ class libpng extends LinuxLibraryBase
->exec('make install-libLTLIBRARIES install-data-am DESTDIR=' . BUILD_ROOT_PATH)
->cd(BUILD_LIB_PATH)
->exec('ln -sf libpng16.a libpng.a');
$this->patchPkgconfPrefix(['libpng16.pc'], PKGCONF_PATCH_PREFIX);
}
}