skillfed

dlinfo

Python wrapper for libc's dlinfo and dyld_find on Mac

dlinfo v2.0.0 1.3M downloads/30d#4,019 on PyPI0
Permissive license MIT AGING released

What it is and what it does

dlinfo is a thin Python wrapper around libc's dlinfo function (and macOS's dyld_find), enabling you to inspect runtime properties of dynamically loaded libraries. It wraps low-level C library introspection behind a simple Python interface, so you can query things like the file path of a loaded shared library without calling dlinfo directly through ctypes.

The package has no runtime dependencies and installs as a pure Python wheel. It's intended for developers who need to examine loaded libraries at runtime—for example, to verify which version of a system library is in use, or to locate library files for further inspection. The interface is minimal: you create a DLInfo object from a ctypes library handle and access properties like path.

Use it for:

  • Verify which version of libc or another system library is currently loaded in your Python process.
  • Locate the file path of a dynamically loaded library for debugging or introspection purposes.
  • Build tools or diagnostics that need to report on runtime library dependencies and their locations.
  • Cross-platform library inspection on Linux and macOS without writing platform-specific C code.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides Python access to libc's dlinfo function and macOS dyld_find, allowing you to query runtime information about loaded dynamic libraries.

Yes, if you need low-level library introspection on Linux or macOS. The package is lightweight, has no dependencies, and carries a permissive license. The aging maintenance is a minor concern—the last release was 575 days ago—but the code is stable and the repository is not archived. Install it if you have a specific need for dlinfo; otherwise, it's a niche tool.

Install

dlinfo on PyPI

pip

pip install dlinfo

uv

uv add dlinfo

poetry

poetry add dlinfo

Installing dlinfo

Before you install

Low install friction with no runtime dependencies. Maintenance is aging—last release was 575 days ago, though the repository remains active and the package is marked Production/Stable.

License in practice

MIT license is permissive; you can use, modify, and distribute this package with minimal restrictions.

Quickstart

pip install dlinfo

from dlinfo import DLInfo
import ctypes
import ctypes.util

lib = ctypes.cdll.LoadLibrary(ctypes.util.find_library('c'))
dlinfo = DLInfo(lib)
print(dlinfo.path)

Requires Python 3.9 or later; only works on Linux and macOS systems where libc's dlinfo or dyld_find is available.

Verify before relying

  • Whether the package works correctly with Python 3.12 despite the aging maintenance status.
  • Current compatibility with recent macOS and Linux kernel versions.

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance aging — 575 days since the last release
Last repo commit
First released
Downloads 1,347,352/month — #4,019 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: dlinfo-2.0.0-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersOperating System :: MacOS :: MacOS XOperating System :: POSIX :: LinuxProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.9

Tags

dlinfo wrapper pythonlibc dlinfo bindingdynamic library infoloaded library metadatadyld_find macosctypes library introspection
ctypes-wrappersystem-introspection

More Software Development packages