-
Notifications
You must be signed in to change notification settings - Fork 81
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 macOS bindist configure more deterministic #1462
Conversation
With this change, on GitHub Actions the build goes down from 36 minutes to less than 13 minutes. With a 99.9% cache hit rate on BuildBuddy. |
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.
Great, thanks for tracking this down!
3ff569a
to
726bb31
Compare
This makes me think that we should also be passing |
If we used |
GHC from a bindist requires running `./configure` and then `make install`. One would assume that the result is always the same, in particular if we run this twice on the same host with the same environment variables. However, this is not the case. See #1461. The fix is to set an environment variable telling `ar` and friends to not futz around with timestamps in static library archives. This environment variable is only necessary and only has an effect on macOS, but there's no harm in setting it always. If the bindists stop having a configure stage, or start using `libtool` instead of `ar` and `ranlib`, then the fix will better be pushed within the bindists themselves, using the `-D` flag to `libtool`, introduced in XCode 10.2. Fixes #1461.
726bb31
to
db86f9a
Compare
GHC from a bindist requires running
./configure
and thenmake install
. One would assume that the result is always the same, inparticular if we run this twice on the same host with the same
environment variables. However, this is not the case. See #1461.
The fix is to set an environment variable telling
ar
and friends tonot futz around with timestamps in static library archives. This
environment variable is only necessary and only has an effect on
macOS, but there's no harm in setting it always. If the bindists stop
having a configure stage, or start using
libtool
instead ofar
andranlib
, then the fix will better be pushed within the bindiststhemselves, using the
-D
flag tolibtool
, introduced in XCode10.2.
Fixes #1461.