Closed ehardin2 closed 2 years ago
Hi Ed,
The project was originally created with VS2017. I moved over to VS2019 and I recall that I updated the runtime version of the toolset. I cant tell you why VS2019 did not increment the toolset version, it might be that VS2019 can interoperate with both vs2017 and vs2019 project. So I would suggest you compile it with VS2019.
Derek
Derek,
Thanks for the reply. I was going to check VS2019. Once I setup the Toolset to v141 I got a huge quantity of compile errors. I was going to open the .vcproj file to check the SDK you were using to see if that may be the case since I have noticed, especially while I have been trying to figure out BTLE, that a change in SDK can reek havoc with the code. In VS2017 I have it set to 10.0 18362.0. I can't find in the .vcproj file what SDK you were using. Do you remember what it was? I just unzipped the project again and saw that it was 10.0. Odd that it was just listed as 10.0 without any other digits after. If that was 10.0.00000.0 then that would have been a long time ago.
I'll keep messing about and see if I can get it going. Thanks again.
Ed
At 03:48 AM 7/4/2022, you wrote:
Hi Ed,
The project was originally created with VS2017. I moved over to VS2019 and I recall that I updated the runtime version of the toolset. I cant tell you why VS2019 did not increment the toolset version, it might be that VS2019 can interoperate with both vs2017 and vs2019 project. So I would suggest you compile it with VS2019.
Derek
Reply to this email directly, https://github.com/DerekGn/WinBle/issues/12#issuecomment-1173536904view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AIURENBUOABRO6OBPCURGVDVSKQOBANCNFSM52RKIHDAunsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
-- This email has been checked for viruses by AVG. https://www.avg.com
Derek,
TaDaaaa! Everything went fine with VS2019. You might want to mention that in your ReadMe file. Thanks again. I'm now going to try VS 2019 on your WinRtBle project.
Ed
At 03:48 AM 7/4/2022, you wrote:
Hi Ed,
The project was originally created with VS2017. I moved over to VS2019 and I recall that I updated the runtime version of the toolset. I cant tell you why VS2019 did not increment the toolset version, it might be that VS2019 can interoperate with both vs2017 and vs2019 project. So I would suggest you compile it with VS2019.
Derek
Reply to this email directly, https://github.com/DerekGn/WinBle/issues/12#issuecomment-1173536904view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AIURENBUOABRO6OBPCURGVDVSKQOBANCNFSM52RKIHDAunsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
-- This email has been checked for viruses by AVG. https://www.avg.com
Derek,
PPS. I still cannot fix the WinRTBle project. It complainers that the cppwinrt.2017.8.25.1 NuGet package is not in the source and I cannot find anywhere on the internet that there is such a NuGet package. So I have edited the .vcxproj file to delete all reference to it and then installed the cppwinrt.2.0.220608.4 and then uninstalled that and reinstalled it to get everything into sync. Once done I get nothing but compile errors.
Apparantly you had that cppwinrt.2017.8.25.1 NuGet package in your project directory at some point. Do you still have it? I would like to try and compile what the same package that you originally used.
Ed
At 03:48 AM 7/4/2022, you wrote:
Hi Ed,
The project was originally created with VS2017. I moved over to VS2019 and I recall that I updated the runtime version of the toolset. I cant tell you why VS2019 did not increment the toolset version, it might be that VS2019 can interoperate with both vs2017 and vs2019 project. So I would suggest you compile it with VS2019.
Derek
Reply to this email directly, https://github.com/DerekGn/WinBle/issues/12#issuecomment-1173536904view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AIURENBUOABRO6OBPCURGVDVSKQOBANCNFSM52RKIHDAunsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
-- This email has been checked for viruses by AVG. https://www.avg.com
FWISW here is just one example of the errors it is throwing
Severity Code Description Project File Line Suppression State Suppression State
Error (active) E1776 function "winrt::impl::await_adapter
At 03:48 AM 7/4/2022, you wrote:
Hi Ed,
The project was originally created with VS2017. I moved over to VS2019 and I recall that I updated the runtime version of the toolset. I cant tell you why VS2019 did not increment the toolset version, it might be that VS2019 can interoperate with both vs2017 and vs2019 project. So I would suggest you compile it with VS2019.
Derek
Reply to this email directly, https://github.com/DerekGn/WinBle/issues/12#issuecomment-1173536904view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AIURENBUOABRO6OBPCURGVDVSKQOBANCNFSM52RKIHDAunsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
-- This email has been checked for viruses by AVG. https://www.avg.com
Can you not cross post issues from different repos. WinRTBle should be in the other repo, it could confuse others.
It built first time for me from a fresh clone of the repo.
You dont need the package it will restore from nuget on compile.
From a fresh git clone of the winrt repo you will be asked to update the platform toolset to v142 which is aligned with VS2019
The windows SDK aligns to the version of windows you plan running the code on, the SDK version exposes different APIs versions.
If you still have VS2017 it may be attempting to compile against v141 and an older version of the SDK or you might not have a compatible version available.
If you chose not to upgrade the SDK you will get the following error if you are missing the SDK from your PC
Build started...
1>------ Build started: Project: WinRTBle, Configuration: Debug x64 ------
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Microsoft\VC\v160\Microsoft.Cpp.WindowsSDK.targets(46,5): error MSB8036: The Windows SDK version 10.0.15063.0 was not found. Install the required version of Windows SDK or change the SDK version in the project property pages or by right-clicking the solution and selecting "Retarget solution".
1>Done building project "WinRTBle.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Sorry, I didn't realize these email exchanges were getting posted on-line. I will try and see if the clone idea works differently than the download zip has worked. Thanks again.
Ed
At 01:13 PM 7/4/2022, you wrote:
Can you not cross post issues from different repos. WinRTBle should be in the other repo, it could confuse others.
It built first time for me from a fresh clone of the repo.
You dont need the package it will restore from nuget on compile.
From a fresh git clone of the winrt repo you will be asked to update the platform toolset to v142 which is aligned with VS2019 https://user-images.githubusercontent.com/4487837/177202207-3e72fab1-4dbe-47a7-b5ba-f4adace7bb8c.png The windows SDK aligns to the version of windows you plan running the code on, the SDK version exposes different APIs versions.
If you still have VS2017 it may be attempting to compile against v141 and an older version of the SDK or you might not have a compatible version available.
If you chose not to upgrade the SDK you will get the following error if you are missing the SDK from your PC
Build started... 1>------ Build started: Project: WinRTBle, Configuration: Debug x64 ------ 1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Microsoft\VC\v160\Microsoft.Cpp.WindowsSDK.targets(46,5): error MSB8036: The Windows SDK version 10.0.15063.0 was not found. Install the required version of Windows SDK or change the SDK version in the project property pages or by right-clicking the solution and selecting "Retarget solution". 1>Done building project "WinRTBle.vcxproj" -- FAILED. ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== Reply to this email directly, https://github.com/DerekGn/WinBle/issues/12#issuecomment-1174049846view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AIURENFFPLUL4GW6BF2UJWTVSMSUJANCNFSM52RKIHDAunsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
-- This email has been checked for viruses by AVG. https://www.avg.com
Yep all of your emails end up as posts on the issue :)
I am using Visual Studio 2017 v141 on Windows 10. The first problem that I ran into was that the compiler complained that v142 was no available. I went to Project Properties and changed the Toolset to v141 and it compiled, When I go to run I get the error that the WinBleLib.lib is not a proper Win32 application.
From what I know v142 is from Visual Studio 2019 but in opening the project file in text mode I see <Project DefaultTargets="Build" ToolsVersion="15.0"..... and the 15.0 would indicate VS 2017.
The question is, then, what did you create the project file with? VS 2017 or 2019? And if it was VS2017, how is it you are using the v142 Toolset?
Ed