From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-178.mta1.migadu.com (out-178.mta1.migadu.com [95.215.58.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C1F9A221FA1 for ; Wed, 30 Jul 2025 11:48:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.178 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753876137; cv=none; b=oERZArGWuFG8w+9VlMd1Y2wRwKEdA0eE9N9nD8xqDIRzAt1hQGVf3kc8HLsHcKZBfoEA5wgA06peJ7vGR+RM5gPoU+Wu/jtrhwPiRaXp9/ISMgLRDFQwxsFrZg4aseghXeBj6fTNc/+H8On1WEtq3mZOf9nG1NASLQF61uLpJ1M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753876137; c=relaxed/simple; bh=1e0fzHuI/rntwQ57mo91TY0dA532PxuDhYaJ1EW9Fz8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=rDMu4SYCFCd/0Yx0M2bkVL8+972LTrd5NPwi0iyL2XMdfQ/XZNp+0kWfs9UrFth5vMegmZvVLPW/oHKccL9moHJweNpw5UfCpUpLtujmmT3ePcobsGw+TyZhmm4LXBurIoQSH4L/TpjQttZqO5l/KR8BGPMgT/Pyg0eHGMz94/M= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=snqlehLV; arc=none smtp.client-ip=95.215.58.178 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="snqlehLV" X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1753876132; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=1tv44tN9Mkqwho1YUvMPXc0XtnufGsYHnhFM50s3ejw=; b=snqlehLVJm5dmFYpQ5CoQBDOqJp7lK5atUz0xlsgANwqNwoErusBnuIjn1SlZWvPS3htbm P0solDqoFnEK8bzZkVBCSFcb6Tl2Jlvaf2IZvysmuGZJNUtc0UmdRmXnzy+90DueanlqFW yhHRWP3EwpIXNPhmplsZafxmBMHaS6k= From: Tao Chen To: rostedt@goodmis.org, bristot@kernel.org Cc: linux-trace-kernel@vger.kernel.org, linux-kernel@vger.kernel.org, Tao Chen Subject: [PATCH linux-next 1/2] tools/latency-collector: Check pkg-config install Date: Wed, 30 Jul 2025 19:48:22 +0800 Message-ID: <20250730114823.1667088-1-chen.dylane@linux.dev> Precedence: bulk X-Mailing-List: linux-trace-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT The tool pkg-config used to check libtraceevent and libtracefs, if not installed, it will report the libs not found, even though they have already been installed. Before: libtraceevent is missing. Please install libtraceevent-dev/libtraceevent-devel libtracefs is missing. Please install libtracefs-dev/libtracefs-devel After: Makefile.config:10: *** Error: pkg-config needed by libtraceevent/libtracefs is missing on this system, please install it. Fixes: 9d56c88e5225 ("tools/tracing: Use tools/build makefiles on latency-collector") Signed-off-by: Tao Chen --- tools/tracing/latency/Makefile.config | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/tracing/latency/Makefile.config b/tools/tracing/latency/Makefile.config index 0fe6b50f029b..6efa13e3ca93 100644 --- a/tools/tracing/latency/Makefile.config +++ b/tools/tracing/latency/Makefile.config @@ -1,7 +1,15 @@ # SPDX-License-Identifier: GPL-2.0-only +include $(srctree)/tools/scripts/utilities.mak + STOP_ERROR := +ifndef ($(NO_LIBTRACEEVENT),1) + ifeq ($(call get-executable,$(PKG_CONFIG)),) + $(error Error: $(PKG_CONFIG) needed by libtraceevent/libtracefs is missing on this system, please install it) + endif +endif + define lib_setup $(eval LIB_INCLUDES += $(shell sh -c "$(PKG_CONFIG) --cflags lib$(1)")) $(eval LDFLAGS += $(shell sh -c "$(PKG_CONFIG) --libs-only-L lib$(1)")) -- 2.48.1