This is an archive of the discontinued LLVM Phabricator instance.

[llvm-libtool-darwin] Switch to OptTableSummary
ClosedPublic

Authored by avillega on Jun 23 2023, 2:19 PM.

Details

Summary

Switch the parse of command line options fromllvm::cl to OptTable.

The motivation for this change is to continue adding llvm based tools
to the llvm driver multicall. For more information about the proposal
and motivation, please see https://discourse.llvm.org/t/rfc-llvm-busybox-proposal/58494

Diff Detail

Event Timeline

avillega created this revision.Jun 23 2023, 2:19 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 23 2023, 2:19 PM
avillega requested review of this revision.Jun 23 2023, 2:19 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 23 2023, 2:19 PM
avillega retitled this revision from [llvm-libtool-darwin] Switch to OptTable Summary: Switch the parse of command line options from llvm::cl to OptTable. Reviewers: Subscribers: # NEW DIFFERENTIAL REVISION # Describe the changes in this new revision. # # Included commits in... to [llvm-libtool-darwin] Switch to OptTableSummary.Jun 23 2023, 2:22 PM
avillega edited the summary of this revision. (Show Details)
avillega added reviewers: smeenai, int3, keith, abrachet.
avillega updated this revision to Diff 534076.EditedJun 23 2023, 2:26 PM

Add end of line char

This looks good, but could you add the motivation for the change to the commit description as well?

llvm/tools/llvm-libtool-darwin/Opts.td
24

Apple's libtool accepts this option with or without a space, so this should be SeparateOrJoined (and the help should be updated accordingly).

avillega edited the summary of this revision. (Show Details)Jun 23 2023, 3:58 PM
smeenai accepted this revision.Jun 23 2023, 4:17 PM

Okay, this looks good after you address the -L comment. It'd be great if you could add a test for both the separate and joined forms of the argument as part of that too.

This revision is now accepted and ready to land.Jun 23 2023, 4:17 PM
avillega updated this revision to Diff 534115.Jun 23 2023, 4:24 PM

Fix review comments and type in bazel build file

avillega marked an inline comment as done.Jun 23 2023, 4:24 PM
avillega updated this revision to Diff 534625.Jun 26 2023, 10:04 AM

Add tests for passing the -L and -l option arguments separated from the
option name

This revision was automatically updated to reflect the committed changes.