Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

Move linkopts to llvm:Support #189

Merged
merged 1 commit into from
Apr 23, 2021
Merged

Conversation

GMNGeoffrey
Copy link
Contributor

@GMNGeoffrey GMNGeoffrey commented Apr 23, 2021

-lm is needed by Support itself. Adding this on every possible leaf
binary seems a bit silly. There will be some weirdness by nature of
this being a transitive thing (line includes) that means we might
have some things happen to work because they dep on Support even though
there are other libraries that really should have those options as well
and don't have them, but I'm not sure how to avoid that. Luckily the
linker error gives you the name of the object file, so I think adding
the option on the appropriate library if/when that comes up shouldn't
be too bad.

Fixes #188

Copy link
Contributor

@chandlerc chandlerc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@GMNGeoffrey GMNGeoffrey merged commit 95d5e10 into google:main Apr 23, 2021
@GMNGeoffrey GMNGeoffrey deleted the linkopts branch April 23, 2021 02:03
copybara-service bot pushed a commit that referenced this pull request Apr 23, 2021
We moved these to the library that actually needs them (llvm:Support) in #189

PiperOrigin-RevId: 370101023
lelandjansen pushed a commit to lelandjansen/llvm-bazel that referenced this pull request May 2, 2021
`-lm` is needed by Support itself. Adding this on every possible leaf
binary seems a bit silly. There will be some weirdness by nature of
this being a transitive thing (line `includes`) that means we might
have some things happen to work because they dep on Support even though
there are other libraries that really should have those options as well
and don't have them, but I'm not sure how to avoid that. Luckily the
linker error gives you the name of the object file, so I think adding
the option on the appropriate library if/when that comes up shouldn't
be too bad.

Fixes google#188
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

undefined reference to 'log10'
2 participants