From patchwork Thu Aug 31 10:04:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 13371183 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 87128C83F32 for ; Thu, 31 Aug 2023 10:04:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233881AbjHaKEp (ORCPT ); Thu, 31 Aug 2023 06:04:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231617AbjHaKEo (ORCPT ); Thu, 31 Aug 2023 06:04:44 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 99565CED for ; Thu, 31 Aug 2023 03:04:41 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B2C50C15; Thu, 31 Aug 2023 03:05:20 -0700 (PDT) Received: from oss-tx204.lab.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id BDF6D3F64C; Thu, 31 Aug 2023 03:04:40 -0700 (PDT) From: ross.burton@arm.com To: linux-trace-devel@vger.kernel.org Cc: nd@arm.com Subject: [PATCH 1/3] meson: add option to disable documentation Date: Thu, 31 Aug 2023 11:04:36 +0100 Message-Id: <20230831100438.3946997-1-ross.burton@arm.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-trace-devel@vger.kernel.org From: Ross Burton Building the documentation shouldn't be mandatory, as it needs asciidoc and xmlto. Add a "docs" option, defaulting to true, to control whether the documentation should be built. Signed-off-by: Ross Burton --- meson.build | 15 +++++++++------ meson_options.txt | 4 ++++ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/meson.build b/meson.build index b61c873..506b0e8 100644 --- a/meson.build +++ b/meson.build @@ -45,10 +45,13 @@ if cunit_dep.found() subdir('utest') endif subdir('samples') -subdir('Documentation') -custom_target( - 'docs', - output: 'docs', - depends: [html, man], - command: ['echo']) +if get_option('docs') + subdir('Documentation') + + custom_target( + 'docs', + output: 'docs', + depends: [html, man], + command: ['echo']) +endif diff --git a/meson_options.txt b/meson_options.txt index b2294f6..0611216 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -4,6 +4,10 @@ option('plugindir', type : 'string', description : 'set the plugin dir') + +option('docs', type : 'boolean', value: true, + description : 'build documentation') + option('htmldir', type : 'string', value : 'share/doc/libtraceevent-doc', description : 'directory for HTML documentation') option('asciidoctor', type : 'boolean', value: false, From patchwork Thu Aug 31 10:04:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 13371184 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A4D49C83F33 for ; Thu, 31 Aug 2023 10:04:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231617AbjHaKEp (ORCPT ); Thu, 31 Aug 2023 06:04:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229733AbjHaKEo (ORCPT ); Thu, 31 Aug 2023 06:04:44 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 41251CEE for ; Thu, 31 Aug 2023 03:04:42 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 7ADB1FEC; Thu, 31 Aug 2023 03:05:21 -0700 (PDT) Received: from oss-tx204.lab.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 7E7D23F64C; Thu, 31 Aug 2023 03:04:41 -0700 (PDT) From: ross.burton@arm.com To: linux-trace-devel@vger.kernel.org Cc: nd@arm.com Subject: [PATCH 2/3] meson: build plugins as modules Date: Thu, 31 Aug 2023 11:04:37 +0100 Message-Id: <20230831100438.3946997-2-ross.burton@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230831100438.3946997-1-ross.burton@arm.com> References: <20230831100438.3946997-1-ross.burton@arm.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-trace-devel@vger.kernel.org From: Ross Burton Don't build the plugins with library() as that will install both static libraries and versioned shared libraries. Plugins are shared_modules(). Signed-off-by: Ross Burton --- plugins/meson.build | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/meson.build b/plugins/meson.build index 74ad664..4919be4 100644 --- a/plugins/meson.build +++ b/plugins/meson.build @@ -19,11 +19,10 @@ plugins = [ pdeps = [] foreach plugin : plugins - pdeps += library( + pdeps += shared_module( plugin.replace('.c', ''), plugin, name_prefix: '', - version: library_version, dependencies: [libtraceevent_dep], include_directories: [incdir], install: true, From patchwork Thu Aug 31 10:04:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 13371185 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6017FC83F34 for ; Thu, 31 Aug 2023 10:04:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240560AbjHaKEp (ORCPT ); Thu, 31 Aug 2023 06:04:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229733AbjHaKEp (ORCPT ); Thu, 31 Aug 2023 06:04:45 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 08657CF2 for ; Thu, 31 Aug 2023 03:04:43 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 4457DC15; Thu, 31 Aug 2023 03:05:22 -0700 (PDT) Received: from oss-tx204.lab.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 477A13F64C; Thu, 31 Aug 2023 03:04:42 -0700 (PDT) From: ross.burton@arm.com To: linux-trace-devel@vger.kernel.org Cc: nd@arm.com Subject: [PATCH 3/3] meson: set the default plugindir to make Makefile Date: Thu, 31 Aug 2023 11:04:38 +0100 Message-Id: <20230831100438.3946997-3-ross.burton@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230831100438.3946997-1-ross.burton@arm.com> References: <20230831100438.3946997-1-ross.burton@arm.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-trace-devel@vger.kernel.org From: Ross Burton The Makefiles install the plugins to $libdir/traceevent/plugins, so make the Meson build files install to the same location. Signed-off-by: Ross Burton --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 506b0e8..4bba4d8 100644 --- a/meson.build +++ b/meson.build @@ -25,7 +25,7 @@ htmldir = join_paths(prefixdir, get_option('htmldir')) libdir = join_paths(prefixdir, get_option('libdir')) plugindir = get_option('plugindir') if plugindir == '' - plugindir = join_paths(libdir, 'libtraceevent/plugins') + plugindir = join_paths(libdir, 'traceevent/plugins') endif add_project_arguments(