You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Been testing and using the new arm64 version of lime very nicely! It's possible to compile downwards to x86 from apple silicon, but then creating a universal binary would involve running all of the build/compile commands twice, and then combining the builds with lipo.
A good convenience might be something like a mac-universal target, which would compile both x86 and arm for mac, and then run lipo to create a universal binary with no fuss. Of course it might be unpleasant for day to day use, but rather something nice for when getting ready to package something up!
The text was updated successfully, but these errors were encountered:
for potential reference, for FNF I made this script
#!/bin/sh# Create x86_64 version
lime build mac -64 -release
# Create folder to hold our universal binary stuff (and delete our previous one if it exists so we start fresh)cd export/release
rm -rf macosUniversal
mkdir macosUniversal
# Move the x86_64 version to our universal folder
cp -r macos/bin/Funkin.app macosUniversal
cd ../..
# Create arm64 version
lime build mac -arm64 -release
# Move the arm64 Funkin *executable* and *lime.ndll* into our to-be universal binary, renaming them along the waycd export/release
cp -r macos/bin/Funkin.app/Contents/MacOS/Funkin macosUniversal/Funkin.app/Contents/MacOS/FunkinArm
cp -r macos/bin/Funkin.app/Contents/MacOS/lime.ndll macosUniversal/Funkin.app/Contents/MacOS/limeArm.ndll
# cd into where we will run our `lipo` commands to combine the binariescd macosUniversal/Funkin.app/Contents/MacOS
# change the filenames of the x86_64 versions of the executable/ndll
mv Funkin Funkin64
mv lime.ndll lime64.ndll
# combine our x86_64 and our arm64 versions of the ndll into a universal lime.ndll
lipo -create -output lime.ndll lime64.ndll limeArm.ndll
# combine our x86_64 and our arm64 versions of the Funkin executable into a universal binary
lipo -create -output Funkin Funkin64 FunkinArm
# remove leftovers
rm FunkinArm Funkin64 lime64.ndll limeArm.ndll
and this creates a universal binary!
There's other files that we include but those are already universal (libvlc stuff), but potentially maybe some stuff like Steam api or other libraries might need to be created universally if they don't go thru the lime build process
I think phase 1 of making this workflow easier is to allow easy creation of a universal lime.ndll, since right now lime separates the x86 and arm64 versions into their own folders, so can probably just make a new folder somewhere along the process for a combined universal lime.ndll?
Been testing and using the new arm64 version of lime very nicely! It's possible to compile downwards to x86 from apple silicon, but then creating a universal binary would involve running all of the build/compile commands twice, and then combining the builds with
lipo
.A good convenience might be something like a
mac-universal
target, which would compile both x86 and arm for mac, and then runlipo
to create a universal binary with no fuss. Of course it might be unpleasant for day to day use, but rather something nice for when getting ready to package something up!The text was updated successfully, but these errors were encountered: