Closed mthalman closed 1 week ago
Alpine320_Online_MsftSdk_x64 (internal Microsoft link) tests also failed with the same issue:
Failed to load /vmr/artifacts/bin/Microsoft.DotNet.SourceBuild.SmokeTests/Release/projects-202408290823141750/BasicScenarioTests_Console_VB/bin/publish/libhostpolicy.so, error: Error loading shared library ld-linux-x86-64.so.2: No such file or directory (needed by /vmr/artifacts/bin/Microsoft.DotNet.SourceBuild.SmokeTests/Release/projects-202408290823141750/BasicScenarioTests_Console_VB/bin/publish/libhostpolicy.so)
An error occurred while loading required library libhostpolicy.so from [/vmr/artifacts/bin/Microsoft.DotNet.SourceBuild.SmokeTests/Release/projects-202408290823141750/BasicScenarioTests_Console_VB/bin/publish/]
@mthalman - what is the fix here? Does SB need to be re-bootstrapped?
Looks like the wrong RID is being used. From the test output: publish --self-contained true -r linux-x64
. It should be using linux-musl-x64
instead.
I don't understand how this ever worked. It's always set the RID to linux-x64
even in past versions when this was working: https://github.com/dotnet/dotnet/blob/0d9fcc105f4c482ebde73e3b513053a53a9792a1/test/Microsoft.DotNet.SourceBuild.SmokeTests/TestScenario.cs#L62
Did it work because is was just publishing linux-x64 from an alpine alpine environment, it was not actually running the published application? Now something changes which bundles linker library with the app?
It does run the application and always has in past .NET versions. It's really weird. I tried changing the RID to linux-musl-x64 and it worked. Interestingly, it also worked in the CentOS leg.
Example build (internal link)
This is a regression caused by https://github.com/dotnet/sdk/pull/42969