summaryrefslogtreecommitdiffstats
path: root/Python/ceval.c
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2011-01-06 17:01:36 (GMT)
committerDavid Malcolm <dmalcolm@redhat.com>2011-01-06 17:01:36 (GMT)
commitf1397ad3999b9a12b47ecc17ba2c7b5bce0a9f2e (patch)
tree589ec01fa80e12aa3b86463a6de13ce2520cd86f /Python/ceval.c
parentecbb8dc17a00dccc1d6d7b0c5bf0b3400736775c (diff)
downloadcpython-f1397ad3999b9a12b47ecc17ba2c7b5bce0a9f2e.zip
cpython-f1397ad3999b9a12b47ecc17ba2c7b5bce0a9f2e.tar.gz
cpython-f1397ad3999b9a12b47ecc17ba2c7b5bce0a9f2e.tar.bz2
Issue #10655: Fix the build on PowerPC on Linux with GCC when building with
timestamp profiling (--with-tsc): the preprocessor test for the PowerPC support now looks for "__powerpc__" as well as "__ppc__": the latter seems to only be present on OS X; the former is the correct one for Linux with GCC.
Diffstat (limited to 'Python/ceval.c')
-rw-r--r--Python/ceval.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index 684c6c2..f6d4b0b 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -26,10 +26,11 @@
typedef unsigned long long uint64;
-#if defined(__ppc__) /* <- Don't know if this is the correct symbol; this
- section should work for GCC on any PowerPC
- platform, irrespective of OS.
- POWER? Who knows :-) */
+/* PowerPC suppport.
+ "__ppc__" appears to be the preprocessor definition to detect on OS X, whereas
+ "__powerpc__" appears to be the correct one for Linux with GCC
+*/
+#if defined(__ppc__) || defined (__powerpc__)
#define READ_TIMESTAMP(var) ppc_getcounter(&var)