-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Remove some magic handling of native shared libraries #20886
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -761,16 +761,7 @@ def phase_setup(options, state, newargs): | |
| else: | ||
| message = arg + ': Unknown format, not a static library!' | ||
| exit_with_error(message) | ||
| if file_suffix in DYNAMICLIB_ENDINGS and not building.is_bitcode(arg) and not building.is_wasm(arg): | ||
| # For shared libraries that are neither bitcode nor wasm, assuming its local native | ||
| # library and attempt to find a library by the same name in our own library path. | ||
| # TODO(sbc): Do we really need this feature? See test_other.py:test_local_link | ||
| libname = removeprefix(get_library_basename(arg), 'lib') | ||
| flag = '-l' + libname | ||
| diagnostics.warning('map-unrecognized-libraries', f'unrecognized file type: `{arg}`. Mapping to `{flag}` and hoping for the best') | ||
| state.add_link_flag(i, flag) | ||
| else: | ||
| input_files.append((i, arg)) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps we could add an error here that suggests the proper form, to help people update? That is, if
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd rather not for the following reasons:
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fair enough, lgtm. |
||
| input_files.append((i, arg)) | ||
| elif arg.startswith('-L'): | ||
| state.add_link_flag(i, arg) | ||
| newargs[i] = '' | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.