Compiling for test

Gnucap has two different modes for compiling.

  1. For regular users, only default compile options are used, for minimum clutter during compiling, so real problems will stand out.
  2. For developers, additional warnings are enabled, to catch minor issues that may lead to errors. For code to be accepted into the main distribution (not plugins that are distributed separately) it must compile without warnings, with most compiler warnings enabled.

For g++, the following compile options are used to enable additional warnings.

  -DUNIX  -g -O0 -I. -I../../include -DTRACE_UNTESTED \
  -Wall -Wextra \
  -Wswitch-enum -Wundef -Wpointer-arith -Woverloaded-virtual \
  -Wcast-qual -Wcast-align -Wpacked -Wshadow -Wconversion \
  -Winit-self -Wmissing-include-dirs -Winvalid-pch \
  -Wvolatile-register-var -Wstack-protector \
  -Wlogical-op -Wvla -Woverlength-strings -Wsign-conversion
gnucap/manual/tech/compiling.txt · Last modified: 2015/12/11 15:39 (external edit)
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Run by Debian Driven by DokuWiki