* [PATCH] perf tools: Fix bfd dependency libraries detection
@ 2014-04-28 9:22 Jiri Olsa
2014-04-28 15:01 ` David Ahern
2014-05-01 6:32 ` [tip:perf/core] " tip-bot for Jiri Olsa
0 siblings, 2 replies; 7+ messages in thread
From: Jiri Olsa @ 2014-04-28 9:22 UTC (permalink / raw)
To: linux-kernel
Cc: Jiri Olsa, Arnaldo Carvalho de Melo, Corey Ashford, David Ahern,
Frederic Weisbecker, Ingo Molnar, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Jiri Olsa
From: Jiri Olsa <jolsa@redhat.com>
There's false assumption in the library detection code
assuming -liberty and -lz are always present once bfd
is detected. The fails on Ubuntu (14.04) as reported
by Ingo.
Forcing the bdf dependency libraries detection any
time bfd library is detected.
Reported-by: Ingo Molnar <mingo@kernel.org>
Tested-by: Ingo Molnar <mingo@kernel.org>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/perf/config/Makefile | 34 +++++++++++++++++++++++-----------
1 file changed, 23 insertions(+), 11 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index a71fb39..a57d59e 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -194,7 +194,10 @@ VF_FEATURE_TESTS = \
stackprotector-all \
timerfd \
libunwind-debug-frame \
- bionic
+ bionic \
+ liberty \
+ liberty-z \
+ cplus-demangle
# Set FEATURE_CHECK_(C|LD)FLAGS-all for all CORE_FEATURE_TESTS features.
# If in the future we need per-feature checks/flags for features not
@@ -512,7 +515,21 @@ else
endif
ifeq ($(feature-libbfd), 1)
- EXTLIBS += -lbfd -lz -liberty
+ EXTLIBS += -lbfd
+
+ # call all detections now so we get correct
+ # status in VF output
+ $(call feature_check,liberty)
+ $(call feature_check,liberty-z)
+ $(call feature_check,cplus-demangle)
+
+ ifeq ($(feature-liberty), 1)
+ EXTLIBS += -liberty
+ else
+ ifeq ($(feature-liberty-z), 1)
+ EXTLIBS += -liberty -lz
+ endif
+ endif
endif
ifdef NO_DEMANGLE
@@ -523,15 +540,10 @@ else
CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT
else
ifneq ($(feature-libbfd), 1)
- $(call feature_check,liberty)
- ifeq ($(feature-liberty), 1)
- EXTLIBS += -lbfd -liberty
- else
- $(call feature_check,liberty-z)
- ifeq ($(feature-liberty-z), 1)
- EXTLIBS += -lbfd -liberty -lz
- else
- $(call feature_check,cplus-demangle)
+ ifneq ($(feature-liberty), 1)
+ ifneq ($(feature-liberty-z), 1)
+ # we dont have neither HAVE_CPLUS_DEMANGLE_SUPPORT
+ # or any of 'bfd iberty z' trinity
ifeq ($(feature-cplus-demangle), 1)
EXTLIBS += -liberty
CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT
--
1.8.3.1
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH] perf tools: Fix bfd dependency libraries detection
2014-04-28 9:22 [PATCH] perf tools: Fix bfd dependency libraries detection Jiri Olsa
@ 2014-04-28 15:01 ` David Ahern
2014-04-28 15:17 ` Jiri Olsa
2014-05-01 6:32 ` [tip:perf/core] " tip-bot for Jiri Olsa
1 sibling, 1 reply; 7+ messages in thread
From: David Ahern @ 2014-04-28 15:01 UTC (permalink / raw)
To: Jiri Olsa, linux-kernel
Cc: Jiri Olsa, Arnaldo Carvalho de Melo, Corey Ashford,
Frederic Weisbecker, Ingo Molnar, Namhyung Kim, Paul Mackerras,
Peter Zijlstra
On 4/28/14, 3:22 AM, Jiri Olsa wrote:
> From: Jiri Olsa <jolsa@redhat.com>
>
> There's false assumption in the library detection code
> assuming -liberty and -lz are always present once bfd
> is detected. The fails on Ubuntu (14.04) as reported
> by Ingo.
>
> Forcing the bdf dependency libraries detection any
> time bfd library is detected.
Have you tried static builds? I need to do those occasionally and I
always have to muck around with the Makefiles to get it to succeed --
something with the -liberty and bfd checks.
>
> Reported-by: Ingo Molnar <mingo@kernel.org>
> Tested-by: Ingo Molnar <mingo@kernel.org>
> Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
> Cc: David Ahern <dsahern@gmail.com>
> Cc: Frederic Weisbecker <fweisbec@gmail.com>
> Cc: Ingo Molnar <mingo@kernel.org>
> Cc: Namhyung Kim <namhyung@kernel.org>
> Cc: Paul Mackerras <paulus@samba.org>
> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
> Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> ---
> tools/perf/config/Makefile | 34 +++++++++++++++++++++++-----------
> 1 file changed, 23 insertions(+), 11 deletions(-)
>
> diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
> index a71fb39..a57d59e 100644
> --- a/tools/perf/config/Makefile
> +++ b/tools/perf/config/Makefile
> @@ -194,7 +194,10 @@ VF_FEATURE_TESTS = \
> stackprotector-all \
> timerfd \
> libunwind-debug-frame \
> - bionic
> + bionic \
> + liberty \
> + liberty-z \
> + cplus-demangle
>
> # Set FEATURE_CHECK_(C|LD)FLAGS-all for all CORE_FEATURE_TESTS features.
> # If in the future we need per-feature checks/flags for features not
> @@ -512,7 +515,21 @@ else
> endif
>
> ifeq ($(feature-libbfd), 1)
> - EXTLIBS += -lbfd -lz -liberty
> + EXTLIBS += -lbfd
> +
> + # call all detections now so we get correct
> + # status in VF output
Are you folding the "VF" into V?
David
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] perf tools: Fix bfd dependency libraries detection
2014-04-28 15:01 ` David Ahern
@ 2014-04-28 15:17 ` Jiri Olsa
2014-04-28 15:23 ` David Ahern
2014-04-29 6:44 ` Ingo Molnar
0 siblings, 2 replies; 7+ messages in thread
From: Jiri Olsa @ 2014-04-28 15:17 UTC (permalink / raw)
To: David Ahern
Cc: Jiri Olsa, linux-kernel, Arnaldo Carvalho de Melo, Corey Ashford,
Frederic Weisbecker, Ingo Molnar, Namhyung Kim, Paul Mackerras,
Peter Zijlstra
On Mon, Apr 28, 2014 at 09:01:57AM -0600, David Ahern wrote:
> On 4/28/14, 3:22 AM, Jiri Olsa wrote:
> >From: Jiri Olsa <jolsa@redhat.com>
> >
> >There's false assumption in the library detection code
> >assuming -liberty and -lz are always present once bfd
> >is detected. The fails on Ubuntu (14.04) as reported
> >by Ingo.
> >
> >Forcing the bdf dependency libraries detection any
> >time bfd library is detected.
>
> Have you tried static builds? I need to do those occasionally and I
> always have to muck around with the Makefiles to get it to succeed
> -- something with the -liberty and bfd checks.
hm, I just tried and even without of the fix I wasn't able
to do static build.. so far I ended up with:
---
$ make LDFLAGS=-static NO_LIBUNWIND=1 NO_GTK2=1 JOBS=1
...
SUBDIR /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/
LINK perf
/bin/ld: cannot find -lelf
/home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/libtraceevent.a(event-plugin.o): In function `load_plugin':
/home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/event-plugin.c:60: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/bin/ld: cannot find -lelf
/bin/ld: cannot find -ldw
/bin/ld: cannot find -laudit
/bin/ld: cannot find -lslang
/bin/ld: cannot find -lperl
libperf.a(target.o): In function `target__parse_uid':
/home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:79: warning: Using 'getpwnam_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:91: warning: Using 'getpwuid_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/lib/gcc/x86_64-redhat-linux/4.8.2/../../../../lib64/libpthread.a(libpthread.o): In function `sem_open':
(.text+0x67eb): warning: the use of `mktemp' is dangerous, better use `mkstemp'
/bin/ld: cannot find -lpython2.7
/bin/ld: cannot find -lz
/bin/ld: cannot find -lnuma
collect2: error: ld returned 1 exit status
make[1]: *** [perf] Error 1
make: *** [all] Error 2
---
Any hints what you did to make it pass?
Let's fix it and put test for this in tests/make suite ;-)
thanks,
jirka
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] perf tools: Fix bfd dependency libraries detection
2014-04-28 15:17 ` Jiri Olsa
@ 2014-04-28 15:23 ` David Ahern
2014-04-29 8:12 ` Jiri Olsa
2014-04-29 6:44 ` Ingo Molnar
1 sibling, 1 reply; 7+ messages in thread
From: David Ahern @ 2014-04-28 15:23 UTC (permalink / raw)
To: Jiri Olsa
Cc: Jiri Olsa, linux-kernel, Arnaldo Carvalho de Melo, Corey Ashford,
Frederic Weisbecker, Ingo Molnar, Namhyung Kim, Paul Mackerras,
Peter Zijlstra
On 4/28/14, 9:17 AM, Jiri Olsa wrote:
> On Mon, Apr 28, 2014 at 09:01:57AM -0600, David Ahern wrote:
>> On 4/28/14, 3:22 AM, Jiri Olsa wrote:
>>> From: Jiri Olsa <jolsa@redhat.com>
>>>
>>> There's false assumption in the library detection code
>>> assuming -liberty and -lz are always present once bfd
>>> is detected. The fails on Ubuntu (14.04) as reported
>>> by Ingo.
>>>
>>> Forcing the bdf dependency libraries detection any
>>> time bfd library is detected.
>>
>> Have you tried static builds? I need to do those occasionally and I
>> always have to muck around with the Makefiles to get it to succeed
>> -- something with the -liberty and bfd checks.
>
> hm, I just tried and even without of the fix I wasn't able
> to do static build.. so far I ended up with:
>
> ---
> $ make LDFLAGS=-static NO_LIBUNWIND=1 NO_GTK2=1 JOBS=1
> ...
>
> SUBDIR /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/
> LINK perf
> /bin/ld: cannot find -lelf
> /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/libtraceevent.a(event-plugin.o): In function `load_plugin':
> /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/event-plugin.c:60: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /bin/ld: cannot find -lelf
> /bin/ld: cannot find -ldw
> /bin/ld: cannot find -laudit
> /bin/ld: cannot find -lslang
> /bin/ld: cannot find -lperl
> libperf.a(target.o): In function `target__parse_uid':
> /home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:79: warning: Using 'getpwnam_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:91: warning: Using 'getpwuid_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /usr/lib/gcc/x86_64-redhat-linux/4.8.2/../../../../lib64/libpthread.a(libpthread.o): In function `sem_open':
> (.text+0x67eb): warning: the use of `mktemp' is dangerous, better use `mkstemp'
> /bin/ld: cannot find -lpython2.7
> /bin/ld: cannot find -lz
> /bin/ld: cannot find -lnuma
> collect2: error: ld returned 1 exit status
> make[1]: *** [perf] Error 1
> make: *** [all] Error 2
> ---
>
> Any hints what you did to make it pass?
> Let's fix it and put test for this in tests/make suite ;-)
# rpm -qa | grep static
glibc-static-2.14.90-24.fc16.9.x86_64
audit-libs-static-2.2.1-1.fc16.x86_64
elfutils-libelf-devel-static-0.154-2.fc16.x86_64
zlib-static-1.2.5-7.fc16.x86_64
# make O=/tmp/junk LDFLAGS=-static
David
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] perf tools: Fix bfd dependency libraries detection
2014-04-28 15:23 ` David Ahern
@ 2014-04-29 8:12 ` Jiri Olsa
0 siblings, 0 replies; 7+ messages in thread
From: Jiri Olsa @ 2014-04-29 8:12 UTC (permalink / raw)
To: David Ahern
Cc: Jiri Olsa, linux-kernel, Arnaldo Carvalho de Melo, Corey Ashford,
Frederic Weisbecker, Ingo Molnar, Namhyung Kim, Paul Mackerras,
Peter Zijlstra
On Mon, Apr 28, 2014 at 09:23:04AM -0600, David Ahern wrote:
> On 4/28/14, 9:17 AM, Jiri Olsa wrote:
> >On Mon, Apr 28, 2014 at 09:01:57AM -0600, David Ahern wrote:
> >>On 4/28/14, 3:22 AM, Jiri Olsa wrote:
> >>>From: Jiri Olsa <jolsa@redhat.com>
> >>>
> >>>There's false assumption in the library detection code
> >>>assuming -liberty and -lz are always present once bfd
> >>>is detected. The fails on Ubuntu (14.04) as reported
> >>>by Ingo.
> >>>
> >>>Forcing the bdf dependency libraries detection any
> >>>time bfd library is detected.
> >>
> >>Have you tried static builds? I need to do those occasionally and I
> >>always have to muck around with the Makefiles to get it to succeed
> >>-- something with the -liberty and bfd checks.
> >
> >hm, I just tried and even without of the fix I wasn't able
> >to do static build.. so far I ended up with:
> >
> >---
> > $ make LDFLAGS=-static NO_LIBUNWIND=1 NO_GTK2=1 JOBS=1
> > ...
> >
> > SUBDIR /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/
> > LINK perf
> >/bin/ld: cannot find -lelf
> >/home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/libtraceevent.a(event-plugin.o): In function `load_plugin':
> >/home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/event-plugin.c:60: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> >/bin/ld: cannot find -lelf
> >/bin/ld: cannot find -ldw
> >/bin/ld: cannot find -laudit
> >/bin/ld: cannot find -lslang
> >/bin/ld: cannot find -lperl
> >libperf.a(target.o): In function `target__parse_uid':
> >/home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:79: warning: Using 'getpwnam_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> >/home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:91: warning: Using 'getpwuid_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> >/usr/lib/gcc/x86_64-redhat-linux/4.8.2/../../../../lib64/libpthread.a(libpthread.o): In function `sem_open':
> >(.text+0x67eb): warning: the use of `mktemp' is dangerous, better use `mkstemp'
> >/bin/ld: cannot find -lpython2.7
> >/bin/ld: cannot find -lz
> >/bin/ld: cannot find -lnuma
> >collect2: error: ld returned 1 exit status
> >make[1]: *** [perf] Error 1
> >make: *** [all] Error 2
> >---
> >
> >Any hints what you did to make it pass?
> >Let's fix it and put test for this in tests/make suite ;-)
>
> # rpm -qa | grep static
> glibc-static-2.14.90-24.fc16.9.x86_64
> audit-libs-static-2.2.1-1.fc16.x86_64
> elfutils-libelf-devel-static-0.154-2.fc16.x86_64
> zlib-static-1.2.5-7.fc16.x86_64
>
> # make O=/tmp/junk LDFLAGS=-static
hum.. I must have some bad tree state ;-) I can do it now jsut with:
$ make LDFLAGS=-static
only with glibc-static package
thanks,
jirka
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] perf tools: Fix bfd dependency libraries detection
2014-04-28 15:17 ` Jiri Olsa
2014-04-28 15:23 ` David Ahern
@ 2014-04-29 6:44 ` Ingo Molnar
1 sibling, 0 replies; 7+ messages in thread
From: Ingo Molnar @ 2014-04-29 6:44 UTC (permalink / raw)
To: Jiri Olsa
Cc: David Ahern, Jiri Olsa, linux-kernel, Arnaldo Carvalho de Melo,
Corey Ashford, Frederic Weisbecker, Namhyung Kim, Paul Mackerras,
Peter Zijlstra
* Jiri Olsa <jolsa@redhat.com> wrote:
> On Mon, Apr 28, 2014 at 09:01:57AM -0600, David Ahern wrote:
> > On 4/28/14, 3:22 AM, Jiri Olsa wrote:
> > >From: Jiri Olsa <jolsa@redhat.com>
> > >
> > >There's false assumption in the library detection code
> > >assuming -liberty and -lz are always present once bfd
> > >is detected. The fails on Ubuntu (14.04) as reported
> > >by Ingo.
> > >
> > >Forcing the bdf dependency libraries detection any
> > >time bfd library is detected.
> >
> > Have you tried static builds? I need to do those occasionally and I
> > always have to muck around with the Makefiles to get it to succeed
> > -- something with the -liberty and bfd checks.
>
> hm, I just tried and even without of the fix I wasn't able
> to do static build.. so far I ended up with:
>
> ---
> $ make LDFLAGS=-static NO_LIBUNWIND=1 NO_GTK2=1 JOBS=1
> ...
>
> SUBDIR /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/
> LINK perf
> /bin/ld: cannot find -lelf
> /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/libtraceevent.a(event-plugin.o): In function `load_plugin':
> /home/jolsa/kernel.org/linux-perf/tools/lib/traceevent/event-plugin.c:60: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /bin/ld: cannot find -lelf
> /bin/ld: cannot find -ldw
> /bin/ld: cannot find -laudit
> /bin/ld: cannot find -lslang
> /bin/ld: cannot find -lperl
> libperf.a(target.o): In function `target__parse_uid':
> /home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:79: warning: Using 'getpwnam_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /home/jolsa/kernel.org/linux-perf/tools/perf/util/target.c:91: warning: Using 'getpwuid_r' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
> /usr/lib/gcc/x86_64-redhat-linux/4.8.2/../../../../lib64/libpthread.a(libpthread.o): In function `sem_open':
> (.text+0x67eb): warning: the use of `mktemp' is dangerous, better use `mkstemp'
> /bin/ld: cannot find -lpython2.7
> /bin/ld: cannot find -lz
> /bin/ld: cannot find -lnuma
> collect2: error: ld returned 1 exit status
> make[1]: *** [perf] Error 1
> make: *** [all] Error 2
> ---
>
> Any hints what you did to make it pass?
> Let's fix it and put test for this in tests/make suite ;-)
/me agrees violently.
I try static builds every now and then, to be able to test perf on
ancient systems with userspace that doesn't build perf anymore.
Thanks,
Ingo
^ permalink raw reply [flat|nested] 7+ messages in thread
* [tip:perf/core] perf tools: Fix bfd dependency libraries detection
2014-04-28 9:22 [PATCH] perf tools: Fix bfd dependency libraries detection Jiri Olsa
2014-04-28 15:01 ` David Ahern
@ 2014-05-01 6:32 ` tip-bot for Jiri Olsa
1 sibling, 0 replies; 7+ messages in thread
From: tip-bot for Jiri Olsa @ 2014-05-01 6:32 UTC (permalink / raw)
To: linux-tip-commits
Cc: linux-kernel, paulus, hpa, mingo, jolsa, a.p.zijlstra, acme,
namhyung, fweisbec, dsahern, tglx, cjashfor
Commit-ID: 2cf9040714f3e63f94935c9f1ed4e5bc54265ddb
Gitweb: http://git.kernel.org/tip/2cf9040714f3e63f94935c9f1ed4e5bc54265ddb
Author: Jiri Olsa <jolsa@kernel.org>
AuthorDate: Wed, 23 Apr 2014 16:53:25 +0200
Committer: Jiri Olsa <jolsa@kernel.org>
CommitDate: Wed, 30 Apr 2014 16:48:50 +0200
perf tools: Fix bfd dependency libraries detection
There's false assumption in the library detection code
assuming -liberty and -lz are always present once bfd
is detected. The fails on Ubuntu (14.04) as reported
by Ingo.
Forcing the bdf dependency libraries detection any
time bfd library is detected.
Reported-by: Ingo Molnar <mingo@kernel.org>
Tested-by: Ingo Molnar <mingo@kernel.org>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1398676935-6615-1-git-send-email-jolsa@kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/perf/config/Makefile | 34 +++++++++++++++++++++++-----------
1 file changed, 23 insertions(+), 11 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index a71fb39..a57d59e 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -194,7 +194,10 @@ VF_FEATURE_TESTS = \
stackprotector-all \
timerfd \
libunwind-debug-frame \
- bionic
+ bionic \
+ liberty \
+ liberty-z \
+ cplus-demangle
# Set FEATURE_CHECK_(C|LD)FLAGS-all for all CORE_FEATURE_TESTS features.
# If in the future we need per-feature checks/flags for features not
@@ -512,7 +515,21 @@ else
endif
ifeq ($(feature-libbfd), 1)
- EXTLIBS += -lbfd -lz -liberty
+ EXTLIBS += -lbfd
+
+ # call all detections now so we get correct
+ # status in VF output
+ $(call feature_check,liberty)
+ $(call feature_check,liberty-z)
+ $(call feature_check,cplus-demangle)
+
+ ifeq ($(feature-liberty), 1)
+ EXTLIBS += -liberty
+ else
+ ifeq ($(feature-liberty-z), 1)
+ EXTLIBS += -liberty -lz
+ endif
+ endif
endif
ifdef NO_DEMANGLE
@@ -523,15 +540,10 @@ else
CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT
else
ifneq ($(feature-libbfd), 1)
- $(call feature_check,liberty)
- ifeq ($(feature-liberty), 1)
- EXTLIBS += -lbfd -liberty
- else
- $(call feature_check,liberty-z)
- ifeq ($(feature-liberty-z), 1)
- EXTLIBS += -lbfd -liberty -lz
- else
- $(call feature_check,cplus-demangle)
+ ifneq ($(feature-liberty), 1)
+ ifneq ($(feature-liberty-z), 1)
+ # we dont have neither HAVE_CPLUS_DEMANGLE_SUPPORT
+ # or any of 'bfd iberty z' trinity
ifeq ($(feature-cplus-demangle), 1)
EXTLIBS += -liberty
CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2014-05-01 6:32 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-28 9:22 [PATCH] perf tools: Fix bfd dependency libraries detection Jiri Olsa
2014-04-28 15:01 ` David Ahern
2014-04-28 15:17 ` Jiri Olsa
2014-04-28 15:23 ` David Ahern
2014-04-29 8:12 ` Jiri Olsa
2014-04-29 6:44 ` Ingo Molnar
2014-05-01 6:32 ` [tip:perf/core] " tip-bot for Jiri Olsa
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.