You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My OS: Ubuntu 16.04.4
GCC/G++: Ubuntu 5.4.0-6ubuntu1~16.04.9
OpenCV: manually installed 3.4.1
I'm actually building VLC with OpenCV.
And, I came across the following ERROR message:
/usr/local/include/opencv2/core/cvdef.h:485:1: error: unknown type name ‘namespace’
namespace cv {
^
/usr/local/include/opencv2/core/cvdef.h:485:14: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
namespace cv {
^
And in /usr/local/include/opencv2/core/cvdef.h, the code snippet is:
// Integer types portatibility
#ifdef OPENCV_STDINT_HEADER
#include OPENCV_STDINT_HEADER
#else
#if defined(_MSC_VER) && _MSC_VER < 1600 /* MSVS 2010 */
namespace cv {
typedef signed char int8_t;
typedef unsigned char uint8_t;
typedef signed short int16_t;
typedef unsigned short uint16_t;
typedef signed int int32_t;
typedef unsigned int uint32_t;
typedef signed __int64 int64_t;
typedef unsigned __int64 uint64_t;
}
#elif defined(_MSC_VER) || __cplusplus >= 201103L
#include <cstdint>
namespace cv {
using std::int8_t;
using std::uint8_t;
using std::int16_t;
using std::uint16_t;
using std::int32_t;
using std::uint32_t;
using std::int64_t;
using std::uint64_t;
}
#else
#include <stdint.h>
namespace cv {
typedef ::int8_t int8_t;
typedef ::uint8_t uint8_t;
typedef ::int16_t int16_t;
typedef ::uint16_t uint16_t;
typedef ::int32_t int32_t;
typedef ::uint32_t uint32_t;
typedef ::int64_t int64_t;
typedef ::uint64_t uint64_t;
}
#endif
#endif
It looks if the build goes to #include <stdint.h>,
VLC's compiler is using gcc instead of g++?
And I wonder why __cplusplus >= 201103L ?
Here is my case:
$ gcc --version
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
In such a case, how do you comapre 201103L and ** (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609**?
Cheers
Pei
The text was updated successfully, but these errors were encountered:
@alalek
Hi, alalek, at least please let me know where is the duplicate issue? from where I can find the answer, or at least a similar question has been asked?
I met this problem again just now while I'm building another package, which is also based on OpenCV. What is the issue# that my issue is duplicate with ?
Hi,
My OS: Ubuntu 16.04.4
GCC/G++: Ubuntu 5.4.0-6ubuntu1~16.04.9
OpenCV: manually installed 3.4.1
I'm actually building VLC with OpenCV.
And, I came across the following ERROR message:
And in /usr/local/include/opencv2/core/cvdef.h, the code snippet is:
It looks if the build goes to #include <stdint.h>,
VLC's compiler is using gcc instead of g++?
And I wonder why __cplusplus >= 201103L ?
Here is my case:
In such a case, how do you comapre 201103L and ** (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609**?
Cheers
Pei
The text was updated successfully, but these errors were encountered: