Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code sign Mach O files manually #208

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

amurgshere
Copy link
Contributor

@amurgshere amurgshere commented Nov 9, 2024

This item fixes issue #210 .

Changes

  • Code sign Mach O files manually
  • Fix typo "Usign" to "Using"
  • Add MacOS Output and Temp folders to GitIgnore

Reproduction of Issue

  1. Clone the repository to an Apple Silicon MAC (MacOS 14.6.1)
  2. Run this command from the cloned directory to build, package and sign the app bundles:

./distribution/macos/create_macos_build_ava.sh ./ ./distribution/macos/temp ./distribution/macos/output ./distribution/macos/entitlements.xml 1.0.0 0 Release

ISSUE: x64 version is not signed properly and Universal bundle is not created at all as the x64 signing failed which stops the script. This error is shown:

/Volumes/MACBOOK/ROMS/NSW/Ryujinx/GitHub/Ryujinx/distribution/macos/temp/output_x64/Ryujinx.app: code object is not signed at all In subcomponent: /Volumes/MACBOOK/ROMS/NSW/Ryujinx/GitHub/Ryujinx/distribution/macos/temp/output_x64/Ryujinx.app/Contents/Frameworks/libglfw.3.dylib

EXPECTED OUTCOME: Both the x64 and Universal bundles should be created and signed in the distribution/macOS/output folders.

NOTE: I have not updated "rcodesign" as I do not have this and am not sure how to install it so can't test it.

@Kek5chen
Copy link
Contributor

Kek5chen commented Nov 9, 2024

For this to merge we should probably have reviews from different OSX Versions with different releases of codesign so we don't run into another follow up issue.

I would suggest the following OSX releases:

  • Aarch64 >13.X
  • x86_64 >13.X
  • Aarch64 <13.X
  • x86_64 <13.X

@amurgshere
Copy link
Contributor Author

amurgshere commented Nov 9, 2024

Thanks @Kek5chen ,

I have tested >13.X (MacOS 14.6.1) on Aarch64 and x86_64 (running on an M1 Mac using Rosetta 2) but I don’t have a device on < 13.X so cant test that.

If anyone can help out here that would be great!

also, I can see one of the builds failed when uploading artefacts on this PR, but it looks like it’s just a timeout and not anything to do with my changes, though not 100% sure as it is on the universal macOS build?

@Kek5chen
Copy link
Contributor

Kek5chen commented Nov 9, 2024

Can you tell us the exact version of your system? Because the issue you reported was successfully built on aarch64 15.0.1

@amurgshere
Copy link
Contributor Author

Apologies @Kek5chen , it is 14.6.1, I will be upgrading to 15 in the next few weeks or so, so will retest then too. Have updated above comment.

@Kek5chen
Copy link
Contributor

Kek5chen commented Nov 9, 2024

Hmm. Interesting. I wonder what the issue is there then. It looks like the issue you're having specifically is that the custom build of glfw isn't signed. I think though that I might've used a different provided build of glfw from the nix store. Seems like that's the issue. In that case I do think that doing find and signing each is the way to go.

Though I'm not sure if building the libraries for some triggers an automatic code signing process or what the issue with glfw is specifically. Maybe you want to investigate that a bit before so we exactly know where the issue stems from.

@amurgshere
Copy link
Contributor Author

If I manually sign that one and try again it then fails on another library , the lib sound one I think it was, so that’s when I added the line just to sign them all then it worked.

@Kek5chen
Copy link
Contributor

Kek5chen commented Nov 9, 2024

Oh yea alright. Sounds good. Find seems like the way to go.

@Kek5chen
Copy link
Contributor

@GreemDev would probably be better to rebase instead of merge. general thing.

Fix typo
Add MacOS Output and Temp folders to GitIgnore
@amurgshere amurgshere force-pushed the fix-signing-issue-with-mach-o-files branch from 6e203a4 to 20ddc80 Compare November 24, 2024 22:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infra Updates to dependencies
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants