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

Cross-compilation & debug symbols #1553

Closed
vhbit opened this issue Jun 16, 2018 · 0 comments
Closed

Cross-compilation & debug symbols #1553

vhbit opened this issue Jun 16, 2018 · 0 comments
Labels

Comments

@vhbit
Copy link

vhbit commented Jun 16, 2018

I'm trying to have debug symbols while cross-compiling from Mac OS to Linux, but no matter what flags I'm using output binary is always stripped.

For example, after this super-explicit invocation:
bazel build --platforms=@io_bazel_rules_go//go/toolchain:linux_amd64 --compilation_mode=dbg --strip=never --features=pure,static,debug //services/...

if I check output file I get a stripped binary:

> file bazel-out/darwin-dbg/bin/services/http-server/linux_amd64_pure_debug/http-server

bazel-out/darwin-dbg/bin/services/http-server/linux_amd64_pure_debug/http-server: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), statically linked, stripped

bazel: 0.14.1-homebrew
rules_go: 0.12.1

jayconrod pushed a commit to jayconrod/rules_go that referenced this issue Jun 18, 2018
This was used to work around a linker bug in Xcode 7.2 and earlier. We
probably don't need to support those old versions anymore.

This enables debugging binaries on macOS.

Fixes bazel-contrib#1553
jayconrod added a commit that referenced this issue Jun 19, 2018
This was used to work around a linker bug in Xcode 7.2 and earlier. We
probably don't need to support those old versions anymore.

This enables debugging binaries on macOS.

Fixes #1553
ArielleA pushed a commit to ArielleA/rules_go that referenced this issue Jun 19, 2018
This was used to work around a linker bug in Xcode 7.2 and earlier. We
probably don't need to support those old versions anymore.

This enables debugging binaries on macOS.

Fixes bazel-contrib#1553
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants