On Sun, Sep 27, 2015 at 08:37:59PM +0200, Rabin Vincent wrote: > It's easy to cross-compile a minimal perf binary without any external > libraries (other than a C library of course) but if you want more of the > juicy features it quickly becomes harder. You need to either > cross-compile a bunch of libraries manually and send in the correct > paths or integrate the perf build into some external build system. > > In order to make it easier for people to qucikly get up and running with > a fairly full featured cross-compiled mainline perf, provide a > Makefile.deps which will download and build the required libraries, > which can then be used in a static build of perf: > > $ make ARCH=arm CROSS_COMPILE=arm-linux- -f Makefile.deps
Makefile.cross_compile or Makefile.cross might suit better Could you provide more details help/doc on how to use it and what it's actualy doing? > $ make ARCH=arm CROSS_COMPILE=arm-linux- LDFLAGS="-static" > > Auto-detecting system features: > ... dwarf: [ on ] > ... glibc: [ on ] > ... gtk2: [ OFF ] > ... libaudit: [ on ] > ... libbfd: [ on ] > ... libelf: [ on ] > ... libnuma: [ OFF ] > ... libperl: [ OFF ] > ... libpython: [ OFF ] > ... libslang: [ on ] > ... libunwind: [ on ] > ... libdw-dwarf-unwind: [ OFF ] > ... zlib: [ on ] > ... lzma: [ on ] > > Signed-off-by: Rabin Vincent <[email protected]> running the command from changelog failed on my setup, please check attached log jirka --- [jolsa@krava perf]$ make ARCH=arm CROSS_COMPILE=arm-linux- -f Makefile.deps mkdir -p dl && cd dl && wget -N https://people.redhat.com/sgrubb/audit/audit-2.4.4.tar.gz --2015-10-12 13:36:45-- https://people.redhat.com/sgrubb/audit/audit-2.4.4.tar.gz Resolving people.redhat.com (people.redhat.com)... 10.5.19.28 Connecting to people.redhat.com (people.redhat.com)|10.5.19.28|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 1004024 (980K) [application/x-gzip] Saving to: ‘audit-2.4.4.tar.gz’ audit-2.4.4.tar.gz 100%[=================================================================>] 980.49K 298KB/s in 3.3s 2015-10-12 13:36:50 (298 KB/s) - ‘audit-2.4.4.tar.gz’ saved [1004024/1004024] mkdir -p build-arm && tar xf dl/audit-2.4.4.tar.gz -C build-arm touch build-arm/audit-2.4.4/.extract cd build-arm/audit-2.4.4 && ./configure --host=arm-linux --prefix=/home/jolsa/kernel/linux-perf/tools/perf/deps-arm Configuring auditd checking build system type... x86_64-unknown-linux-gnu checking host system type... arm-unknown-linux-gnu checking target system type... arm-unknown-linux-gnu checking for a BSD-compatible install... /bin/install -c checking whether build environment is sane... yes checking for arm-linux-strip... no checking for strip... strip checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking how to print strings... printf checking for style of include used by make... GNU checking for arm-linux-gcc... arm-linux-gcc checking whether the C compiler works... no configure: error: in `/home/jolsa/kernel/linux-perf/tools/perf/build-arm/audit-2.4.4': configure: error: C compiler cannot create executables See `config.log' for more details Makefile.deps:77: recipe for target 'deps-arm/lib/.audit.install' failed make: *** [deps-arm/lib/.audit.install] Error 77 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

