diff --git a/Directory.Build.props b/Directory.Build.props index 6a5a9d193c..5799a9e9b6 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -10,7 +10,7 @@ true true <_SkipUpgradeNetAnalyzersNuGetWarning>true - + http://go.microsoft.com/fwlink/?LinkID=288859 @@ -19,4 +19,18 @@ true diagnostics + + + + 6.0 + net$(NetCoreAppMinVersion) + + net6.0;net8.0;net9.0 + + net6.0;net8.0 + diff --git a/NuGet.config b/NuGet.config index 85d9e3140b..4b675ebca4 100644 --- a/NuGet.config +++ b/NuGet.config @@ -5,15 +5,21 @@ - - + + + + - + + + + + diff --git a/documentation/FAQ.md b/documentation/FAQ.md index 499e34a30e..467672c824 100644 --- a/documentation/FAQ.md +++ b/documentation/FAQ.md @@ -1,6 +1,32 @@ Frequently Asked Questions ========================== +* On MacOS if you see any of the following errors: + ``` + (lldb) plugin load libsosplugin.so + error: this file does not represent a loadable dylib + ``` + or if the sos plugin loads correctly but you see this error on any command: + ``` + (lldb) setsymbolserver -ms + Error: Fail to initialize coreclr 80070008 + ``` + or something like this error: + ``` + (lldb) setsymbolserver -ms + SOS_HOSTING: Fail to initialize hosting runtime '/usr/local/share/dotnet/shared/Microsoft.NETCore.App/6.0.29/libcoreclr.dylib' 80004005 + Unrecognized command 'setsymbolserver' because managed hosting failed or was disabled. See sethostruntime command for details. + ``` + + Try the following workaround for Apple's standard lldb installation: + ``` + $ sudo cp /Applications/Xcode.app/Contents/Developer/usr/bin/lldb /usr/local/bin + $ sudo install_name_tool -add_rpath /Applications/Xcode.app/Contents/SharedFrameworks /usr/local/bin/lldb + $ sudo codesign --force --sign - /usr/local/bin/lldb + ``` + +This will make a copy of Xcode lldb and adhoc sign it. Note that this workaround is only applicable to Xcode lldb, not the System lldb (`/usr/bin/lldb`), which may still fail to load. You may need to delete or rename `~/.lldbinit` to use `/usr/bin/lldb`. + * `dotnet-dump analyze` running on Windows doesn't support MacOS .NET 5.0 and 6.0 core dumps. `dotnet-dump` running on MacOS does support .NET 5.0 but not 6.0 core dumps (which will be fixed in a future dotnet-dump release). MacOS .NET 6.0 core dumps generated by the runtime via [createdump](https://github.com/dotnet/runtime/blob/main/docs/design/coreclr/botr/xplat-minidump-generation.md#os-x) are supported by lldb/SOS running on MacOS. * If SOS or dotnet-dump analyze commands display "UNKNOWN" for types or functions names, your core dump may not have all the managed state. Dumps created with gdb or gcore have this problem. Linux system generated core dumps need the `coredump_filter` for the process to be set to at least 0x3f. See [core](http://man7.org/linux/man-pages/man5/core.5.html) for more information. diff --git a/documentation/diagnostics-client-library-instructions.md b/documentation/diagnostics-client-library-instructions.md index 1ebddb12b4..a3d8fd6063 100644 --- a/documentation/diagnostics-client-library-instructions.md +++ b/documentation/diagnostics-client-library-instructions.md @@ -1,524 +1,3 @@ # Microsoft.Diagnostics.NETCore.Client API Documentation -## Intro -Microsoft.Diagnostics.NETCore.Client (also known as the Diagnostics Client library) is a managed library that lets you interact with .NET Core runtime (CoreCLR) for various diagnostics related tasks, such as tracing, requesting a dump, or attaching an ICorProfiler. Using this library, you can write your own diagnostics tools customized for your particular scenario. - -## Installing -Microsoft.Diagnostics.NETCore.Client is available on [NuGet](https://www.nuget.org/packages/Microsoft.Diagnostics.NETCore.Client/). - - -## Sample Code: - -Here are some sample code showing the usage of this library. - -#### 1. Attaching to a process and dumping out all the runtime GC events in real time to the console -This sample shows an example where we trigger an EventPipe session with the .NET runtime provider with the GC keyword at informational level, and use `EventPipeEventSource` (provided by the [TraceEvent library](https://www.nuget.org/packages/Microsoft.Diagnostics.Tracing.TraceEvent/)) to parse the events coming in and print the name of each event to the console in real time. - -```cs -using Microsoft.Diagnostics.NETCore.Client; -using Microsoft.Diagnostics.Tracing.Parsers; - -public void PrintRuntimeGCEvents(int processId) -{ - var providers = new List() - { - new EventPipeProvider("Microsoft-Windows-DotNETRuntime", - EventLevel.Informational, (long)ClrTraceEventParser.Keywords.GC) - }; - - var client = new DiagnosticsClient(processId); - using (var session = client.StartEventPipeSession(providers, false)) - { - var source = new EventPipeEventSource(session.EventStream); - - source.Clr.All += (TraceEvent obj) => { - Console.WriteLine(obj.EventName); - }; - - try - { - source.Process(); - } - // NOTE: This exception does not currently exist. It is something that needs to be added to TraceEvent. - catch (EventStreamException e) - { - Console.WriteLine("Error encountered while processing events"); - Console.WriteLine(e.ToString()); - } - } -} -``` - -#### 2. Write a core dump. -This sample shows how to trigger a dump using `DiagnosticsClient`. -```cs -using Microsoft.Diagnostics.NETCore.Client; - -public void TriggerCoreDump(int processId) -{ - var client = new DiagnosticsClient(processId); - client.WriteDump(DumpType.Normal); -} -``` - -#### 3. Trigger a core dump when CPU usage goes above a certain threshold -This sample shows an example where we monitor the `cpu-usage` counter published by the .NET runtime and use the `WriteDump` API to write out a dump when the CPU usage grows beyond a certain threshold. -```cs - -using Microsoft.Diagnostics.NETCore.Client; - -public void TriggerDumpOnCpuUsage(int processId, int threshold) -{ - var providers = new List() - { - new EventPipeProvider( - "System.Runtime", - EventLevel.Informational, - (long)ClrTraceEventParser.Keywords.None, - new Dictionary() { - { "EventCounterIntervalSec", "1" } - } - ) - }; - var client = new DiagnosticsClient(processId); - using(var session = client.StartEventPipeSession(providers)) - { - var source = new EventPipeEventSource(session.EventStream); - source.Dynamic.All += (TraceEvent obj) => - { - if (obj.EventName.Equals("EventCounters")) - { - // I know this part is ugly. But this is all TraceEvent. - var payloadFields = (IDictionary)(obj.GetPayloadValueByName("Payload")); - if (payloadFields["Name"].ToString().Equals("cpu-usage")) - { - double cpuUsage = Double.Parse(payloadFields["Mean"]); - if (cpuUsage > (double)threshold) - { - client.WriteDump(DumpType.Normal, "/tmp/minidump.dmp"); - } - } - } - } - try - { - source.Process(); - } - catch (EventStreamException) {} - - } - } -} -``` - -#### 4. Trigger a CPU trace for given number of seconds -This sample shows an example where we trigger an EventPipe session for certain period of time, with the default CLR trace keyword as well as the sample profiler, and read from the stream that gets created as a result and write the bytes out to a file. Essentially this is what `dotnet-trace` uses internally to write a trace file. - -```cs - -using Microsoft.Diagnostics.NETCore.Client; -using System.Diagnostics; -using System.IO; -using System.Threading.Task; - -public void TraceProcessForDuration(int processId, int duration, string traceName) -{ - var cpuProviders = new List() - { - new EventPipeProvider("Microsoft-Windows-DotNETRuntime", EventLevel.Informational, (long)ClrTraceEventParser.Keywords.Default), - new EventPipeProvider("Microsoft-DotNETCore-SampleProfiler", EventLevel.Informational, (long)ClrTraceEventParser.Keywords.None) - }; - var client = new DiagnosticsClient(processId); - using (var traceSession = client.StartEventPipeSession(cpuProviders)) - { - Task copyTask = Task.Run(async () => - { - using (FileStream fs = new FileStream(traceName, FileMode.Create, FileAccess.Write)) - { - await traceSession.EventStream.CopyToAsync(fs); - } - }); - - copyTask.Wait(duration * 1000); - traceSession.Stop(); - } -} -``` - -#### 5. Print names of all .NET processes that published a diagnostics server to connect - -This sample shows how to use `DiagnosticsClient.GetPublishedProcesses` API to print the names of the .NET processes that published a diagnostics IPC channel. - -```cs -using Microsoft.Diagnostics.NETCore.Client; -using System.Linq; - -public static void PrintProcessStatus() -{ - var processes = DiagnosticsClient.GetPublishedProcesses() - .Select(GetProcessById) - .Where(process => process != null) - - foreach (var process in processes) - { - Console.WriteLine($"{process.ProcessName}"); - } -} -``` - - -#### 6. Live-parsing events for a specified period of time. - -This sample shows an example where we create two tasks, one that parses the events coming in live with `EventPipeEventSource` and one that reads the console input for a user input signaling the program to end. If the target app exists before the users presses enter, the app exists gracefully. Otherwise, `inputTask` will send the Stop command to the pipe and exit gracefully. - -```cs -using Microsoft.Diagnostics.NETCore.Client; -using Microsoft.Diagnostics.Tracing.Parsers; - -public static void PrintEventsLive(int processId) -{ - var providers = new List() - { - new EventPipeProvider("Microsoft-Windows-DotNETRuntime", - EventLevel.Informational, (long)ClrTraceEventParser.Keywords.Default) - }; - var client = new DiagnosticsClient(processId); - using (var session = client.StartEventPipeSession(providers, false)) - { - - Task streamTask = Task.Run(() => - { - var source = new EventPipeEventSource(session.EventStream); - source.Dynamic.All += (TraceEvent obj) => - { - Console.WriteLine(obj.EventName); - }; - try - { - source.Process(); - } - // NOTE: This exception does not currently exist. It is something that needs to be added to TraceEvent. - catch (Exception e) - { - Console.WriteLine("Error encountered while processing events"); - Console.WriteLine(e.ToString()); - } - }); - - Task inputTask = Task.Run(() => - { - Console.WriteLine("Press Enter to exit"); - while (Console.ReadKey().Key != ConsoleKey.Enter) - { - Thread.Sleep(100); - } - session.Stop(); - }); - - Task.WaitAny(streamTask, inputTask); - } -} -``` - -#### 7. Attach a ICorProfiler profiler - -This sample shows how to attach an ICorProfiler to a process (profiler attach). -```cs -public static void AttachProfiler(int processId, Guid profilerGuid, string profilerPath) -{ - var client = new DiagnosticsClient(processId); - client.AttachProfiler(TimeSpan.FromSeconds(10), profilerGuid, profilerPath); -} -``` - -#### 8. Set an ICorProfiler to be used as the startup profiler - -This sample shows how to request that the runtime use an ICorProfiler as the startup profiler (not as an attaching profiler). It is only valid to issue this command while the runtime is paused in "reverse server" mode. - -```cs -public static void SetStartupProfilerProfiler(Guid profilerGuid, string profilerPath) -{ - var client = new DiagnosticsClient(processId); - client.SetStartupProfiler(profilerGuid, profilerPath); -} -``` - -#### 9. Resume the runtime when it is paused in reverse server mode - -This sample shows how a client can instruct the runtime to resume loading after it has been paused in "reverse server" mode. - -```cs -public static void ResumeRuntime(Guid profilerGuid, string profilerPath) -{ - var client = new DiagnosticsClient(processId); - client.ResumeRuntime(); -} -``` - -## API Description - -This section describes the APIs of the library. - -#### class DiagnosticsClient -```cs -public DiagnosticsClient -{ - public DiagnosticsClient(int processId); - public EventPipeSession StartEventPipeSession(IEnumerable providers, bool requestRundown=true, int circularBufferMB=256); - public void WriteDump(DumpType dumpType, string dumpPath=null, bool logDumpGeneration=false); - public void AttachProfiler(TimeSpan attachTimeout, Guid profilerGuid, string profilerPath, byte[] additionalData=null); - public static IEnumerable GetPublishedProcesses(); -} -``` - - - -#### Methods - -```csharp -public DiagnosticsClient(int processId); -``` - -Creates a new instance of `DiagnosticsClient` for a compatible .NET process running with process ID of `processId`. - -`processID` : Process ID of the target application. - - - -```csharp -public EventPipeSession StartEventPipeSession(IEnumerable providers, bool requestRundown=true, int circularBufferMB=256) -``` - -Starts an EventPipe tracing session using the given providers and settings. - -* `providers` : An `IEnumerable` of [`EventPipeProvider`](#class-eventpipeprovider)s to start tracing. -* `requestRundown`: A `bool` specifying whether rundown provider events from the target app's runtime should be requested. -* `circularBufferMB`: An `int` specifying the total size of circular buffer used by the target app's runtime on collecting events. - - -```csharp -public EventPipeSession StartEventPipeSession(EventPipeProvider providers, bool requestRundown=true, int circularBufferMB=256) -``` - -* `providers` : An [`EventPipeProvider`](#class-eventpipeprovider) to start tracing. -* `requestRundown`: A `bool` specifying whether rundown provider events from the target app's runtime should be requested. -* `circularBufferMB`: An `int` specifying the total size of circular buffer used by the target app's runtime on collecting events. - - -**Remarks** - -Rundown events contain payloads that may be needed for post analysis, such as resolving method names of thread samples. Unless you know you do not want this, we recommend setting this to true. In large applications, this may take up to minutes. - -* `circularBufferMB` : The size of the circular buffer to be used as a buffer for writing events within the runtime. - - - -```csharp -public void WriteDump(DumpType dumpType, string dumpPath=null, bool logDumpGeneration=false); -``` - -Request a dump for post-mortem debugging of the target application. The type of the dump can be specified using the [`DumpType`](#enum-dumptype) enum. - -* `dumpType` : Type of the dump to be requested. - -* `dumpPath` : The path to the dump to be written out to. -* `logDumpGeneration` : If set to `true`, the target application will write out diagnostic logs during dump generation. - - - - - -```csharp -public void AttachProfiler(TimeSpan attachTimeout, Guid profilerGuid, string profilerPath, byte[] additionalData=null); -``` - -Request to attach an ICorProfiler to the target application. - -* `attachTimeout` : A `TimeSpan` after which attach will be aborted. -* `profilerGuid` : `Guid` of the ICorProfiler to be attached. -* `profilerPath ` : Path to the ICorProfiler dll to be attached. -* `additionalData` : Optional additional data that can be passed to the runtime during profiler attach. - - - -```csharp -public static IEnumerable GetPublishedProcesses(); -``` - -Get an `IEnumerable` of process IDs of all the active .NET processes that can be attached to. - - - - - -#### class EventPipeProvider - -```cs -public class EventPipeProvider -{ - public EventPipeProvider( - string name, - EventLevel eventLevel, - long keywords = 0, - IDictionary arguments = null) - - public string Name { get; } - - public EventLevel EventLevel { get; } - - public long Keywords { get; } - - public IDictionary Arguments { get; } - - public override string ToString(); - - public override bool Equals(object obj); - - public override int GetHashCode(); - - public static bool operator ==(Provider left, Provider right); - - public static bool operator !=(Provider left, Provider right); -} -``` - - - -```csharp -public EventPipeProvider(string name, - EventLevel eventLevel, - long keywords = 0, - IDictionary arguments = null) -``` - -Creates a new instance of `EventPipeProvider` with the given provider name, [EventLevel](https://docs.microsoft.com/en-us/dotnet/api/system.diagnostics.tracing.eventlevel), keywords, and arguments. - -#### Properties - - - -```csharp -public string Name { get; } -``` - -The name of the Provider - - - -```csharp -public EventLevel EventLevel { get; } -``` - -The EventLevel of the given instance of [`EventPipeProvider`](#class-eventpipeprovider). - - - -```csharp -public long Keywords { get; } -``` - -A long that represents bitmask for keywords of the EventSource. - - - -```csharp -public IDictionary Arguments { get; } -``` - -An `IDictionary` of key-value pair string representing optional arguments to be passed to EventSource representing the given `EventPipeProvider`. - - -#### Remarks - -This class is immutable, as EventPipe does not allow a provider's configuration to be modified during an EventPipe session (as of .NET Core 3.1). - - - -### class EventPipeSession - -```csharp -public class EventPipeSession : IDisposable -{ - public Stream EventStream { get; } - - public void Stop(); -} -``` - -This class represents an ongoing EventPipe session that has been started. It is immutable and acts as a handle to an EventPipe session of the given runtime. - -#### Properties - -```csharp -public Stream EventStream { get; } -``` - -Returns a `Stream` that can be used to read the event stream. - -#### Methods - -```csharp -public void Stop(); -``` - -Stops the given EventPipe session. - - - -### enum DumpType - -```csharp -public enum DumpType -{ - Normal = 1, - WithHeap = 2, - Triage = 3, - Full = 4 -} -``` - -Represents the type of dump that can be requested. - -* `Normal`: Include just the information necessary to capture stack traces for all existing traces for all existing threads in a process. Limited GC heap memory and information. -* `WithHeap`: Includes the GC heaps and information necessary to capture stack traces for all existing threads in a process. -* `Triage`: Include just the information necessary to capture stack traces for all existing traces for all existing threads in a process. Limited GC heap memory and information. -* `Full`: Include all accessible memory in the process. The raw memory data is included at the end, so that the initial structures can be mapped directly without the raw memory information. This option can result in a very large dump file. - - - -### Exceptions - -Either `DiagnosticsClientException` or its subclass can be thrown from the library. - -```csharp -public class DiagnosticsClientException : Exception -``` - -#### UnsupportedProtocolException - -```csharp -public class UnsupportedProtocolException : DiagnosticsClientException -``` - -This may be thrown when the command is not supported by either the library or the target process' runtime. - - - -#### ServerNotAvailableException - -```csharp -public class ServerNotAvailableException : DiagnosticsClientException -``` - -This may be thrown when the runtime is not available for diagnostics IPC commands, such as early during runtime startup before the runtime is ready for diagnostics commands, or when the runtime is shutting down. - -#### ServerErrorException - -```csharp -public class ServerErrorException : DiagnosticsClientException -``` - -This may be thrown when the runtime responds with an error to a given command. - - - +These docs have moved to: https://learn.microsoft.com/dotnet/core/diagnostics/diagnostics-client-library diff --git a/documentation/privatebuildtesting.md b/documentation/privatebuildtesting.md index 83440d092e..1753392531 100644 --- a/documentation/privatebuildtesting.md +++ b/documentation/privatebuildtesting.md @@ -9,7 +9,7 @@ Here are some instructions on how to run the diagnostics repo's tests against a 4. On Windows 11 (this doesn't work on Windows 10), add the following DWORD registry key: `HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\MiniDumpSettings\DisableAuxProviderSignatureCheck` and set it to 1. This allows the unsigned privately built DAC to be used to generate dumps. 5. Copy the private runtime binaries over the test SDK/runtimes installed in `.dotnet-test`. This step is hard to automate because there are usually 3 versions of the runtime installed: one as part of the .NET SDK, one as part of the AspNetCore runtime and one from latest runtime DARC update. 6. Run the diagnostics repo tests either: - a. `test.cmd` or `test.sh` - this runs all the diagnostics tests including SOS's. A html test report will be generated in `artifacts/TestResults/{Debug,Release}/SOS.UnitTests_net6.0_x64.html`. + a. `test.cmd` or `test.sh` - this runs all the diagnostics tests including SOS's. A html test report will be generated in `artifacts/TestResults/{Debug,Release}/SOS.UnitTests_net8.0_x64.html`. b. Use the VS Test Explorer to run all the SOS tests or a specific one. c. Use `eng\testsos.cmd` or `eng/testsos.sh` to run just the SOS tests. The html test report isn't generated in this case, but the SOS test logs are in artifacts/TestResults/{Debug,Release}/sos_*. diff --git a/documentation/tutorial/src/triggerdump/triggerdump.csproj b/documentation/tutorial/src/triggerdump/triggerdump.csproj index 19b4ee1143..534711c0db 100644 --- a/documentation/tutorial/src/triggerdump/triggerdump.csproj +++ b/documentation/tutorial/src/triggerdump/triggerdump.csproj @@ -1,7 +1,7 @@  - net6.0 + net8.0 true triggerdump Diagnosticv.TriggerDump diff --git a/eng/AuxMsbuildFiles/SdkPackOverrides.targets b/eng/AuxMsbuildFiles/SdkPackOverrides.targets index edfcb9bff2..a5e85ad852 100644 --- a/eng/AuxMsbuildFiles/SdkPackOverrides.targets +++ b/eng/AuxMsbuildFiles/SdkPackOverrides.targets @@ -3,12 +3,10 @@ @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net6.0')->Metadata('Runtime')) - @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net7.0')->Metadata('Runtime')) @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net8.0')->Metadata('Runtime')) @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net9.0')->Metadata('Runtime')) @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net6.0')->Metadata('AspNet')) - @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net7.0')->Metadata('AspNet')) @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net8.0')->Metadata('AspNet')) @(RuntimeTestVersions->WithMetadataValue('TargetFramework', 'net9.0')->Metadata('AspNet')) @@ -21,10 +19,6 @@ $(RuntimeVersion60) - - $(RuntimeVersion70) - - $(RuntimeVersion80) @@ -41,11 +35,6 @@ $(RuntimeVersion60) - - $(RuntimeVersion70) - $(RuntimeVersion70) - - $(RuntimeVersion80) $(RuntimeVersion80) @@ -60,10 +49,6 @@ $(RuntimeVersion60) - - $(RuntimeVersion70) - - $(RuntimeVersion80) @@ -76,10 +61,6 @@ $(RuntimeVersion60) - - $(RuntimeVersion70) - - $(RuntimeVersion80) @@ -96,11 +77,6 @@ $(AspNetVersion60) - - $(AspNetVersion70) - $(AspNetVersion70) - - $(AspNetVersion80) $(AspNetVersion80) @@ -115,10 +91,6 @@ $(AspNetVersion60) - - $(AspNetVersion70) - - $(AspNetVersion80) @@ -131,10 +103,6 @@ $(AspNetVersion60) - - $(AspNetVersion70) - - $(AspNetVersion80) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 059c9b813f..b756a6c5e5 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,57 +1,57 @@ - + https://github.com/microsoft/clrmd - 496892ecb1b05a72df368493b49ea08ea0876149 + 898339503a4f9d877be46826b5814c1813808ac5 - + https://github.com/microsoft/clrmd - 496892ecb1b05a72df368493b49ea08ea0876149 + 898339503a4f9d877be46826b5814c1813808ac5 - + https://github.com/dotnet/arcade - 9ba9980c4996a540387b9a0ef0d68accf00689c0 + f209a925b15bc66ecb9a8825bd9595937bbe3aa1 - + https://github.com/dotnet/arcade - 9ba9980c4996a540387b9a0ef0d68accf00689c0 + f209a925b15bc66ecb9a8825bd9595937bbe3aa1 - + https://github.com/dotnet/arcade - 9ba9980c4996a540387b9a0ef0d68accf00689c0 + f209a925b15bc66ecb9a8825bd9595937bbe3aa1 https://github.com/dotnet/arcade ccfe6da198c5f05534863bbb1bff66e830e0c6ab - + https://github.com/dotnet/sdk - 1a658dfc714a5064eea57af48d5fd68a3ffab7ef + 6a7f86a90566a15439ae0332f17e50cf34c21c3a - + https://github.com/dotnet/aspnetcore - d962763e8e7d1efb409f9688d6dd7c87aab93b3d + 9f57b1ed7a4adab022ec5d227723f23862aad0e3 - + https://github.com/dotnet/aspnetcore - d962763e8e7d1efb409f9688d6dd7c87aab93b3d + 9f57b1ed7a4adab022ec5d227723f23862aad0e3 - + https://github.com/dotnet/runtime - db95ac47f72d605e7676ad155db2bab00be889ed + 24cfc7cc9dabdbe8607a3bf81ffbedf7e2cbb97f - + https://github.com/dotnet/runtime - db95ac47f72d605e7676ad155db2bab00be889ed + 24cfc7cc9dabdbe8607a3bf81ffbedf7e2cbb97f - + https://github.com/dotnet/source-build-reference-packages - 38a050f3b80b4dfdd0e8f6c772a3e9835674d3b4 + fd609e3b427601180d23633e2f1a4cdac6c42c20 diff --git a/eng/Versions.props b/eng/Versions.props index 4d0750f5d2..5da621e5b9 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -16,11 +16,11 @@ - 9.0.0-rtm.24468.5 - 9.0.0-rtm.24468.5 + 9.0.0-rtm.24508.17 + 9.0.0-rtm.24508.17 - 9.0.0-rtm.24468.6 - 9.0.0-rtm.24468.6 + 9.0.0-rtm.24508.22 + 9.0.0-rtm.24508.22 9.0.100-rc.1.24409.1 @@ -28,6 +28,8 @@ false 1.12.0 + 1.43.0 + 12.22.0 @@ -35,7 +37,7 @@ 8.0.0 6.0.0 - 4.0.0-beta.24463.1 + 4.0.0-beta.24480.1 17.10.0-beta1.24272.1 3.0.7 6.0.0 @@ -51,14 +53,14 @@ 4.3.0 4.5.4 8.0.0 - 8.0.4 + 8.0.5 2.0.3 - 10.0.0-beta.24463.4 + 10.0.0-beta.24504.4 1.2.0-beta.406 7.0.0-beta.22316.2 10.0.26100.1 13.0.1 - 10.0.0-alpha.1.24467.1 + 10.0.0-alpha.1.24507.1 - 8.0.5 - 7.0.19 - 6.0.30 + + + 8.0.8 + 6.0.33 default @@ -119,20 +122,22 @@ $(MicrosoftAspNetCoreAppRefVersion) net9.0 + + $(MicrosoftNETCoreApp80Version) $(MicrosoftNETCoreApp80Version) $(MicrosoftNETCoreApp80Version) $(MicrosoftNETCoreApp80Version) net8.0 - - $(MicrosoftNETCoreApp70Version) - $(MicrosoftNETCoreApp70Version) - $(MicrosoftNETCoreApp70Version) - $(MicrosoftNETCoreApp70Version) - net7.0 - $(MicrosoftNETCoreApp60Version) $(MicrosoftNETCoreApp60Version) diff --git a/eng/common/core-templates/job/job.yml b/eng/common/core-templates/job/job.yml index ba53ebfbd5..c37d16634d 100644 --- a/eng/common/core-templates/job/job.yml +++ b/eng/common/core-templates/job/job.yml @@ -19,6 +19,7 @@ parameters: # publishing defaults artifacts: '' enableMicrobuild: false + enableMicrobuildForMacAndLinux: false enablePublishBuildArtifacts: false enablePublishBuildAssets: false enablePublishTestResults: false @@ -134,11 +135,26 @@ jobs: signType: $(_SignType) zipSources: false feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json + ${{ if and(eq(parameters.enableMicrobuildForMacAndLinux, 'true'), ne(variables['Agent.Os'], 'Windows_NT')) }}: + azureSubscription: 'MicroBuild Signing Task (DevDiv)' env: TeamName: $(_TeamName) MicroBuildOutputFolderOverride: '$(Agent.TempDirectory)' + SYSTEM_ACCESSTOKEN: $(System.AccessToken) continueOnError: ${{ parameters.continueOnError }} - condition: and(succeeded(), in(variables['_SignType'], 'real', 'test'), eq(variables['Agent.Os'], 'Windows_NT')) + condition: and( + succeeded(), + or( + and( + eq(variables['Agent.Os'], 'Windows_NT'), + in(variables['_SignType'], 'real', 'test') + ), + and( + ${{ eq(parameters.enableMicrobuildForMacAndLinux, true) }}, + ne(variables['Agent.Os'], 'Windows_NT'), + eq(variables['_SignType'], 'real') + ) + )) - ${{ if and(eq(parameters.runAsPublic, 'false'), eq(variables['System.TeamProject'], 'internal')) }}: - task: NuGetAuthenticate@1 @@ -171,7 +187,19 @@ jobs: - ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: - task: MicroBuildCleanup@1 displayName: Execute Microbuild cleanup tasks - condition: and(always(), in(variables['_SignType'], 'real', 'test'), eq(variables['Agent.Os'], 'Windows_NT')) + condition: and( + always(), + or( + and( + eq(variables['Agent.Os'], 'Windows_NT'), + in(variables['_SignType'], 'real', 'test') + ), + and( + ${{ eq(parameters.enableMicrobuildForMacAndLinux, true) }}, + ne(variables['Agent.Os'], 'Windows_NT'), + eq(variables['_SignType'], 'real') + ) + )) continueOnError: ${{ parameters.continueOnError }} env: TeamName: $(_TeamName) diff --git a/eng/common/core-templates/steps/publish-logs.yml b/eng/common/core-templates/steps/publish-logs.yml index 173bcfe5ce..de24d0087c 100644 --- a/eng/common/core-templates/steps/publish-logs.yml +++ b/eng/common/core-templates/steps/publish-logs.yml @@ -34,7 +34,9 @@ steps: '$(akams-client-id)' '$(microsoft-symbol-server-pat)' '$(symweb-symbol-server-pat)' + '$(dnceng-symbol-server-pat)' '$(dn-bot-all-orgs-build-rw-code-rw)' + '$(System.AccessToken)' ${{parameters.CustomSensitiveDataList}} continueOnError: true condition: always() diff --git a/eng/common/cross/build-rootfs.sh b/eng/common/cross/build-rootfs.sh index 4b5e8d7166..20ae8c2868 100644 --- a/eng/common/cross/build-rootfs.sh +++ b/eng/common/cross/build-rootfs.sh @@ -66,6 +66,7 @@ __UbuntuPackages+=" libcurl4-openssl-dev" __UbuntuPackages+=" libkrb5-dev" __UbuntuPackages+=" libssl-dev" __UbuntuPackages+=" zlib1g-dev" +__UbuntuPackages+=" libbrotli-dev" __AlpinePackages+=" curl-dev" __AlpinePackages+=" krb5-dev" @@ -91,18 +92,18 @@ __HaikuPackages="gcc_syslibs" __HaikuPackages+=" gcc_syslibs_devel" __HaikuPackages+=" gmp" __HaikuPackages+=" gmp_devel" -__HaikuPackages+=" icu66" -__HaikuPackages+=" icu66_devel" +__HaikuPackages+=" icu[0-9]+" +__HaikuPackages+=" icu[0-9]*_devel" __HaikuPackages+=" krb5" __HaikuPackages+=" krb5_devel" __HaikuPackages+=" libiconv" __HaikuPackages+=" libiconv_devel" -__HaikuPackages+=" llvm12_libunwind" -__HaikuPackages+=" llvm12_libunwind_devel" +__HaikuPackages+=" llvm[0-9]*_libunwind" +__HaikuPackages+=" llvm[0-9]*_libunwind_devel" __HaikuPackages+=" mpfr" __HaikuPackages+=" mpfr_devel" -__HaikuPackages+=" openssl" -__HaikuPackages+=" openssl_devel" +__HaikuPackages+=" openssl3" +__HaikuPackages+=" openssl3_devel" __HaikuPackages+=" zlib" __HaikuPackages+=" zlib_devel" @@ -496,7 +497,7 @@ if [[ "$__CodeName" == "alpine" ]]; then arch="$(uname -m)" ensureDownloadTool - + if [[ "$__hasWget" == 1 ]]; then wget -P "$__ApkToolsDir" "https://gitlab.alpinelinux.org/api/v4/projects/5/packages/generic/v$__ApkToolsVersion/$arch/apk.static" else @@ -681,7 +682,7 @@ elif [[ "$__CodeName" == "haiku" ]]; then ensureDownloadTool - echo "Downloading Haiku package tool" + echo "Downloading Haiku package tools" git clone https://github.com/haiku/haiku-toolchains-ubuntu --depth 1 "$__RootfsDir/tmp/script" if [[ "$__hasWget" == 1 ]]; then wget -O "$__RootfsDir/tmp/download/hosttools.zip" "$("$__RootfsDir/tmp/script/fetch.sh" --hosttools)" @@ -691,34 +692,42 @@ elif [[ "$__CodeName" == "haiku" ]]; then unzip -o "$__RootfsDir/tmp/download/hosttools.zip" -d "$__RootfsDir/tmp/bin" - DepotBaseUrl="https://depot.haiku-os.org/__api/v2/pkg/get-pkg" - HpkgBaseUrl="https://eu.hpkg.haiku-os.org/haiku/master/$__HaikuArch/current" + HaikuBaseUrl="https://eu.hpkg.haiku-os.org/haiku/master/$__HaikuArch/current" + HaikuPortsBaseUrl="https://eu.hpkg.haiku-os.org/haikuports/master/$__HaikuArch/current" + + echo "Downloading HaikuPorts package repository index..." + if [[ "$__hasWget" == 1 ]]; then + wget -P "$__RootfsDir/tmp/download" "$HaikuPortsBaseUrl/repo" + else + curl -SLO --create-dirs --output-dir "$__RootfsDir/tmp/download" "$HaikuPortsBaseUrl/repo" + fi - # Download Haiku packages echo "Downloading Haiku packages" read -ra array <<<"$__HaikuPackages" for package in "${array[@]}"; do echo "Downloading $package..." - # API documented here: https://github.com/haiku/haikudepotserver/blob/master/haikudepotserver-api2/src/main/resources/api2/pkg.yaml#L60 - # The schema here: https://github.com/haiku/haikudepotserver/blob/master/haikudepotserver-api2/src/main/resources/api2/pkg.yaml#L598 + hpkgFilename="$(LD_LIBRARY_PATH="$__RootfsDir/tmp/bin" "$__RootfsDir/tmp/bin/package_repo" list -f "$__RootfsDir/tmp/download/repo" | + grep -E "${package}-" | sort -V | tail -n 1 | xargs)" + if [ -z "$hpkgFilename" ]; then + >&2 echo "ERROR: package $package missing." + exit 1 + fi + echo "Resolved filename: $hpkgFilename..." + hpkgDownloadUrl="$HaikuPortsBaseUrl/packages/$hpkgFilename" if [[ "$__hasWget" == 1 ]]; then - hpkgDownloadUrl="$(wget -qO- --post-data '{"name":"'"$package"'","repositorySourceCode":"haikuports_'$__HaikuArch'","versionType":"LATEST","naturalLanguageCode":"en"}' \ - --header 'Content-Type:application/json' "$DepotBaseUrl" | jq -r '.result.versions[].hpkgDownloadURL')" wget -P "$__RootfsDir/tmp/download" "$hpkgDownloadUrl" else - hpkgDownloadUrl="$(curl -sSL -XPOST --data '{"name":"'"$package"'","repositorySourceCode":"haikuports_'$__HaikuArch'","versionType":"LATEST","naturalLanguageCode":"en"}' \ - --header 'Content-Type:application/json' "$DepotBaseUrl" | jq -r '.result.versions[].hpkgDownloadURL')" curl -SLO --create-dirs --output-dir "$__RootfsDir/tmp/download" "$hpkgDownloadUrl" fi done for package in haiku haiku_devel; do echo "Downloading $package..." if [[ "$__hasWget" == 1 ]]; then - hpkgVersion="$(wget -qO- "$HpkgBaseUrl" | sed -n 's/^.*version: "\([^"]*\)".*$/\1/p')" - wget -P "$__RootfsDir/tmp/download" "$HpkgBaseUrl/packages/$package-$hpkgVersion-1-$__HaikuArch.hpkg" + hpkgVersion="$(wget -qO- "$HaikuBaseUrl" | sed -n 's/^.*version: "\([^"]*\)".*$/\1/p')" + wget -P "$__RootfsDir/tmp/download" "$HaikuBaseUrl/packages/$package-$hpkgVersion-1-$__HaikuArch.hpkg" else - hpkgVersion="$(curl -sSL "$HpkgBaseUrl" | sed -n 's/^.*version: "\([^"]*\)".*$/\1/p')" - curl -SLO --create-dirs --output-dir "$__RootfsDir/tmp/download" "$HpkgBaseUrl/packages/$package-$hpkgVersion-1-$__HaikuArch.hpkg" + hpkgVersion="$(curl -sSL "$HaikuBaseUrl" | sed -n 's/^.*version: "\([^"]*\)".*$/\1/p')" + curl -SLO --create-dirs --output-dir "$__RootfsDir/tmp/download" "$HaikuBaseUrl/packages/$package-$hpkgVersion-1-$__HaikuArch.hpkg" fi done diff --git a/eng/common/template-guidance.md b/eng/common/template-guidance.md index 5ef6c30ba9..98bbc1ded0 100644 --- a/eng/common/template-guidance.md +++ b/eng/common/template-guidance.md @@ -57,7 +57,7 @@ extends: Note: Multiple outputs are ONLY applicable to 1ES PT publishing (only usable when referencing `templates-official`). -# Development notes +## Development notes **Folder / file structure** diff --git a/eng/common/templates-official/job/job.yml b/eng/common/templates-official/job/job.yml index 3d16b41c78..605692d2fb 100644 --- a/eng/common/templates-official/job/job.yml +++ b/eng/common/templates-official/job/job.yml @@ -1,6 +1,7 @@ parameters: # Sbom related params enableSbom: true + runAsPublic: false PackageVersion: 9.0.0 BuildDropPath: '$(Build.SourcesDirectory)/artifacts' diff --git a/eng/common/templates/job/job.yml b/eng/common/templates/job/job.yml index 07d317bf8f..d1aeb92fce 100644 --- a/eng/common/templates/job/job.yml +++ b/eng/common/templates/job/job.yml @@ -4,6 +4,7 @@ parameters: componentGovernanceIgnoreDirectories: '' # Sbom related params enableSbom: true + runAsPublic: false PackageVersion: 9.0.0 BuildDropPath: '$(Build.SourcesDirectory)/artifacts' diff --git a/eng/common/tools.ps1 b/eng/common/tools.ps1 index 9574f4eb9d..22954477a5 100644 --- a/eng/common/tools.ps1 +++ b/eng/common/tools.ps1 @@ -900,7 +900,7 @@ function IsWindowsPlatform() { } function Get-Darc($version) { - $darcPath = "$TempDir\darc\$(New-Guid)" + $darcPath = "$TempDir\darc\$([guid]::NewGuid())" if ($version -ne $null) { & $PSScriptRoot\darc-init.ps1 -toolpath $darcPath -darcVersion $version | Out-Host } else { diff --git a/eng/pipelines/templateInternal.yml b/eng/pipelines/templateInternal.yml index 4c1d63a973..af64305fd9 100644 --- a/eng/pipelines/templateInternal.yml +++ b/eng/pipelines/templateInternal.yml @@ -24,6 +24,13 @@ extends: name: $(BuildPool) image: $(WindowsImage) os: windows + sdl: + policheck: + enabled: true + tsa: + enabled: true + featureFlags: + autoBaseline: true containers: ${{ parameters.containers }} diff --git a/eng/release/DiagnosticsReleaseTool/DiagnosticsManifestGenerator.cs b/eng/release/DiagnosticsReleaseTool/DiagnosticsManifestGenerator.cs index 0cafc121d8..71cddbd658 100644 --- a/eng/release/DiagnosticsReleaseTool/DiagnosticsManifestGenerator.cs +++ b/eng/release/DiagnosticsReleaseTool/DiagnosticsManifestGenerator.cs @@ -15,7 +15,7 @@ namespace DiagnosticsReleaseTool.Impl { - internal sealed class DiagnosticsManifestGenerator : IManifestGenerator + internal sealed partial class DiagnosticsManifestGenerator : IManifestGenerator { private readonly ReleaseMetadata _productReleaseMetadata; private readonly JsonDocument _assetManifestManifestDom; @@ -160,16 +160,12 @@ private string GenerateSubpath(FileReleaseData fileToRelease) return $"{_productReleaseMetadata.ReleaseVersion}/{pathHash}/{fi.Name}"; } - private static readonly Regex s_akaMsMetadataMatcher = new( - $@"<(?[a-zA-Z]\w*)>", - RegexOptions.Compiled | RegexOptions.ExplicitCapture); - private string GenerateLinkFromMetadata(FileReleaseData fileToRelease, string linkSchema) { FileInfo fi = new(fileToRelease.FileMap.LocalSourcePath); string link = linkSchema; //TODO: Revisit for perf if necessary... - MatchCollection results = s_akaMsMetadataMatcher.Matches(linkSchema); + MatchCollection results = AkamsMetadataMatcher().Matches(linkSchema); foreach (Match match in results) { if (!match.Groups.TryGetValue("metadata", out Group metadataGroup)) @@ -219,5 +215,8 @@ private void WriteMetadata(Utf8JsonWriter writer) element.WriteTo(writer); } } + + [GeneratedRegex(@"<(?[a-zA-Z]\w*)>", RegexOptions.ExplicitCapture | RegexOptions.Compiled)] + private static partial Regex AkamsMetadataMatcher(); } } diff --git a/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseCommandLine.cs b/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseCommandLine.cs index 3a5b89589f..00a0fc00b0 100644 --- a/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseCommandLine.cs +++ b/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseCommandLine.cs @@ -4,6 +4,7 @@ using System.CommandLine; using System.CommandLine.Builder; using System.CommandLine.Invocation; +using System.CommandLine.NamingConventionBinder; using System.CommandLine.Parsing; using System.IO; using System.Threading; @@ -17,8 +18,7 @@ internal sealed class DiagnosticsReleaseCommandLine { private static async Task Main(string[] args) { - Parser parser = new CommandLineBuilder() - .AddCommand(PrepareRelease()) + Parser parser = new CommandLineBuilder(PrepareRelease()) .CancelOnProcessTermination() .UseDefaults() .Build(); @@ -58,7 +58,7 @@ private static Option ToolManifestPathOption() => private static Option ToolManifestVerificationOption() => new( - alias: "--verify-tool-manifest", + aliases: ["--verify-tool-manifest"], description: "Verifies that the assets being published match the manifest", getDefaultValue: () => true); diff --git a/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseTool.csproj b/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseTool.csproj index 60cde3873e..2c6bf3b090 100644 --- a/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseTool.csproj +++ b/eng/release/DiagnosticsReleaseTool/DiagnosticsReleaseTool.csproj @@ -3,7 +3,7 @@ Exe - net6.0 + net8.0 $(NoWarn);CA2007 @@ -14,24 +14,19 @@ - - - - - - + + + + + + - - - + + + + + + + - - - - - - - - - diff --git a/eng/release/DiagnosticsReleaseTool/DiagnosticsRepoHelpers.cs b/eng/release/DiagnosticsReleaseTool/DiagnosticsRepoHelpers.cs index 79a811b556..81904f7aed 100644 --- a/eng/release/DiagnosticsReleaseTool/DiagnosticsRepoHelpers.cs +++ b/eng/release/DiagnosticsReleaseTool/DiagnosticsRepoHelpers.cs @@ -8,7 +8,7 @@ namespace DiagnosticsReleaseTool.Util { - public static class DiagnosticsRepoHelpers + public static partial class DiagnosticsRepoHelpers { public static readonly string[] ProductNames = ["diagnostics", "dotnet-diagnostics"]; public static readonly string[] RepositoryUrls = ["https://github.com/dotnet/diagnostics", "https://dev.azure.com/dnceng/internal/_git/dotnet-diagnostics"]; @@ -17,13 +17,9 @@ public static class DiagnosticsRepoHelpers public const string BundledToolsCategory = "ToolBundleAssets"; public const string PdbCategory = "PdbAssets"; - private static readonly Regex s_ridBundledToolsMatcher = new( - $@"{BundledToolsPrefix}(?(\w+-)+\w+)\.zip", - RegexOptions.Compiled | RegexOptions.ExplicitCapture); - private static string GetRidFromBundleZip(FileInfo zipFile) { - MatchCollection matches = s_ridBundledToolsMatcher.Matches(zipFile.Name); + MatchCollection matches = RidBundledToolsRegex().Matches(zipFile.Name); if (matches.Count != 1) { @@ -83,5 +79,8 @@ public static string GetSha512(string filePath) byte[] checksum = sha.ComputeHash(stream); return Convert.ToHexString(checksum); } + + [GeneratedRegex(@"diagnostic-tools-(?(\w+-)+\w+)\.zip", RegexOptions.ExplicitCapture | RegexOptions.Compiled)] + private static partial Regex RidBundledToolsRegex(); } } diff --git a/global.json b/global.json index efc66dd06a..c1f99d9127 100644 --- a/global.json +++ b/global.json @@ -4,18 +4,16 @@ "runtimes": { "dotnet": [ "$(MicrosoftNETCoreApp60Version)", - "$(MicrosoftNETCoreApp70Version)", "$(MicrosoftNETCoreApp80Version)" ], "dotnet/x86": [ "$(MicrosoftNETCoreApp60Version)", - "$(MicrosoftNETCoreApp70Version)", "$(MicrosoftNETCoreApp80Version)" ] } }, "msbuild-sdks": { "Microsoft.Build.NoTargets": "3.5.0", - "Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.24463.4" + "Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.24504.4" } } diff --git a/src/Microsoft.Diagnostics.DebugServices.Implementation/Microsoft.Diagnostics.DebugServices.Implementation.csproj b/src/Microsoft.Diagnostics.DebugServices.Implementation/Microsoft.Diagnostics.DebugServices.Implementation.csproj index cbb95d87ee..8a4af246cb 100644 --- a/src/Microsoft.Diagnostics.DebugServices.Implementation/Microsoft.Diagnostics.DebugServices.Implementation.csproj +++ b/src/Microsoft.Diagnostics.DebugServices.Implementation/Microsoft.Diagnostics.DebugServices.Implementation.csproj @@ -13,17 +13,19 @@ true false - + + + - + diff --git a/src/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.csproj b/src/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.csproj index 187039ef98..06eff1a40a 100644 --- a/src/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.csproj +++ b/src/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.csproj @@ -1,7 +1,7 @@ Library - netstandard2.0;net6.0 + netstandard2.0;$(NetCoreAppMinTargetFramework) netstandard2.0 Microsoft.Diagnostics.NETCore.Client .NET Core Diagnostics Client Library diff --git a/src/Microsoft.Diagnostics.TestHelpers/Microsoft.Diagnostics.TestHelpers.csproj b/src/Microsoft.Diagnostics.TestHelpers/Microsoft.Diagnostics.TestHelpers.csproj index 0057d575f5..4e3df14e84 100644 --- a/src/Microsoft.Diagnostics.TestHelpers/Microsoft.Diagnostics.TestHelpers.csproj +++ b/src/Microsoft.Diagnostics.TestHelpers/Microsoft.Diagnostics.TestHelpers.csproj @@ -1,6 +1,6 @@ - net6.0 + $(NetCoreAppMinTargetFramework) true ;1591;1701 false @@ -11,13 +11,13 @@ true false - + - + diff --git a/src/Microsoft.Diagnostics.TestHelpers/TestConfiguration.cs b/src/Microsoft.Diagnostics.TestHelpers/TestConfiguration.cs index c499bac11f..f79d646599 100644 --- a/src/Microsoft.Diagnostics.TestHelpers/TestConfiguration.cs +++ b/src/Microsoft.Diagnostics.TestHelpers/TestConfiguration.cs @@ -673,7 +673,7 @@ public string BuildProjectMicrosoftNetCoreAppVersion } /// - /// The framework type/version used to build the debuggee like "net6.0" or "net7.0" + /// The framework type/version used to build the debuggee like "net6.0" or "net8.0" /// public string BuildProjectFramework { diff --git a/src/Microsoft.Diagnostics.WebSocketServer/Microsoft.Diagnostics.WebSocketServer.csproj b/src/Microsoft.Diagnostics.WebSocketServer/Microsoft.Diagnostics.WebSocketServer.csproj index 873bb470ba..1eb999cc0c 100644 --- a/src/Microsoft.Diagnostics.WebSocketServer/Microsoft.Diagnostics.WebSocketServer.csproj +++ b/src/Microsoft.Diagnostics.WebSocketServer/Microsoft.Diagnostics.WebSocketServer.csproj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) ;1591;1701 Provides a WebSocket adapter to allow dotnet-dsrouter to talk to browser-based runtimes diff --git a/src/SOS/SOS.Extensions/MemoryServiceFromDebuggerServices.cs b/src/SOS/SOS.Extensions/MemoryServiceFromDebuggerServices.cs index 2de76b90c3..e825b9908d 100644 --- a/src/SOS/SOS.Extensions/MemoryServiceFromDebuggerServices.cs +++ b/src/SOS/SOS.Extensions/MemoryServiceFromDebuggerServices.cs @@ -31,6 +31,7 @@ internal MemoryServiceFromDebuggerServices(ITarget target, DebuggerServices debu { case Architecture.X64: case Architecture.Arm64: + case (Architecture)6 /* Architecture.LoongArch64 */: PointerSize = 8; break; case Architecture.X86: diff --git a/src/SOS/SOS.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt b/src/SOS/SOS.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt index c45a887ecc..fd034675a5 100644 --- a/src/SOS/SOS.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt +++ b/src/SOS/SOS.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt @@ -8,10 +8,8 @@ --> - ../../../../.. - $(RepoRootDir)/.dotnet-test - + $(RepoRootDir)/.dotnet-test ProjectK @@ -186,9 +184,9 @@ $(DotNetRoot)/shared/Microsoft.NETCore.App/$(RuntimeFrameworkVersion) $(ScriptRootDir)/lldbhelper.py + net10.0 net9.0 net8.0 - net7.0 net6.0 diff --git a/src/SOS/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt b/src/SOS/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt index 2d701b681b..7e0e353cc8 100644 --- a/src/SOS/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt +++ b/src/SOS/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt @@ -8,11 +8,9 @@ --> - ..\..\..\..\.. + $(RepoRootDir)\.dotnet-test $(RepoRootDir)\.dotnet-test\x86 - - $(RepoRootDir)\src\SOS\SOS.UnitTests\Scripts @@ -229,9 +227,9 @@ $(RuntimeFrameworkVersion) $(DotNetRoot)\shared\Microsoft.NETCore.App\$(RuntimeFrameworkVersion) + net10.0 net9.0 net8.0 - net7.0 net6.0 diff --git a/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt b/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt index 73ec55e9c5..4aefca334b 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt +++ b/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt @@ -32,6 +32,5 @@ add_library_clr(DesktopClrHost SHARED ${DESKTOPCLRHOST_SOURCES}) target_link_libraries(DesktopClrHost ${DESKTOPCLRHOST_LIBRARY}) install(TARGETS DesktopClrHost DESTINATION ${CLR_MANAGED_BINARY_DIR}/WebApp3/${CLR_BUILD_TYPE}/net6.0) -install(TARGETS DesktopClrHost DESTINATION ${CLR_MANAGED_BINARY_DIR}/WebApp3/${CLR_BUILD_TYPE}/net7.0) install(TARGETS DesktopClrHost DESTINATION ${CLR_MANAGED_BINARY_DIR}/WebApp3/${CLR_BUILD_TYPE}/net8.0) install(TARGETS DesktopClrHost DESTINATION ${CLR_MANAGED_BINARY_DIR}/WebApp3/${CLR_BUILD_TYPE}/net9.0) diff --git a/src/SOS/SOS.UnitTests/Debuggees/Directory.Build.props b/src/SOS/SOS.UnitTests/Debuggees/Directory.Build.props index 88a79b7218..246d710418 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/Directory.Build.props +++ b/src/SOS/SOS.UnitTests/Debuggees/Directory.Build.props @@ -7,7 +7,6 @@ full true false - net6.0;net7.0;net8.0;net9.0 diff --git a/src/SOS/SOS.UnitTests/Debuggees/DivZero/DivZero.csproj b/src/SOS/SOS.UnitTests/Debuggees/DivZero/DivZero.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/DivZero/DivZero.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/DivZero/DivZero.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/DotnetDumpCommands/DotnetDumpCommands.csproj b/src/SOS/SOS.UnitTests/Debuggees/DotnetDumpCommands/DotnetDumpCommands.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/DotnetDumpCommands/DotnetDumpCommands.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/DotnetDumpCommands/DotnetDumpCommands.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/DynamicMethod/DynamicMethod.csproj b/src/SOS/SOS.UnitTests/Debuggees/DynamicMethod/DynamicMethod.csproj index 299cffbb99..fb0a6fd1ce 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/DynamicMethod/DynamicMethod.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/DynamicMethod/DynamicMethod.csproj @@ -3,7 +3,7 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/GCPOH/GCPOH.csproj b/src/SOS/SOS.UnitTests/Debuggees/GCPOH/GCPOH.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/GCPOH/GCPOH.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/GCPOH/GCPOH.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/GCWhere/GCWhere.csproj b/src/SOS/SOS.UnitTests/Debuggees/GCWhere/GCWhere.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/GCWhere/GCWhere.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/GCWhere/GCWhere.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/LineNums/LineNums.csproj b/src/SOS/SOS.UnitTests/Debuggees/LineNums/LineNums.csproj index c704adf493..1a899918e6 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/LineNums/LineNums.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/LineNums/LineNums.csproj @@ -3,6 +3,6 @@ Exe true $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/NestedExceptionTest/NestedExceptionTest.csproj b/src/SOS/SOS.UnitTests/Debuggees/NestedExceptionTest/NestedExceptionTest.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/NestedExceptionTest/NestedExceptionTest.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/NestedExceptionTest/NestedExceptionTest.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/Overflow/Overflow.csproj b/src/SOS/SOS.UnitTests/Debuggees/Overflow/Overflow.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/Overflow/Overflow.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/Overflow/Overflow.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/ReflectionTest/ReflectionTest.csproj b/src/SOS/SOS.UnitTests/Debuggees/ReflectionTest/ReflectionTest.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/ReflectionTest/ReflectionTest.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/ReflectionTest/ReflectionTest.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/SimpleThrow/SimpleThrow.csproj b/src/SOS/SOS.UnitTests/Debuggees/SimpleThrow/SimpleThrow.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/SimpleThrow/SimpleThrow.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/SimpleThrow/SimpleThrow.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestApp/SymbolTestApp.csproj b/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestApp/SymbolTestApp.csproj index 662b550344..d55c18ba73 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestApp/SymbolTestApp.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestApp/SymbolTestApp.csproj @@ -2,7 +2,7 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) $(DefineConstants);FULL_CLR @@ -14,7 +14,4 @@ - - - diff --git a/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/SymbolTestDll.csproj b/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/SymbolTestDll.csproj index 01794bdad7..70475d3d56 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/SymbolTestDll.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/SymbolTestDll.csproj @@ -2,7 +2,7 @@ Library $(BuildProjectFramework) - $(BuildTargetFrameworks) - net462;$(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) + net462;$(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/RandomUserLibrary/RandomUserLibrary.csproj b/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/RandomUserLibrary/RandomUserLibrary.csproj index e6fd811af7..706430c525 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/RandomUserLibrary/RandomUserLibrary.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/RandomUserLibrary/RandomUserLibrary.csproj @@ -2,6 +2,6 @@ Library $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/TaskNestedException/TaskNestedException.csproj b/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/TaskNestedException/TaskNestedException.csproj index 1285b3532f..39b71c90fa 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/TaskNestedException/TaskNestedException.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/TaskNestedException/TaskNestedException/TaskNestedException.csproj @@ -2,7 +2,7 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/Debuggees/WebApp3/WebApp3.csproj b/src/SOS/SOS.UnitTests/Debuggees/WebApp3/WebApp3.csproj index c9bab0a2f1..2ec653657d 100644 --- a/src/SOS/SOS.UnitTests/Debuggees/WebApp3/WebApp3.csproj +++ b/src/SOS/SOS.UnitTests/Debuggees/WebApp3/WebApp3.csproj @@ -2,7 +2,7 @@ $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/SOS/SOS.UnitTests/SOS.UnitTests.csproj b/src/SOS/SOS.UnitTests/SOS.UnitTests.csproj index db08980770..8e874822d5 100644 --- a/src/SOS/SOS.UnitTests/SOS.UnitTests.csproj +++ b/src/SOS/SOS.UnitTests/SOS.UnitTests.csproj @@ -1,13 +1,13 @@  - net6.0 + $(NetCoreAppMinTargetFramework) false ;1591;1701 $(DefineConstants);CORE_CLR true $(OutputPath)$(TargetFramework)\Debugger.Tests.Common.txt - + @@ -33,7 +33,7 @@ - + @@ -44,19 +44,20 @@ $(Configuration) + $(RepoRoot) $(NuGetPackageRoot)cdb-sos\$(cdbsosversion)\runtimes\win-%24(TargetArchitecture)\native\cdb.exe ]]> - + - + - + diff --git a/src/SOS/SOS.UnitTests/SOSRunner.cs b/src/SOS/SOS.UnitTests/SOSRunner.cs index 5511fe2ed6..3eb574c353 100644 --- a/src/SOS/SOS.UnitTests/SOSRunner.cs +++ b/src/SOS/SOS.UnitTests/SOSRunner.cs @@ -1458,7 +1458,7 @@ private HashSet GetEnabledDefines() { defines.Add("32BIT"); } - else if (_config.TargetArchitecture.Equals("x64") || _config.TargetArchitecture.Equals("arm64")) + else if (_config.TargetArchitecture.Equals("x64") || _config.TargetArchitecture.Equals("arm64") || _config.TargetArchitecture.Equals("loongarch64")) { defines.Add("64BIT"); } diff --git a/src/SOS/Strike/clrma/thread.cpp b/src/SOS/Strike/clrma/thread.cpp index bd8220f8ac..6e3e994b82 100644 --- a/src/SOS/Strike/clrma/thread.cpp +++ b/src/SOS/Strike/clrma/thread.cpp @@ -403,7 +403,7 @@ ClrmaThread::NestedException( HRESULT hr; USHORT nCount = 0; - if (hr = get_NestedExceptionCount(&nCount)) + if (FAILED(hr = get_NestedExceptionCount(&nCount))) { return hr; } diff --git a/src/SOS/Strike/eeheap.cpp b/src/SOS/Strike/eeheap.cpp index 259cb42996..c83f46b5c6 100644 --- a/src/SOS/Strike/eeheap.cpp +++ b/src/SOS/Strike/eeheap.cpp @@ -436,7 +436,7 @@ size_t AlignLarge(size_t nbytes) size_t GetNumComponents(TADDR obj) { // The number of components is always the second pointer in the object. - DWORD Value = NULL; + DWORD Value = 0; HRESULT hr = MOVE(Value, obj + sizeof(size_t)); // If we fail to read out the number of components, let's assume 0 so we don't try to diff --git a/src/SOS/extensions/hostcoreclr.cpp b/src/SOS/extensions/hostcoreclr.cpp index ddb26a11e2..4c49602343 100644 --- a/src/SOS/extensions/hostcoreclr.cpp +++ b/src/SOS/extensions/hostcoreclr.cpp @@ -69,10 +69,9 @@ namespace RuntimeHostingConstants { // This list is in probing order. constexpr RuntimeVersion SupportedHostRuntimeVersions[] = { + {9, 0}, {8, 0}, - {7, 0}, {6, 0}, - {9, 0}, }; constexpr char DotnetRootEnvVar[] = "DOTNET_ROOT"; @@ -126,10 +125,9 @@ namespace RuntimeHostingConstants #endif "/usr/local/share/dotnet" #else - "/rh-dotnet60/root/usr/bin/dotnet", - "/rh-dotnet70/root/usr/bin/dotnet", - "/rh-dotnet80/root/usr/bin/dotnet", "/rh-dotnet90/root/usr/bin/dotnet", + "/rh-dotnet80/root/usr/bin/dotnet", + "/rh-dotnet60/root/usr/bin/dotnet", "/usr/share/dotnet", #endif }; diff --git a/src/SOS/lldbplugin.tests/TestDebuggee/TestDebuggee.csproj b/src/SOS/lldbplugin.tests/TestDebuggee/TestDebuggee.csproj index 8069c5a84b..e6d75050e0 100644 --- a/src/SOS/lldbplugin.tests/TestDebuggee/TestDebuggee.csproj +++ b/src/SOS/lldbplugin.tests/TestDebuggee/TestDebuggee.csproj @@ -1,6 +1,6 @@  Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/Tools/dotnet-counters/dotnet-counters.csproj b/src/Tools/dotnet-counters/dotnet-counters.csproj index 790b04b95d..4631fdc3ac 100644 --- a/src/Tools/dotnet-counters/dotnet-counters.csproj +++ b/src/Tools/dotnet-counters/dotnet-counters.csproj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) true dotnet-counters Microsoft.Diagnostics.Tools.Counters diff --git a/src/Tools/dotnet-dsrouter/dotnet-dsrouter.csproj b/src/Tools/dotnet-dsrouter/dotnet-dsrouter.csproj index b0a498179f..3aade96021 100644 --- a/src/Tools/dotnet-dsrouter/dotnet-dsrouter.csproj +++ b/src/Tools/dotnet-dsrouter/dotnet-dsrouter.csproj @@ -1,7 +1,7 @@  - net6.0 + $(NetCoreAppMinTargetFramework) true dotnet-dsrouter Microsoft.Diagnostics.Tools.DiagnosticsServerRouter @@ -26,6 +26,7 @@ + diff --git a/src/Tools/dotnet-dump/dotnet-dump.csproj b/src/Tools/dotnet-dump/dotnet-dump.csproj index 4926daf5c4..b59b77a51d 100644 --- a/src/Tools/dotnet-dump/dotnet-dump.csproj +++ b/src/Tools/dotnet-dump/dotnet-dump.csproj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) true dotnet-dump Microsoft.Diagnostic.Tools.Dump @@ -12,10 +12,6 @@ tools/$(TargetFramework)/any - - ClrMD2 - - @@ -27,7 +23,7 @@ - + diff --git a/src/Tools/dotnet-gcdump/dotnet-gcdump.csproj b/src/Tools/dotnet-gcdump/dotnet-gcdump.csproj index fc49822593..dd1d268d77 100644 --- a/src/Tools/dotnet-gcdump/dotnet-gcdump.csproj +++ b/src/Tools/dotnet-gcdump/dotnet-gcdump.csproj @@ -1,6 +1,6 @@ - net6.0 + $(NetCoreAppMinTargetFramework) Microsoft.Diagnostics.Tools.GCDump dotnet-gcdump .NET Managed Heap Dump and Analysis Tool diff --git a/src/Tools/dotnet-sos/dotnet-sos.csproj b/src/Tools/dotnet-sos/dotnet-sos.csproj index 071f3638a1..949eb8e557 100644 --- a/src/Tools/dotnet-sos/dotnet-sos.csproj +++ b/src/Tools/dotnet-sos/dotnet-sos.csproj @@ -1,6 +1,6 @@  - net6.0 + $(NetCoreAppMinTargetFramework) dotnet-sos Microsoft.Diagnostics.Tools.SOS Diagnostic SOS installer @@ -21,7 +21,7 @@ - + false diff --git a/src/Tools/dotnet-stack/dotnet-stack.csproj b/src/Tools/dotnet-stack/dotnet-stack.csproj index 74254cdb7a..853e14ab36 100644 --- a/src/Tools/dotnet-stack/dotnet-stack.csproj +++ b/src/Tools/dotnet-stack/dotnet-stack.csproj @@ -1,6 +1,6 @@ - net6.0 + $(NetCoreAppMinTargetFramework) Microsoft.Diagnostics.Tools.Stack dotnet-stack .NET Stack Printing Tool diff --git a/src/Tools/dotnet-symbol/dotnet-symbol.csproj b/src/Tools/dotnet-symbol/dotnet-symbol.csproj index bf363f1a99..d6f440da7f 100644 --- a/src/Tools/dotnet-symbol/dotnet-symbol.csproj +++ b/src/Tools/dotnet-symbol/dotnet-symbol.csproj @@ -1,6 +1,6 @@ - net6.0 + $(NetCoreAppMinTargetFramework) dotnet-symbol Microsoft.Diagnostic.Tools.Symbol Symbols download utility @@ -8,7 +8,7 @@ $(Description) ;1591;1701 - + All @@ -16,9 +16,11 @@ + + - + True @@ -26,7 +28,7 @@ Resources.resx - + ResXFileCodeGenerator diff --git a/src/Tools/dotnet-trace/dotnet-trace.csproj b/src/Tools/dotnet-trace/dotnet-trace.csproj index a4ed81dde4..6e5f9192b2 100644 --- a/src/Tools/dotnet-trace/dotnet-trace.csproj +++ b/src/Tools/dotnet-trace/dotnet-trace.csproj @@ -1,6 +1,6 @@  - net6.0 + $(NetCoreAppMinTargetFramework) Microsoft.Diagnostics.Tools.Trace dotnet-trace .NET Performance Trace Tool diff --git a/src/singlefile-tools.proj b/src/singlefile-tools.proj index 97fc47c979..2af734d3a5 100644 --- a/src/singlefile-tools.proj +++ b/src/singlefile-tools.proj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) win-x64;win-x86;win-arm;win-arm64;linux-x64;linux-musl-arm64;linux-arm64;linux-musl-x64;linux-arm $([System.IO.Path]::GetDirectoryName('$(ArcadeSdkBuildTasksAssembly)'))\..\ $(ArcadeSdkMSBuildProjectDir)Sign.proj @@ -46,8 +46,8 @@ - @@ -69,7 +69,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) $(OutputPath)$(TargetFramework)\Debugger.Tests.Common.txt diff --git a/src/tests/CommonTestRunner/ConfigFiles/Unix/Debugger.Tests.Config.txt b/src/tests/CommonTestRunner/ConfigFiles/Unix/Debugger.Tests.Config.txt index 26de56b088..35c0da8c61 100644 --- a/src/tests/CommonTestRunner/ConfigFiles/Unix/Debugger.Tests.Config.txt +++ b/src/tests/CommonTestRunner/ConfigFiles/Unix/Debugger.Tests.Config.txt @@ -39,9 +39,9 @@ + net10.0 net9.0 net8.0 - net7.0 net6.0 diff --git a/src/tests/CommonTestRunner/ConfigFiles/Windows/Debugger.Tests.Config.txt b/src/tests/CommonTestRunner/ConfigFiles/Windows/Debugger.Tests.Config.txt index 6eefa3c1af..4077d745d4 100644 --- a/src/tests/CommonTestRunner/ConfigFiles/Windows/Debugger.Tests.Config.txt +++ b/src/tests/CommonTestRunner/ConfigFiles/Windows/Debugger.Tests.Config.txt @@ -38,9 +38,9 @@ + net10.0 net9.0 net8.0 - net7.0 net6.0 diff --git a/src/tests/DacCompareNativeTypes/DacCompareNativeTypes.csproj b/src/tests/DacCompareNativeTypes/DacCompareNativeTypes.csproj index 41f1d5ad4b..9552ffe614 100644 --- a/src/tests/DacCompareNativeTypes/DacCompareNativeTypes.csproj +++ b/src/tests/DacCompareNativeTypes/DacCompareNativeTypes.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/DbgShim.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt b/src/tests/DbgShim.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt index 836082dd3c..d6bf7af01d 100644 --- a/src/tests/DbgShim.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt +++ b/src/tests/DbgShim.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt @@ -119,9 +119,9 @@ $(DotNetRoot)/shared/Microsoft.NETCore.App/$(RuntimeFrameworkVersion) + net10.0 net9.0 net8.0 - net7.0 net6.0 diff --git a/src/tests/DbgShim.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt b/src/tests/DbgShim.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt index 27da83b106..b280bd5904 100644 --- a/src/tests/DbgShim.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt +++ b/src/tests/DbgShim.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt @@ -120,9 +120,9 @@ $(DotNetRoot)\shared\Microsoft.NETCore.App\$(RuntimeFrameworkVersion) + net10.0 net9.0 net8.0 - net7.0 net6.0 $(InstallDir)\dbgshim.dll diff --git a/src/tests/DbgShim.UnitTests/DbgShim.UnitTests.csproj b/src/tests/DbgShim.UnitTests/DbgShim.UnitTests.csproj index e8fe6766f1..7af9023141 100644 --- a/src/tests/DbgShim.UnitTests/DbgShim.UnitTests.csproj +++ b/src/tests/DbgShim.UnitTests/DbgShim.UnitTests.csproj @@ -1,7 +1,7 @@  - net6.0 + $(NetCoreAppMinTargetFramework) true $(OutputPath)$(TargetFramework)\Debugger.Tests.Common.txt 1.0.351101 @@ -26,17 +26,17 @@ Always - + - + - + diff --git a/src/tests/DbgShim.UnitTests/Debuggees/SimpleDebuggee/SimpleDebuggee.csproj b/src/tests/DbgShim.UnitTests/Debuggees/SimpleDebuggee/SimpleDebuggee.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/tests/DbgShim.UnitTests/Debuggees/SimpleDebuggee/SimpleDebuggee.csproj +++ b/src/tests/DbgShim.UnitTests/Debuggees/SimpleDebuggee/SimpleDebuggee.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/tests/Directory.Build.props b/src/tests/Directory.Build.props index e69bc2090e..9abe7d34cd 100644 --- a/src/tests/Directory.Build.props +++ b/src/tests/Directory.Build.props @@ -4,8 +4,6 @@ $(Platform) $([System.Runtime.InteropServices.RuntimeInformation]::ProcessArchitecture.ToString().ToLowerInvariant) - net6.0;net7.0;net8.0 - net6.0;net7.0;net8.0;net9.0 diff --git a/src/tests/EventPipeStress/Orchestrator/Orchestrator.csproj b/src/tests/EventPipeStress/Orchestrator/Orchestrator.csproj index 020212c80d..003cca3083 100644 --- a/src/tests/EventPipeStress/Orchestrator/Orchestrator.csproj +++ b/src/tests/EventPipeStress/Orchestrator/Orchestrator.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/EventPipeStress/Stress/Stress.csproj b/src/tests/EventPipeStress/Stress/Stress.csproj index 24cd03482b..3277f12440 100644 --- a/src/tests/EventPipeStress/Stress/Stress.csproj +++ b/src/tests/EventPipeStress/Stress/Stress.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/EventPipeTracee/EventPipeTracee.csproj b/src/tests/EventPipeTracee/EventPipeTracee.csproj index f02e3fee9e..39e40b1eea 100644 --- a/src/tests/EventPipeTracee/EventPipeTracee.csproj +++ b/src/tests/EventPipeTracee/EventPipeTracee.csproj @@ -2,14 +2,13 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) - NET8_0_OR_GREATER + $(SupportedSubProcessTargetFrameworks) - + diff --git a/src/tests/ExitCodeTracee/ExitCodeTracee.csproj b/src/tests/ExitCodeTracee/ExitCodeTracee.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/tests/ExitCodeTracee/ExitCodeTracee.csproj +++ b/src/tests/ExitCodeTracee/ExitCodeTracee.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/tests/Grape/Grape.csproj b/src/tests/Grape/Grape.csproj index e72911e15d..2b42ad1cf3 100644 --- a/src/tests/Grape/Grape.csproj +++ b/src/tests/Grape/Grape.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/Microsoft.Diagnostics.DebugServices.UnitTests/Microsoft.Diagnostics.DebugServices.UnitTests.csproj b/src/tests/Microsoft.Diagnostics.DebugServices.UnitTests/Microsoft.Diagnostics.DebugServices.UnitTests.csproj index 97c94e74db..c6efc5cfd9 100644 --- a/src/tests/Microsoft.Diagnostics.DebugServices.UnitTests/Microsoft.Diagnostics.DebugServices.UnitTests.csproj +++ b/src/tests/Microsoft.Diagnostics.DebugServices.UnitTests/Microsoft.Diagnostics.DebugServices.UnitTests.csproj @@ -1,7 +1,7 @@  - net6.0 + $(NetCoreAppMinTargetFramework) $(OutputPath)$(TargetFramework)\Debugger.Tests.Common.txt 1.0.351101 @@ -18,18 +18,18 @@ - + - + - + Debugger.Tests.Config.txt @@ -40,7 +40,7 @@ Always - + diff --git a/src/tests/Microsoft.Diagnostics.Monitoring.EventPipe/Microsoft.Diagnostics.Monitoring.EventPipe.UnitTests.csproj b/src/tests/Microsoft.Diagnostics.Monitoring.EventPipe/Microsoft.Diagnostics.Monitoring.EventPipe.UnitTests.csproj index 0681d15467..0e99221cc1 100644 --- a/src/tests/Microsoft.Diagnostics.Monitoring.EventPipe/Microsoft.Diagnostics.Monitoring.EventPipe.UnitTests.csproj +++ b/src/tests/Microsoft.Diagnostics.Monitoring.EventPipe/Microsoft.Diagnostics.Monitoring.EventPipe.UnitTests.csproj @@ -1,7 +1,7 @@  - $(UnitTestTargetFrameworks) + $(SupportedXUnitTestTargetFrameworks) diff --git a/src/tests/Microsoft.Diagnostics.Monitoring/Microsoft.Diagnostics.Monitoring.UnitTests.csproj b/src/tests/Microsoft.Diagnostics.Monitoring/Microsoft.Diagnostics.Monitoring.UnitTests.csproj index d56445933f..d46d2645b6 100644 --- a/src/tests/Microsoft.Diagnostics.Monitoring/Microsoft.Diagnostics.Monitoring.UnitTests.csproj +++ b/src/tests/Microsoft.Diagnostics.Monitoring/Microsoft.Diagnostics.Monitoring.UnitTests.csproj @@ -1,7 +1,7 @@  - $(UnitTestTargetFrameworks) + $(SupportedXUnitTestTargetFrameworks) diff --git a/src/tests/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.UnitTests.csproj b/src/tests/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.UnitTests.csproj index 8db5cfa78f..0737076d0e 100644 --- a/src/tests/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.UnitTests.csproj +++ b/src/tests/Microsoft.Diagnostics.NETCore.Client/Microsoft.Diagnostics.NETCore.Client.UnitTests.csproj @@ -1,7 +1,7 @@  - $(UnitTestTargetFrameworks) + $(SupportedXUnitTestTargetFrameworks) diff --git a/src/tests/Microsoft.FileFormats.UnitTests/Microsoft.FileFormats.UnitTests.csproj b/src/tests/Microsoft.FileFormats.UnitTests/Microsoft.FileFormats.UnitTests.csproj index 59a73891df..35b78f4be7 100644 --- a/src/tests/Microsoft.FileFormats.UnitTests/Microsoft.FileFormats.UnitTests.csproj +++ b/src/tests/Microsoft.FileFormats.UnitTests/Microsoft.FileFormats.UnitTests.csproj @@ -1,12 +1,12 @@ - net6.0 + $(NetCoreAppMinTargetFramework) ;1591;1701 - + PreserveNewest diff --git a/src/tests/Microsoft.SymbolStore.UnitTests/Microsoft.SymbolStore.UnitTests.csproj b/src/tests/Microsoft.SymbolStore.UnitTests/Microsoft.SymbolStore.UnitTests.csproj index 04396b193c..b3a103a3fa 100644 --- a/src/tests/Microsoft.SymbolStore.UnitTests/Microsoft.SymbolStore.UnitTests.csproj +++ b/src/tests/Microsoft.SymbolStore.UnitTests/Microsoft.SymbolStore.UnitTests.csproj @@ -1,9 +1,9 @@ - net6.0 + $(NetCoreAppMinTargetFramework) ;1591;1701 - + diff --git a/src/tests/StackTracee/StackTracee.csproj b/src/tests/StackTracee/StackTracee.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/tests/StackTracee/StackTracee.csproj +++ b/src/tests/StackTracee/StackTracee.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/tests/Tracee/Tracee.csproj b/src/tests/Tracee/Tracee.csproj index 03cd2f5e0e..644ea7fa32 100644 --- a/src/tests/Tracee/Tracee.csproj +++ b/src/tests/Tracee/Tracee.csproj @@ -2,6 +2,6 @@ Exe $(BuildProjectFramework) - $(BuildTargetFrameworks) + $(SupportedSubProcessTargetFrameworks) diff --git a/src/tests/benchmarks/benchmarks.csproj b/src/tests/benchmarks/benchmarks.csproj index 5173a12603..8e11bb4eb2 100644 --- a/src/tests/benchmarks/benchmarks.csproj +++ b/src/tests/benchmarks/benchmarks.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/dotnet-counters/DotnetCounters.UnitTests.csproj b/src/tests/dotnet-counters/DotnetCounters.UnitTests.csproj index 00f6e91c0d..435bf3a738 100644 --- a/src/tests/dotnet-counters/DotnetCounters.UnitTests.csproj +++ b/src/tests/dotnet-counters/DotnetCounters.UnitTests.csproj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/dotnet-stack/DotnetStack.UnitTests.csproj b/src/tests/dotnet-stack/DotnetStack.UnitTests.csproj index 8290545959..d6b536f04d 100644 --- a/src/tests/dotnet-stack/DotnetStack.UnitTests.csproj +++ b/src/tests/dotnet-stack/DotnetStack.UnitTests.csproj @@ -1,7 +1,7 @@ - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/dotnet-trace/DotnetTrace.UnitTests.csproj b/src/tests/dotnet-trace/DotnetTrace.UnitTests.csproj index fb372850fe..2ec652b315 100644 --- a/src/tests/dotnet-trace/DotnetTrace.UnitTests.csproj +++ b/src/tests/dotnet-trace/DotnetTrace.UnitTests.csproj @@ -1,7 +1,7 @@  - net6.0 + $(NetCoreAppMinTargetFramework) diff --git a/src/tests/eventpipe/EventPipe.UnitTests.csproj b/src/tests/eventpipe/EventPipe.UnitTests.csproj index efa46f1b5c..d375aac992 100644 --- a/src/tests/eventpipe/EventPipe.UnitTests.csproj +++ b/src/tests/eventpipe/EventPipe.UnitTests.csproj @@ -1,7 +1,7 @@  - $(UnitTestTargetFrameworks) + $(SupportedXUnitTestTargetFrameworks)