A couple of observations on the newest version of Lazarus (0.9.27) lazarus / 15-macOS - Mac OS X ---------------------------------------------------------------------- Carbonide · 2009-02-05 15:05 After an year or so, I tried Lazarus again today and wow..., what a difference! It seems like enormous progress has been made since my last encounter with Lazarus (which was still X11 based). Now we have a nice Carbon interface and double clickable files from the Finder. Many thanks for all those involved in this wonderful work! I have encountered some small bugs, though: - there must not be a space in the folder containing the Lazarus project (otherwise the compiled program will not launch) - the Lazarus icon appears two times in my dock - lots of 'unknown stabs type 0xE0 in...' error messages while compilation is running, although it succeeds in the end nevertheless - there is a file created called 'unit1.lrs' created in the root folder of my boot drive, even if I save my project in some other location - the source window is not shown on my desktop: I suspect it is created off-screen as the highlight of my other windows changes if I select Source Editor from the Window menu or double-click on an object (I work around this bug by simply editing the .pas file in TextEdit) Apart of that, great work guys, thanks a lot! ---------------------------------------------------------------------- Phil · 2009-02-05 15:20 I have not noticed any of the problems you describe. Have you tested the stable 0.9.26 or 0.9.26.1 with fixes? If either of those work any better, then it sounds like some problems have been introduced in 0.9.27 and need bug reports. Thanks. -Phil ---------------------------------------------------------------------- Carbonide · 2009-02-05 18:19 I wasn't sure how to uninstall Lazarus from my iMac without any remaining traces, so installed version 0.9.26 on my Macbook: this doesn't solve any of the issues apart from the source editor window that now displays correctly. So still: - two icons in the dock - no space permitted in the path to a project - 'unknown stabs' errors Also, sometimes the Lazarus menu bar isn't correctly displayed when switching the app in or out. Another problem present in 0.9.27 is that you have to draw a rectangle when creating a new object, in .26 a simple click is enough. But those aren't showstoppers for me, I have converted all my (admittedly simple) Delphi projects over to Lazarus. Speed is also great (I remember always having a drink while launching previous versions of Lazarus ) ---------------------------------------------------------------------- Phil · 2009-02-05 18:47 There's an uninstall.sh script in your Lazarus folder that you can run to uninstall Laz. It only has to remove 4 things so you could do these things separately. Please log the source editor window as a bug since that appears to be a regression from 0.9.26. And also log the issue with needing to draw a rectangle when adding a component to a form (assume that's what you mean by "object"). As for your other problems: - I'm not at my Mac right now but I'll test to see if I can reproduce the spaces-in-path issue. - Not sure what you mean by two icons on the Dock. Did you drag the lazarus.app to the Dock? When you click this, the arrow indicating that it's loaded should appear with this icon rather than another one being added to the Dock. - I've never seen "unknown stabs" error or issues with the menu bar. If you can figure out a way to reliably reproduce these problems with 0.9.26 I'll test it out. Thanks. -Phil ---------------------------------------------------------------------- Carbonide · 2009-02-05 20:26 Sorry, didn't see the uninstall script. Worked fine but I still couldn't install v.26 until I also deleted the receipt files in the Library folder (the Installer app complained there was still a newer version already installed). Something seems foobared on my iMac, as I'm now getting the source code editor bug in version .26, too This is what I meant by two icons in the Dock (notice they both are running apps; I simply double-clicked an .lpr file): ---------------------------------------------------------------------- Carbonide · 2009-02-05 20:32 Another small bug: a menu icon is displayed over all my labels left side ---------------------------------------------------------------------- Phil · 2009-02-05 20:40 Check the Activity Monitor to see if two instances of Lazarus are actually running. Thanks. -Phil ---------------------------------------------------------------------- Carbonide · 2009-02-05 21:12 One item in the dock is 'Lazarus', the other 'lazarus' (note the lowercase 'l'). Activity monitor displays to apps, one bizarrely as non responding although Lazarus works just fine. ---------------------------------------------------------------------- Vincent Snijders · 2009-02-05 21:31 One might be startlazarus, the other lazarus? ---------------------------------------------------------------------- Phil · 2009-02-05 21:39 The Lazarus .app bundle's bundle name is "Lazarus". That should be what you see on the Dock. The name of the actual executable file is "lazarus". It is possible to run the executable itself, which is actually outside of the bundle to make rebuilding easier and just symlinked to from within the bundle. But the executable itself won't run correctly by itself. Did you double-click the executable or drag it to the Dock rather than the .app bundle? Thanks. -Phil ---------------------------------------------------------------------- Carbonide · 2009-02-05 22:07 Actually, I double clicked the .lpr (or .lpi) file. I now started Lazarus itself by double clicking on it -> only one instance running I then double clicked a project file -> now I have 3 instances in my dock  I did not put Lazarus in my dock permanently. Another thing, I sometimes get the 'Execution stopped' message when I'm actually launching my app. ---------------------------------------------------------------------- Phil · 2009-02-06 03:30 Okay, you're on to some new bugs: (1) If the path to a project has a space, running the project in the IDE causes a crash with this type of message in the Console app: [Debugger] Running GDB version: Apple version gdb-573 [tdebugger.SetFileName] "/Users/phil/LazTests/spaces in name/project1.app" [TMainIDE.DoRunProject] B TGDBMIDebugger TGDBMIDebugger.StartDebugging WorkingDir="/Users/phil/LazTests/spaces in name/" TGDBMIDebugger.ProcessResult Error: ,msg="/Users/phil/LazTests/spaces: No such file or directory." As you can see, the debugger process appears to be choking on the first space in my project's folder name, "spaces in name". See if you're getting an similar Console message. If so, could you log a bug report? You can look at the code in lazarus/debugger/gdbmidebugger.pp - I looked there but didn't see anything offhand. Maybe they just need to put quotes around the path name somewhere. Also, I'm seeing the same unit1.lrs file created in my root folder when this happens. Note that compiling and linking the project with lazbuild and running the app from Finder works fine so the space bug is probably confined to the debugging . (2) I can't get two instances of either Lazarus or my apps to appear on the Dock, no matter what I do, so this is something that's apparently specific to your system. I'm running 10.4 - are you running 10.5, maybe? If you can reproduce this, please log a bug report. (3) For some reason, when I double click an .lpi or .lpr file, Lazarus doesn't start. However, double-clicking files for my app launches the app fine, so I'm not sure what the problem is. Both Lazarus and my app register the extension the same way in their info.plist files... (4) Running startlazarus does start Lazarus momentarily, then it shuts down and I see this message in the Console app: RegisterProcess failed (error = -2805) Another bug apparently. Are you able to double-click the startlazarus.app? (5) Google "free pascal lazarus unknown stabs" and you'll get lots of hits. Maybe you can get some ideas there. One thing that occurred to me while looking through these is: Do you have the correct architecture installed? Intel Macs can run the PowerPC versions of Lazarus, but you really want to be running the Intel version. This mixup has happened to others... Thanks. -Phil ---------------------------------------------------------------------- Vincent Snijders · 2009-02-06 09:44 Bug 4 already has been reported (and might be fixed). Bug 1 is related to http://bugs.freepascal.org/view.php?id=9964 and simply not yet implemented. ---------------------------------------------------------------------- Marc · 2009-02-06 09:47 I doubt that bug 1 is the same. For the debugger I use a gdb-mi call to set the name of the exe. It is up to gdb how to parse it, but I (maybe wrong) assumed that when setting a name it will use that name. ---------------------------------------------------------------------- Vincent Snijders · 2009-02-06 09:49 Not the same, but related. If compiling with spaces doesn't even work, how would debugging with spaces work. ---------------------------------------------------------------------- Carbonide · 2009-02-06 12:45 Compiling with spaces in the path works for me, debugging with spaces does not. Also, I only get the double icon in the dock on my iMac and not on my Macbook. Coincidentally, the source code editor bug is also only present on the iMac, so I guess there's something wrong with that machine, although it seems rather bizarre that it is only affecting those two functions. Apart from the iMac being Core 2 Duo based and the Macbook being a Core Duo machine, they both run Mac OS X 10.5.6 and are very similarly configured. ---------------------------------------------------------------------- Phil · 2009-02-06 15:57 When you run from within the IDE, that invokes the debugger. That's the part that I think is broken. Debugging externally works fine with spaces in the path, e.g., gdb "/Users/phil/laztests/spaces in name/project1.app" See if something like that works for you. Not sure what to suggest about the differences in two similarly configured Macs. That's kind of troubling. Do you see any anomalies like this with other software? For example, can you get double icons on the Dock with other apps or is it just Lazarus? Thanks. -Phil ---------------------------------------------------------------------- Jonas Maebe · 2009-02-07 15:11 Quote from: Carbonide on February 05, 2009, 04:05:20 pm- lots of 'unknown stabs type 0xE0 in...' error messages while compilation is running, although it succeeds in the end nevertheless This is caused by an error in the Xcode 3.x linker. You can solve it by switching from stabs to dwarf debug information. ---------------------------------------------------------------------- Carbonide · 2009-02-07 18:25 Well, I really don't care as long as my app runs, or is there any downside to these messages? Using gdb manually works fine, btw. ---------------------------------------------------------------------- Phil · 2009-02-08 13:29 Quote from: jmaebe on February 07, 2009, 04:11:39 pmThis is caused by an error in the Xcode 3.x linker. You can solve it by switching from stabs to dwarf debug information. Jonas, Could you share with us how to do that in the Lazarus IDE? Thanks. -Phil ---------------------------------------------------------------------- Jonas Maebe · 2009-02-10 21:27 Quote from: Carbonide on February 07, 2009, 07:25:34 pmWell, I really don't care as long as my app runs, or is there any downside to these messages? Using gdb manually works fine, btw. The downside is that single stepping in gdb will fail in procedures/functions with local constants. ---------------------------------------------------------------------- Jonas Maebe · 2009-02-10 21:30 Quote from: Phil on February 08, 2009, 02:29:22 pmQuote from: jmaebe on February 07, 2009, 04:11:39 pmThis is caused by an error in the Xcode 3.x linker. You can solve it by switching from stabs to dwarf debug information. Could you share with us how to do that in the Lazarus IDE? I have no idea how to do that in Lazarus. The compiler option is -gw2, so you can probably add that to some custom compiler options setting. When using Xcode 3.x (i.e., on Mac OS X 10.5.x), you best also add -godwarfsets at the same time, otherwise sets won't have proper debugging information. That option will however completely break debugging with the gdb shipped with Xcode 2.x (which is why it's not enabled by default). On Mac OS X 10.4.x, I would therefore recommend to stay with stabs debugging information (especially since that linker bug is specific to Xcode 3.x).