[OpenWrt-Devel] mfloat-abi=soft

Boris Krasnovskiy borkra at gmail.com
Sat Apr 13 18:49:18 EDT 2019


Hello Everybody,


I checked how Yocto solved this issue, and they added —disable-neon configure flag when neon is not available. We can do the same in the Makefile. Below is the link to Yocto recipe.

http://cgit.openembedded.org/meta-openembedded/tree/meta-oe/recipes-crypto/botan/botan_2.9.0.bb

Thank you,
Boris Krasnovskiy

> On Apr 13, 2019, at 5:54 PM, Christian Lamparter <chunkeey at gmail.com> wrote:
> 
>> On Saturday, April 13, 2019 11:08:38 PM CEST Rosen Penev wrote:
>>> On Sat, Apr 13, 2019 at 7:07 AM Christian Lamparter <chunkeey at gmail.com> wrote:
>>> 
>>> Cc'd: BangLang Huang <banglang.huang at foxmail.com>
>>> 
>>>> On Saturday, April 6, 2019 10:35:48 PM CEST Rosen Penev wrote:
>>>> According to rules.mk, -mfloat-abi=soft is used. This is causing build
>>>> failures with the botan library:
>>>> 
>>>> https://downloads.openwrt.org/snapshots/faillogs/armeb_xscale/packages/botan/compile.txt
>>>> 
>>>> Is it sensical to change the default to softfp, as the error message suggests?
>>> That's the error:
>>> 
>>> #error "NEON intrinsics not available with the soft-float ABI.  Please use -mfloat-abi=softp or -mfloat-abi=hard"
>>> 
>>> I think the best option would be to tell the package to disable neon in this
>>> case, just like ffmpeg is doing already. If you can test:
>>> 
>>> ifeq ($(CONFIG_SOFT_FLOAT),y)
>>> CONFIGURE_ARGS += --disable-neon
>>> endif
>> That could work. I find it interesting that it's only the old ARM
>> architectures that are getting compilation errors.
> Ah, that's because ARM's toolchain was recently changed in order to fix
> the gcc 8.x error due to conflicting march vs mcpu compiler flags.
> 
> See PR 1913 for the gory details: https://github.com/openwrt/openwrt/pull/1913
> Before that commit, botan would probably compile, but the binaries
> may not work on the target system (didn't test so take this with a
> load of salt).
> 
> But if you look on the botan's github issue tracker, you'll find that
> someone reported a similar problem with powerpc + altivec vs. SPE:
> <https://github.com/randombit/botan/issues/1820>
> 
> Which when you think about it might become obvious. The ahead-of-time
> autodetection employed by botan does not really work when everything
> is cross-compiled. But this has been the bane of OpenWrt and several
> other Buildroot and non-buildroot projects from the beginning, so there
> are ways to mitigate these problems efficiently.
> 
> Cheers,
> Christian
> 
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/openwrt-devel/attachments/20190413/13aed614/attachment.htm>
-------------- next part --------------
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list