madskjeldgaard / portedplugins

A collection of plugins for the SuperCollider sound environment, all of which are ported / remixed from elsewhere
GNU General Public License v3.0
180 stars 13 forks source link

Somewhat misleading macOS install instructions #46

Open ryanlaws opened 3 months ago

ryanlaws commented 3 months ago

I attempted to build per the Building for Rosetta on the Mac M1 instructions, but my SuperCollider server would not install the built UGen .scx files and yielded this error:

$HOME/Library/Application Support/SuperCollider/Extensions/PortedPlugins/Fverb_supernova.scx' err 
    (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e' or 'arm64'))

I'm running the 3.13.0 universal binary SC downloaded from https://supercollider.github.io/ (filename: SuperCollider-3.13.0-macOS-universal.dmg).

Anyway, I went ahead and rebuilt them for arm64 (or whatever architecture was detected) by simply removing the OSX_ARCH environment variable and the corresponding -DCMAKE_OSX_ARCHITECTURES flag that used it. So the full series of commands were:

# Location of SuperCollider source code
SC_LOCATION="/path/to/sc/source"

# Install here:
INSTALL_LOCATION="$HOME/Library/Application Support/SuperCollider/Extensions"

cmake .. -DCMAKE_BUILD_TYPE=Release -DSC_PATH="$SC_LOCATION" -DCMAKE_INSTALL_PREFIX="$INSTALL_LOCATION"
cmake --build . --config Release
cmake --build . --config Release --target install 

And now after restarting SCIDE, everything is working great.

I was going to go ahead open a PR for this to save you a bit of time, but I'm not sure I understand the Rosetta compatibility layer well enough to rephrase that section without muddying the waters.

Thanks for your work on this project! I hope this is helpful.

madskjeldgaard commented 3 months ago

Thanks for the report! I think this is a leftover from the early days of apple sillicon where people would use the rosetta version of SC, but I think it might be good to just remove the architecture part of the build command as you mention.