summaryrefslogtreecommitdiff
path: root/third_party/build
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2008-01-24 15:27:30 +0000
committerBenny Prijono <bennylp@teluu.com>2008-01-24 15:27:30 +0000
commit83e87b76edf4c5c5819a0d08ba1ba0897bec10c7 (patch)
tree79b6644c7d0205458a844603f9fad937833a5032 /third_party/build
parent6b80575da6571096086b911a8462417b1f54e685 (diff)
More ticket #61: SRTP will try to use /dev/urandom as RNG if fcntl.h and unistd.h is present. If it fails, it will fallback to using rand()
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@1738 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'third_party/build')
-rw-r--r--third_party/build/srtp/srtp_config.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/third_party/build/srtp/srtp_config.h b/third_party/build/srtp/srtp_config.h
index 2442b072..6d1cfcfc 100644
--- a/third_party/build/srtp/srtp_config.h
+++ b/third_party/build/srtp/srtp_config.h
@@ -26,7 +26,7 @@
(defined(PJ_M_X86_64) && PJ_M_X86_64!=0) || \
(defined(PJ_M_IA64) && PJ_M_IA64!=0)
# define CPU_CISC 1
-# define HAVE_X86 1 /* use X86 inlined assembly code */
+/* # define HAVE_X86 1 use X86 inlined assembly code */
#else
# define CPU_RISC 1
#endif
@@ -113,7 +113,7 @@
typedef pj_int64_t int64_t;
#endif
-#define SIZEOF_UNSIGNED_LONG (sizeof(unsigned long))
+#define SIZEOF_UNSIGNED_LONG 8
#define SIZEOF_UNSIGNED_LONG_LONG 8
@@ -155,6 +155,13 @@
/* Path to random device */
/* #define DEV_URANDOM "/dev/urandom" */
+/* Only with PJSIP:
+ * Try to open PJ_DEV_URANDOM if present
+ */
+#if defined(PJ_HAS_FCNTL_H) && defined(PJ_HAS_UNISTD_H)
+# define PJ_DEV_URANDOM "/dev/urandom"
+#endif
+
/* We have overridden libsrtp error mechanism, so these are not used. */
/* #undef ERR_REPORTING_FILE */
/* #undef ERR_REPORTING_STDOUT */