aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-11-05 11:49:09 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-11-05 22:10:02 +0100
commit66872161cbb7187b0c20267653d415ef700aca35 (patch)
tree977fb4d569fa14df823af7a733da0ed97f826460
parent6cfaf9cde87508f8fd1dac0960483470a7137afa (diff)
downloadffmpeg-66872161cbb7187b0c20267653d415ef700aca35.tar.gz
avutil/common: error out with clear message if __STDC_CONSTANT_MACROS is not defined with c++
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavutil/common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavutil/common.h b/libavutil/common.h
index b1203ad5a2..e487218e72 100644
--- a/libavutil/common.h
+++ b/libavutil/common.h
@@ -26,6 +26,10 @@
#ifndef AVUTIL_COMMON_H
#define AVUTIL_COMMON_H
+#if defined(__cplusplus) && !defined(__STDC_CONSTANT_MACROS) && !defined(UINT64_C)
+#error missing -D__STDC_CONSTANT_MACROS / #define __STDC_CONSTANT_MACROS
+#endif
+
#include <errno.h>
#include <inttypes.h>
#include <limits.h>