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

Drop target configuration and import path prefix from output file path #2448

Closed
jayconrod opened this issue Apr 20, 2020 · 0 comments · Fixed by #2453
Closed

Drop target configuration and import path prefix from output file path #2448

jayconrod opened this issue Apr 20, 2020 · 0 comments · Fixed by #2453

Comments

@jayconrod
Copy link
Contributor

Output files for libraries and binaries currently have paths like this:

bazel-bin/darwin_amd64/go_default_library%/example.com/hello.a

darwin_amd64 is no longer necessary since #2219 has been fixed. Previously, we used an aspect for cross-compilation, so we had to add a directory prefix to distinguish files built in different modes. Bazel now adds its own prefix when switching configurations, so this is no longer necessary.

example.com/hello is no longer necessary. We used to pass an -I or -L argument to the compiler or linker for each archive. This is no longer needed, since we use -importcfg files.

Instead, output file names should look like:

bazel-bin/go_default_library.a
bazel-bin/hello

Or, in a non-default configuration:

bazel-out/darwin-fastbuild-ST-7912f95a9c5bf6fc1ba1c485f63292d65dad39084e5362eb6254aa7fb8987eba/bin/hello

This should mitigate a number of issues caused by long file names on Windows and macOS like #2002. Also related: #2249, #1239, #1257.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant