1
0
mirror of https://github.com/SerenityOS/serenity synced 2024-07-09 12:00:49 +00:00

Utilities: Rename ldd => elfdeps

As a preparation to introducing ldd as a symlink to /usr/lib/Loader.so
we rename the ldd utility to be elfdeps, at its sole purpose is to list
ELF object dependencies, and not how the dynamic loader loads them.
This commit is contained in:
Liav A 2023-09-17 10:38:15 +03:00 committed by Andrew Kaster
parent 7437ccd66d
commit 56790098ea
3 changed files with 10 additions and 10 deletions

View File

@ -1,16 +1,16 @@
## Name
ldd - list dynamic dependencies
elfdeps - list ELF object dynamic dependencies
## Synopsis
```**sh
$ ldd [-r] [-f] <path>
$ elfdeps [-r] [-f] <path>
```
## Description
`ldd` prints all dependency libraries of an ELF object.
`elfdeps` prints all dependency libraries of an ELF object.
## Options
@ -24,18 +24,18 @@ $ ldd [-r] [-f] <path>
## Security
In contrast to other OS implementations, the `ldd` binary is completely safe for
usage on untrusted binaries - we only use the `LibELF` code for doing library
resolving, and the actual binary interpreter (when specified) is never called to
The `elfdeps` binary is completely safe for usage on untrusted binaries -
we only use the `LibELF` code for doing library resolving, and the actual
binary interpreter (when specified in an ELF exectuable) is never called to
decode the dependency information.
## Examples
```sh
# List all dependency libraries for libc.so
$ ldd -f /usr/lib/libc.so
$ elfdeps -f /usr/lib/libc.so
# List all dependency libraries for /bin/id
$ ldd /bin/id
$ elfdeps /bin/id
# List all dependency libraries for /bin/WindowServer
$ ldd /bin/WindowServer
$ elfdeps /bin/WindowServer
```

View File

@ -92,6 +92,7 @@ target_link_libraries(cpp-preprocessor PRIVATE LibCpp)
target_link_libraries(diff PRIVATE LibDiff)
target_link_libraries(disasm PRIVATE LibELF LibX86)
target_link_libraries(drain PRIVATE LibFileSystem)
target_link_libraries(elfdeps PRIVATE LibELF)
target_link_libraries(expr PRIVATE LibRegex)
target_link_libraries(fdtdump PRIVATE LibDeviceTree)
target_link_libraries(file PRIVATE LibELF LibGfx LibIPC LibArchive LibCompress LibAudio)
@ -110,7 +111,6 @@ target_link_libraries(install-bin PRIVATE LibFileSystem)
target_link_libraries(isobmff PRIVATE LibGfx)
target_link_libraries(js PRIVATE LibCrypto LibJS LibLine LibLocale LibTextCodec)
target_link_libraries(keymap PRIVATE LibKeyboard)
target_link_libraries(ldd PRIVATE LibELF)
target_link_libraries(less PRIVATE LibLine)
target_link_libraries(ls PRIVATE LibFileSystem LibURL)
target_link_libraries(lspci PRIVATE LibPCIDB)