FIND-ALL-SYMBOLS(1)

πŸ“¦
version 15.0.7 Β· 3 versions
, in ubuntu jammy

πŸ‘‘ FIND-ALL-SYMBOLS πŸ‘‘

okay so bestie, you have officially stumbled into the find-all-symbols manual page πŸ’– it lives in the User Commands corner of the manual-verse, and it is so much more chill than it looks, i promise. buckle up, we're going symbol hunting πŸ¦‹


πŸŽ€ NAME πŸŽ€

find-all-symbols β€” the manual page for find-all-symbols 15, bestie. that's it, that's the whole name section, she's concise πŸ’…


✨ DESCRIPTION ✨

here's the whole entire vibe of how you actually call this thing:

USAGE: find-all-symbols [options] <source0> [... <sourceN>]

then it says, plain as day:

OPTIONS:

and then we get into the good stuff, because the options are split into two little cliques β€” the generic ones and the find_all_symbols ones 🌈


πŸ’« Generic Options πŸ’«

these are the universal besties, the ones basically every tool has:

  • --help β€” shows you all the available options. and if that's not enough for you (greedy, love that), there's --help-hidden for more 🫢
  • --help-list β€” displays the list of available options. and again, if you want the secret menu, --help-list-hidden has you covered πŸ™ˆ
  • --version β€” displays the version of this program. no cap, sometimes you just gotta know what you're running ⭐

🌸 find_all_symbols options 🌸

the main character options, the ones that actually do the symbol-finding 😭

  • --extra-arg=<string> β€” an additional argument to append to the compiler command line. yes, append, as in it goes at the end, we're being specific here πŸ”₯
  • --extra-arg-before=<string> β€” an additional argument to prepend to the compiler command line. yep, prepend, it goes up front. these two are literally siblings, don't mix them up πŸ’€
  • --merge-dir=<string> β€” the directory for merging symbols. that's the whole description, she's mysterious, she's iconic πŸ‘‘
  • --output-dir=<string> β€” the output directory for saving the results. where the goods go, periodt πŸ’–
  • -p <string> β€” build path πŸŽ€

and now the part where -p gets to explain herself, because she has lore:

-p <build-path> is used to read a compile command database.

for example, bestie, it can be a CMake build directory in which a file named compile_commands.json exists. and ooh, use the -DCMAKE_EXPORT_COMPILE_COMMANDS=ON CMake option to get that output, iykyk ✨

and when no build path is specified at all? then it will attempt a search for compile_commands.json through all parent paths of the first input file. literally all of them, she's thorough 🧚

see: https://clang.llvm.org/docs/HowToSetupToolingForLLVM.html for an example of setting up Clang Tooling on a source tree. go look, it's helpful, trust 🌈


πŸ¦‹ about <source0> ... πŸ¦‹

<source0> ... these specify the paths of source files. and here's the tea, because the rules are specific:

  • these paths get looked up in the compile command database πŸ”
  • if the path of a file is absolute, it needs to point into CMake's source tree ⭐
  • if the path is relative, then the current working directory needs to be in the CMake source tree, and the file must be in a subdirectory of the current working directory πŸ’…
  • "./" prefixes in the relative files will be automatically removed β€” cute, she cleans up after herself πŸŽ€
  • but the rest of a relative path must be a suffix of a path in the compile command database. no shortcuts, bestie 😭
also, the manpage literally just says "More help text..." right at the end there and honestly? same. that's the whole mood. πŸ™ˆ

and that's the page, you ate it, you understood it, you're a find-all-symbols girlie now πŸ’œ

this was find-all-symbols 15, dated July 2023, and it comes to you from the FIND-ALL-SYMBOLS(1) manual page. mwah, love you, go find some symbols πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from