Make python import relative

This commit is contained in:
Bruce Hill 2025-02-26 23:59:24 -05:00
parent 8ef270934a
commit ecca731104

View File

@ -2,12 +2,13 @@ import ctypes
import enum import enum
import functools import functools
import time import time
import os.path
from contextlib import contextmanager from contextlib import contextmanager
__all__ = ['open', 'TextAttr', 'ClearType', 'CursorType', 'BTUIMode'] __all__ = ['open', 'TextAttr', 'ClearType', 'CursorType', 'BTUIMode']
# Load the shared library into c types. # Load the shared library into c types.
libbtui = ctypes.CDLL("./libbtui.so") libbtui = ctypes.CDLL(os.path.dirname(os.path.abspath(__file__)) + os.path.sep + "libbtui.so")
class FILE(ctypes.Structure): class FILE(ctypes.Structure):
pass pass