Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 1 | From 878f89b6136ff7b870a19e04901cc6f316bbe10a Mon Sep 17 00:00:00 2001 |
William A. Kennington III | ac69b48 | 2021-06-02 12:28:27 -0700 | [diff] [blame] | 2 | From: Bruce Ashfield <bruce.ashfield@gmail.com> |
| 3 | Date: Sat, 15 May 2021 10:26:38 -0400 |
| 4 | Subject: [PATCH] src/Kbuild: change missing CONFIG_TRACEPOINTS to warning |
| 5 | |
| 6 | Taken from a previous patch to the main lttng-modules Makefile, by |
| 7 | Otavio Salvador: |
| 8 | |
| 9 | The lttng-modules are being pulled by the tools-profile image feature, |
| 10 | however, not every kernel has the CONFIG_TRACEPOINTS feature enabled. |
| 11 | |
| 12 | This change makes the build do not fail when CONFIG_TRACEPOINTS is not |
| 13 | available, allowing it to be kept being pulled by default. |
| 14 | |
| 15 | Upstream-Status: Inappropriate [embedded specific] |
| 16 | |
| 17 | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> |
| 18 | --- |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 19 | src/Kbuild | 7 ++++++- |
| 20 | 1 file changed, 6 insertions(+), 1 deletion(-) |
William A. Kennington III | ac69b48 | 2021-06-02 12:28:27 -0700 | [diff] [blame] | 21 | |
| 22 | diff --git a/src/Kbuild b/src/Kbuild |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 23 | index 7137874..04eb5c9 100644 |
William A. Kennington III | ac69b48 | 2021-06-02 12:28:27 -0700 | [diff] [blame] | 24 | --- a/src/Kbuild |
| 25 | +++ b/src/Kbuild |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 26 | @@ -2,10 +2,13 @@ |
William A. Kennington III | ac69b48 | 2021-06-02 12:28:27 -0700 | [diff] [blame] | 27 | |
| 28 | ifdef CONFIG_LOCALVERSION # Check if dot-config is included. |
| 29 | ifeq ($(CONFIG_TRACEPOINTS),) |
| 30 | - $(error The option CONFIG_TRACEPOINTS needs to be enabled in your kernel configuration) |
| 31 | + $(warning The option CONFIG_TRACEPOINTS needs to be enabled in your kernel configuration) |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 32 | + DISABLE_MODULE = y |
William A. Kennington III | ac69b48 | 2021-06-02 12:28:27 -0700 | [diff] [blame] | 33 | endif # CONFIG_TRACEPOINTS |
| 34 | endif # ifdef CONFIG_LOCALVERSION |
| 35 | |
Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 36 | +ifneq ($(DISABLE_MODULE),y) |
| 37 | + |
| 38 | TOP_LTTNG_MODULES_DIR := $(shell dirname $(lastword $(MAKEFILE_LIST)))/.. |
| 39 | |
| 40 | lttng_check_linux_version = $(shell pwd)/include/linux/version.h |
| 41 | @@ -150,3 +153,5 @@ lttng-statedump-objs := lttng-statedump-impl.o |
| 42 | obj-$(CONFIG_LTTNG) += probes/ |
| 43 | obj-$(CONFIG_LTTNG) += lib/ |
| 44 | obj-$(CONFIG_LTTNG) += tests/ |
| 45 | + |
| 46 | +endif # DISABLE_MODULE |