summaryrefslogtreecommitdiff
path: root/cook.py
diff options
context:
space:
mode:
authorAlejandro Sior <aho@sior.be>2022-08-07 14:29:10 +0200
committerAlejandro Sior <aho@sior.be>2022-08-07 14:29:10 +0200
commite3f26569e012bc961bc355d25c731303856fec04 (patch)
tree3ea87640ce99ea56af31584a9ed320a2ff2f80d8 /cook.py
parent7e75a1223a66f1b062cc01f666b6a846a7da830f (diff)
cook: check if output of pkgconfig is not empty string
Diffstat (limited to 'cook.py')
-rwxr-xr-xcook.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/cook.py b/cook.py
index 8917145..c42de23 100755
--- a/cook.py
+++ b/cook.py
@@ -532,6 +532,8 @@ def CDependency(name):
try:
inc = subproc([pkgconfig.path, "--cflags", name]).strip().decode("utf-8")
lib = subproc([pkgconfig.path, "--libs", name]).strip().decode("utf-8")
+ inc = inc if inc != "" else []
+ lib = lib if lib != "" else []
module.mkdep(shared_ld_args = lib, shared_cc_args = inc)
return module
except subprocess.CalledProcessError: