Skip to content

Commit 6605bba

Browse files
andredcodebytere
authored andcommitted
build: allow passing multiple libs to pkg_config
Sometimes it's necessary to pass multiple library names to pkg-config, e.g. the brotli shared libraries can be pulled in with pkg-config libbrotlienc libbrotlidec Update the code to handle both, strings (as used so far), and lists of strings. Signed-off-by: André Draszik <[email protected]> PR-URL: #32046 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Michael Dawson <[email protected]> Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Richard Lau <[email protected]>
1 parent efd20f0 commit 6605bba

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

‎configure.py‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -669,7 +669,11 @@ def pkg_config(pkg):
669669
retval= ()
670670
forflagin ['--libs-only-l', '--cflags-only-I',
671671
'--libs-only-L', '--modversion']:
672-
args+= [flag, pkg]
672+
args+= [flag]
673+
ifisinstance(pkg, list):
674+
args+=pkg
675+
else:
676+
args+= [pkg]
673677
try:
674678
proc=subprocess.Popen(shlex.split(pkg_config) +args,
675679
stdout=subprocess.PIPE)

0 commit comments

Comments
(0)