-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Make sure openssl compiles with only one core #41563
Make sure openssl compiles with only one core #41563
Conversation
@bors: r+ p=10 Holy cow nice find! That'd do it... |
📌 Commit 367e907 has been approved by |
… r=alexcrichton Make sure openssl compiles with only one core This is (hopefully) a fix for the osx openssl spurious failure - #40417. The intermittent failures and failing in different ways made me think of a race condition. But programs are parallel make safe right? [Not openssl](openssl/openssl#298). But we don't do a parallel make on openssl [do we](https://github.com/rust-lang/rust/blob/8c4f2c64c6759a82f143e23964a46a65c67509c9/src/bootstrap/native.rs#L309)? This confused me, except "Waiting for unfinished jobs" is present in the logs...which is evidence of a parallel make! It turns out that when we invoke to top level target [in run.sh](https://github.com/rust-lang/rust/blob/036983201d4e9aeb5c5e56e47c305971972b2569/src/ci/run.sh#L75-L77), make will [pass the flags downwards](https://www.gnu.org/software/make/manual/html_node/Options_002fRecursion.html) in order to take advantage of parallelism in sub-makes. Of course, we don't want this in openssl! Override this by explicitly disabling parallelism on the command line. I don't know why this hasn't happened on anything except OSX. Maybe Linux binutils check if the file is in use? r? @alexcrichton
libressl is not reproduced? |
@denji sorry, I'm not sure what you're asking - can you elaborate? |
@aidanhs my question: build libressl instead of openssl can solve the problem of parallel make? |
@denji ah I see. To be honest, I don't know. I can't see anything in the git log for libressl that suggests they've done anything about it, so my instinctive answer is "no". That said, openssl have put some effort in (here and here), so potentially upgrading to 1.1.0 might also fix our issue. If we verify that this PR fixes the failure over a period of a few weeks, then we could consider an experiment to upgrade to openssl 1.1.0 with an eye kept out for future failures. For now this PR is probably the fix with the lowest risk (assuming it works!). |
☀️ Test successful - status-appveyor, status-travis |
This is (hopefully) a fix for the osx openssl spurious failure - #40417.
The intermittent failures and failing in different ways made me think of a race condition. But programs are parallel make safe right? Not openssl. But we don't do a parallel make on openssl do we? This confused me, except "Waiting for unfinished jobs" is present in the logs...which is evidence of a parallel make!
It turns out that when we invoke to top level target in run.sh, make will pass the flags downwards in order to take advantage of parallelism in sub-makes. Of course, we don't want this in openssl! Override this by explicitly disabling parallelism on the command line.
I don't know why this hasn't happened on anything except OSX. Maybe Linux binutils check if the file is in use?
r? @alexcrichton