SkAT-VG / SDT

Sound Design Toolkit
Other
97 stars 8 forks source link

Mac M1 compilation issue #23

Open JakubOrlinskiUPM opened 1 year ago

JakubOrlinskiUPM commented 1 year ago

After installing the latest release of SDT on my Mac M1, I am getting an error in my Pd console:

/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin: dlopen(/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin, 0x000A): tried: '/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64')), '/System/Volumes/Preboot/Cryptexes/OS/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (no such file), '/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64'))
/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin: dlopen(/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin, 0x000A): tried: '/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64')), '/System/Volumes/Preboot/Cryptexes/OS/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (no such file), '/Users/me/Documents/Pd/externals/SDT/SDT.pd_darwin' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64'))

I understand this to be an issue with the fact that my CPU has a different architecture. I tried compiling from source, but when changing the MACARCH to arm64, there were many errors in the CLI.

Has anyone managed to compile SDT for M1? Is there a possible M1 release coming?

Screenshot 2022-11-15 at 21 23 49
Command-line output when compiling for arm64: ``` clang -isysroot ../../3rdparty/MacOSX10.7.sdk -mmacosx-version-min=10.7 -Wall -Wno-unknown-pragmas -Werror -g -O3 -I../../3rdparty/json-parser -I../../3rdparty/json-builder -c ../../src/SDT/SDTAnalysis.c -o ../../src/SDT/SDTAnalysis.o In file included from ../../src/SDT/SDTAnalysis.c:1: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/assert.h:42: ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/cdefs.h:540:4: error: Unknown architecture # error Unknown architecture ^ In file included from ../../src/SDT/SDTAnalysis.c:2: ../../3rdparty/MacOSX10.7.sdk/usr/include/math.h:32:2: error: Unknown architecture #error Unknown architecture ^ In file included from ../../src/SDT/SDTAnalysis.c:3: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/stdlib.h:63: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/_types.h:27: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:33: ../../3rdparty/MacOSX10.7.sdk/usr/include/machine/_types.h:36:2: error: architecture not supported #error architecture not supported ^ In file included from ../../src/SDT/SDTAnalysis.c:3: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/stdlib.h:63: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/_types.h:27: ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:94:9: error: unknown type name '__int64_t' typedef __int64_t __darwin_blkcnt_t; /* total blocks */ ^ ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:95:9: error: unknown type name '__int32_t'; did you mean '__int128_t'? typedef __int32_t __darwin_blksize_t; /* preferred block size */ ^ note: '__int128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:96:9: error: unknown type name '__int32_t'; did you mean '__int128_t'? typedef __int32_t __darwin_dev_t; /* dev_t */ ^ note: '__int128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:99:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_gid_t; /* [???] process and group IDs */ ^ note: '__uint128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:100:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_id_t; /* [XSI] pid_t, uid_t, or gid_t*/ ^ note: '__uint128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:101:9: error: unknown type name '__uint64_t' typedef __uint64_t __darwin_ino64_t; /* [???] Used for 64 bit inodes */ ^ ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:107:9: error: unknown type name '__darwin_natural_t' typedef __darwin_natural_t __darwin_mach_port_name_t; /* Used by mach */ ^ ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:109:9: error: unknown type name '__uint16_t'; did you mean '__uint128_t'? typedef __uint16_t __darwin_mode_t; /* [???] Some file attributes */ ^ note: '__uint128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:110:9: error: unknown type name '__int64_t' typedef __int64_t __darwin_off_t; /* [???] Used for file sizes */ ^ ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:111:9: error: unknown type name '__int32_t'; did you mean '__int128_t'? typedef __int32_t __darwin_pid_t; /* [???] process and group IDs */ ^ note: '__int128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:131:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_sigset_t; /* [???] signal set */ ^ note: '__uint128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:132:9: error: unknown type name '__int32_t'; did you mean '__int128_t'? typedef __int32_t __darwin_suseconds_t; /* [???] microseconds */ ^ note: '__int128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:133:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_uid_t; /* [???] user IDs */ ^ note: '__uint128_t' declared here ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/_types.h:134:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_useconds_t; /* [???] microseconds */ ^ note: '__uint128_t' declared here In file included from ../../src/SDT/SDTAnalysis.c:3: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/stdlib.h:63: ../../3rdparty/MacOSX10.7.sdk/usr/include/_types.h:42:9: error: unknown type name '__uint32_t'; did you mean '__uint128_t'? typedef __uint32_t __darwin_wctype_t; ^ note: '__uint128_t' declared here In file included from ../../src/SDT/SDTAnalysis.c:3: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/stdlib.h:65: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/wait.h:116: In file included from ../../3rdparty/MacOSX10.7.sdk/usr/include/sys/signal.h:81: ../../3rdparty/MacOSX10.7.sdk/usr/include/machine/signal.h:36:2: error: architecture not supported #error architecture not supported ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 20 errors generated. make: *** [../../src/SDT/SDTAnalysis.o] Error 1 ```
thouldcroft commented 1 year ago

I can’t contribute with any insight on compilation for the ARM macs, but I would really appreciate an ARM/Universal compilation. I’m on an M1 but I don’t have any experience with compiling from source, but if I can assist in any way I’d be more than happy to help.

stepap commented 1 year ago

A universal build is coming soon. Stay tuned!

icaro-rdp commented 1 year ago

I have this issue too, any suggestion?

ChromaticIsobar commented 1 year ago

A release is coming within the month. Apologies for any inconvenience caused by our delay.

ChromaticIsobar commented 11 months ago

A release candidate for v83.0.0 has been published. This release should be compatible with Apple Silicon (arm64 architectures).

ChromaticIsobar commented 7 months ago

Release v83.0.0-Max3.1.0-Pd0.97.0 is out