from pysndfile import formatinfo, sndfile
from pysndfile import supported_format, supported_endianness, \
                                       supported_encoding
from pysndfile import PyaudioException, PyaudioIOError
from _sndfile import Sndfile, Format, available_file_formats, available_encodings

from _sndfile import Sndfile, Format, available_file_formats, available_encodings
from compat import formatinfo, sndfile, PyaudioException, PyaudioIOError
from pysndfile import supported_format, supported_endianness, \
                                       supported_encoding

Use compat module instead of ctypes-based implementation.