actions / runner-images

GitHub Actions runner images
MIT License
10.14k stars 3.06k forks source link

Unable to compile project that includes mscoree.h #869

Closed cmconti closed 4 years ago

cmconti commented 4 years ago

Describe the bug Unable to compile project that includes mscoree.h

Area for Triage: .NET Framework, C/C++

Question, Bug, or Feature?: Bug

Virtual environments affected

Expected behavior Expect project to compile

Actual behavior Compile fails with error: Error C1083: Cannot open include file: 'mscoree.h': No such file or directory

cpp file contains the line '#include ' project is targeting SDK 10.0.16299.0

exploration has shown that:

utility task output to find the header

2020-05-01T22:02:57.0121046Z ##[section]Starting: CmdLine
2020-05-01T22:02:57.0223803Z ==============================================================================
2020-05-01T22:02:57.0224103Z Task         : Command line
2020-05-01T22:02:57.0224419Z Description  : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows
2020-05-01T22:02:57.0224806Z Version      : 2.164.0
2020-05-01T22:02:57.0225018Z Author       : Microsoft Corporation
2020-05-01T22:02:57.0225345Z Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line
2020-05-01T22:02:57.0225693Z ==============================================================================
2020-05-01T22:02:58.1839942Z Generating script.
2020-05-01T22:02:58.1936755Z Script contents:
2020-05-01T22:02:58.1944500Z dir "C:\Program Files (x86)\Windows Kits\mscoree.h" /s
2020-05-01T22:02:58.2282183Z ========================== Starting Command Output ===========================
2020-05-01T22:02:58.2614902Z ##[command]"C:\windows\system32\cmd.exe" /D /E:ON /V:OFF /S /C "CALL "d:\a\_temp\353ea702-8c84-4d07-be32-71321790ff64.cmd""
2020-05-01T22:02:58.2739630Z  Volume in drive C is Windows
2020-05-01T22:02:58.2740159Z  Volume Serial Number is C20F-DB5C
2020-05-01T22:03:49.8746055Z 
2020-05-01T22:03:49.8747658Z  Directory of C:\Program Files (x86)\Windows Kits\NETFXSDK\4.7.2\Include\um
2020-05-01T22:03:49.8748086Z 
2020-05-01T22:03:49.8748433Z 06/06/2018  06:07 PM           253,424 mscoree.h
2020-05-01T22:03:49.8748935Z                1 File(s)        253,424 bytes
2020-05-01T22:03:50.0047512Z 
2020-05-01T22:03:50.0048771Z  Directory of C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\Include\um
2020-05-01T22:03:50.0049193Z 
2020-05-01T22:03:50.0049813Z 07/24/2019  06:00 PM           253,424 mscoree.h
2020-05-01T22:03:50.0050269Z                1 File(s)        253,424 bytes
2020-05-01T22:03:50.0978631Z 
2020-05-01T22:03:50.0979671Z      Total Files Listed:
2020-05-01T22:03:50.0980609Z                2 File(s)        506,848 bytes
2020-05-01T22:03:50.0981753Z                0 Dir(s)  127,974,961,152 bytes free
2020-05-01T22:03:50.1275053Z ##[section]Finishing: CmdLine
miketimofeev commented 4 years ago

Hi @cmconti! Could you please provide a failed sample workflow? It will help us a lot during the investigation.

cmconti commented 4 years ago

If you have access to it, here is the job output from a test project https://dev.azure.com/Pegasystems-ATL/Chris%20Conti%20Playground/_build/results?buildId=1695&view=results

if not, I've attached the source code and the build logs logs_1695.zip MscoreeTest.zip

miketimofeev commented 4 years ago

@cmconti we don't have access, thanks for the files!

nikita-bykov commented 4 years ago

Hello @cmconti, thank you for the report! We investigated your issue and it is a known problem in Visual Studio that was mentioned here https://developercommunity.visualstudio.com/content/problem/895653/netfxkitsdir-netfxsdkdir-empty-on-vs-2019-again.html?childToView=1039881#comment-1039881. This issue was resolved in the latest preview version (16.7 preview 1). We installed 16.7 preview 1 version of Visual Studio in runtime and successfully built your project. We can confirm that it works as expected. Unfortunately we are not going to install the preview version of Visual Studio, but as soon as version 16.7 is released, we will update VS on our images. If you have any questions, please let us know!

nikita-bykov commented 4 years ago

Hello @cmconti! We close this issue, but feel free to reopen if you have any questions or concerns.