-
Notifications
You must be signed in to change notification settings - Fork 701
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
Harden dummy:dummy binutils #2228
Conversation
By adding the system library path using the `rpath` option, the resulting binaries should be 'harden' to work in an environment with a other libstdc++ etc. The rpath will make sure it always finds the correct library.
Test report by @wpoely86 |
Test report by @wpoely86 |
Verification by
|
Test report by @wpoely86 |
Easyconfigs unit test suite PASSed (see https://jenkins1.ugent.be/job/easybuild-easyconfigs-pr-builder/5353/console for more details). This pull request is now ready for review/testing. Please try and find someone who can tackle this; contact @boegel if you're not sure what to do. |
prebuildopts = 'LIBS="$EBROOTZLIB/lib/libz.a"' | ||
# further, add the system library path in the rpath: this should 'harden' the | ||
# resulting binutils to bootstrap GCC (no trouble when other libstdc++ is build etc) | ||
preconfigopts = 'LIBS="$EBROOTZLIB/lib/libz.a -Wl,-rpath=/lib64 -Wl,-rpath=/usr/lib64 -Wl,-rpath=/lib -Wl,-rpath=/usr/lib"' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can't combine all the rpath
chunks in a single one?
-Wl,-rpath=/lib64:/usr/lib64:/lib:/usr/lib"
Haven't checked, but I would fine it weird if this is not supported.
This is screaming for support in framework btw. ;-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The shortest form I can find is:
-Wl,-rpath=/lib64,-rpath=/usr/lib64,-rpath=/lib,-rpath=/usr/lib
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the framework support, follow up in easybuilders/easybuild-framework#651
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure whether it's a good idea to include something like this so close to the release... On the other hand, I guess just building this + GCC on top of its is going to tell us whether it causes any problems? @geimer, @ocaisa: do you think something like this may have fallout in one way or another? |
Test report by @boegel |
built on top of this binutils (all easyconfigs that use a dummy-built binutils): https://gist.github.com/ea03dd15f457abefdc3f |
Just made very sure that this doesn't "trickle up" to stuff build on top of this binutils, it doesn't (seem to):
cc @ocaisa |
Given the way the mainline toolchains (foss, intel) are constructed in the next release (with a new binutils built on top of the compiled GCC) I can't see any problem for them. Also since the dummy binutils libs are not dynamic there's no issue there. I guess the only impact would be if this somehow affected the behaviour of the linker...but from GCC at least that doesn't seem to be the case. |
I rebuilt more than just GCC on top of this, see https://gist.github.com/ea03dd15f457abefdc3f . So, should be good to go, I'm merging this in, so @geimer can come back to us later to tell us this is the worst idea ever. ;-) |
Thanks @wpoely86! |
…ention OpenFOAM 3.0.0 in v2.5.0 release notes
This relies on But to be honest, I also can't think of a better alternative at the moment. |
@geimer yes, I'm aware. I've been playing with And, it's indeed quite dirty. But this binutils should only be used once for building GCC and then thrown away. |
By adding the system library path using the
rpath
option, theresulting binaries should be 'harden' to work in an environment with a
other libstdc++ etc. The rpath will make sure it always finds the
correct library.
Fix for #2188