mitsuba icon indicating copy to clipboard operation
mitsuba copied to clipboard

Compiler Error with vs2017

Open elegabriel opened this issue 8 years ago • 5 comments

Hello, I tried to complie Mitsuba using vs2017, but got 2 errors when it came to "simply run scons" step.

Severity	Code	Description	Project	File	Line	Suppression State
Error	C2248	'ply::ply_parser::scalar_property_definition_callbacks_type::callbacks_element<U1>': cannot access private struct declared in class 'ply::ply_parser::scalar_property_definition_callbacks_type'	mitsuba-vs2017	G:\Document\Git\mitsuba\dependencies\include\boost\mpl\aux_\preprocessed\plain\inherit.hpp	22	

Severity	Code	Description	Project	File	Line	Suppression State
Error	C2248	'ply::ply_parser::scalar_property_definition_callbacks_type::callbacks_element<U1>': cannot access private struct declared in class 'ply::ply_parser::scalar_property_definition_callbacks_type'	mitsuba-vs2017	G:\Document\Git\mitsuba\dependencies\include\boost\mpl\aux_\preprocessed\plain\inherit.hpp	22	

I changed all private members of 'scalar_property_definition_callbacks_type' and 'list_property_definition_callbacks_type' in ply_parser.hpp into public, making project build succeed, which was quiet ugly. It seems that template class 'inherit2' in file inherit.hpp accesses some private member of the two type above. How can I fix it more correctly?

elegabriel avatar Oct 11 '17 15:10 elegabriel

It is a bug with VS2017.

amyspark avatar Oct 11 '17 16:10 amyspark

all right. Thanks!

elegabriel avatar Oct 13 '17 05:10 elegabriel

What is the workaround? in the build directory the aren't conf files for other versions of VS.

tuket avatar Jan 27 '18 18:01 tuket

Ok, it looks that I just had to update Visual Studio. Then it compiled fine Now it's crashing on start up. image

tuket avatar Jan 27 '18 22:01 tuket

You can find some solutions from this issue. https://github.com/mitsuba-renderer/mitsuba/issues/52#issuecomment-357189129

elegabriel avatar Apr 14 '18 08:04 elegabriel