title: options superseded in gcc
body: <p>In a Makefile of a library I am trying to build, there are a few lines specify the options to gcc:</p>
  
  <pre><code>CFLAGS          += -I$(CURDIR) -pedantic -std=c89 -O3  
  CFLAGS          += -Wall -Wno-unused-function -Wno-long-long  
  CFLAGS          += $(if $(DEBUG), -O0 -g)  
  </code></pre>
  
  <p>If DEBUG exists, there will be both -O3 and -O0 -g in CFLAGS. But -O0 and -O3 cannot be used at the same time. Will the one specified later supersede the one earlier?</p>
  
  <p>Thanks and regards!</p>