I am using a few days old Lazarus/Cocoa/FPC setup for compiling my Mac apps:
- FPC 3.0.4
- Lazarus IDE v2.1.0 r602244m
- My apps are signed+ 64bit / "x86_64-darwin" / "x86_64-darwin-cocoa (alpha)"
The app works fine when I download from my own website on my Mac - I have tried versions
1.14.1 +
1.14.3...
However, a user just using
High Sierra 10.13.6 reported to me he gets this error:
xxx cannot be opened because of a problem
Check with the developer to make sure xxx works with this version of macOS. You may need to reinstall the application. Be sure to install any available updates for the application and macOS
with error.log stating this:
Process: MyProgram [32151]
Path: /Applications/MyProgram.app/Contents/MacOS/MyProgram
Identifier: com.MyCompany.MyProgram
Version: 1.0 (1)
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: MyProgram [32151]
User ID: 501
Date/Time: 2019-02-05 08:59:18.475 +0000
OS Version: Mac OS X 10.13.6 (17G4015)
Report Version: 12
Time Awake Since Boot: 1200000 seconds
System Integrity Protection: enabled
Crashed Thread: 0
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: DYLD, [0x4] Symbol missing
Application Specific Information:
dyld: launch, loading dependent libraries
Dyld Error Message:
Symbol not found: __objc_empty_cache
Referenced from: /Applications/MyProgram.app/Contents/MacOS/MyProgram
Expected in: /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
in /Applications/MyProgram.app/Contents/MacOS/MyProgram
...
I have attached two screenshots of his system which he has emailed.
...
In my "Project settings" I have set the following:
Compiler options > Custom options:
If TargetOS = 'darwin' then
begin
UsageCustomOptions += '-WM10.6'
end;
Customer reports that there is
no difference on ability run apps
compiled with/without the above.
Still - the only explanation possible seems to be an issue with backwards compability with "old" Mac OS system?
Maybe this could be related
https://github.com/graemeg/freepascal/commit/3af49fe90ac3b4c631a115bbb5a631c27756daf5?