You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by al...@apache.org on 2023/01/13 19:45:31 UTC

[kudu] branch master updated: Replaces the preprocessor trigger ARCH_POWERPC64 with __powerpc64__

This is an automated email from the ASF dual-hosted git repository.

alexey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git


The following commit(s) were added to refs/heads/master by this push:
     new 1683f00ae Replaces the preprocessor trigger ARCH_POWERPC64 with __powerpc64__
1683f00ae is described below

commit 1683f00aed76f3cba705f7091ddfc6322c0863a2
Author: harinreddy <hn...@us.ibm.com>
AuthorDate: Sun Sep 18 12:10:01 2022 -0500

    Replaces the preprocessor trigger ARCH_POWERPC64 with __powerpc64__
    
    ARCH_POWERPC64 is not a compiler preprocessor trigger
    for both gcc and clang. This patch replaces ARCH_POWERPC64
    with a preprocessor trigger __powerpc64__
    
    This eliminates the requirement to set a definition in CMAKE_CXX_FLAGS.
         Changes to be committed:
                modified:   src/kudu/gutil/atomicops-internals-powerpc.h
                modified:   src/kudu/gutil/atomicops.h
    ~
    
    Change-Id: I3e81899fb73d9e9362dba242e43fdec734c638c6
    Reviewed-on: http://gerrit.cloudera.org:8080/19004
    Tested-by: Alexey Serbin <al...@apache.org>
    Reviewed-by: Alexey Serbin <al...@apache.org>
---
 src/kudu/gutil/atomicops-internals-powerpc.h | 2 +-
 src/kudu/gutil/atomicops.h                   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/kudu/gutil/atomicops-internals-powerpc.h b/src/kudu/gutil/atomicops-internals-powerpc.h
index 18eaa1fc8..68ca3ffad 100644
--- a/src/kudu/gutil/atomicops-internals-powerpc.h
+++ b/src/kudu/gutil/atomicops-internals-powerpc.h
@@ -39,7 +39,7 @@ typedef int32_t Atomic32;
 #define ATOMICOPS_COMPILER_BARRIER() __asm__ __volatile__("" : : : "memory")
 
 // 32-bit PowerPC is not supported yet.
-#ifndef ARCH_POWERPC64
+#ifndef __powerpc64__ 
 #error "Only PowerPC64 is supported"
 #endif
 
diff --git a/src/kudu/gutil/atomicops.h b/src/kudu/gutil/atomicops.h
index 39c20222e..f12d6ba89 100644
--- a/src/kudu/gutil/atomicops.h
+++ b/src/kudu/gutil/atomicops.h
@@ -80,7 +80,7 @@
 #include "kudu/gutil/auxiliary/atomicops-internals-arm-generic.h" // IWYU pragma: export
 #elif defined(__GNUC__) && (defined(__i386) || defined(__x86_64__))
 #include "kudu/gutil/atomicops-internals-x86.h" // IWYU pragma: export
-#elif defined(__GNUC__) && defined(ARCH_POWERPC64)
+#elif defined(__GNUC__) && defined(__powerpc64__)
 #include "kudu/gutil/atomicops-internals-powerpc.h" // IWYU pragma: export
 #elif defined(OS_WINDOWS)
 #include "kudu/gutil/auxiliary/atomicops-internals-windows.h" // IWYU pragma: export