summaryrefslogtreecommitdiff
blob: 3becef9ae9eb2f66e791ccd0355519beea9c619e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
--- Makefile.orig	2013-05-28 17:58:03.379228527 -0400
+++ Makefile	2013-05-28 17:58:24.768491369 -0400
@@ -88,8 +88,6 @@
       endif
     endif
   endif
-else
-  CFLAGS += -O
 endif
 
 ifdef DEBUG
@@ -108,6 +106,7 @@
   endif
 else
   CFLAGS += -DNDEBUG
+  CXXFLAGS += -DNDEBUG
 endif
 
 ifneq ($(PROFILE),)
@@ -120,6 +119,7 @@
 
 ifneq  ($(MULTI_THREAD),)
   CFLAGS += -DMULTI_THREAD=$(MULTI_THREAD)
+  CXXFLAGS += -DMULTI_THREAD=$(MULTI_THREAD)
   ifneq  ($(MULTI_THREAD),1)
     ifeq ($(OSTYPE),mingw)
 #use lpthreadGC2d for debug alternatively
@@ -134,10 +134,12 @@
   REV = $(shell svnversion)
   ifneq ($(REV),)
     CFLAGS  += -DREVISION="$(REV)"
+    CXXFLAGS  += -DREVISION="$(REV)"
   endif
 endif
 
 CFLAGS   += -Wall -W -Wcast-qual -Wpointer-arith -Wcast-align $(FLAGS)
+CXXFLAGS   += -Wall -W -Wcast-qual -Wpointer-arith -Wcast-align $(FLAGS)
 CCFLAGS  += -Wstrict-prototypes
 
 
@@ -456,6 +458,7 @@
 ifeq ($(BACKEND),sdl)
   SOURCES += simsys_s.cc
   CFLAGS  += -DUSE_16BIT_DIB
+  CXXFLAGS  += -DUSE_16BIT_DIB
   ifeq ($(OSTYPE),mac)
     # Core Audio (Quicktime) base sound system routines
     SOURCES += sound/core-audio_sound.mm
@@ -488,6 +491,7 @@
     endif
   endif
   CFLAGS += $(SDL_CFLAGS)
+  CXXFLAGS += $(SDL_CFLAGS)
   LIBS   += $(SDL_LDFLAGS)
 endif
 
@@ -497,6 +501,7 @@
   SOURCES += sound/sdl_mixer_sound.cc
   SOURCES += music/sdl_midi.cc
   CFLAGS  += -DUSE_16BIT_DIB
+  CXXFLAGS  += -DUSE_16BIT_DIB
   ifeq ($(SDL_CONFIG),)
     SDL_CFLAGS  := -I$(MINGDIR)/include/SDL -Dmain=SDL_main
     SDL_LDFLAGS := -lmingw32 -lSDLmain -lSDL
@@ -511,6 +516,7 @@
     endif
   endif
   CFLAGS += $(SDL_CFLAGS)
+  CXXFLAGS += $(SDL_CFLAGS)
   LIBS   += $(SDL_LDFLAGS) -lSDL_mixer
 endif
 
@@ -544,6 +550,7 @@
     endif
   endif
   CFLAGS += $(SDL_CFLAGS)
+  CXXFLAGS += $(SDL_CFLAGS)
   LIBS   += $(SDL_LDFLAGS) -lglew32
   ifeq ($(OSTYPE),mingw)
     LIBS += -lopengl32
@@ -559,6 +566,7 @@
 endif
 
 CFLAGS += -DCOLOUR_DEPTH=$(COLOUR_DEPTH)
+CXXFLAGS += -DCOLOUR_DEPTH=$(COLOUR_DEPTH)
 
 ifneq ($(findstring $(OSTYPE), cygwin mingw),)
   SOURCES += simres.rc
@@ -566,7 +574,6 @@
 endif
 
 CCFLAGS  += $(CFLAGS)
-CXXFLAGS += $(CFLAGS)
 
 BUILDDIR ?= build/$(CFG)
 PROGDIR  ?= $(BUILDDIR)