Skip to content

ld/macho: add all missing load commands #25906

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

Closed

Conversation

mistydemeo
Copy link
Contributor

@mistydemeo mistydemeo commented Jun 15, 2018

The ld/macho code currently understands a subset of the mach-o load
commands. I've encountered one of these in the wild in a Go-produced
binary, which tripped up the Go linker because its switch statement
expects its list of load commands to be exhaustive; the rest I've
added for the sake of completion.

The ruby-macho library is a good non-Darwin header resource for these:
https://github.com/homebrew/ruby-macho

Fixes #25908

@googlebot googlebot added the cla: yes Used by googlebot to label PRs as having a valid CLA. The text of this label should not change. label Jun 15, 2018
@gopherbot
Copy link
Contributor

This PR (HEAD: 655e3f4) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/#/c/go/+/119115 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 1:

Congratulations on opening your first change. Thank you for your contribution!

Next steps:
Within the next week or so, a maintainer will review your change and provide
feedback. See https://golang.org/doc/contribute.html#review for more info and
tips to get your patch through code review.

Most changes in the Go project go through a few rounds of revision. This can be
surprising to people new to the project. The careful, iterative review process
is our way of helping mentor contributors and ensuring that their contributions
have a lasting impact.

During May-July and Nov-Jan the Go project is in a code freeze, during which
little code gets reviewed or merged. If a reviewer responds with a comment like
R=go1.11, it means that this CL will be reviewed as part of the next development
cycle. See https://golang.org/s/release for more details.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 1:

[+iant]

Misty, unless this fixes a currently-open bug for Go 1.11, we're generally pushing off all changes until August when the Go 1.12 tree opens. (https://github.com/golang/go/wiki/Go-Release-Cycle)

If there's not an open bug, though, please open one with more details. We generally leave most discussion & details on GitHub and just have commits reference the issues.

Thanks.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Misty De Méo:

Patch Set 1:

Patch Set 1:

[+iant]

Misty, unless this fixes a currently-open bug for Go 1.11, we're generally pushing off all changes until August when the Go 1.12 tree opens. (https://github.com/golang/go/wiki/Go-Release-Cycle)

If there's not an open bug, though, please open one with more details. We generally leave most discussion & details on GitHub and just have commits reference the issues.

Sorry for not opening a bug first! This does fix a specific bug I've encountered. I've filed one on GitHub: #25908


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Ian Lance Taylor:

Patch Set 1: Run-TryBot+1

This is OK for 1.11.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 1:

TryBots beginning. Status page: https://farmer.golang.org/try?commit=952816ae


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Ian Lance Taylor:

Patch Set 1:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 1:

Build is still in progress...
This change failed on misc-vet-vetall:
See https://storage.googleapis.com/go-build-log/952816ae/misc-vet-vetall_73df0fd2.log

Consult https://build.golang.org/ to see whether it's a new failure. Other builds still in progress; subsequent failure notices suppressed until final report.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 1: TryBot-Result-1

1 of 17 TryBots failed:
Failed on misc-vet-vetall: https://storage.googleapis.com/go-build-log/952816ae/misc-vet-vetall_73df0fd2.log

Consult https://build.golang.org/ to see whether they are new failures.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Misty De Méo:

Patch Set 2: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gerrit Bot:

Uploaded patch set 3: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gerrit Bot:

Uploaded patch set 4: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

gopherbot pushed a commit that referenced this pull request Jun 15, 2018
The ld/macho code currently understands a subset of the mach-o load
commands. I've encountered one of these in the wild in a Go-produced
binary, which tripped up the Go linker because its switch statement
expects its list of load commands to be exhaustive; the rest I've
added for the sake of completion.

The ruby-macho library is a good non-Darwin header resource for these:
https://github.com/homebrew/ruby-macho

Fixes #25908

Change-Id: Ib54c065d27e87d8726a9870df05a2bae24828b98
GitHub-Last-Rev: 655e3f4
GitHub-Pull-Request: #25906
Reviewed-on: https://go-review.googlesource.com/119115
Reviewed-by: Ian Lance Taylor <[email protected]>
@gopherbot
Copy link
Contributor

Message from Ian Lance Taylor:

Patch Set 4: Code-Review+2

Thanks.


Please don’t reply on this GitHub thread. Visit golang.org/cl/119115.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

This PR is being closed because golang.org/cl/119115 has been merged.

@gopherbot gopherbot closed this Jun 15, 2018
@mistydemeo mistydemeo deleted the add_all_missing_load_commands branch August 11, 2018 00:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes Used by googlebot to label PRs as having a valid CLA. The text of this label should not change.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants