Python in Max


    Oct 17 2016 | 10:34 am
    Hi I'm banging my head against this and am probably being pretty thick. I'm trying to use py.mxo and pyext but I keep getting the following.
    2016-10-17 11:20:03.270 Max[45701:7957849] Error loading /Users/repeat/Documents/Max 7/Packages/py.mxo/Contents/MacOS/py: dlopen(/Users/repeat/Documents/Max 7/Packages/py.mxo/Contents/MacOS/py, 262): no suitable image found. Did find: /Users/repeat/Documents/Max 7/Packages/py.mxo/Contents/MacOS/py: no matching architecture in universal wrapper
    So I realise this is likely a 64 bit vs 32 bit issue but I can't seem to find where the problem lies. I've typed a script into the terminal which I'm told will force python to choose 32 bit and Max is set to 32 bit but no joy. Similarly when I leave them both in 64 bit, no joy.
    I need to use python as I'm trying to bring over Mathematica code (that a colleague is writing in python) to use within Max.
    I'm not a text based coder by any means so it's all a bit confusing I'm afraid. Any help would be very welcome!

    • Oct 17 2016 | 12:23 pm
      If you open the Terminal and type:
      lipo -info "/Users/repeat/Documents/Max 7/Packages/py.mxo/Contents/MacOS/py"
      what do you get in response?
    • Oct 17 2016 | 12:24 pm
      Also, it bears noting the the Packages folder is the wrong place for loose externals. You could dump them in Library. The Packages folder is intended for packages (only).
    • Oct 17 2016 | 1:26 pm
      Thanks for the reply Jeremy, I get this in the terminal: fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't map input file: /Users/repeat/Documents/Max (Invalid argument)
      However.
      I do now seem to have it working after a reboot, I imagine my schoolboy error was not restarting to allow the terminal 32 bit python command to work throughout the system (?). I moved it to the library too and all seems well.
      Do I need to neaten up the installation in some way? The terminal seems to suggest things are still a bit wrong...
    • Oct 17 2016 | 1:27 pm
      The Terminal error was just because you forgot to put quotes around the path.
      But if it's working after a reboot, all's well that ends well.
    • Oct 17 2016 | 1:49 pm
      I did indeed. In the end I got this but yeah, all seems well. Architectures in the fat file: /Users/repeat/Documents/Max 7/Packages/py.mxo/Contents/MacOS/py are: ppc7400 i386 Thanks for your help!
      Owen