Skip to content

Fix KeepNativeSymbols to work on mono as well - #66594

Merged
directhex merged 1 commit into
dotnet:mainfrom
omajid:fix-keep-native-symbols-mono-s390x
May 16, 2022
Merged

Fix KeepNativeSymbols to work on mono as well#66594
directhex merged 1 commit into
dotnet:mainfrom
omajid:fix-keep-native-symbols-mono-s390x

Conversation

@omajid

Copy link
Copy Markdown
Member

When packaging .NET on s390x through source-build, we want to keep debug
symbols enabled in the build. The package manager (debbuild, rpmbuild,
etc) generally strips the binaries to create distro-standard
-debug/-debuginfo packages. This was supported in coreclr via
--keepnativesymbols flag, but wasn't supported in mono (ie, s390x). Fix
that.

When packaging .NET on s390x through source-build, we want to keep debug
symbols enabled in the build. The package manager (debbuild, rpmbuild,
etc) generally strips the binaries to create distro-standard
-debug/-debuginfo packages. This was supported in coreclr via
--keepnativesymbols flag, but wasn't supported in mono (ie, s390x). Fix
that.
@ghostghost added area-Build-mono community-contribution Indicates that the PR has been added by a community member labels Mar 14, 2022
@omajid

Copy link
Copy Markdown
MemberAuthor

@uweigand I only tested this on x64, can you help me confirm that this works on s390x as well? I have been building with

CXXFLAGS=-g CFLAGS=-g ./build.sh -c Release --keepnativesymbols true

And looking at the presence of debug symbols in "libcoreclr.so"

@omajid

Copy link
Copy Markdown
MemberAuthor

I have verified this on s390x.

The mono llvmfullaot errors look unrelated, can anyone confirm?

@omajid

Copy link
Copy Markdown
MemberAuthor

@marek-safar@uweigand can you please take a look at this?

@marek-safar

Copy link
Copy Markdown
Contributor

@directhex how does this look to you?

@omajid

Copy link
Copy Markdown
MemberAuthor

Ping. Any review/feedback would be nice.

We have included this change for our 6.0 builds on RHEL/CentOS already: https://git.centos.org/rpms/dotnet6.0/blob/3afb15f24b3fc61da3d56a3e8269f85d084cb71a/f/SOURCES/runtime-66594-s390x-debuginfo.patch

@omajid

Copy link
Copy Markdown
MemberAuthor

Any thoughts, @directhex?

@directhex
directhex merged commit 29e3bf0 into dotnet:mainMay 16, 2022
@ghostghost locked as resolved and limited conversation to collaborators Jun 15, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-Build-monocommunity-contributionIndicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@omajid@marek-safar@directhex