[igt-dev] [PATCH v3 4/7] lib/igt_halffloat.c: Fix musl/uclibc build
Bernd Kuhls
bernd at kuhls.net
Tue Oct 31 19:44:36 UTC 2023
Hi Kamil,
Am 31.10.23 um 19:45 schrieb Kamil Konieczny:
> Hi Bernd,
> On 2023-10-30 at 20:58:06 +0100, Bernd Kuhls wrote:
>> From: Stefano Ragni <st3r4g at protonmail.com>
>>
>> Original patch was added to void-linux:
>> https://github.com/void-linux/void-packages/commit/ddfc1f66a0c571b420303c33aed29fd38ace4fc7
>>
>> Fixes build error:
>> ../lib/igt_halffloat.c:205:6: error: ‘ifunc’ is not supported on this target
>> 205 | void igt_float_to_half(const float *f, uint16_t *h, unsigned int num)
>>
>> ../lib/igt_halffloat.c:216:6: error: ‘ifunc’ is not supported on this target
>> 216 | void igt_half_to_float(const uint16_t *h, float *f, unsigned int num)
>
> Hmm, now I am reading this a second time and have question:
> for what architecture are you compiling this?
I used various versions of gcc, and only gcc, originally tested on
x86_64 with musl libc but the error appeared with uclibc toolchains as
well and on all the other hardware archs buildroot supports:
https://git.buildroot.net/buildroot/tree/support/config-fragments/autobuild
> It would be better to check in build.meson for GCC support
> and add checks in meson for:
I will have a look into it but this will take some time due to lack of
experience with the meson build system on my part.
> #if defined(__x86_64__) && !defined(__clang__) && defined(__GCC_HAVE_IFUNC_ATTRIBUTE)
>
> or is it both gcc and glibc? Do you have other archs for which this
> is supported?
See above, the patch fixed the build on all hardware archs buildroot
supports with gcc being the only compiler used, no clang/llvm etc.
Regards, Bernd
More information about the igt-dev
mailing list