Commits

Leonard Ritter  committed 3a514a5

win32 fixes / installing DLL with package

  • Participants
  • Parent commits de4ab83

Comments (0)

Files changed (2)

File al/internal.py

 def load_lib(cdefs):
     global _LIB
     
-    global _LIB
-    libname = 'openal'
     if IS_WIN32:
         local_dls = [
             os.path.join(_THISDIR, 'soft_oal.dll'),
 
+import sys
 import os
 from setuptools import setup
 
 def read(fname):
     return open(os.path.join(os.path.dirname(__file__), fname)).read()
 
-setup(
+if sys.platform == 'linux2':
+    dllname = None#'libSDL2.so'
+elif sys.platform == 'win32':
+    dllname = 'soft_oal.dll'
+
+kargs = dict(
     name = "pyopenal-cffi",
     version = "0.1",
     author = "Leonard Ritter",
         "License :: OSI Approved :: MIT License",
     ],
 )
+
+if dllname:
+    kargs['package_data'] = {
+        'al' : [dllname],
+    }
+
+
+setup(**kargs)