Skip to content

Commit ee492dc

Browse files
committed
patch pc files
1 parent 22bec87 commit ee492dc

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

config/lib.json

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -186,9 +186,6 @@
186186
},
187187
"grpc": {
188188
"source": "grpc",
189-
"static-libs-unix": [
190-
"libgrpc.a"
191-
],
192189
"pkg-configs": [
193190
"grpc"
194191
],

src/SPC/builder/extension/grpc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public function patchBeforeBuildconf(): bool
4141

4242
public function patchBeforeConfigure(): bool
4343
{
44-
$util = new SPCConfigUtil($this->builder);
44+
$util = new SPCConfigUtil($this->builder, ['libs_only_deps' => true]);
4545
$config = $util->config(['grpc']);
4646
$libs = $config['libs'];
4747
FileSystem::replaceFileStr(SOURCE_PATH . '/php-src/configure', '-lgrpc', $libs);

src/SPC/builder/unix/library/grpc.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ protected function build(): void
5050

5151
$cmake->build();
5252
copy($this->source_dir . '/third_party/re2/re2.pc', BUILD_LIB_PATH . '/pkgconfig/re2.pc');
53+
$this->patchPkgconfPrefix(['grpc++.pc', 'grpc.pc', 'grpc++_unsecure.pc', 'grpc_unsecure.pc', 're2.pc']);
5354

5455
// shell()->cd($this->source_dir)
5556
// ->exec('EXTRA_DEFINES=GRPC_POSIX_FORK_ALLOW_PTHREAD_ATFORK EMBED_OPENSSL=false CXXFLAGS="-L' . BUILD_LIB_PATH . ' -I' . BUILD_INCLUDE_PATH . '" make static -j' . $this->builder->concurrency);

0 commit comments

Comments
 (0)