-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Description
Generate an apphost when targeting macOS by default
The .NET SDK will now create an executable for app projects when building on MacOS.
Since .NET Core 3.0, the .NET SDK has created an executable for app projects when building on other operating systems. However, it did not do so on macOS since we were not signing this binary, resulting in with an app which would be recognized as dangerous by the OS and making it hard for the user to run it. The .NET 6 SDK can sign the app executable, so it now produces it by default.
Version introduced
.NET SDK 6.0.100-preview6
Old behavior
The apphost executable was not generated by default. User could explicitly ask the SDK to generate one by setting the UseAppHost property to true.
New behavior
The apphost is now being generated by default and is signed using the native command-line codesign, making it easier for users to execute the binary.
Reason for change
We implemented the necessary changes in the HostModel for being able to code sign the executables.
Recommended action
If a user which is building an app targeting macOS does not want the apphost to be generated, the UseAppHost property can be set to false to prevent the SDK from generating this file.
Category
- ASP.NET Core
- C#
- Code analysis
- Core .NET libraries
- Cryptography
- Data
- Debugger
- Deployment
- Globalization
- Interop
- JIT
- LINQ
- Managed Extensibility Framework (MEF)
- MSBuild
- Networking
- Printing
- SDK
- Security
- Serialization
- Visual Basic
- Windows Forms
- Windows Presentation Foundation (WPF)
- XML, XSLT
Affected APIs
"Not detectable via API analysis"
Issue metadata
- Issue type: breaking-change