frame 0000006: 0x000000010079af34 lazarus`MAINIDEBARDROPFILES(this=0x000000010a9c68f0, SENDER=0x000000010a9c68f0, FILENAMES=ANSISTRING [] @ 0x000000010ac70670, highFILENAMES=0) at mainbar.pas:405
frame 0000007: 0x000000010005fca4 lazarus`FORMS$_$TCUSTOMFORM_$__$$_INTFDROPFILES$array_of_ANSISTRING + 68
frame 0000008: 0x00000001001eed3d lazarus`-[TAppDelegate application:openFiles:] + 357
frame 0000009: 0x00007fff4e6741ba AppKit`-[NSApplication _doOpenFile:ok:tryTemp:] + 286
frame 0000010: 0x00007fff4e253337 AppKit`-[NSApplication finishLaunching] + 2438
judging by the log file, I can think that the issue comes from the difference in the order of LCL messages sent.
Though an interesting thing is that the issue comes from "files drop" call:Code: [Select]frame 0000006: 0x000000010079af34 lazarus`MAINIDEBARDROPFILES(this=0x000000010a9c68f0, SENDER=0x000000010a9c68f0, FILENAMES=ANSISTRING [] @ 0x000000010ac70670, highFILENAMES=0) at mainbar.pas:405
frame 0000007: 0x000000010005fca4 lazarus`FORMS$_$TCUSTOMFORM_$__$$_INTFDROPFILES$array_of_ANSISTRING + 68
frame 0000008: 0x00000001001eed3d lazarus`-[TAppDelegate application:openFiles:] + 357
frame 0000009: 0x00007fff4e6741ba AppKit`-[NSApplication _doOpenFile:ok:tryTemp:] + 286
frame 0000010: 0x00007fff4e253337 AppKit`-[NSApplication finishLaunching] + 2438
So my question is: how do you start the IDE?
- do you double click on a lazarus file (letting macOS to open the IDE for you)
- do you drag and drop the file into IDE or the app icon
- do you simply launch IDE (by clicking on the app icon in Finder or Dock)
- some other way?
I haven't done a stack trace, but I have the same problem when using fpcupdeluxe.
For a while now, I've had to rebuild using lazbuild from the commandline to get rid of the arithmetic error.
lazbuild --build-ide= --widgetset="Cocoa"
Then I can run it normally, as well as rebuild through the IDE.
(3104) Compiling lclextensions_package.pas
(3104) Compiling delphicompat.pas
/Users/examplename/EN/LazarusComponents/lclextensions_lazarus/delphicompat.pas(131,2) Fatal: (2013) Cannot open include file "uses.inc"
Fatal: (1018) Compilation aborted
Error: (lazarus) Compile package lclextensions_package 0.6.1: stopped with exit code 256
/Users/examplename/EN/LazarusComponents/HtmlViewer/source/FramBrwz.pas(1088,51) Warn
/Developer/lazarus/components/ideintf/dbpropedits.pas(58,32) Hint: (5024) Parameter "Index" no
(310
Error: (lazarus) Compile package FrameViewer09 11.0: terminated
Error: (lazarus) Compile package IDEIntf 1.0: terminated
Error: (lazarus) Compile package SynEdit 1.0: terminated
Error: (lazarus) [TLazPackageGraph.CompileRequiredPackages] "Exit code 256"
Error: (lazarus) Building IDE: Compile AutoInstall Packages failed.
fpcupdeluxe supplies a startlazarus.app file which I use (it seems to launch lazarus.app) by doubbleclicking on it in Finderok, and what happens if you start lazarus.app manually (using lazarus binary)?
fpcupdeluxe supplies a startlazarus.app file which I use (it seems to launch lazarus.app) by doubbleclicking on it in Finderok, and what happens if you start lazarus.app manually (using lazarus binary)?
settings show target.run-args
please run lazarus under lldb.
When lldb loads lazarus, and prompts you to enter the first command, please run the following and provide the output:Code: [Select]settings show target.run-args
and then continue the execution.
and does it crash with EXC_BAD_ACCESS or Arithmetic overflow?
IF it's EXC_BAD_ACCESS, then try to modify cocoaobject.inc (part of cocoaint.pas)
procedure TAppDelegate.application_openFiles(sender: NSApplication; filenames: NSArray); var lFiles: array of string; lNSStr: NSString; i: Integer; begin if (filenames.count=0) then Exit; // this is a new line SetLength(lFiles, filenames.count); for i := 0 to filenames.count-1 do begin lNSStr := NSString(filenames.objectAtIndex(i)); lFiles[i] := NSStringToString(lNSStr); end; Application.IntfDropFiles(lFiles); if Application.MainForm<>nil then Application.MainForm.IntfDropFiles(lFiles); end;
Seems newest trunk solved the issues...there was nothing done in the trunk to resolve the issue.