From 101bfd8122462122ad3a9c474fb12ac59c74298a Mon Sep 17 00:00:00 2001 From: Farid Zakaria Date: Thu, 14 Sep 2023 21:25:47 +0000 Subject: [PATCH] added symbol aliasing in README --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index 4ff4c46..aa3fe39 100644 --- a/README.md +++ b/README.md @@ -199,6 +199,28 @@ LIMIT 25;" └──────────────────────────────────────────┴──────────────────────────────────────────┴──────────────────────┴──────────────────────┘ ``` +## Symbol Aliasing + +
+Find symbols that are exported by more than one library + +```console +❯ sqlelf ./examples/shadowed-symbols/exe --recursive --sql " +SELECT name, version, count(*) as symbol_count, GROUP_CONCAT(path, ':') as libraries +FROM elf_symbols +WHERE exported = TRUE +GROUP BY name, version +HAVING count(*) >= 2;" +┌──────┬────────┬───────────┬────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ +│ name │ versio │ symbol_co │ libraries │ +│ │ n │ unt │ │ +├──────┼────────┼───────────┼────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┤ +│ foo │ NULL │ 2 │ /usr/local/google/home/fmzakari/code/github.com/fzakaria/sqlelf/examples/shadowed- │ +│ │ │ │ symbols/x/libx.so:/usr/local/google/home/fmzakari/code/github.com/fzakaria/sqlelf/examples/shadowed-symbols/x/libx2.so │ +└──────┴────────┴───────────┴────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ +``` +
+ ## Development You must have [Nix](https://nixos.org) installed for development.