Revision: 42399
          http://brlcad.svn.sourceforge.net/brlcad/?rev=42399&view=rev
Author:   starseeker
Date:     2011-01-17 15:00:39 +0000 (Mon, 17 Jan 2011)

Log Message:
-----------
Tweak common.h from CMake and add to trunk.

Modified Paths:
--------------
    brlcad/trunk/include/common.h

Modified: brlcad/trunk/include/common.h
===================================================================
--- brlcad/trunk/include/common.h       2011-01-17 14:53:51 UTC (rev 42398)
+++ brlcad/trunk/include/common.h       2011-01-17 15:00:39 UTC (rev 42399)
@@ -42,7 +42,8 @@
  * should not use config defines)
  */
 #if defined(BRLCADBUILD) && defined(HAVE_CONFIG_H)
-#  if defined(_WIN32) && !defined(__CYGWIN__)
+
+#  if defined(_WIN32) && !defined(__CYGWIN__) && !defined(CMAKE_HEADERS)
 #    include "config_win.h"
 #  else
 #    include "brlcad_config.h"
@@ -113,7 +114,12 @@
  * optional uintptr_t type.
  */
 #if !defined(INT8_MAX) || !defined(INT16_MAX) || !defined(INT32_MAX) || 
!defined(INT64_MAX)
-#  if defined(__STDC__) || defined(__STRICT_ANSI__) || defined(__SIZE_TYPE__) 
|| defined(HAVE_STDINT_H)
+#  if (defined _MSC_VER && (_MSC_VER <= 1500)) 
+     /* Older Versions of Visual C++ seem to need pstdint.h 
+      * but still pass the tests below, so force it based on
+      * version (ugh.) */
+#    include "pstdint.h"
+#  elif defined(__STDC__) || defined(__STRICT_ANSI__) || 
defined(__SIZE_TYPE__) || defined(HAVE_STDINT_H)
 #    define __STDC_LIMIT_MACROS 1
 #    define __STDC_CONSTANT_MACROS 1
 #    include <stdint.h>
@@ -284,7 +290,16 @@
 #  warning "DEPRECATED was previously defined.  Disabling the declaration."
 #endif
 
+/* ActiveState Tcl doesn't include this catch in tclPlatDecls.h, so we
+ * have to add it for them
+ */
+#if defined(_MSC_VER) && defined(__STDC__)
+   #include <tchar.h>
+   /* MSVC++ misses this. */
+   typedef _TCHAR TCHAR;
+#endif
 
+
 #endif  /* __COMMON_H__ */
 /** @} */
 /*


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Protect Your Site and Customers from Malware Attacks
Learn about various malware tactics and how to avoid them. Understand 
malware threats, the impact they can have on your business, and how you 
can protect your company and customers by using code signing.
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to