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

Fix doubled libbacktrace dependency #165

Merged
merged 1 commit into from
Jun 13, 2023

Conversation

lpawelcz
Copy link
Collaborator

@lpawelcz lpawelcz commented May 24, 2023

This PR is the third and the last one in PR chain that consists of:

Each of the following PRs depend on previous ones which means that the correct merging order is:
#167 -> #164 -> #165
I will rebase the PRs one at the time as they are merged in order to avoid conflicts.

This PR fixes #161.

libbacktrace.patch adds explicit bazel dependency on libbacktrace which manifests in compilation args as:

-Wl,-no-whole-archive bazel-out/k8-opt-exec-2B5CBBC6/bin/external/com_github_libbacktrace/liblibbacktrace.a

The patch does not remove -lbacktrace from linkopts which introduces second libbacktrace dependency, this time for OS-installed library. PR fixes the patch by removing unnecessary linker option.

@tcal-x
Copy link
Member

tcal-x commented May 26, 2023

/gcbrun

@QuantamHD
Copy link
Collaborator

Looks like this is related to the boost thing.

https://pantheon.corp.google.com/cloud-build/builds/7414236d-5ada-488b-b4ea-03252f6e5cfe?project=foss-fpga-tools-external

Step #1: ERROR: Traceback (most recent call last):
Step #1: 	File "/builder/home/.cache/bazel/_bazel_root/eab0d61a99b6696edb3d2aff87b585e8/external/boost/BUILD.bazel", line 13, column 30, in <toplevel>
Step #1: 		_repo_dir = repository_name().removeprefix("@")
Step #1: Error: 'string' value has no field or method 'removeprefix'

@lpawelcz lpawelcz mentioned this pull request Jun 1, 2023
lpawelcz added a commit to antmicro/xls that referenced this pull request Jun 13, 2023
This is a temporary change to test the XLS workspace before
PRs in bazel_rules_hdl are merged:

* hdl/bazel_rules_hdl#167
* hdl/bazel_rules_hdl#164
* hdl/bazel_rules_hdl#165

Signed-off-by: Pawel Czarnecki <pczarnecki@antmicro.com>
@proppy
Copy link
Collaborator

proppy commented Jun 13, 2023

LGTM, but @QuantamHD needs to hit the merge button :)

libbacktrace.patch adds explicit bazel dependency on libbacktrace which
manifests in compilation args as:
'-Wl,-no-whole-archive bazel-out/k8-opt-exec-2B5CBBC6/bin/external/com_github_libbacktrace/liblibbacktrace.a'
The patch does not remove '-lbacktrace' from linkopts which introduces
second libbacktrace dependency, this time for OS-installed library.
This commit fixes the patch.

Signed-off-by: Pawel Czarnecki <pczarnecki@antmicro.com>
@lpawelcz lpawelcz merged commit e6540a5 into hdl:main Jun 13, 2023
@lpawelcz lpawelcz deleted the fix-libbacktrace-dep branch June 13, 2023 15:21
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.

OpenROAD build depends on two libbacktrace libraries
4 participants