[MacPorts] #41256: pg cmake: portgroup's debug variant sets release optflags (was: cmake portgroup's debug variant sets release optflags)

MacPorts noreply at macports.org
Sun May 7 16:53:51 UTC 2023


#41256: pg cmake: portgroup's debug variant sets release optflags
--------------------------+-----------------------
  Reporter:  florian@…    |      Owner:  mascguy
      Type:  enhancement  |     Status:  assigned
  Priority:  Normal       |  Milestone:
 Component:  ports        |    Version:
Resolution:               |   Keywords:  portgroup
      Port:  pg-cmake     |
--------------------------+-----------------------
Changes (by mascguy):

 * owner:  macports-tickets@… => mascguy
 * status:  new => assigned
 * port:   => pg-cmake


Comment:

 Since I've started to litter CMake-based ports with logic like that
 mentioned in the description, it makes sense that I add this to my plate.

 Specifically, this is what some of our ports are doing - or with slight
 variations - and that should arguably be handled by the CMake pgs:

 {{{
 if {[variant_isset debug]} {
     cmake.build_type    Debug
     configure.optflags  -O0
 } else {
     cmake.build_type    RelWithDebInfo

     # Clear optflags for non-debug build; controlled by project
     configure.optflags
 }
 }}}

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


More information about the macports-tickets mailing list