Summary:ASTERISK-21006: unsupported host os "linux-gnueabihf"
Reporter:Christian Hesse (chesse)Labels:
Date Opened:2013-01-28 22:37:50.000-0600Date Closed:2013-01-30 11:47:59.000-0600
Versions:11.2.1 Frequency of
Environment:Raspberry Pi, Raspbian, Wheezy, hard-float ABI, Kernel 3.2.27+ #250 compiling as non-rootAttachments:( 0) linux-gnueabihf.patch
( 1) linux-gnueabihf-autoconf.patch
Description:Building Asterisk on Raspbian with hard-float support fails as it uses the string "linux-gnueabihf" rather than "linux-gnueabi" for host os.

In particular, this breaks after libasteriskssl.so.1 is made, because for the then called ldconfig the correct flag -n is missing.
Comments:By: Matt Jordan (mjordan) 2013-01-29 06:31:46.110-0600

It sounds like you already diagnosed this. Do you have a patch for the build system?

By: Christian Hesse (chesse) 2013-01-29 20:44:22.191-0600

Yes, I think I tracked it down. In file 'configure', changing line 4439 from




should do the trick. Maybe, the corresponding change should be done in configure.ac, too.

Patch: Well, err, I never had to create one so I'm not used to the procedure. I googled a bit which lead me to produce the file I attach. I'm not sure if it qualifies as a patch file. If you could hint me on a "supply a patch-howto", best an Asterisk specific one, I'd appreciate that.

Sorry for the inconvenience, I'm just trying to be helpful.

By: Christian Hesse (chesse) 2013-01-29 20:48:50.238-0600

Patch for file "configure" (Asterisk 11.2.1) to support host os "linux-gnueabihf"

By: Matt Jordan (mjordan) 2013-01-29 20:52:15.187-0600

It actually has to be done in configure.ac, as configure is generated from it. I'm guessing line 181 of configure.ac should be modified in a similar fashion.

By: Matt Jordan (mjordan) 2013-01-29 20:52:36.825-0600

If you can confirm that, I'll patch Asterisk tonight... :-)

By: Christian Hesse (chesse) 2013-01-29 21:56:28.936-0600

I checked. Getting the tarball and following the README instructions, I just call the supplied 'configure' file. So, "on my side" 'configure' is not generated from 'configure.ac' and I just patched 'configure' to fix things.

Going more into detail, I realized, that there is an inconsistency between 'configure.ac' and 'configure' in the tarball. The tarball 'configure' is apparently generated from a 'configure.ac' rev. 373229, while the tarball 'configure.ac' is rev. 375191.

Since I'm not aware of the reason and implications of this inconsistency and I just successfully patched the supplied and normally used 'configure' file, I cannot confirm the proposed change in line 181 of file 'configure.ac'. BUT: Your proposed modification seems _very_ reasonable.  

BTW: Do I have to do the "Sign a License Agreement"-thing?

By: Matt Jordan (mjordan) 2013-01-29 22:06:25.772-0600

To re-generate the configure script from configure.ac (and the various other autoconf scripts), run the {{bootstrap.sh}} script in the root directory of Asterisk.

And yes, code contributions can only be included if you sign a license contributor agreement. There's lots of interesting licensing problems if that isn't done, so we ask everyone to do so.

By: Christian Hesse (chesse) 2013-01-30 09:48:47.654-0600

Ok, doing more tests I now can confirm the following:

Starting with release tarball for Asterisk 11.2.1, doing 'bootstrap.sh', 'configure', 'make', build-process fails with following output:

  [CC] xml.c -> xml.o
  [CC] xmldoc.c -> xmldoc.o
  [CC] libasteriskssl.c -> libasteriskssl.o
  [LD] libasteriskssl.o -> libasteriskssl.so.1
/sbin/ldconfig: relative path `.' used to build cache
make[2]: *** [libasteriskssl.so.1] Error 1
make[1]: *** [main] Error 2
make[1]: Leaving directory `/home/pi/asterisk/asterisk-11.2.1'
make: *** [_cleantest_all] Error 2

Starting with release tarball for Asterisk 11.2.1, applying the attached patch, then doing 'bootstrap.sh' (!), 'configure', 'make', build-process succeeds.

License Agreement is signed by me and accepted by Digium.

One comment from my side: In my point of view, in a release tarball, 'configure.ac' and 'configure' should either be consistent (same revision), or there should be instructions in the README file, that running 'bootstrap.sh' is part of the installation process. I was not aware of the bootstrap-script, and now doing some research now I know what I'm looking for still gives me no hints that I should run this to install asterisk.

By: Christian Hesse (chesse) 2013-01-30 09:50:04.677-0600

Patch for file "configure.ac" (Asterisk 11.2.1) to support host os "linux-gnueabihf"

After that, bootstrap.sh must be executed