build: Force pkg-config lookup method for libpci

This is some meson bug but this solution works for now.
This commit is contained in:
Patrick Griffis 2017-11-18 21:29:56 -05:00
parent 38f8cc8e0c
commit 228e08543a

View File

@ -19,8 +19,8 @@ if system == 'linux' or system == 'darwin'
]
if system == 'linux'
libpci = dependency('libpci', required: false)
if libpci.found() and cc.has_header('pci/pci.h')
libpci = dependency('libpci', required: false, method: 'pkg-config')
if libpci.found()
sysinfo_deps += libpci
sysinfo_cargs += '-DHAVE_LIBPCI'
sysinfo_sources += 'unix/pci.c'