Skip to main content

Python bindings for libdiscid

Project description

python-libdiscid implements Python 3 bindings for libdiscid using Cython.

Dependencies

  • libdiscid

  • Cython (>= 0.15, optional)

  • pkgconfig (optional)

Note that the tarballs come with pre-built C source for the Cython module. So Cython is only required if one builds python-libdiscid from the git repository or if one wants to change anything in the Cython module.

If pkgconfig is installed, setup.py uses libdiscid’s pkg-config information to set include directories, libraries to link, etc.

Quick installation guide

python-libdiscid is available in some distributions:

  • Debian/Ubuntu: apt-get install python3-libdiscid (Python 3)

  • Fedora: dnf install python3-libdiscid (Python 3)

python-libdiscid can be installed via pip:

pip install python-libdiscid

or by running:

python3 setup.py install

If you just want to try it locally, run:

python3 setup.py build_ext -i

and hack right away. You can also run:

python3 setup.py build

but please make sure that build/lib.* is in sys.path before the source folder.

A note for Windows users

There are eggs available from PyPI that don’t require the extension module to be built. If these are used, it is still required to drop a working discid.dll in C:\WINDOWS\system32 (or wherever it can be found).

Usage

from libdiscid import read

disc = read("/dev/cdrom")
print("id: {}".format(disc.id))

License

python-libdiscid is released under the Expat license. Check LICENSE for details.

Build status

TravisCI

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python-libdiscid-1.1.tar.gz (77.4 kB view details)

Uploaded Source

File details

Details for the file python-libdiscid-1.1.tar.gz.

File metadata

  • Download URL: python-libdiscid-1.1.tar.gz
  • Upload date:
  • Size: 77.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.4.2 requests/2.21.0 setuptools/41.4.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.7.5

File hashes

Hashes for python-libdiscid-1.1.tar.gz
Algorithm Hash digest
SHA256 c342531ca6cf0c0ed7890515d135e6d16199d81040189c8653002327f7e7229a
MD5 63f2d8849968115b84f0bd2f586a33b4
BLAKE2b-256 fa42be79149fd492878717c3e39d3d81558ce646d9d595eed133c541387a3d1f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page