ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalcmagnetic_scattrelease-4.2.2ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change
on this file since 5a405bd was
2f6d340,
checked in by Paul Kienzle <pkienzle@…>, 8 years ago
|
rename installers directory from sasview to installers
|
-
Property mode set to
100644
|
File size:
802 bytes
|
Line | |
---|
1 | """ |
---|
2 | MachOlib fix |
---|
3 | ============ |
---|
4 | |
---|
5 | Monkey-patch macholib to get around error in v1.7 and earlier, which |
---|
6 | gives:: |
---|
7 | |
---|
8 | TypeError: dyld_find() got an unexpected keyword argument 'loader' |
---|
9 | |
---|
10 | Add the following to the top of your setup_py2app to work around this:: |
---|
11 | |
---|
12 | import macholib_patch |
---|
13 | """ |
---|
14 | |
---|
15 | import macholib |
---|
16 | #print("~"*60 + "macholib verion: "+macholib.__version__) |
---|
17 | if macholib.__version__ <= "1.7": |
---|
18 | print("Applying macholib patch...") |
---|
19 | import macholib.dyld |
---|
20 | import macholib.MachOGraph |
---|
21 | dyld_find_1_7 = macholib.dyld.dyld_find |
---|
22 | def dyld_find(name, loader=None, **kwargs): |
---|
23 | #print("~"*60 + "calling alternate dyld_find") |
---|
24 | if loader is not None: |
---|
25 | kwargs['loader_path'] = loader |
---|
26 | return dyld_find_1_7(name, **kwargs) |
---|
27 | macholib.MachOGraph.dyld_find = dyld_find |
---|
Note: See
TracBrowser
for help on using the repository browser.