patchGNU Autoconf Archive - Patches: patch #9226, ax_check_enable_debug.m4 and...

 
 

patch #9226: ax_check_enable_debug.m4 and ax_code_coverage.m4 both define NDEBUG

Submitter:  None
Submitted:  Tue 17 Jan 2017 12:30:18 PM UTC
   
 
Priority:  5 - Normal Status:  Done
Assigned to:  None Originator Email:  -email is unavailable-
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Sun 12 Feb 2017 03:33:38 PM UTC, comment #4: 
Emanuele Aina <emanueleaina>
Sun 05 Feb 2017 10:56:38 PM UTC, comment #3: 

Thanks for the suggestion! Indeed #defining NDEBUG to 1 with the attached patch is working just fine.

Emanuele Aina <emanueleaina>
Tue 17 Jan 2017 04:04:59 PM UTC, comment #2: 

If they both defined NDEBUG to the same value (after normalizing whitespace and removing comments), a standards-compliant compiler would accept it. The problem is that -DNDEBUG is equivalent to "#define NDEBUG 1", which is not the same as "#define NDEBUG". Using AC_DEFINE([NDEBUG], [1]) would probably address this.

Anonymous
Tue 17 Jan 2017 12:37:16 PM UTC, comment #1: 

If you (or someone else) could suggest a patch to remedy that issue, that would be very much appreciated.

Peter Simons <simons>
Group administrator
Tue 17 Jan 2017 12:30:18 PM UTC, original submission:  

Both ax_check_enable_debug.m4 and ax_code_coverage.m4 define NDEBUG, which leads to a warning.

If ax_compiler_flags.m4 is also used, -Werror is the default and it leads to the following build failure:

  ./config.h:38:0: error: "NDEBUG" redefined [-Werror]

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #39676:  0001-AX_CHECK_ENABLE_DEBUG-Do-not-conflict-with-DNDEBUG.patch added by emanueleaina (2KiB - text/x-patch - Patch to #define NDEBUG 1 to avoid conflicting with -DNDEBUG)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by emanueleaina (Updated the item)
  • -email is unavailable- added by simons (Posted a comment)
  • -email is unavailable- added by simons (Macros Authors)
  • -email is unavailable- added by simons (Macros Authors)
  • -email is unavailable- added by None (Submitted the item)
  •  

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-02-12 simons StatusNeed Info Done
        Open/ClosedOpen Closed
    2017-02-05 emanueleaina Attached File- Added 0001-AX_CHECK_ENABLE_DEBUG-Do-not-conflict-with-DNDEBUG.patch, #39676
    2017-01-17 simons StatusNone Need Info
        Carbon-Copy- Added rhys ulerich <rhys.ulerich@gmail.com>
        Carbon-Copy- Added philip withnall <philip@tecnocode.co.uk>

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code