zkmkarlsruhe / ofxTensorFlow2

TensorFlow 2 AI/ML library wrapper for openFrameworks
Other
109 stars 16 forks source link

error: Signing Identity: “-” #37

Closed stephanschulz closed 3 weeks ago

stephanschulz commented 4 months ago

I had this addon working successfully with OF 11.2 on a previous macOS system. now I am on a M1 with macOS 12.6.8 and Xcode 14.1.0 and get these 2 errors:

CodeSign /Applications/of_v0.12.0_osx_release/addons/ofxTensorFlow2/example_video_matting/bin/example_video_mattingDebug.app/Contents/MacOS/libtensorflow_framework.dylib (in target 'example_video_matting' from project 'example_video_matting')
    cd /Applications/of_v0.12.0_osx_release/addons/ofxTensorFlow2/example_video_matting

    Signing Identity:     "-"

    /usr/bin/codesign --force --sign - --deep --timestamp\=none --preserve-metadata\=identifier,entitlements,flags --generate-entitlement-der /Applications/of_v0.12.0_osx_release/addons/ofxTensorFlow2/example_video_matting/bin/example_video_mattingDebug.app/Contents/MacOS/libtensorflow_framework.dylib

/Applications/of_v0.12.0_osx_release/addons/ofxTensorFlow2/example_video_matting/bin/example_video_mattingDebug.app/Contents/MacOS/libtensorflow_framework.dylib: main executable failed strict validation
Command CodeSign failed with a nonzero exit code

The .dylib is in the right place Screen Shot 2024-02-15 at 5 50 22 PM and I think it has the right permissions Screen Shot 2024-02-15 at 5 51 00 PM

and then the main issue I guess is the Signing Identity: "-" thing?

the same issue is mentioned but for a different project. https://github.com/openframeworks/openFrameworks/issues/6705

I am a bit lost.

other default OF examples compile and run just fine.

stephanschulz commented 4 months ago

ah Stephan of the past had the solution all along. set Embed Without Signing https://forum.openframeworks.cc/t/command-codesign-failed-with-a-nonzero-exit-code-xcode-13-3-1/39814/2 Screen Shot 2024-02-15 at 6 45 39 PM

suyashcjoshi commented 4 months ago

I had the same error and setting all of those libraries to 'Embed Without Signing' resolved this error for me.

danomatika commented 3 weeks ago

This step isn't actually needed, so the files can be removed from the Copy Files build phase since the macos_install.libs.sh script installs them. See my answer in #38.

danomatika commented 1 week ago

This step isn't actually needed, so the files can be removed from the Copy Files build phase since the macos_install.libs.sh script installs them. See my answer in #38.

Hah, actually this doesn't work as linking will fail without them. IN any case, unchecking the COdeSign boxes in the Copy Files phase works fine. I have updated the readme for ofxTF2 1.5.0.