[MacPorts] #65743: cherrytree @0.99.48: crash on launch

MacPorts noreply at macports.org
Fri Sep 16 22:28:16 UTC 2022


#65743: cherrytree @0.99.48: crash on launch
-------------------------+----------------------
  Reporter:  afield1235  |      Owner:  mascguy
      Type:  defect      |     Status:  assigned
  Priority:  Normal      |  Milestone:
 Component:  ports       |    Version:  2.7.2
Resolution:              |   Keywords:
      Port:  cherrytree  |
-------------------------+----------------------

Comment (by afield1235):

 Replying to [comment:30 kencu]:
 >
 > To do that you edit the cherrytree Portfile:
 >
 > {{{bbedit `port file cherrytree`}}} and add a line like this:
 >
 > {{{
 > configure.optflags -g
 > }}}
 >
 > right under {{{compiler.cxx_standard   2017}}} so it looks like this:
 >
 > {{{
 > compiler.cxx_standard   2017
 > configure.optflags -g
 > patchfiles-append       patch-cherrytree-all-apple-is-not-homebrew-for-
 goodness-sake.diff
 > # Fix crash on launch; see: https://trac.macports.org/ticket/65743
 > patchfiles-append       patch-ct_filesystem-empty-string.diff
 > }}}
 >
 > then you build cherrytree like this:
 >
 > {{{
 > sudo port uninstall cherrytree
 > sudo port -v -s -k install cherrytree +debug
 > }}}

 I followed your instructions and was able to run Cherrytree without any
 issues **other than the segmentation fault when quitting**. I didn't even
 need to use 'lldb' debugger.

 {{{
 % cherrytree
 [2022-09-16 14:59:09.281] [gtk] [critical] Class::register_derived_type():
 base_query.type_name is NULL.
 [2022-09-16 14:59:09.311] [   ] [warning]
 /Users/user/.config/cherrytree/config.cfg missing
 [2022-09-16 14:59:09.583] [   ] [debug] autosave is started
 [2022-09-16 14:59:32.175] [   ] [debug] shift images in MenuBar/context
 menu
 zsh: segmentation fault  cherrytree
 }}}

 {{{
 % cherrytree
 [2022-09-16 15:00:12.518] [gtk] [critical] Class::register_derived_type():
 base_query.type_name is NULL.
 [2022-09-16 15:00:12.549] [   ] [debug]
 /Users/user/.config/cherrytree/config.cfg parsed
 [2022-09-16 15:00:12.813] [   ] [debug] autosave is started
 }}}


 I re-edited the config file and removed the 'configure.optflags -g' and
 reinstalled Cherrytree a variety of ways with no success!

 {{{
 sudo port -s install cherrytree
 sudo port -v -s -k install cherrytree
 sudo port -v -s -k install cherrytree +debug
 }}}

 It always resulted in a segmentation fault upon launch and the app not
 running.
 {{{
 [2022-09-16 15:06:43.540] [gtk] [critical] Class::register_derived_type():
 base_query.type_name is NULL.
 zsh: segmentation fault  cherrytree
 }}}

 Through process of elimination, if I simply added the 'configure.optflags
 -g' back and reinstalled Cherrytree normally, it would run again fine!

 {{{
 % sudo port install cherrytree
 }}}
 **
 TLDR: What is it about that flag that fixes it for me?**

-- 
Ticket URL: <https://trac.macports.org/ticket/65743#comment:45>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list