Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5425738ybp; Tue, 8 Oct 2019 02:40:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqx1fU9RZXshG7jFdrMX5nCE0dykMBEnV5W01cRmQH/POQxPYWRKIafdrwPRNFltOuKbdb7/ X-Received: by 2002:a50:f19c:: with SMTP id x28mr32266071edl.42.1570527608820; Tue, 08 Oct 2019 02:40:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570527608; cv=none; d=google.com; s=arc-20160816; b=yXQPMcM1fpGYtBYB9Q6ME/9Q/q87D3VXmEPjbLorJEEVMF8kfV6r68wPSgw35KWn8o 26WzKsmmhtt63Ixhg6oEF8/8xuzaSeqaQjur1b/1k0JAytaq7FC1ZUE2tyShnY8MvBEZ b7tXfcmoslHtdV8myI989mZVqLKCkIzmU8N8Tqgm3LIZS/0xFC7AZIFsxCQpzDogYfww i5kzc8PXmM0AzLm2bznePF198O6SwPiWKKgEai3XXVLuVp3KMnNSwJQ5SOKnKRO6YIqX cL4bkA1Qtqca6pdaEVuXEMCGl0NPD1EqXGnRgphHtVnvlY6T8s/A65pCQlxNh5TndvFp 5VOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=NzuPvPEmqkDDjv2u2BnWlUXl07ulCIHjWPNf/nE7UAc=; b=ycplehCMxu9VZBn3NfW07J0OKvHbACUpVFAgv26QMf64WbtasmShH3FDnYQ4dw9y5X vAgiQPwrTMB+hrzMQs0VqLHWD5rZmk3VmwHdvyQcpniwdv1SUc0KtnTy2JWV3G/5U6So b8ZJgOwy8KLYZVCStredneowBUiaWD5zEpAGKZAMeJ6tV6yqkgAmyniYjqRNJ5BcEb9C m9k4tB8sd4yk20NkSYEuvq9DEQQg7d7B1E1C3GnQWk7dkboK39Q5LkNmWrX4prxKICnn gflAAgLpbvf1U4HsRCiqVIB3E17Xqvybqf5wB6v6OP7t5dL+ejNpqKJbIyKltEk92j0R 1AOQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g8si10134345eda.105.2019.10.08.02.39.44; Tue, 08 Oct 2019 02:40:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730043AbfJHJix (ORCPT + 99 others); Tue, 8 Oct 2019 05:38:53 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:53990 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729767AbfJHJix (ORCPT ); Tue, 8 Oct 2019 05:38:53 -0400 Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x989RIGa095767 for ; Tue, 8 Oct 2019 05:38:51 -0400 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0a-001b2d01.pphosted.com with ESMTP id 2vgnkwnmvp-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 08 Oct 2019 05:38:51 -0400 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Oct 2019 10:38:49 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Tue, 8 Oct 2019 10:38:46 +0100 Received: from b06wcsmtp001.portsmouth.uk.ibm.com (b06wcsmtp001.portsmouth.uk.ibm.com [9.149.105.160]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x989ciw131260718 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 8 Oct 2019 09:38:44 GMT Received: from b06wcsmtp001.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C558FA4065; Tue, 8 Oct 2019 09:38:44 +0000 (GMT) Received: from b06wcsmtp001.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 83161A4060; Tue, 8 Oct 2019 09:38:44 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by b06wcsmtp001.portsmouth.uk.ibm.com (Postfix) with ESMTP; Tue, 8 Oct 2019 09:38:44 +0000 (GMT) From: Thomas Richter To: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, acme@kernel.org Cc: gor@linux.ibm.com, heiko.carstens@de.ibm.com, Thomas Richter Subject: [PATCH] perf jvmti: Link against tools/lib/ctype.h to have weak strlcpy() Date: Tue, 8 Oct 2019 11:38:41 +0200 X-Mailer: git-send-email 2.17.1 X-TM-AS-GCONF: 00 x-cbid: 19100809-0016-0000-0000-000002B605B3 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19100809-0017-0000-0000-000033170657 Message-Id: <20191008093841.59387-1-tmricht@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-10-08_03:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=688 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910080092 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The build of file libperf-jvmti.so succeeds but the resulting object fails to load: # ~/linux/tools/perf/perf record -k mono -- java \ -XX:+PreserveFramePointer \ -agentpath:/root/linux/tools/perf/libperf-jvmti.so \ hog 100000 123450 Error occurred during initialization of VM Could not find agent library /root/linux/tools/perf/libperf-jvmti.so in absolute path, with error: /root/linux/tools/perf/libperf-jvmti.so: undefined symbol: _ctype Add the missing _ctype symbol into the build script. Fixes: c5d048240e49 ("perf jvmti: Link against tools/lib/string.h to have weak strlcpy()") Signed-off-by: Thomas Richter --- tools/perf/jvmti/Build | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/perf/jvmti/Build b/tools/perf/jvmti/Build index 1e148bbdf820..202cadaaf097 100644 --- a/tools/perf/jvmti/Build +++ b/tools/perf/jvmti/Build @@ -2,7 +2,7 @@ jvmti-y += libjvmti.o jvmti-y += jvmti_agent.o # For strlcpy -jvmti-y += libstring.o +jvmti-y += libstring.o libctype.o CFLAGS_jvmti = -fPIC -DPIC -I$(JDIR)/include -I$(JDIR)/include/linux CFLAGS_REMOVE_jvmti = -Wmissing-declarations @@ -15,3 +15,7 @@ CFLAGS_libstring.o += -Wno-unused-parameter -DETC_PERFCONFIG="BUILD_STR($(ETC_PE $(OUTPUT)jvmti/libstring.o: ../lib/string.c FORCE $(call rule_mkdir) $(call if_changed_dep,cc_o_c) + +$(OUTPUT)jvmti/libctype.o: ../lib/ctype.c FORCE + $(call rule_mkdir) + $(call if_changed_dep,cc_o_c) -- 2.21.0