aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/Makefile.config
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/Makefile.config')
-rw-r--r--tools/perf/Makefile.config10
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/perf/Makefile.config b/tools/perf/Makefile.config
index b97e31498ff7..1f1fdc5a0031 100644
--- a/tools/perf/Makefile.config
+++ b/tools/perf/Makefile.config
@@ -180,10 +180,10 @@ strip-libs = $(filter-out -l%,$(1))
PYTHON_CONFIG_SQ := $(call shell-sq,$(PYTHON_CONFIG))
ifdef PYTHON_CONFIG
- PYTHON_EMBED_LDOPTS := $(shell $(PYTHON_CONFIG_SQ) --ldflags 2>/dev/null)
+ PYTHON_EMBED_LDOPTS := $(shell pkg-config --libs python 2>/dev/null)
PYTHON_EMBED_LDFLAGS := $(call strip-libs,$(PYTHON_EMBED_LDOPTS))
PYTHON_EMBED_LIBADD := $(call grep-libs,$(PYTHON_EMBED_LDOPTS)) -lutil
- PYTHON_EMBED_CCOPTS := $(shell $(PYTHON_CONFIG_SQ) --cflags 2>/dev/null)
+ PYTHON_EMBED_CCOPTS := $(shell pkg-config --cflags python 2>/dev/null)
ifeq ($(CC_NO_CLANG), 1)
PYTHON_EMBED_CCOPTS := $(filter-out -specs=%,$(PYTHON_EMBED_CCOPTS))
endif
@@ -548,8 +548,9 @@ ifndef NO_SLANG
msg := $(warning slang not found, disables TUI support. Please install slang-devel, libslang-dev or libslang2-dev);
NO_SLANG := 1
else
- # Fedora has /usr/include/slang/slang.h, but ubuntu /usr/include/slang.h
- CFLAGS += -I/usr/include/slang
+ # Some releases like Fedora have /usr/include/slang/slang.h instead of /usr/include/slang.h
+ SLANG_INC ?= -idirafter =/usr/include/slang
+ CFLAGS += $(SLANG_INC)
CFLAGS += -DHAVE_SLANG_SUPPORT
EXTLIBS += -lslang
$(call detected,CONFIG_SLANG)
@@ -583,6 +584,7 @@ else
FLAGS_PERL_EMBED=$(PERL_EMBED_CCOPTS) $(PERL_EMBED_LDOPTS)
ifneq ($(feature-libperl), 1)
+ msg := $(warning libperl not found, disables Perl scripting support. Please install libperl-dev or perl-devel);
CFLAGS += -DNO_LIBPERL
NO_LIBPERL := 1
msg := $(warning Missing perl devel files. Disabling perl scripting support, please install perl-ExtUtils-Embed/libperl-dev);