aboutsummaryrefslogtreecommitdiffstats
path: root/addr2line.c
diff options
context:
space:
mode:
authorngoto <ngoto@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-12-18 16:17:17 +0000
committerngoto <ngoto@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-12-18 16:17:17 +0000
commit28eaeaf4d41ac600ad9889aec96290e8a252d58b (patch)
tree3ebb79062372fa9a3812ef716e91d69b7c7d9684 /addr2line.c
parent3f23aac5527125198353025dc7769ac30a7122de (diff)
downloadruby-28eaeaf4d41ac600ad9889aec96290e8a252d58b.tar.gz
Support C89 if possible
* addr2line.c: Because stdbool.h is a C99 feature, compile error occurs with some old compilers without specifying C99 options. Fix compile error with Oracle Solaris Studio 12.4 on Solaris 10. [Bug #14200] [ruby-dev:50366] * missing/stdbool.h: Alternative of stdbool.h for C89 compilers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'addr2line.c')
-rw-r--r--addr2line.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/addr2line.c b/addr2line.c
index 44ccff0d0d..09fcc3c225 100644
--- a/addr2line.c
+++ b/addr2line.c
@@ -13,9 +13,14 @@
#include "addr2line.h"
#include <stdio.h>
-#include <stdbool.h>
#include <errno.h>
+#ifdef HAVE_STDBOOL_H
+#include <stdbool.h>
+#else
+#include "missing/stdbool.h"
+#endif
+
#ifdef USE_ELF
#include <fcntl.h>