llvm-config should not produce "-DNDEBUG" in CXXFLAGS

Bug #666753 reported by Sameer D. Sahasrabuddhe
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
llvm (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: llvm

Description: Ubuntu 10.04.1 LTS
Release: 10.04
llvm:
  Installed: 2.7-0ubuntu1
  Candidate: 2.7-0ubuntu1

Run llvm-config with the most basic parameters like so:

$ /usr/bin/llvm-config --cxxflags

-DNDEBUG -D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -O2 -fomit-frame-pointer -g -fno-exceptions -fPIC -Woverloaded-virtual

Notice that the flags define NDEBUG, which disables all the assertions in the user code. There does not seem to be any particular reason for this behaviour, since the user is probably trying to compile their own (possibly experimental) source code along with the system-provided llvm libraries.

Other flags in the output string such as "-O2 and -g" also should be reconsidered. Why are they forced on the user here?

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.