Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions Make.config
Original file line number Diff line number Diff line change
Expand Up @@ -510,10 +510,11 @@ DOTNET_FEED_DIR ?= $(DOTNET_DESTDIR)/nuget-feed

BUNDLED_NETCORE_PLATFORMS_PACKAGE_VERSION:=$(shell if test -f $(TOP)/builds/BundledNETCorePlatformsPackageVersion.txt; then cat $(TOP)/builds/BundledNETCorePlatformsPackageVersion.txt; else echo "run-make-in-builds-directory-first"; fi)

DOTNET6_VERSION=6.0.100-preview.2.21155.3
DOTNET6_VERSION=6.0.100-preview.3.21161.23
DOTNET6_VERSION_BAND=$(firstword $(subst -, ,$(DOTNET6_VERSION)))
DOTNET6_URL=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/6.0.100-preview.2.21155.3/dotnet-sdk-6.0.100-preview.2.21155.3-osx-x64.pkg
DOTNET6_TARBALL=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/6.0.100-preview.2.21155.3/dotnet-sdk-6.0.100-preview.2.21155.3-osx-x64.tar.gz
DOTNET6_URL=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/6.0.100-preview.3.21161.23/dotnet-sdk-6.0.100-preview.3.21161.23-osx-x64.pkg
DOTNET6_TARBALL=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/6.0.100-preview.3.21161.23/dotnet-sdk-6.0.100-preview.3.21161.23-osx-x64.tar.gz

DOTNET6_TARBALL_NAME=$(notdir $(DOTNET6_TARBALL))
DOTNET6_DIR=$(abspath $(TOP)/builds/downloads/$(basename $(basename $(DOTNET6_TARBALL_NAME))))
DOTNET6=$(DOTNET6_DIR)/dotnet
Expand Down
2 changes: 1 addition & 1 deletion tests/bgen/bgen-tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<PackageReference Include="NUnit3TestAdapter" Version="3.15.1" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" />
<PackageReference Include="Mono.Cecil" Version="0.11.2" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.303" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>

<ItemGroup>
Expand Down
42 changes: 40 additions & 2 deletions tests/common/BinLog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,49 @@ public static IEnumerable<string> PrintToLines (string path)
if (args is ProjectStartedEventArgs psea) {
if (psea.Properties != null) {
yield return "Initial Properties";
foreach (var prop in psea.Properties.Cast<System.Collections.DictionaryEntry> ().OrderBy (v => v.Key))
yield return $"{prop.Key} = {prop.Value}";
var dict = psea.Properties as IDictionary<string, string>;
if (dict == null) {
yield return $"Unknown property dictionary type: {psea.Properties.GetType ().FullName}";
} else {
foreach (var prop in dict.OrderBy (v => v.Key))
yield return $"{prop.Key} = {prop.Value}";
}
}
}

if (args is TaskParameterEventArgs tpea) {
switch (tpea.Kind) {
case TaskParameterMessageKind.AddItem:
yield return "Added Item(s)";
break;
case TaskParameterMessageKind.RemoveItem:
yield return "Removed Item(s)";
break;
case TaskParameterMessageKind.TaskInput:
yield return "Task Parameter";
break;
case TaskParameterMessageKind.TaskOutput:
yield return "Output Item(s)";
break;
default:
yield return $"Unknown Kind ({tpea.Kind})";
break;
}
foreach (var item in tpea.Items) {
var taskItem = item as ITaskItem;
yield return $"\t{tpea.ItemType}=";
if (taskItem != null) {
yield return $"\t\t{taskItem.ItemSpec}";
foreach (var metadataName in taskItem.MetadataNames) {
yield return $"\t\t\t{metadataName}={taskItem.GetMetadata (metadataName?.ToString ())}";
}
} else {
yield return $"\t{item}";
}
}
continue;
}

foreach (var line in args.Message.Split (eols, System.StringSplitOptions.RemoveEmptyEntries))
yield return line;
}
Expand Down
2 changes: 1 addition & 1 deletion tests/dotnet/UnitTests/DotNetUnitTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<PackageReference Include="NUnit3TestAdapter" Version="3.15.1" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" />
<PackageReference Include="Mono.Cecil" Version="0.11.2" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.303" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion tests/generator/generator-tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<PackageReference Include="NUnit" Version="3.12.0" />
<PackageReference Include="NUnit.ConsoleRunner" Version="3.11.1" />
<PackageReference Include="Mono.Cecil" Version="0.11.1" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.303" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>
<ItemGroup>
<Compile Include="ErrorTests.cs" />
Expand Down
12 changes: 12 additions & 0 deletions tests/linker/ios/link all/Main.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,16 @@ static void Main (string[] args)
}
#endif // !__WATCHOS__
}

#if NET
// https://github.com/mono/linker/issues/1913
[Foundation.Preserve (AllMembers = true)]
class Preserver
{
public Preserver ()
{
GC.KeepAlive (new System.Runtime.CompilerServices.InternalsVisibleToAttribute ("preserve this constructor"));
}
}
#endif
}
4 changes: 1 addition & 3 deletions tests/mmptest/mmptest.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,7 @@
<HintPath>..\..\_mac-build\Library\Frameworks\Xamarin.Mac.framework\Versions\git\lib\mmp\mmp.exe</HintPath>
</Reference>
<PackageReference Include="Mono.Cecil" Version="0.11.1" />
<PackageReference Include="MSBuild.StructuredLogger">
<Version>2.1.176</Version>
</PackageReference>
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>
<ItemGroup>
<Folder Include="Resources\" />
Expand Down
4 changes: 2 additions & 2 deletions tests/msbuild/Xamarin.MacDev.Tests/TestHelpers/BuildEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,9 @@ public void ParseBinLog (string log)
} else if (args is ProjectEvaluationStartedEventArgs projectEvaluationStarted) {
if (verbose)
Console.WriteLine ($"ProjectEvaluationStarted: {projectEvaluationStarted.ProjectFile}");
} else if (args is ProjectEvaluationFinishedEventArgs projectEvaluationFinished) {
} else if (args.GetType ().Name == "ProjectEvaluationFinishedEventArgs") {
if (verbose)
Console.WriteLine ($"ProjectEvaluationFinished: {projectEvaluationFinished.ProjectFile}");
Console.WriteLine ($"ProjectEvaluationFinished: {args}");
} else if (args is ProjectStartedEventArgs projectStarted) {
if (verbose)
Console.WriteLine ($"ProjectStarted: {projectStarted.ProjectFile}");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<PackageReference Include="NUnit.ConsoleRunner" Version="3.11.1" />
<PackageReference Include="NUnit.Extension.NUnitV2ResultWriter" Version="3.6.0" />
<PackageReference Include="Mono.Cecil" Version="0.11.1" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.303" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\..\mtouch\Cache.cs">
Expand Down
2 changes: 1 addition & 1 deletion tests/mtouch/mtouch.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<PackageReference Include="NUnit" Version="3.12.0" />
<PackageReference Include="NUnit.ConsoleRunner" Version="3.11.1" />
<PackageReference Include="Mono.Cecil" Version="0.11.1" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.303" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.364" />
</ItemGroup>
<ItemGroup>
<Compile Include="MTouch.cs" />
Expand Down
6 changes: 1 addition & 5 deletions tools/dotnet-linker/LinkerConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -309,11 +309,7 @@ public void Write ()

public string GetAssemblyFileName (AssemblyDefinition assembly)
{
// See: https://github.com/mono/linker/issues/1313
// Call LinkContext.Resolver.GetAssemblyFileName (https://github.com/mono/linker/blob/da2cc0fcd6c3a8e8e5d1b5d4a655f3653baa8980/src/linker/Linker/AssemblyResolver.cs#L88) using reflection.
var resolver = typeof (LinkContext).GetProperty ("Resolver").GetValue (Context);
var filename = (string) resolver.GetType ().GetMethod ("GetAssemblyFileName", new Type [] { typeof (AssemblyDefinition) }).Invoke (resolver, new object [] { assembly });
return filename;
return Context.GetAssemblyLocation (assembly);
}

public void WriteOutputForMSBuild (string itemName, List<MSBuildItem> items)
Expand Down
2 changes: 1 addition & 1 deletion tools/dotnet-linker/dotnet-linker.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="XliffTasks" Version="1.0.0-beta.20154.1" />
<PackageReference Include="Microsoft.NET.ILLink" Version="6.0.0-alpha.1.21065.1" />
<PackageReference Include="Microsoft.NET.ILLink" Version="6.0.100-preview.2.21166.1" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\common\ApplePlatform.cs">
Expand Down