summaryrefslogtreecommitdiff
path: root/src/_counter.h
diff options
context:
space:
mode:
authorDwayne C. Litzenberger <dlitz@dlitz.net>2011-10-10 23:33:38 -0400
committerDwayne C. Litzenberger <dlitz@dlitz.net>2011-10-10 23:37:51 -0400
commit7401e648d44f9324a313346f45e86fc5e779a7aa (patch)
treebe30ac9265b6ea5f8913aed1c6e9ace6eabe9216 /src/_counter.h
parent323ce9ef951378dc96ce14c9e514e9aa19ab39d9 (diff)
downloadpycrypto-7401e648d44f9324a313346f45e86fc5e779a7aa.tar.gz
Fix build on Solaris 9 and eariler
We use <sys/inttypes.h> on Solaris platforms that don't have <stdint.h>. This should fix https://bugs.launchpad.net/pycrypto/+bug/518871, reported by Sebastian Kayser.
Diffstat (limited to 'src/_counter.h')
-rw-r--r--src/_counter.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/_counter.h b/src/_counter.h
index 47dd494..fc3e24e 100644
--- a/src/_counter.h
+++ b/src/_counter.h
@@ -24,7 +24,14 @@
#ifndef PCT__COUNTER_H
#define PCT__COUNTER_H
-#include <stdint.h>
+#include "config.h"
+#if HAVE_STDINT_H
+# include <stdint.h>
+#elif defined(__sun) || defined(__sun__)
+# include <sys/inttypes.h>
+#else
+# error "stdint.h not found"
+#endif
typedef struct {
PyObject_HEAD