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

Cleanup layout.ld #40

Merged
merged 3 commits into from
May 18, 2020
Merged

Cleanup layout.ld #40

merged 3 commits into from
May 18, 2020

Conversation

josephlr
Copy link
Contributor

@josephlr josephlr commented May 18, 2020

Depends on #41 (to fix the CI).

Right now the linker script uses a mixture of tabs and spaces for indentation, switch to using all spaces.

Also, we remove the /DISCARD/ section taken from EDK2. There's not a good reason to have this section (it's purpose is very EDK2 specific). In fact, it can often hide section/linking bugs by removing code that we actually want to be in the final binary.

We keep the /DISCARD/ section that handles stripping symbols and symbol tables from the binary. Eventually, we will just use Cargo's strip option (see rust-lang/cargo#8246) to handle this instead of having it in the linker script. This will allow us to strip symbols in release mode and keep them in debug mode.

@josephlr josephlr requested a review from rbradford May 18, 2020 01:07
Signed-off-by: Joe Richey <joerichey@google.com>
We are currently using a mixture of tabs and spaces, this is silly.

Signed-off-by: Joe Richey <joerichey@google.com>
This was just copied over, but isn't necessary. The only data this
removes is the `.comment` section, but it's fine (and even desireable)
to leave that in.

Signed-off-by: Joe Richey <joerichey@google.com>
@rbradford rbradford merged commit 7e65617 into cloud-hypervisor:master May 18, 2020
@josephlr josephlr deleted the layout branch May 28, 2020 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants