-
Notifications
You must be signed in to change notification settings - Fork 653
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
Building Cgo code depending on shared libraries fails for --remote_download_minimal #2906
Labels
Comments
glukasiknuro
added a commit
to glukasiknuro/rules_go
that referenced
this issue
Jul 1, 2021
Checking whether it fixes bazelbuild#2906
glukasiknuro
changed the title
Building Cgo code depending on shared libraries fails for --remote_download_minimal
Building Cgo code depending on shared libraries fails for --nobuild_runfile_links
Jul 8, 2021
glukasiknuro
changed the title
Building Cgo code depending on shared libraries fails for --nobuild_runfile_links
Building Cgo code depending on shared libraries fails for --remote_download_minimal
Jul 8, 2021
Looks like the option The issue seem to be somewhat complicated, and the patch in #2907 solves this issue in slightly indirect way. Still it maybe good to apply this patch, to be consistent with how libraries are linked in case of C++. Description of the current issue
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Note that
--remote_download_minimal
expands to--nobuild_runfile_links
, and this option itself triggers the issue.It was working properly on
0.24.14
version, but is broken in current master.What version of rules_go are you using?
Current master, testing on rules_go repository.
What version of Bazel are you using?
4.0.0, 5.0.0-pre.20210623.2
Does this issue reproduce with the latest releases of all the above?
Yes
What operating system and processor architecture are you using?
Linux
What did you do?
Execute rules_go test while using
--nobuild_runfile_links
Possible regression
Looks like reverting those two lines in https://github.com/bazelbuild/rules_go/pull/2445/files#diff-1fae1aeb9bbd89e02d89a880ef0d1122bd51b265bc281978f01c14fc27f41f47R191 fixes the issue. Based on the comment that was to fix some other issues, but possibly the fix is not entirely valid: #2445 (comment)
Current master:
With revert:
Note that after revert the
rpath
is using mangled names, which seems to be in line with what bazel does for shared libraries: https://github.com/bazelbuild/bazel/blob/c9ab52a294ee490bec43f9ea6e5cf545d97e2ae7/src/main/java/com/google/devtools/build/lib/rules/cpp/SolibSymlinkAction.java#L49.CC @steeve @jayconrod for any insights why the change was necessary
Other references
The text was updated successfully, but these errors were encountered: