]> git.ipfire.org Git - thirdparty/xz.git/commit
sysdefs.h: Avoid <stdalign.h> even with C11 compilers
authorLasse Collin <lasse.collin@tukaani.org>
Sat, 29 Mar 2025 10:41:32 +0000 (12:41 +0200)
committerLasse Collin <lasse.collin@tukaani.org>
Sat, 29 Mar 2025 10:41:32 +0000 (12:41 +0200)
commit307c02ed698a69763ef1c9c0df4ff24727442118
tree215bacccd14b582b87e393337c36318962140396
parent7ce38b318339d6c01378a77585e08169ca3a604e
sysdefs.h: Avoid <stdalign.h> even with C11 compilers

Oracle Developer Studio 12.6 on Solaris 10 claims C11 support in
__STDC_VERSION__ and supports _Alignas. However, <stdalign.h> is missing.
We only need alignas, so define it to _Alignas with C11/C17 compilers.
If something included <stdalign.h> later, it shouldn't cause problems.

Thanks to Ihsan Dogan for reporting the issue and testing the fix.

Fixes: c0e7eaae8d6eef1e313c9d0da20ccf126ec61f38
src/common/sysdefs.h