Commits

Anonymous committed ab1aab4

OS X: Added dynamic library loading support for pyinstaller's handling of dynamic libraries on OS X (thanks Nathan Stocks)

Comments (0)

Files changed (2)

     * tools/gl_info.py: add pyglet version and platform info
     * Windows: fix loading system cursors
 	* OS X: fix window creation under Mountain Lion (thanks Kuba Niegowski)
+	* OS X: Added dynamic library loading support for pyinstaller's handling of
+	  dynamic libraries on OS X (thanks Nathan Stocks)
 
 1.2alpha1
 	The major 1.2 release brings pyglet to Python 3. Pyglet now also runs on
                 'Frameworks',
                 libname))
 
+        # pyinstaller.py sets sys.frozen to True, and puts dylibs in
+        # Contents/MacOS, which path pyinstaller puts in sys._MEIPASS
+        if (hasattr(sys, 'frozen') and hasattr(sys, '_MEIPASS') and
+                sys.frozen == True and sys.platform == 'darwin'):
+            search_path.append(os.path.join(sys._MEIPASS, libname))
+
         if '/' in path:
             search_path.extend(
                 [os.path.join(p, libname) \
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.