Skip to content
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

[master] Update dependencies from dotnet/coreclr #76

Conversation

dotnet-maestro[bot]
Copy link
Contributor

This pull request updates the following dependencies

From https://github.com/dotnet/coreclr

  • Build: 20191114.1
  • Date Produced: 11/14/2019 2:18 PM
  • Commit: a9f3fc16483eecfc47fb79c362811d870be02249
  • Branch: refs/heads/master
  • Updates:
    • Microsoft.NET.Sdk.IL -> 5.0.0-alpha1.19564.1
    • Microsoft.NETCore.ILAsm -> 5.0.0-alpha1.19564.1
    • Microsoft.NETCore.Runtime.CoreCLR -> 5.0.0-alpha1.19564.1

…1114.1

- Microsoft.NET.Sdk.IL - 5.0.0-alpha1.19564.1
- Microsoft.NETCore.ILAsm - 5.0.0-alpha1.19564.1
- Microsoft.NETCore.Runtime.CoreCLR - 5.0.0-alpha1.19564.1
@jkotas jkotas deleted the darc-master-ad15044b-dafc-4fe8-a790-d9316e8f3e2c branch November 22, 2019 16:42
@karelz karelz added this to the 5.0.0 milestone Aug 18, 2020
MichalStrehovsky added a commit to MichalStrehovsky/runtime that referenced this pull request Sep 3, 2020
Before this change, running link.exe on the output of the compilation produced `LINK : fatal error LNK1561: entry point must be defined`.

This took longer to figure out than I would be willing to admit.

There are two things at play - linker uses the presence of a method named `main` or `wmain` to choose between setting `wmainCRTStartup` or `mainCRTStartup` as the actual entrypoint of the application (C apps don't start with `main` - they start in the C runtime library that calls `main`).

In dotnet#21 we deleted the `__fail_fast` method from main.cpp and then in dotnet#72 we also removed the compiler reference to the now non-existent symbol. The obscure result of that was that main.obj stopped being part of the linking set because nothing now references symbols from it. When linker looks for `main` or `wmain`, it only looks at object files that are already part of the linking set.

As a result, linker didn't inject `wmainCRTStartup` as the entrypoint and we failed with the above message.

It looks like the only way out is to hardcode the CRT implementation detail here. We were already hardcoding it, but for other reasons.

We also need to set the subsystem since the autodetection is failing.
@ghost ghost locked as resolved and limited conversation to collaborators Dec 11, 2020
@danmoseley danmoseley added area-codeflow for labeling automated codeflow and removed area-Infrastructure-libraries labels Jul 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-codeflow for labeling automated codeflow
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants