
    )+Ci                     N    S r SSKrSSKrSSKJr  SSKJr  SSKJr  S/r	S r
S rg)	z!Loads zbar and its dependencies.
    N)cdll)find_library)Pathloadc                  J    [         R                  S:  a  Sn S/nX4$ Sn S/nX4$ )zFor convenience during development and to aid debugging, the DLL names
are specific to the bit depth of interpreter.

This logic has its own function to make testing easier
l        zlibzbar-64.dllzlibiconv.dllzlibzbar-32.dllzlibiconv-2.dll)sysmaxsize)fnamedependenciess     M/home/james-whalen/.local/lib/python3.13/site-packages/pyzbar/zbar_library.py_windows_fnamesr      s@     {{U &'  !()    c                  n  ^^ S[         R                  " 5       :X  a-  [        5       u  mmUU4S jn  U " [        S5      5      u  mnUT4$ [        S5      nU(       d  [        S5      e[        R                  " U5      n/ mUT4$ ! [         a(    U " [        [
        5      R                  5      u  mn UT4$ f = f)z:Loads the libzar shared library and its dependencies.
    Windowsc           
         > T Vs/ s H1  n[         R                  " [        U R                  U5      5      5      PM3     nn[         R                  " [        U R                  T5      5      5      nX#4$ s  snf )N)r   LoadLibrarystrjoinpath)	directorydepdepslibzbarr   r
   s       r   load_objectsload.<locals>.load_objects0   so     ('C   Y%7%7%<!=>'   &&s9+=+=e+D'EFG= s   8A1 zbarz"Unable to find zbar shared library)platformsystemr   r   OSError__file__parentr   ImportErrorr   r   )r   r   pathr   r
   s      @@r   r   r   !   s     HOO%% ./|	!	H$0b$:!L' L   F#BCC""4(L    	H$0h1F1F$G!L' L  	Hs   B ,B43B4)__doc__r   r   ctypesr   ctypes.utilr   pathlibr   __all__r   r    r   r   <module>r*      s*     
  $ (($!r   