From patchwork Tue Aug 6 09:19:25 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: andi@dri-devel.l.notmuch.email X-Patchwork-Id: 11078529 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A321A1395 for ; Tue, 6 Aug 2019 09:29:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8726B288C6 for ; Tue, 6 Aug 2019 09:29:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7B54B28958; Tue, 6 Aug 2019 09:29:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9F601288C6 for ; Tue, 6 Aug 2019 09:29:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F07E26E345; Tue, 6 Aug 2019 09:29:13 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org X-Greylist: delayed 569 seconds by postgrey-1.36 at gabe; Tue, 06 Aug 2019 09:29:12 UTC Received: from mail.h4ck.space (mx.h4ck.space [136.243.22.202]) by gabe.freedesktop.org (Postfix) with ESMTP id 574CF6E345 for ; Tue, 6 Aug 2019 09:29:12 +0000 (UTC) Received: from localhost (unknown [IPv6:2a00:e67:1a6:0:e67c:76b0:918a:5b92]) by mail.h4ck.space (Postfix) with ESMTPSA id 191141C02CA; Tue, 6 Aug 2019 09:19:42 +0000 (UTC) From: andi@dri-devel.l.notmuch.email To: dri-devel@lists.freedesktop.org Subject: [PATCH] meson: support for custom nm path Date: Tue, 6 Aug 2019 11:19:25 +0200 Message-Id: <20190806091925.6558-1-andi@dri-devel.l.notmuch.email> X-Mailer: git-send-email 2.22.0 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?J=C3=B6rg_Thalheim?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Jörg Thalheim When cross-compiling target toolchains i.e. binutils are often prefixed by its target architecture. This patch gives the user to option to specify the nm used during the build process. Signed-off-by: Jörg Thalheim --- meson.build | 2 +- meson_options.txt | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index e292554a..64607139 100644 --- a/meson.build +++ b/meson.build @@ -327,7 +327,7 @@ pkg.generate( ) env_test = environment() -env_test.set('NM', find_program('nm').path()) +env_test.set('NM', find_program(get_option('nm-path')).path()) if with_libkms subdir('libkms') diff --git a/meson_options.txt b/meson_options.txt index 8af33f1c..b4f46a52 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -141,3 +141,9 @@ option( value : false, description : 'Enable support for using udev instead of mknod.', ) +option( + 'nm-path', + type : 'string', + description : 'path to nm', + value : 'nm' +)