How do I build it for I64?
I ran and installed everything on my Intel Mac - only to discover it was for ( or defaulted to ) ARM64 not Intel Macs
how do I get it running on my Intel mac? ( Sonoma 14.5 )
Sorry for the delay in replying. Unfortunately I don't have an x64 Mac. However there is no default for ARM64 - it is supposed to build both. If you edit the package.json the line with "arm64" does it build correctly?
Yes, it seems despite being an array it can only accept a single string, so "arm64", "x64" doesn't work. Instead, "universal" is needed.
The full set of architecture options is:
"arm64" | "armv7l" | "ia32" | "universal" | "x64"
I made a PR after confirming the build still works for arm64 macOS when using universal:
https://github.com/midi2-dev/MIDI2.0Workbench/pull/15
Unfortunately the build still doesn't work on Intel macOS, although it gets further. I'll share what I've observed below.
Here's what I see when running after building using x64 only (which I don't think is the right way forward):
(The ProtoZOA is detected but the main window is not populated as it is on arm64 macOS:
New USB:51966_16385_64)
yarn run v1.22.22
$ electron .
TypeError: Cannot read properties of undefined (reading 'interfaces')
at getRawUSBMIDI2 (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/usbMIDI2Devices.js:89:30)
at Array.map (<anonymous>)
at Object.startUSB (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/usbMIDI2Devices.js:24:15)
at Object.<anonymous> (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/index.js:226:20)
at Module._compile (node:internal/modules/cjs/loader:1118:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1173:10)
at Module.load (node:internal/modules/cjs/loader:988:32)
at Module._load (node:internal/modules/cjs/loader:829:12)
at c._load (node:electron/js2c/asar_bundle:5:13343)
at Module.require (node:internal/modules/cjs/loader:1012:19)
TypeError: Cannot read properties of undefined (reading 'interfaces')
at getRawUSBMIDI2 (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/usbMIDI2Devices.js:89:30)
at Array.map (<anonymous>)
at Object.startUSB (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/usbMIDI2Devices.js:24:15)
at Object.<anonymous> (/Users/zendev/repos/MIDI2.0Workbench/node_modules/usb_midi_2/index.js:226:20)
at Module._compile (node:internal/modules/cjs/loader:1118:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1173:10)
at Module.load (node:internal/modules/cjs/loader:988:32)
at Module._load (node:internal/modules/cjs/loader:829:12)
at c._load (node:electron/js2c/asar_bundle:5:13343)
at Module.require (node:internal/modules/cjs/loader:1012:19)```
When building using universal, I see this popup dialog window when starting the app:
The app GUI never loads in this case.
That is an issue with the node midi library. I might investigate if other forks of the node-midi library have improved on this issue.
@nonchai @kcoul
I managed to run it on Intel Mac. x86_64 architecture. Sequoia 15.2. The error is due to having MIDI library compiled for Apple Silicon.
rm -rf node_modules/midi
yarn add midi
yarn start
@unobatbayar if you end up finding this as a solution I'll add it to the docs as a solution thanks for doing this work!