ldac: Use pkg-config instead of raw lib/header search
authorArun Raghavan <arun@asymptotic.io>
Wed, 27 Jan 2021 22:09:07 +0000 (17:09 -0500)
committerArun Raghavan <arun@asymptotic.io>
Wed, 27 Jan 2021 22:16:57 +0000 (17:16 -0500)
The ldacBT library includes pkg-config files for the standard and ABR
libraries, so let's just use that instead of doing a header/library
search.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1990>

ext/ldac/gstldacenc.h
ext/ldac/meson.build

index 2eafb7bcceed26ee8978df37502516b511eca755..5fe80e511357543c61e85c4e00891fadf10b0b99 100644 (file)
@@ -19,7 +19,7 @@
 #include <gst/gst.h>
 #include <gst/audio/audio.h>
 
-#include <ldac/ldacBT.h>
+#include <ldacBT.h>
 
 G_BEGIN_DECLS
 
index 1f29d881e2aed1334e43e8f7cf3d613077ffc477..47f028bdcbec5e4e899b717b64032a4e7aa43d29 100644 (file)
@@ -3,10 +3,9 @@ ldac_sources = [
   'gstldacenc.c',
 ]
 
-ldac_dep = cc.find_library('ldacBT_enc', required : get_option('ldac'))
-ldac_hdr = cc.has_header('ldac/ldacBT.h', required: get_option('ldac'))
+ldac_dep = dependency('ldacBT-enc', required : get_option('ldac'))
 
-if ldac_dep.found() and ldac_hdr
+if ldac_dep.found()
   gstldac = library('gstldac',
     ldac_sources,
     c_args : gst_plugins_bad_args,