Universal build (intel/apple silicon) manually lipo'ed works fine #91
Replies: 2 comments
-
I'm not sure there's much of a benefit to that unless you want to distribute via the App Store. It's certainly a lot of work. Obvs it would be preferable to get it to work on a single machine, cross-compiling the other architecture. The last time I poked at that Gnome was still using autotools and getting it to deal with executable build components like gdk-pixbuf-query-loaders and glib-compile-schemas for the cross-build was too hard. Maybe that's better with meson, but even so jhbuild doesn't make cross-compiling a whole tree very easy.
Not that I know about but it should be simple enough to write a little Python program to do it using |
Beta Was this translation helpful? Give feedback.
-
Yes, some work but once I made the script it wasn't so bad anymore. But I'm certainly only doing that longer times apart. It was just an itch I wanted to scratch to provide a universal build on our homepage.
Getting cross-compiling to work would probably be a big task with not a lot of usage :)
Since I have no Python knowledge, I'll make do of my crude script :) |
Beta Was this translation helpful? Give feedback.
-
Just posting to mention that my universal build of GTK3 works fine :)
I've built the Intel arch (deployment version 10.11, SDK 13.0) on my Intel mac and the arm64 (deployment version 11.0, SDK 13.0) on my M1 mac and then just lipo'ed the libs to get a universal prefix (I didn't bother with the binaries as I'd be building for release only on my M1).
The "script" is attached (it's not fancy, just the lipo commands), I did this in May this year and only
meta-gtk-osx-bootstrap meta-gtk-osx-gtk3
so it might need more tinkering if someone wants to make use of it.I wonder if there is a program to do this automatically, take two folders and lipo every binary and dump it with the same structure in a third folder :)
gtk3lipo.sh.txt
Beta Was this translation helpful? Give feedback.
All reactions