Ask Your Question
1

Compile problems OpenCV 4.0 with VS2015

asked 2018-11-21 23:48:32 -0600

Christoph gravatar image

updated 2018-11-21 23:55:53 -0600

berak gravatar image

Hello,

I try to build OpenCV 4.0 with VS2015 but I stuck when ADE is compiled with several failures:

Severity    Code    Description Project File    Line
Error   C2059   syntax error: '<L_ATTRIBUTE_SPECIFIER>' (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\check_cycles.cpp)    ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\assert.hpp    86
Error   C2893   Failed to specialize function template 'void ade::throw_error(ExceptionType &&)' (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\check_cycles.cpp)   ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\assert.hpp    86
Error   C2059   syntax error: '<L_ATTRIBUTE_SPECIFIER>' (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\passes\communications.cpp)   ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\assert.hpp    86
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\check_cycles.cpp)    ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\memory_accessor.cpp) ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\search.cpp)  ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\subgraphs.cpp)   ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\passes\communications.cpp)   ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34
Error   C2100   illegal indirection (compiling source file C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\source\topological_sort.cpp)    ade C:\opencv4\build\3rdparty\ade\ade-0.1.1d\sources\ade\include\ade\util\range_iterator.hpp    34

Do you have any idea what to change to finish the build for ADE? I have absolutely no clue...

Thanks!

edit retag flag offensive close merge delete

Comments

do you really need ade ? you can disable ade in cmake-gui

LBerger gravatar imageLBerger ( 2018-11-22 02:31:11 -0600 )edit

Hello, no, I don't need it but I didn't found it in cmake-gui... Do you have a hint for me?

Christoph gravatar imageChristoph ( 2018-11-22 03:33:12 -0600 )edit

try -DBUILD_opencv_gapi=OFF

I tried with vs2015 and I got no error with ade

Microsoft Visual Studio Enterprise 2015 Version 14.0.25431.01 Update 3 Microsoft .NET Framework Version 4.7.03056

Visual C++ 2015 00322-90053-88155-AA030 Microsoft Visual C++ 2015

LBerger gravatar imageLBerger ( 2018-11-22 04:11:37 -0600 )edit

I tried with gapi=OFF, but ade ist still part of the solution... I've updatet to .NET 4.7 (from 4.5) but this did not help...

Christoph gravatar imageChristoph ( 2018-11-23 00:10:18 -0600 )edit

disable ade project in config manager (VS 2015 item in menu build) and rebuild opencv

LBerger gravatar imageLBerger ( 2018-11-23 03:21:26 -0600 )edit

did any understand the actual error(s) ?

berak gravatar imageberak ( 2018-11-23 04:44:05 -0600 )edit

I don‘t. Bit these files haven‘t changed for a long time, so I think it is not a problem of the code but somehow of the compiler or the arguments.

Christoph gravatar imageChristoph ( 2018-11-23 09:02:55 -0600 )edit

1 answer

Sort by » oldest newest most voted
0

answered 2018-11-23 04:19:14 -0600

LBerger gravatar image

updated 2018-11-23 04:19:50 -0600

I think there is a bug in opencv but it will be solved as soon as this PR will be merged

edit flag offensive delete link more

Comments

@Christoph It is merged you can pull opencv ( and opencv_contrib if you use it)

LBerger gravatar imageLBerger ( 2018-11-23 11:14:02 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-11-21 23:48:32 -0600

Seen: 1,035 times

Last updated: Nov 23 '18