Commit 69c9fe35 authored by Andrey Kamaev's avatar Andrey Kamaev Committed by OpenCV Buildbot

Merge pull request #702 from taka-no-me:refactor_core_headers

parents 98585a96 aaf69c42
...@@ -112,15 +112,15 @@ ...@@ -112,15 +112,15 @@
#define CV_HARDWARE_MAX_FEATURE 255 #define CV_HARDWARE_MAX_FEATURE 255
#if defined __SSE2__ || defined _M_X64 || (defined _M_IX86_FP && _M_IX86_FP >= 2) #if defined __SSE2__ || defined _M_X64 || (defined _M_IX86_FP && _M_IX86_FP >= 2)
# include "emmintrin.h" # include <emmintrin.h>
# define CV_SSE 1 # define CV_SSE 1
# define CV_SSE2 1 # define CV_SSE2 1
# if defined __SSE3__ || (defined _MSC_VER && _MSC_VER >= 1500) # if defined __SSE3__ || (defined _MSC_VER && _MSC_VER >= 1500)
# include "pmmintrin.h" # include <pmmintrin.h>
# define CV_SSE3 1 # define CV_SSE3 1
# endif # endif
# if defined __SSSE3__ || (defined _MSC_VER && _MSC_VER >= 1500) # if defined __SSSE3__ || (defined _MSC_VER && _MSC_VER >= 1500)
# include "tmmintrin.h" # include <tmmintrin.h>
# define CV_SSSE3 1 # define CV_SSSE3 1
# endif # endif
# if defined __SSE4_1__ || (defined _MSC_VER && _MSC_VER >= 1500) # if defined __SSE4_1__ || (defined _MSC_VER && _MSC_VER >= 1500)
...@@ -187,7 +187,13 @@ ...@@ -187,7 +187,13 @@
*/ */
#if !defined _MSC_VER && !defined __BORLANDC__ #if !defined _MSC_VER && !defined __BORLANDC__
# include <stdint.h> # if defined __cplusplus && __cplusplus >= 201103L
# include <cstdint>
# else
# include <stdint.h>
# endif
#else
typedef unsigned uint;
#endif #endif
typedef signed char schar; typedef signed char schar;
...@@ -318,6 +324,8 @@ typedef signed char schar; ...@@ -318,6 +324,8 @@ typedef signed char schar;
#if defined __BORLANDC__ #if defined __BORLANDC__
# include <fastmath.h> # include <fastmath.h>
#elif defined __cplusplus
# include <cmath>
#else #else
# include <math.h> # include <math.h>
#endif #endif
...@@ -414,7 +422,7 @@ CV_INLINE int cvIsInf( double value ) ...@@ -414,7 +422,7 @@ CV_INLINE int cvIsInf( double value )
# define CV_XADD(addr, delta) __atomic_fetch_add((_Atomic(int)*)(addr), delta, 4) # define CV_XADD(addr, delta) __atomic_fetch_add((_Atomic(int)*)(addr), delta, 4)
# endif # endif
# else # else
# ifdef __ATOMIC_ACQ_REL # if defined __ATOMIC_ACQ_REL && !defined __clang__
// version for gcc >= 4.7 // version for gcc >= 4.7
# define CV_XADD(addr, delta) __atomic_fetch_add(addr, delta, __ATOMIC_ACQ_REL) # define CV_XADD(addr, delta) __atomic_fetch_add(addr, delta, __ATOMIC_ACQ_REL)
# else # else
......
This diff is collapsed.
...@@ -111,11 +111,11 @@ static bool isDir(const cv::String& path, DIR* dir) ...@@ -111,11 +111,11 @@ static bool isDir(const cv::String& path, DIR* dir)
return (attributes != INVALID_FILE_ATTRIBUTES) && ((attributes & FILE_ATTRIBUTE_DIRECTORY) != 0); return (attributes != INVALID_FILE_ATTRIBUTES) && ((attributes & FILE_ATTRIBUTE_DIRECTORY) != 0);
#else #else
(void)dir;
struct stat stat_buf; struct stat stat_buf;
stat( path.c_str(), &stat_buf); if (0 != stat( path.c_str(), &stat_buf))
return false;
int is_dir = S_ISDIR( stat_buf.st_mode); int is_dir = S_ISDIR( stat_buf.st_mode);
(void)dir;
return is_dir != 0; return is_dir != 0;
#endif #endif
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment