perf tools: Fix linking errors with --as-needed flag
authorTom Zanussi <tzanussi@gmail.com>
Tue, 24 Aug 2010 05:23:50 +0000 (00:23 -0500)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 25 Aug 2010 20:35:21 +0000 (17:35 -0300)
commitf2481f3df4521e731da36afe7f0fe19a5c93e46d
tree2fd10a0ff129bf4e6e1650832774f1b257959d7a
parent90f18e63fbd005133624bf18a5e8b75c92e90f4d
perf tools: Fix linking errors with --as-needed flag

External shared libraries should never be appended to the LDFLAGS as this
messes the linking order. As EXTLIBS collects those libraries, it seems that
perl and python libraries  should also be appended to EXTLIBS.

Also fix the broken linking order.

This is a refresh of a patch by Ozan Çağlayan and improved by both Tom Zanussi
and Kirill A. Shutemov.

Cc: Ozan Çağlayan <ozan@pardus.org.tr>
Tested-by: Kirill A. Shutemov <kirill@shutemov.name>
Tested-by: Tom Zanussi <tzanussi@gmail.com>
LKML-Reference: <1282627430.28324.8.camel@tropicana>
Signed-off-by: Tom Zanussi <tzanussi@gmail.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/Makefile