Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

+gnu.org/glibc #147

Open
wants to merge 21 commits into
base: main
Choose a base branch
from
Open

+gnu.org/glibc #147

wants to merge 21 commits into from

Conversation

jhheider
Copy link
Contributor

@jhheider jhheider commented Jan 28, 2023

  • debootstrap binutils/gcc
  • build glibc
  • use glibc without segfault

@mxcl // @jonchang I'd love some eyes on this. Currently, things using the new glibc like to segfault. I'm guessing I need to runtime.env.$some_env_vars to make it first on the list of libcs looked for.

@what-the-diff
Copy link

what-the-diff bot commented Jan 28, 2023

  • binutils:
    • added 2.40 version, moved v2.39 to '2.39' (string)
    • removed bootstrap block for linux platform in build script; now depends on gcc/binutils package instead of installing via apt-get directly
    • changed test from objdump | grep $TEST_STRING to objdump | grep "$TEST_STRING" and also added a second line with the same command but using grep with the -s flag so that it will exit nonzero if no match is found

@jhheider
Copy link
Contributor Author

I probably need to move the binutils/gcc stuff out to peel out the bootstraps.

@jhheider jhheider force-pushed the +glibc branch 7 times, most recently from 1dce9da to 2f3d528 Compare February 11, 2023 00:01
@jhheider jhheider force-pushed the +glibc branch 2 times, most recently from 4bf6560 to e3f1734 Compare March 5, 2023 05:26
@jhheider jhheider force-pushed the +glibc branch 2 times, most recently from 2c3a4d0 to 3df19ad Compare March 31, 2023 18:15
@jhheider jhheider marked this pull request as ready for review March 31, 2023 18:39
@jhheider
Copy link
Contributor Author

This passes testing, though I'm far from sure it's actually testing what I think it is. Next step is to make tea for linux selectively use it for tea-provided binaries iff the system's glibc is too old. 👀

exit 1
;;
esac
gcc \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-nostdinc & -nostdlib

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that looks less promising. you sure we want both?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it'll stop it using the system headers and libraries… which is surely what we want?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh ok I see. gcc considers glibc’s headers and libraries the system libraries…?

The goal is for gcc to only use glibc and tea libs, nothing from /usr/lib or /lib or /include or /usr/include etc.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

which means, I think, providing the init loader from libgcc. we'll see.

@mxcl
Copy link
Member

mxcl commented Sep 13, 2023

this pr has become epic in scope and effort

@felipecrs
Copy link
Contributor

felipecrs commented Sep 13, 2023

no wonder, it basically solves one of the world's biggest problems (i.e allows to run anything on alpine)

@jhheider jhheider added the help wanted Extra attention is needed label Dec 27, 2023
mxcl added a commit to pkgxdev/pkgx that referenced this pull request Jan 16, 2024
mxcl added a commit to pkgxdev/pkgx that referenced this pull request Jan 16, 2024
@mxcl mxcl mentioned this pull request Jan 17, 2024
@mxcl mxcl mentioned this pull request Feb 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot be used for older glibc libs
3 participants