Preliminary Ada support#134
Open
1ma wants to merge 1 commit into
Open
Conversation
Author
|
I now tried bootstrapping MCM from the first toolchain and rebuilding the projects I mentioned in #133, everything still works :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before I forget, here is the rationale for each change. They've been gathered from several places but I haven't copied the patches verbatim, only what I seemed to need.
With this patch I've been able to build GNAT 9.4.0 targeting x86_64-linux-musl on Alpine Linux 3.12 with just the
build-baseandgcc-gnatpackages as prerequisites.Removed
callocfrompragma GCC poisonThis is actually the only thing that prevented GCC from building, the other patches fix runtime errors. I found the cure in an old email thread from the musl mailing list
Prevent compilation of
s-tsmona__linux.adbOrigin: https://gitlab.alpinelinux.org/alpine/aports/-/blob/fbd708d54ad9ec01f3927e760ef241f3a436b6fb/main/gcc/0027-ada-musl-support-fixes.patch
This fixes an undefined reference to the
_r_debugsymbol that happens at runtime when executing even the simplest hello world Ada program.Remove bindings to
pthread_mutexattr_setprioceilingandpthread_rwlockattr_setkind_npOrigin: https://gitlab.alpinelinux.org/alpine/aports/-/blob/fbd708d54ad9ec01f3927e760ef241f3a436b6fb/main/gcc/0026-ada-libgnarl-compatibility-for-musl.patch
pthread_rwlockattr_setkind_npis not defined in musl andpthread_mutexattr_setprioceilinghasn't exactly the same layout as glibc or something. I got undefined references to these symbols at link time while attempting to build GPRBuild. The original patch was precisely created for GPRBuild