summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRahul Chaudhry <rahulchaudhry@google.com>2018-03-27 20:01:36 +0000
committerandroid-build-merger <android-build-merger@google.com>2018-03-27 20:01:36 +0000
commit19df9bb8a21642ab6bd44cee72528bf468c7cd20 (patch)
tree8881cba66123f00b5bd3ce467d83151bf4db2214
parentf1ff343f7f20857b3ca508ee32aaeaaa78bf5795 (diff)
parentb415c49e4c4b8fcddc1f5551bb1e357a8fe93ad7 (diff)
downloadbinutils-19df9bb8a21642ab6bd44cee72528bf468c7cd20.tar.gz
gold: fix build errors on darwin.
am: b415c49e4c Change-Id: I483b208c1052e9a7d33881bd4ceee90605fadc7f
-rw-r--r--binutils-2.27/gold/gold.h2
-rw-r--r--binutils-2.27/gold/output.h2
2 files changed, 4 insertions, 0 deletions
diff --git a/binutils-2.27/gold/gold.h b/binutils-2.27/gold/gold.h
index c75bc7f2..3d7ac083 100644
--- a/binutils-2.27/gold/gold.h
+++ b/binutils-2.27/gold/gold.h
@@ -32,9 +32,11 @@
#include <stdint.h>
#include <sys/types.h>
+#ifndef __STDC_FORMAT_MACROS
// __STDC_FORMAT_MACROS is needed to turn on macros in <inttypes.h>.
#define __STDC_FORMAT_MACROS
#include <inttypes.h>
+#endif
#include "system.h"
diff --git a/binutils-2.27/gold/output.h b/binutils-2.27/gold/output.h
index f4b8e5eb..ee109f00 100644
--- a/binutils-2.27/gold/output.h
+++ b/binutils-2.27/gold/output.h
@@ -27,9 +27,11 @@
#include <list>
#include <vector>
+#ifndef __STDC_FORMAT_MACROS
// __STDC_FORMAT_MACROS is needed to turn on macros in <inttypes.h>.
#define __STDC_FORMAT_MACROS
#include <inttypes.h>
+#endif
#include "elfcpp.h"
#include "mapfile.h"