KiCad crashes at startup on macOS Sierra

Bug #1667759 reported by Alastair Houghton
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KiCad
Expired
Undecided
Unassigned

Bug Description

On macOS Sierra 10.12.3 (16D32), all of the KiCad programs other than "kicad" itself initially crash on startup. The problem seems to be that the other programs are embedded within kicad.app, but refer to a library in the outer bundle. That's great, but if you execute them individually before you start kicad.app, they are subjected to App Translocation and run in an isolated area of the filesystem (so they aren't able to find the dynamic library in question because they can't get to the outer Frameworks folder).

Start kicad.app appears to fix this problem - having done that, everything else is now working.

Tags: macos osx
Revision history for this message
Alastair Houghton (al45tair) wrote :

Attached crash log from pcbnew.

Revision history for this message
Chris Pavlina (pavlina-chris) wrote :

Since you can start kicad itself, could you please do so, then get the version information and paste it here? The method depends on the version unfortunately, it is:

4.0 series: Help -> Copy Version Information
pre-5.0 (nightly) series: KiCad -> About KiCad -> Copy Version Info

I don't have a 4.0 handy to test right now, but my pre-5.0 works fine.

tags: added: macos osx
Changed in kicad:
status: New → Incomplete
Revision history for this message
Alastair Houghton (al45tair) wrote :

It's the current release. Note that it will work fine if you build it, because the problem is only going to happen if you download the DMG from somewhere (I *think*, but I'm not certain, that e-mailing a DMG to yourself would also be sufficient to trigger it). FWIW, we had a similar (but not identical) problem with iDefrag; it isn't obvious that behaviour will differ depending on whether it's been downloaded or not, and it isn't something most people tend to test.

Application: kicad
Version: 4.0.5 release build
wxWidgets: Version 3.0.2 (debug,UTF-8,compiler with C++ ABI 1002,GCC 4.2.1,STL containers,compatible with 2.8)
Platform: Mac OS X (Darwin 16.4.0 x86_64), 64 bit, Little endian, wxMac
Boost version: 1.57.0
         USE_WX_GRAPHICS_CONTEXT=ON
         USE_WX_OVERLAY=ON
         KICAD_SCRIPTING=ON
         KICAD_SCRIPTING_MODULES=ON
         KICAD_SCRIPTING_WXPYTHON=ON
         USE_FP_LIB_TABLE=HARD_CODED_ON
         BUILD_GITHUB_PLUGIN=ON

Revision history for this message
Adam Wolf (adamwolf) wrote :

Are you indicating that once you run kicad.app once, the standalone apps will work later? Or that the standalone apps will never work?

If the latter, I am not able to reproduce this, even after downloading the dmg and reinstalling.

(Relatedly, I have been working on and off on getting the macOS bundle signed, and I am not 100% sure the symlink trick is compatible with macOS's signing stuff.)

Revision history for this message
Chris Pavlina (pavlina-chris) wrote :

I'm 100% in favor of dropping the standalone app approach on macOS for 5.0. It really just is not compatible with the way macOS does things. We'll need a replacement because the apps do behave differently in standalone mode, but I think that should be pretty easy to achieve.

Revision history for this message
Alastair Houghton (al45tair) wrote :

The former. The standalone apps work after the first run of the full application, I think because that's the point at which macOS strips the quarantine attribute.

As for code signing, I think you're right - the symlink thing won't work with code signing. You *can* put multiple executables into an application bundle (i.e. put the other executables all in the same bundle, in the MacOS folder), but then it might be difficult to start the standalone apps. Other joyful aspects of code signing might also be an issue for you - in particular, code signatures have changed recently and IIRC the new ones aren't compatible with older systems.

Revision history for this message
Adam Wolf (adamwolf) wrote : Re: [Bug 1667759] Re: KiCad crashes at startup on macOS Sierra

Chris, please loop me into any discussions about this, I'd love to
help. This and not copying Python into the bundle are the two things
I got stymied by when I tried to add code signing for macOS, and it
sounds like Wayne is pro-copying Python in!

On Fri, Feb 24, 2017 at 1:03 PM, Chris Pavlina <email address hidden> wrote:
> I'm 100% in favor of dropping the standalone app approach on macOS for
> 5.0. It really just is not compatible with the way macOS does things.
> We'll need a replacement because the apps do behave differently in
> standalone mode, but I think that should be pretty easy to achieve.
>
> --
> You received this bug notification because you are subscribed to KiCad.
> Matching subscriptions: OS X KiCad bugs
> https://bugs.launchpad.net/bugs/1667759
>
> Title:
> KiCad crashes at startup on macOS Sierra
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/kicad/+bug/1667759/+subscriptions

Revision history for this message
Adam Wolf (adamwolf) wrote :

Is this something we should put in the README of the nightlies? "If
you are having problems running the standalone apps, please run
Kicad.app first, and if it still has problems, please let us know."?

I'm hesitant to try to fix something I want to destroy anyway
(standalone apps on macOS), but I am also realistic about how much
time I can spend on KiCad...

On Fri, Feb 24, 2017 at 1:06 PM, Alastair Houghton
<email address hidden> wrote:
> The former. The standalone apps work after the first run of the full
> application, I think because that's the point at which macOS strips the
> quarantine attribute.
>
> As for code signing, I think you're right - the symlink thing won't work
> with code signing. You *can* put multiple executables into an
> application bundle (i.e. put the other executables all in the same
> bundle, in the MacOS folder), but then it might be difficult to start
> the standalone apps. Other joyful aspects of code signing might also be
> an issue for you - in particular, code signatures have changed recently
> and IIRC the new ones aren't compatible with older systems.
>
> --
> You received this bug notification because you are subscribed to KiCad.
> Matching subscriptions: OS X KiCad bugs
> https://bugs.launchpad.net/bugs/1667759
>
> Title:
> KiCad crashes at startup on macOS Sierra
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/kicad/+bug/1667759/+subscriptions

Revision history for this message
Wayne Stambaugh (stambaughw) wrote :

We are copying python on windows installers so I see no reason not to do
it on osx if it makes life easier for both packagers and users.

On 2/24/2017 2:17 PM, Adam Wolf wrote:
> Chris, please loop me into any discussions about this, I'd love to
> help. This and not copying Python into the bundle are the two things
> I got stymied by when I tried to add code signing for macOS, and it
> sounds like Wayne is pro-copying Python in!
>
> On Fri, Feb 24, 2017 at 1:03 PM, Chris Pavlina <email address hidden> wrote:
>> I'm 100% in favor of dropping the standalone app approach on macOS for
>> 5.0. It really just is not compatible with the way macOS does things.
>> We'll need a replacement because the apps do behave differently in
>> standalone mode, but I think that should be pretty easy to achieve.
>>
>> --
>> You received this bug notification because you are subscribed to KiCad.
>> Matching subscriptions: OS X KiCad bugs
>> https://bugs.launchpad.net/bugs/1667759
>>
>> Title:
>> KiCad crashes at startup on macOS Sierra
>>
>> To manage notifications about this bug go to:
>> https://bugs.launchpad.net/kicad/+bug/1667759/+subscriptions
>

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for KiCad because there has been no activity for 60 days.]

Changed in kicad:
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.