possible to enable debug symbols by default?

Ryan Schmidt ryandesign at macports.org
Fri Jun 1 02:40:33 UTC 2018

On May 31, 2018, at 21:10, Eitan Adler wrote:
> On Thursday, 31 May 2018, Ken Cunningham wrote:
>> Well, to do that, you would have to change the default configure.optflags in portconfigure.tcl
>> open 
>> /opt/local/libexec/macports/lib/port1.0/portconfigure.tcl
>> and change 
>> default configure.optflags      {-Os}
>> to something like
>> default configure.optflags      {"-O0 -g"}
>> perhaps, or whatever works for you.

> Would it be reasonable to add a supported option to add -g to C flags without changing other things? Even with optimizations having some symbols are better than nothing. 

What are you asking for?

A command that can be inserted into a Portfile to automatically add -g to configure.optflags for that port? That would be no easier than what Ken suggested.

Or: A setting in macports.conf that makes MacPorts base add -g for all ports? That would cause the built result to be different. We could offer that, but would have to also make sure that MacPorts doesn't attempt to download any binaries from our packages servers, since they would not have been built with that setting.

More information about the macports-users mailing list