Запуск SMJobBless:
(PrefPane проекта xcode version 4 Build 4A304a)
SMJobBless(kSMDomainSystemLaunchd, @"com.coderama.coderamaHelper", authRef, &err);
Вызывает эту ошибку:
System Preferences[22312:903] Bless Error: Error Domain=kSMErrorDomainFramework Code=5 UserInfo=0x2005790e0 "The operation couldn’t be completed. (kSMErrorDomainFramework error 5 - The tool at the specified path is not valid.)"
Ниже приведены мои списки.
Может кто-нибудь расшифровать сообщение об ошибке, чтобы я мог попытаться устранить его? Я просмотрел все свои списки, чтобы убедиться, что имена совпадают.
coderama-info.plist:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIconFile</key>
<string></string>
<key>CFBundleIdentifier</key>
<string>com.coderama.${PRODUCT_NAME:rfc1034identifier}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2012 coderama. All rights reserved.</string>
<key>NSMainNibFile</key>
<string>coderama</string>
<key>NSPrefPaneIconFile</key>
<string>show_wireframe_zoom_24.gif</string>
<key>NSPrefPaneIconLabel</key>
<string>coderama</string>
<key>NSPrincipalClass</key>
<string>coderama</string>
<key>SMPrivilegedExecutables</key>
<dict>
<key>com.coderama.coderamaHelper</key>
<string>identifier com.coderama.coderamaHelper and certificate leaf[subject.CN] = "Joe Developer"</string>
</dict>
</dict>
</plist>
coderamaHelper-info.plist:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleIdentifier</key>
<string>com.coderama.coderamaHelper</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>coderamaHelper</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>SMAuthorizedClients</key>
<array>
<string>identifier com.coderama.coderama and certificate leaf[subject.CN] = "Joe Developer"</string>
</array>
</dict>
</plist>
coderamaHelper-Launchd.plist выглядит так:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.coderama.coderamaHelper</string>
<key>MachServices</key>
<dict>
<key>com.coderama.coderamaHelper.mach</key>
<true/>
</dict>
</dict>
</plist>