{"id":47685343,"url":"https://github.com/zeppe-lin/librevdep","last_synced_at":"2026-04-02T14:48:01.335Z","repository":{"id":344860593,"uuid":"1170716544","full_name":"zeppe-lin/librevdep","owner":"zeppe-lin","description":"Reverse dependency auditing library","archived":false,"fork":false,"pushed_at":"2026-03-16T21:17:22.000Z","size":1569,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-03-17T03:53:55.820Z","etag":null,"topics":["dependency-analysis","elf-format","elf-parser"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zeppe-lin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":"COPYRIGHT","agents":null,"dco":null,"cla":null}},"created_at":"2026-03-02T12:43:09.000Z","updated_at":"2026-03-16T21:17:25.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/zeppe-lin/librevdep","commit_stats":null,"previous_names":["zeppe-lin/librevdep"],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/zeppe-lin/librevdep","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zeppe-lin%2Flibrevdep","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zeppe-lin%2Flibrevdep/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zeppe-lin%2Flibrevdep/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zeppe-lin%2Flibrevdep/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zeppe-lin","download_url":"https://codeload.github.com/zeppe-lin/librevdep/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zeppe-lin%2Flibrevdep/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31308433,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-02T12:59:32.332Z","status":"ssl_error","status_checked_at":"2026-04-02T12:54:48.875Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dependency-analysis","elf-format","elf-parser"],"created_at":"2026-04-02T14:47:55.614Z","updated_at":"2026-04-02T14:48:01.327Z","avatar_url":"https://github.com/zeppe-lin.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"OVERVIEW\n========\n\n`librevdep` is a reusable C++17 library for auditing installed ELF\nobjects and reporting unresolved shared-library dependencies.\n\nIt models dynamic loader search semantics relevant to static audit:\n`DT_NEEDED`, `RUNPATH`, `RPATH`, and configurable search directories.\nFindings are reported per file and may be aggregated per package by\nthe embedding application.\n\nThe library is structured for reuse:\n- clear separation of audit engine, context, ELF parsing, formatting,\n  and optional parallel scheduling\n- no built-in package manager policy (*FIXME: not yet*)\n- no built-in CLI I/O contract (*FIXME: CLI storytelling still leaks*)\n- sink-based reporting for incremental consumptions by callers\n\n`librevdep` originated from the `revdep` work previously coupled to\nthe CLI utility.\nThe command-line frontend now lives in a separate project:\n\nhttps://github.com/zeppe-lin/revdep\n\nThis library lineage ultimately traces back to the CRUX `revdep`\nimplementation from `prt-utils` (fork point: `41dfcb6`, Thu Oct 15\n2020), but has since been substantially refactored.\n\nMajor differences from the original CRUX implementation include:\n- extracted reusable code into C++17 library\n- separation of engine, context, formatting, and parallel scheduler\n- optional parallel audit support\n- broader ELF machine coverage (powerpc{,64}, loongarch{,64}, RISC-V)\n- API documentation and library manual pages in `scdoc(5)` format\n\nSee the git history for detailed changes.\n\nOriginal sources:\n\nhttps://git.crux.nu/tools/prt-utils.git\n\n---\n\nARCHITECTURE\n============\n\nThe library is layered as follows:\n\nEngine (`revdep_engine`)  \nAudits ELF objects and emits structured findings.\n\nContext (`revdep_context`)  \nHolds configuration and shared state, including ELF cache.\n\nELF layer (`elf`, `elf_cache`)  \nParses ELF objects and performs loader-like resolution.\n\nFormatting (`revdep_format`)  \nConverts findings into stable textual representations.\n\nParallel scheduler (`revdep_parallel`)  \nOptional concurrency layer for large audits.\n\nUmbrella header (`librevdep.h`)  \nPulls in the public API for embedders.\n\n`librevdep` is intended to provide facts and resolution results.\nPolicy, package-database interpretations, presentation style, and CLI\nstorytelling belong to the embedding application.\n\n---\n\nNON-GOALS\n=========\n\n`librevdep` is not a dynamic loader implementation.\n\nSpecifically:\n\n- It does not use or parse `/etc/ld.so.cache`.\n- It does not implement full glibc `ld.so` behavior.\n- It does not execute binaries.\n- It does not resolve `dlopen(3)` at runtime.\n- It does not validate symbol-level resolution.\n- It does not perform ABI compatibility analysis.\n\nThe library focuses strictly on static `DT_NEEDED` dependency\nresolution using documented search rules (see `revdep_semantics(7)`).\n\n---\n\nEMBEDDING librevdep\n===================\n\n`librevdep` provides a C++ API for programmatic audits.\n\nMinimal example:\n\n```cpp\n#include \u003clibrevdep/librevdep.h\u003e\n#include \u003ciostream\u003e\n\nint main() {\n    RevdepConfig cfg;\n    cfg.searchDirs = {\"/lib\", \"/usr/lib\"};\n\n    RevdepContext ctx(cfg);\n\n    auto sink = [](const RevdepFinding\u0026 f) {\n        std::cout \u003c\u003c RevdepFormatFinding(f) \u003c\u003c \"\\n\";\n    };\n\n    Package pkg;\n    pkg.name = \"example\";\n    pkg.files = {\"/usr/bin/example\"};\n\n    RevdepAuditPackage(pkg, ctx, sink);\n}\n```\n\nThe engine is sink-based: findings are delivered incrementally\nvia a callback.\nThe library itself does not impose CLI output or package manager\npolicy.\n\nParallel scheduling is available via\n`RevdepAuditWorkItemsParallel()`; see `revdep_parallel(3)`.\n\n---\n\nAPI AND ABI STABILITY\n=====================\n\nThe `librevdep` API is intended to remain source-stable within major\nversion.\n\nABI stability is **not** guaranteed across major releases.\n\nConsumers are encouraged to:\n- link dynamically when possible\n- rebuild against new major releases\n- consult `librevdep(3)` for authoritative API documentation\n\n---\n\nREQUIREMENTS\n============\n\nBuild-time\n----------\n\n- C++17 compiler\n- Meson\n- Ninja\n- `elfutils` (`libelf`)\n- `scdoc(1)` to generate manual pages (if manpage build is enabled)\n- `pkg-config(1)` for dependency discovery\n\nRuntime\n-------\n\n- ELF-based system\n- package/file inventory supplied by the embedded application\n  (*FIXME: Package database in expected format is expected now*)\n\n`librevdep` itself does not require a specific package manager, but\nmany embedding use-cases will provide package/file ownership data from\nan external database.\n\n---\n\nINSTALLATION\n============\n\nConfigure and build with Meson:\n\n```sh\nmeson setup build \\\n    --buildtype=plain \\\n    --wrap-mode=nodownload\n\nninja -C build\n```\n\nInstall:\n\n```sh\nDESTDIR=\"$PKG\" ninja -C build install\n```\n\nCommon options:\n\n```sh\nmeson setup build \\\n    --prefix=/usr \\\n    -D build_man=true \\\n    -D b_lto=false\n```\n\nUse `meson configure build` to inspect available options.\n\n---\n\nDEFAULT PATHS\n=============\n\nSome runtime defaults (*FIXME: like package database, yeah*) are\ncompiled in at build time.\n\nThese defaults are intended to be removed.\n\n---\n\nDOCUMENTATION\n=============\n\nManual pages are provided in `/man` and installed under the system\nmanual hierarchy.\n\nKey entry points:\n\n- `librevdep(3)` - public API overview\n- `librevdep(7)` - library overview\n- `revdep_context(3)` - context and configuration\n- `revdep_engine(3)` - audit engine\n- `revdep_format(3)` - formatting helpers\n- `revdep_parallel(3)` - optional parallel scheduler\n- `revdep_semantics(7)` - resolver rules\n\nThe `revdep(1)` CLI and its user-facing manuals now live in the\nseparate `revdep` repository.\n\n---\n\nLICENSE\n=======\n\n`librevdep` is licensed under the\n[GNU General Public License v3 or later](https://gnu.org/licenses/gpl.html).\n\nSee `COPYING` for license terms and `COPYRIGHT` for notices.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzeppe-lin%2Flibrevdep","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzeppe-lin%2Flibrevdep","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzeppe-lin%2Flibrevdep/lists"}