SourceCode does not Compile properly as Plugin

That was indeed the problem. The code already had a YAML_CPP_API macro, but it was wrongly defined:

#ifdef YAML_CPP_DLL
	#ifdef yaml_cpp_EXPORTS 
		#define YAML_CPP_API __declspec(dllexport)
	#else 
		#define YAML_CPP_API __declspec(dllimport)
	#endif 
#else 
	#define YAML_CPP_API
#endif  

Normally YAML_CPP_DLL and yaml_cpp_EXPORTS would have been declared somewhere in the CMake script, but since I used the UBT, I needed to define those manually (via PublicDefinitions in the Build.cs).

After that, all the linker errors disappeared and the project was built without any errors!

Thank you very much for the Help!

1 Like