Em sáb., 16 de abr. de 2022 às 21:07, Alexandre Torres Porres < porres@gmail.com> escreveu:
Hi, I have fat binaries for a test release update of else, it should work on apple silicon macs running Pd compiled for arm that loads externals for arm. Can anyone test these? I don't have a silicon mac.
Download from here since deken seems to be down. https://github.com/porres/pd-else/releases/tag/v1.0-rc1-test
So, someone on facebook said he couldn't load the externals. The usual ~load _object: Symbol "else_setup" not found~ is given. He also said he had to run *sudo spctl --master-disable* to allow it to load, no idea what that means, but doesn't look good as well.
The fat binaries run fine in my mac intel...
Let me tell you my process.
Hi, I now have a machine with Monterey and XCode 13 installed and I want to build fat binaries for my externals. I still have a mac intell by the way.
Em ter., 20 de out. de 2020 às 17:36, Alexandre Torres Porres < porres@gmail.com> escreveu:
I did *make install objectsdir=../ extension=d_fat *and pd-lib-builder generated binaries with that extension.
Before, I was using the above command to build fat binaries with pdlibbuilder for both 32/64 bits (taken from some other email to this list). Today I installed Monterey and XCode 13 on a mac intel and tried that command but got an error.
porres@Alexandres-MacBook-Pro pd-else copy % make install objectsdir=../ extension=d_fat
++++ info: using Makefile.pdlibbuilder version 0.6.0
++++ info: making target install in lib else
++++ info: installpath is '..//else'
++++ info: linking objects in timed.gate~.d_fat for lib else
cc -undefined suppress -flat_namespace -bundle -arch i386 -arch x86_64 -mmacosx-version-min=10.6 -o timed.gate~.d_fat Classes/Source/timed.gate~.o -lc
ld: warning: The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)
ld: warning: ignoring file Classes/Source/timed.gate~.o, building for macOS-i386 but attempting to link with file built for unknown-x86_64
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd (3 slices)
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/libc.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/libc.tbd (3 slices)
ld: dynamic main executables must link with libSystem.dylib for architecture i386
clang: *error: **linker command failed with exit code 1 (use -v to see invocation)*
make: *** [timed.gate~.d_fat] Error 1
porres@Alexandres-MacBook-Pro pd-else copy %
I understood it tried to compile for 32/64 bits t even possible to create a single fat binary for all the 3 architectures? It complained that *The i386 architecture is deprecated for macOS*, so I guess I can't build it anymore for it with XCode 13, right? I wondered if I could build a fat binary for 32/64 bits and arm, but I can forget about it, right?
Well, I then tried compiling with pdlibbuilder like this: "make install objectsdir=../ arch="arm64 x86_64 i386" extension=d_fat" didn't work...
It didn't work either... then I tried.
*make install objectsdir=../ arch="arm64 x86_64" extension=d_fat*
and it worked, it did build, but I got stuff like
++++ info: linking objects in timed.gate~.d_fat for lib else cc -undefined suppress -flat_namespace -bundle -arch arm64 -arch x86_64 -mmacosx-version-min=10.6 -o timed.gate~.d_fat Classes/Source/timed.gate~.o -lc *ld: warning: ignoring file Classes/Source/timed.gate~.o, building for macOS-arm64 but attempting to link with file built for unknown-x86_64* ++++ info: linking objects in trig.delay2~.d_fat for lib else
I was worried from the warning *attempting to link with file built for unknown-x86_64* would mean it would work for apple silicon but probably not for mac intel, but it worked for mac intel, so I thought it'd work just fine for apple silicon as well, but it didn't!
I couldn't upload to deken because the server is down, but I made deken package the external, it did create a deken file named *else[v1.0-0rc1-test_with_live_electronics_tutorial]* *(Darwin-amd64-32)(Darwin-arm64-0)**.dek*, so that seems ok. Nonetheless, I got some warnings in deken, probably for all objects, which said, for example:
OUCH: couldn't detect float-size for 'else/asr~.d_fat'
and no default set, assuming None
use '--default-floatsize <N>' to override)
I didn't bother trying to explicitly define a float size because I wasn't uploading it to deken... and this wouldn't change my build anyway...
So, I'm really lost here and I don't know what I should do to build a proper fat binary...
As for not being able to create a fat binary that also includes *i386*, I guess we can forget about it, for deken at least. I can still build for it and keep that on my release page on github if needed, but it doesn't seem like something I should bother that much these days (I'm not even mentioning ppc).
Anyway, any hints on what I can do to build it properly? And also maybe avoid the needed *sudo spctl --master-disable *command (whatever that is)?
Thanks