-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proper VS_WINRT_REFERENCES for Microsoft.Advertising.winmd? #17
Comments
Hmmm... I guess I try again and see if Process Monitor can tell me where msbuild is looking to find the references. |
Sorry, missed the issue. Will try to look at this this week. |
Any news on this issue? I'm having similar issues (or at least I can't figure out how to appropriately add a reference to a .winmd file in an UWP app? |
By coincidence, I was going to look at this again today or tomorrow. As I said, step #1 is reverse-engineering msbuild/VS using Process Monitor to see how it finds the actual dll's. |
If I look at the project when adding a reference to the SDK, it gets an SDKReference defined, not just a Reference. It should be easy to add a new VS_SDKREFERENCE variable to CMake to allow for SDKs to be specified. I had added that support for Windows 10, but specifically for the IOT, Mobile and Desktop extensions. Making it generic should be simple enough. |
Sorry for the delay, I've added support for generic SDKReferences. @d7ec8f90c9d42eec42e2b3f6305329415881740c Simply add a Target property to the SDK like this: |
Excellent support as usual. But now I just can't get cmake 3.5 to give me a winrt/phone8.1 project.
|
If I understand this solution correctly, this requires the SDK to be pre-installed on the computer on which the solution is build. From my perspective (building on different remote servers) it causes unwanted configurations on these machines. Especially if the list continues to grow regarding which SDK's is needed in a configuration. |
Merged this fix over and I have a Win8.1 project building. But I can't get a WinPhone8.1 project building. Maybe CMAKE_VS_MSBUILD_COMMAND needs to be set based on toolset, not VS version (GetToolsVersion()). But then it tries to use msbuild files from the toolset version, which I don't have as I don't have VS2013 installed. |
I was not aware of the -T v120/-T v140 issues. I have never tried specifying the toolset, but have always set the As for the Ad Mediation SDK, in order not to use the SDK_REFERENCES, then as Ted mentions, the references of the SDK would need to be reverse engineered for the assemblies to be part of the build and referenced directly by the project. I'm at F8 until Thursday, so it might take a little more time. |
My next attempt will be to merge the VS_SDK_REFERENCES feature into the 3.4 codebase. I'll report back when I get around to that. |
That worked! Thanks. I changed "this->GeneratorTarget->GetProperty" to "this->Target->GetProperty" but maybe I misunderstood where I should be setting the SDK reference. set_target_properties() made sense to me. fyi, The MSFT ads sdk for Win8.1 is "Microsoft.AdMediatorWindows81, Version=1.0" for but WinPhone8.1 is "Microsoft.AdMediator81, Version=1.0". Bit of a surprise. |
Any idea if this (VS_SDK_REFERENCES) will be merged into the official CMAKE? |
Sorry, I've been working on some other issues, I'll try to update the code and issue a patch to the official release. |
They are now in their master branch. |
I'm trying to add the MSFT ad mediation SDK to our game. I can't seem to figure out the correct way to set VS_WINRT_REFERENCES. Or maybe I found a bug/limitation. If I manually add a reference to "Ad Mediator SDK for Windows 8.1 XAML" Version=1.0 everything works.
I've tried setting it to the .winmd file, full path or partial path. I've tried setting it to the per-architecture .dll file. The closest I've ever gotten was it compiled but upon running there was a ClassNotRegisteredException trying to use the sdk classes.
Anyone have any good thoughts?
The text was updated successfully, but these errors were encountered: