mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: tip-bot for Sudeep Holla <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: jolsa@kernel.org, keescook@chromium.org, mingo@kernel.org,
	peterz@infradead.org, Sudeep.Holla@arm.com, tglx@linutronix.de,
	alexander.shishkin@linux.intel.com, elena.reshetova@intel.com,
	acme@redhat.com, wangnan0@huawei.com, davidcc@google.com,
	eranian@google.com, pjt@google.com, linux-kernel@vger.kernel.org,
	sudeep.holla@arm.com, hpa@zytor.com
Subject: [tip:perf/core] perf jvmti: Fix linker error when libelf config is disabled
Date: Wed, 26 Jul 2017 10:23:02 -0700	[thread overview]
Message-ID: <tip-5d90faf45427dd76fadbe7a4dc4fce3b6f87b550@git.kernel.org> (raw)
In-Reply-To: <20170719011839.99399-5-davidcc@google.com>

Commit-ID:  5d90faf45427dd76fadbe7a4dc4fce3b6f87b550
Gitweb:     http://git.kernel.org/tip/5d90faf45427dd76fadbe7a4dc4fce3b6f87b550
Author:     Sudeep Holla <Sudeep.Holla@arm.com>
AuthorDate: Tue, 18 Jul 2017 18:18:39 -0700
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Tue, 25 Jul 2017 11:23:53 -0300

perf jvmti: Fix linker error when libelf config is disabled

When libelf is disabled in the configuration, we get the following
linker error:

  LINK     libperf-jvmti.so
  ld: cannot find -lelf
  Makefile.perf:515: recipe for target 'libperf-jvmti.so' failed

Jiri pointed out that both librt and libelf are not really required. So
this patch fixes the linker error by getting rid of unwanted libraries
in the linker stage.

Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
Acked-by: David Carrillo-Cisneros <davidcc@google.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Elena Reshetova <elena.reshetova@intel.com>
Cc: Kees Kook <keescook@chromium.org>
Cc: Paul Turner <pjt@google.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Sudeep Holla <sudeep.holla@arm.com>
Cc: Wang Nan <wangnan0@huawei.com>
Fixes: 209045adc2bb ("perf tools: add JVMTI agent library")
Link: http://lkml.kernel.org/r/20170719011839.99399-5-davidcc@google.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/Makefile.perf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index 100a6c1..d66f90e 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -518,7 +518,7 @@ $(LIBJVMTI_IN): FORCE
 	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=jvmti obj=jvmti
 
 $(OUTPUT)$(LIBJVMTI): $(LIBJVMTI_IN)
-	$(QUIET_LINK)$(CC) -shared -Wl,-soname -Wl,$(LIBJVMTI) -o $@ $< -lelf -lrt
+	$(QUIET_LINK)$(CC) -shared -Wl,-soname -Wl,$(LIBJVMTI) -o $@ $<
 endif
 
 $(patsubst perf-%,%.o,$(PROGRAMS)): $(wildcard */*.h)

  reply	other threads:[~2017-07-26 17:27 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-19  1:18 [PATCH 0/4] Resubmitted forgotten patches David Carrillo-Cisneros
2017-07-19  1:18 ` [PATCH 1/4] perf tool cgroup: Initialize cgroup refcnt with refcount_set David Carrillo-Cisneros
2017-07-21 16:55   ` Arnaldo Carvalho de Melo
2017-07-19  1:18 ` [PATCH 2/4] perf tools: Add EXCLUDE_EXTLIBS and EXTRA_PERFLIBS to makefile David Carrillo-Cisneros
2017-07-26 17:22   ` [tip:perf/core] " tip-bot for David Carrillo-Cisneros
2017-07-19  1:18 ` [PATCH 3/4] perf annotate: Process tracing data in pipe mode David Carrillo-Cisneros
2017-07-26 17:22   ` [tip:perf/core] " tip-bot for David Carrillo-Cisneros
2017-07-19  1:18 ` [PATCH 4/4] tools: perf: Fix linker error when libelf config is disabled David Carrillo-Cisneros
2017-07-26 17:23   ` tip-bot for Sudeep Holla [this message]
2017-07-19  8:45 ` [PATCH 0/4] Resubmitted forgotten patches Jiri Olsa
2017-07-21 17:00 ` Arnaldo Carvalho de Melo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tip-5d90faf45427dd76fadbe7a4dc4fce3b6f87b550@git.kernel.org \
    --to=tipbot@zytor.com \
    --cc=Sudeep.Holla@arm.com \
    --cc=acme@redhat.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=davidcc@google.com \
    --cc=elena.reshetova@intel.com \
    --cc=eranian@google.com \
    --cc=hpa@zytor.com \
    --cc=jolsa@kernel.org \
    --cc=keescook@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=pjt@google.com \
    --cc=tglx@linutronix.de \
    --cc=wangnan0@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome