Fix building for powerpc* targets with some compilers

Under some configurations, GCC didn't predefined macro 'powerpc' for
such a target. Use the guaranteed macro '__powerpc__' instead.

Reviewed-by: Tino Reichardt <milky-zfs@mcmilk.de>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: WHR <msl0000023508@gmail.com>
Closes #14631
This commit is contained in:
Low-power 2023-03-16 01:44:28 +08:00 committed by GitHub
parent b7bc334d13
commit c31bb934cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -31,7 +31,7 @@
#include <sys/types.h>
/* including <sys/auxv.h> clashes with AT_UID and others */
#if defined(__arm__) || defined(__aarch64__) || defined(powerpc)
#if defined(__arm__) || defined(__aarch64__) || defined(__powerpc__)
#if defined(__FreeBSD__)
#define AT_HWCAP 25
#define AT_HWCAP2 26