mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-20 15:25:36 +08:00
-ldl and --with-pic for imagemagick
This commit is contained in:
@@ -16,10 +16,12 @@ trait gettext
|
|||||||
$cflags = $this->builder->getOption('enable-zts') ? '-lpthread -D_REENTRANT' : '';
|
$cflags = $this->builder->getOption('enable-zts') ? '-lpthread -D_REENTRANT' : '';
|
||||||
$ldflags = $this->builder->getOption('enable-zts') ? '-lpthread' : '';
|
$ldflags = $this->builder->getOption('enable-zts') ? '-lpthread' : '';
|
||||||
|
|
||||||
|
$ldl = $this->builder->getLib('libgomp') && getenv('SPC_LIBC') === 'glibc' ? '-ldl' : '';
|
||||||
|
|
||||||
shell()->cd($this->source_dir)
|
shell()->cd($this->source_dir)
|
||||||
->setEnv([
|
->setEnv([
|
||||||
'CFLAGS' => "{$this->getLibExtraCFlags()} {$cflags}",
|
'CFLAGS' => "{$this->getLibExtraCFlags()} {$cflags}",
|
||||||
'LDFLAGS' => $this->getLibExtraLdFlags() ?: $ldflags,
|
'LDFLAGS' => trim($this->getLibExtraLdFlags() . ' ' . $ldflags . ' ' . $ldl),
|
||||||
'LIBS' => $this->getLibExtraLibs(),
|
'LIBS' => $this->getLibExtraLibs(),
|
||||||
])
|
])
|
||||||
->execWithEnv(
|
->execWithEnv(
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ trait imagemagick
|
|||||||
])
|
])
|
||||||
->execWithEnv(
|
->execWithEnv(
|
||||||
'./configure ' .
|
'./configure ' .
|
||||||
'--enable-static --disable-shared ' .
|
'--enable-static --disable-shared --with-pic ' .
|
||||||
$extra .
|
$extra .
|
||||||
'--prefix='
|
'--prefix='
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user