My system (uname --all)

Linux shyamdaramubtnb 3.2.0-23-generic #36-Ubuntu SMP Tue Apr 10 20:39:51 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

My target

ARM Cortex A7

I am in the process of cross compiling perf tools for ARM, but perf while compilation requires the elfutils package to read the VMLinux file later, can any one suggest me a way to cross compile elfutils

Downloaded package from here.

Currently I am following the below procedure:

$ aclocal
$ autoheader
$ autoconf
$ automake --add-missing
$ ./configure --host=arm-none-linux-gnueabi \
$ make
$ make install

but i stuck at the process of executing ./configure, which throws me an error of

./configure: line 5115: syntax error near unexpected token `zlib,ZLIB,z,gzdirect,gzip'
./configure: line 5115: `eu_ZIPLIB(zlib,ZLIB,z,gzdirect,gzip)'

What may be the reason ? Strange that I did not find a Makefile in the folder downloaded does configure is supposed to create a make file ?(I see files like Makefile.in, Makefile.am).

LATEST DEVELOPMENTS 1: i started following the link which has few hacks for my problems and trying to do the same as what i am trying

previously i faced some warnings which i ignored, and i understood they are the real cause of problems, on running aclocal i recieved an error saying

warning: macro AM_PO_SUBDIRS not found in library.

which were resolved by installing intltool and gettext

after running automake --add-missing i received an warning saying that

libdwfl/Makefile.am:73: ZLIB does not appear in AM_CONDITIONAL
libdwfl/Makefile.am:76: BZLIB does not appear in AM_CONDITIONAL
libdwfl/Makefile.am:79: LZMA does not appear in AM_CONDITIONAL
tests/Makefile.am:59: BIARCH does not appear in AM_CONDITIONAL
tests/Makefile.am:122: BIARCH does not appear in AM_CONDITIONAL
tests/Makefile.am:135: LZMA does not appear in AM_CONDITIONAL
tests/Makefile.am:139: ZLIB does not appear in AM_CONDITIONAL

so as suggested by the link i tried autoreconf -f -i and then automake --add-missing again which worked like charm

then i ran the ./configure as above which actually did not stop any where, provided i have also done few thinks like commenting parts of Makefile and backends/Makefile which involve in some script related to i386 and x86_64 which have solved my problem in building elfutils for ARM !

Can anyone explain what actually is happening in the above steps ?

  • You may have an old version of the autotools. Did you check this ? – perror Aug 19 '15 at 7:03
  • please find the updated question – kakeh Aug 19 '15 at 8:55
  • Did you run a make CROSS_COMPILE=arm-none-linux-gnueabi- and sudo make CROSS_COMPILE=arm-none-linux-gnueabi- install after the ./configure ? Because, once you finished to configure your build-system, you just have to build the binaries through a make and, then, install the package through a make install (you need to be root, which explains the sudo). – perror Aug 19 '15 at 11:59
  • just after configuration , i just done sudo make and then sudo make install , my problem is solved my perf tool is now working thanks – kakeh Aug 19 '15 at 15:49

The autotools suite is a framework of scripts and tools to automate the settings and the compilation of a software package virtually on any type of system (in theory).

It is quite complex.

Usually, the first phase of it is to configure the build-system in order to check that everything that you need to compile the software is present on your system and, also, to know where it is (and in what version it is present).

Then, the build-system (based on Makefiles) is configured and ready to go.

You seems to stop at the configure phase because on some error internal to the configure script.

Note that the command you ran, previous to the configure script, are usually for developpers, they are probably needed because of the cross-compilation.

Finally, the error message seems to stop at the detection of the zip library (the script has the choice between the list display, as zip is a standard algorithm, it can just pick one of the lib, but it seems that it is not happy with the script it find).

I cannot tell much more as you did not specified more about your distribution and the context in which you are working.

  • please find the updated question – kakeh Aug 19 '15 at 8:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.