link libgomp statically on glibc

This commit is contained in:
DubbleClick
2025-03-27 08:48:52 +07:00
parent ee54b6d347
commit 9a7889e46b
3 changed files with 15 additions and 6 deletions

View File

@@ -92,7 +92,11 @@ class SPCConfigUtil
}
// patch: imagick (imagemagick wrapper) for linux needs -lgomp
if (in_array('imagemagick', $libraries) && PHP_OS_FAMILY === 'Linux') {
$short_name[] = '-lgomp';
if (getenv('SPC_LIBC') === 'glibc') {
$short_name[] = '-l:libgomp.a';
} else {
$short_name[] = '-lgomp';
}
}
return implode(' ', $short_name);
}