This is for a non-GUI program -- intended to be a LaunchDaemon at some point; I followed Quinn's instructions for this. As I've commented before, I'm using cmake to generate an xcodeproj (wheeeee), so I wouldn't be surprised if it's doing something wrong.
I get the error if I use open Debug/HelperDaemon.app
or try to run it in Xcode. That doesn't quite surprise me a lot (again, not a GUI app), and Xcode says there may be a problem with signing. If I run it via the command line (that is, ./Debu/HelperDaemon.app/Contents/MacOS/HelperDaemon
), it is immediately killed. I haven't been able to find much in the logs.
What I have noted is that if I do codesign --force --deep --sign - ./Debug/HelperDaemon.app
, it then does work (although then I run into other crashes). However, doing codesign -vv Debug/HelperDaemon.app
, it says everything is fine. (codesign -dv --entitlements :- Debug/HelperDaemon.app
shows the entitlements I expect, as well.)
This is on macOS; I'm building on and for 11.6, using Xcode 13.1.
For the program's entitlements, I've got com.apple.developer.system-extension.install
, keychain-access-groups
, and com.apple.security.application-groups
(although I tried removing that one, with no difference in behaviour).