From patchwork Wed Jun 5 15:40:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 1360 Return-Path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 62B0C66260 for ; Wed, 5 Jun 2019 17:41:08 +0200 (CEST) Received: from pendragon.ideasonboard.com (85-76-35-254-nat.elisa-mobile.fi [85.76.35.254]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 6104B84 for ; Wed, 5 Jun 2019 17:41:06 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1559749268; bh=uB/Lt0h859rAN/nARFHZNjPwSxh33shZnhfFqekXy9E=; h=From:To:Subject:Date:From; b=IUHZMdSNOuYI5Ja+sdatgpoQHtkwvIDXn6mslovfqvYvdCmGH7n0B9Q4NGTJA1KHl mELk7godOA3yYr7mFntmaj4gVWWnijGt8owFm/JQrXZQJaS6Svxc8ZCsSdLTWMzSAd 2j8bKBqCN91oN7R1pwmbfgfUJYyKbPfARlUkR1NA= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Wed, 5 Jun 2019 18:40:47 +0300 Message-Id: <20190605154047.12055-1-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH] libcamera: Use dependency instead of link_args to link against libdl X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jun 2019 15:41:08 -0000 Instead of specifying the link arguments directly, which may be compiler-specific, use a dependency object provided by find_library(). Signed-off-by: Laurent Pinchart Reviewed-by: Paul Elder Tested-by: Paul Elder --- src/libcamera/meson.build | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/libcamera/meson.build b/src/libcamera/meson.build index 0889b0d31f36..1ca1083cf5c7 100644 --- a/src/libcamera/meson.build +++ b/src/libcamera/meson.build @@ -63,12 +63,16 @@ if libudev.found() ]) endif +libcamera_deps = [ + cc.find_library('dl'), + libudev, +] + libcamera = shared_library('camera', libcamera_sources, install : true, include_directories : includes, - dependencies : libudev, - link_args : '-ldl') + dependencies : libcamera_deps) libcamera_dep = declare_dependency(sources : [libcamera_api, libcamera_h], include_directories : libcamera_includes,