[PD-dev] Externals in Pd.52.2(Rosetta Mode) on Mac M1!

Roman Haefeli reduzent at gmail.com
Sat Apr 30 20:33:48 CEST 2022


I finally had the chance run Pd [1] on an M1-Mac with Monterey. Here's
what I found:

When starting Pd normally, two processes (Pd and pd) are running in
native mode. Deken shows only arm64 externals. When installing an
external, it can be loaded afterwards.

When 'Open with Rosetta' is checked in the information dialog and Pd is
started, both processes (Pd and pd) are running in Rosetta mode (the
intel binary is executed). Trying to load the previously downloaded
arm64 external fails with an error message indicating wront
architecture. Now, Deken only shows amd64 externals. When downloading
and installing an external now, it can be loaded successfully
afterwards.

tl;dr: Pd and Deken seem to do everything correctly on M1 Macs. 

Child processed are launched with the same arch as their parent. I
observed this also with QjackCtl and jackd. Normally, both run in
native mode. When 'Open with Rosetta' is checked in QjackCtl, jackd
runs under Rosetta too.


Roman  



[1] http://msp.ucsd.edu/Software/pd-0.52-2.macos.zip


On Wed, 2022-04-27 at 09:01 +0200, Roman Haefeli wrote:
> On Wed, 2022-04-27 at 08:42 +0200, IOhannes m zmoelnig wrote:
> 
> > so here's a better solution (also untested).
> > instead if *everything* i wrote above do this:
> > 
> > 1. find the file Pd.app/Content/Resources/tcl/pd-gui.tcl
> > 2. open it in an editor
> > 3. locate the line (somewhere around line:846) that says:
> >     "[exec -- $pd_exec -guiport $::port {*}$::pd_startup_args &]"
> > 4. in this line put an "arch -x86_64" before the $pd_exec, so it
> > now
> > reads:
> >     "[exec -- arch -x86_64 $pd_exec -guiport $::port 
> > {*}$::pd_startup_args &]"
> 
> That's valuable to know. Thanks, IOHannes. I still have two questions
> regarding this matter:
> 
> 1. How does Deken detect current platform/arch? Does it something
> like
> `uname -m` or does it check what arch Pd has, or something else?
> 
> 2. Does the code-signing take into account only the compiled binaries
> or the whole app? Do I have to re-code-sign after having modified pd-
> gui.tcl?
> 
> BTW: I have access to an M1 with macOS Monterey and hopefully will
> soon
> be able to build a few externals and test stuff. 
> 
> Roman

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: This is a digitally signed message part
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20220430/035aafc9/attachment.sig>


More information about the Pd-dev mailing list