Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • T Trilinos
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 936
    • Issues 936
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 22
    • Merge requests 22
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • James Willenbring
  • Trilinos
  • Issues
  • #87

Closed
Open
Created Jan 20, 2016 by James Willenbring@jmwilleMaintainer

Address handling of CMAKE_BUILD_TYPE, -O0 for debug builds, etc.

Created by: bartlettroscoe

It seems there is some confusion/unhappiness with the way that Trilinos (through TriBITS) is dealing with CMAKE_BUILD_TYPE and the insertion or not of -O0 for "Debug" (or "DEBUG") builds.

For the way the CMake and TriBITS manipulates compiler flags, see "Selecting compiler and linker options" in the Trilinos Build Reference.

On one hand, we want TriBITS (and therefore Trilinos) to keep with raw CMake behavior intact as much as possible (so that people who know CMake already will know how to work with Trilinos), but that would mean that -O0 would not show up in "Debug" builds. On the other hand, we should override default raw CMake behavior when raw CMake behavior it is actually counter-intuitive (in which case you would add -O0 to "Debug" builds). But then that gets TriBITS into the business of knowing how to set compiler flags for all compilers and on platforms. Do we want to step on the CMake's communities ties like this? Do we really want to own this?

This Issue Ticket is to log the discussion of this topic and potentially come up with some action to address this in a way that makes people (by some definition) happy.

Tasks:

  1. Add -DNDEBUG to C and C++ RELEASE compiler flags by default for GCC (see below) [Done]
  2. Add -O0 to C, C++, and Fortran debug flags for Intel builds ...
Assignee
Assign to
Time tracking