[source: blogs.msdn.com]
When building a Windows Phone Store app, there are occasions when you wish to consume logic within a library that you have previously written in C++. In order to consume this logic in a Windows Phone Store app you need to wrap that C++ logic using a WinRT component. The WinRT component acts as a wrapper around the C++ code and is a means of projecting the correct types across the Abstract Binary Interface (such that it may be consumed in languages other than C++). There is documentation and sample code demonstrating how to achieve this, but they tend to show the C++ logic inside of the WinRT component. In the real-world, you will likely have the C++ code in a separate project and therefore you need to reference this from the WinRT component. This scenario is not well documented and so it is the objective of this article to walk through how you can go about setting this up.