eoyilmaz / displaycal-py3

DisplayCAL Modernization Project
https://eoyilmaz.github.io/displaycal-py3/
GNU General Public License v3.0
861 stars 60 forks source link

Mac installer package fails to run post installation #435

Open borez opened 1 month ago

borez commented 1 month ago

Describe the bug A clear and concise description of what the bug is.

Latest MacOS package fails to open, with an error displayed. Versions (please complete the following information):

image
decayedxistence commented 1 month ago

Describe the bug A clear and concise description of what the bug is.

Latest MacOS package fails to open, with an error displayed. Versions (please complete the following information):

* OS: Sequoia 15.0.1

* Python Version: NA (I just used the installer? - do I need to install Python?)

* ArgyllCMS Version: 3.30

* DisplayCAL Version: 3.9.14

Additional context Add any other context about the problem here.

image

If you're on an Intel Mac, there's an x64 .dmg that will work. The arm64 is for Apple Silicon.

borez commented 1 month ago

Thanks but i am on Apple Silicon, and running the arm64 package.

eoyilmaz commented 1 month ago

@borez Let me check the uploaded package... Yeah, for some reason it is broken, let me upload again.

eoyilmaz commented 1 month ago

So, I regenerated the app and dmg image, before uploading it I run both the app and the extracted app from dmg, and they both worked. But after uploading it to GitHub and downloading back again, it stopped working.

As I understand there is an issue with the signature, so the running the following ~disables the gate keeper for~ removes the com.apple.quarantine attribute from DisplayCAL.app.

Not an ideal solution, but will let you run it until I found a solution.

xattr -dr com.apple.quarantine /Applications/DisplayCAL.app
eoyilmaz commented 1 month ago

As I see the com.apple.quarantine attribute is added to all downloaded files, so that the user is asked to give permission when they first run the application, preventing malwares to run wihtout the users permission, and then after the first run it is removed.

But, I believe, in our case, the attribute persists... Still looking for a solution...

MStraeten commented 1 month ago

you might try dummy signing: codesign --sign - --verbose --deep --force --preserve-metadata=entitlements,requirements,flags,runtime -i "org.displaycal" <dmg>

eoyilmaz commented 1 month ago

@MStraeten thanks for the suggestion, I ran the codesign command with a slight modification (net.displaycal instead of org.displaycal):

codesign --sign - --verbose --deep --force --preserve-metadata=entitlements,requirements,flags,runtime -i "net.displaycal" DisplayCAL-3.9.14-macOS_arm64.dmg

I uploaded it, downloaded again, and it is still displaying the same error, and it still requires the com.apple.quarantine attr to be deleted.