From 585cccd940f8b679a6b58a5e7605df2d3e8365bc Mon Sep 17 00:00:00 2001 From: Spencer Thomason Date: Thu, 19 May 2016 18:43:05 -0700 Subject: [PATCH] FS-9185: fix format ifdefs for Solaris SPARC Fix SWITCH_INT64_T_FMT and SWITCH_TIME_T_FMT definitions for Solaris/SPARC FS-9185 #resolve --- configure.ac | 2 ++ src/include/switch_platform.h | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index efe5473ab0..bfc55fa89e 100644 --- a/configure.ac +++ b/configure.ac @@ -1122,6 +1122,8 @@ elif test "$ac_cv_sizeof_long" = "8"; then case "$host" in *pc-solaris2*) ;; + sparc-*-solaris2*) + ;; *-solaris2*|*apple-darwin*|*-openbsd*) if test "$ac_cv_sizeof_long_long" = "8"; then int64_t_fmt='#define SWITCH_INT64_T_FMT "lld"' diff --git a/src/include/switch_platform.h b/src/include/switch_platform.h index 933c4d3688..962bf972b3 100644 --- a/src/include/switch_platform.h +++ b/src/include/switch_platform.h @@ -279,7 +279,7 @@ typedef intptr_t switch_ssize_t; #endif -#if defined(__sun__) && defined(__x86_64) +#if defined(__sun__) && (defined(__x86_64) || defined(__arch64__)) #define SWITCH_TIME_T_FMT SWITCH_SIZE_T_FMT #else #define SWITCH_TIME_T_FMT SWITCH_INT64_T_FMT