]> git.saurik.com Git - wxWidgets.git/blame - src/makeg95.env
1. wxImageHandler::DoCanRead() introduced to solve the virtual function name
[wxWidgets.git] / src / makeg95.env
CommitLineData
2bda0e17
KB
1# makeg95.env
2# Common makefile settings for wxWindows programs
3# This file is included by all the other makefiles, thus changes
4# made here take effect everywhere (except where overriden).
f3ef286f 5# The settings are for GnuWin32-derived compilers, i.e. Cygwin and Mingw32.
2bda0e17 6#
f3ef286f
JS
7
8# If using Cygwin, set this to 0.
9# If using Mingw32, set this to 1.
10MINGW32=0
2bda0e17
KB
11
12########################## Compiler ##################################
13
14# C++ compiler
f3ef286f
JS
15# Put a comment before --pipe for Cygwin, remove comment for Mingw32 2.95
16
17ifeq ($(MINGW32),1)
b4fe5125 18CC = gcc --pipe -fvtable-thunks
f3ef286f
JS
19else
20CC = gcc
21endif
2bda0e17
KB
22
23# C compiler for pure C programs
2bda0e17
KB
24CCC = $(CC)
25
26# Compiler used for LEX generated C
8704bf74 27CCLEX=gcc
2bda0e17
KB
28
29MAKE=make
30
31# LEX
8870c26e 32LEX=flex # -t -L
2bda0e17 33
57c208c5 34# YACC. yacc or bison
2662e49e
RR
35YACC=byacc
36#YACC=bison
2bda0e17 37
57c208c5 38# Settings for Cyginw/Mingw32
2bda0e17 39RESCOMP=windres.exe
57c208c5
JS
40RCINPUTSWITCH=-i
41RCOUTPUTSWITCH=-o
42RCINCSWITCH=--include-dir
43RCDEFSWITCH=--define
2bda0e17 44
6a570331 45RESFLAGS=$(RCINCSWITCH) $(WXDIR)/include $(RCDEFSWITCH) __WIN32__ $(RCDEFSWITCH) __WIN95__ $(RCDEFSWITCH) __GNUWIN32__
2bda0e17
KB
46
47########################## Compiler flags #############################
48
49# Miscellaneous compiler options
f3ef286f 50OPTIONS= -DSTRICT # -D__MINGW32__
2bda0e17
KB
51
52# Debugging information
e4d18e7f 53DEBUGFLAGS = -D__WXDEBUG__
2bda0e17 54
2bda0e17
KB
55WIN95=1
56
57ifeq ($(WIN95),0)
58# With 3.50, Win95 will use your existing icons to show smaller ones.
59# With 4.0, you'll have to follow Win95 procedures for icons or you'll get the
60# default Windows icon.
61APPVER=3.50
62WINVERSION=-DWINVER=0x0350 -D__GNUWIN32__ -D__WIN32__ # Generic WIN32
63else
64APPVER=3.50 # 4.0
65# This means 'enable Windows 95 features' (in wxWindows and in VC++ 4.0).
66WINVERSION=-DWINVER=0x0400 -D__WIN95__ -D__GNUWIN32__ -D__WIN32__
67endif
68
69CPU=i386
70
71# Suffixes
72OBJSUFF=o
73SRCSUFF=cpp
74LIBPREFIX=lib
75LIBSUFF=a
76EXESUFF=.exe
77RESSUFF=res
78RSCSUFF=rsc
79
80# Warnings
2bda0e17
KB
81WARN = -Wall
82
2bda0e17 83# Which GUI, -Dwx_xview or -Dwx_motif (don't change this)
34138703 84GUI = -D__WXMSW__ -D__WINDOWS__
2bda0e17 85
881eba2c
GRG
86# according to Guillermo Rodriguez Garcia <guille@iies.es> this flag is
87# needed to make the standard div() function work - otherwise it returns
88# absolutely incorrect results and completely breaks the wxImage class
89# (where it's used extensively)
90# GRG: at least it is needed in mingw32-gcc2.8.1
e4d18e7f 91OPT = -fno-pcc-struct-return -O2 -fno-rtti -fno-exceptions
2bda0e17
KB
92
93# Options for ar archiver
94# AROPTIONS = crs # For IRIX and Solaris (both SYSVR4).
95AROPTIONS = ruv
96RANLIB = ranlib
2bda0e17 97
b4fe5125
JS
98# Extra compiler libraries
99COMPLIBS=
2bda0e17
KB
100
101# Compiler or system-specific include paths
48d1144b 102COMPPATHS=
2bda0e17 103
2bda0e17
KB
104########################## Directories ###############################
105
2bda0e17 106WINLIBS=-lstdc++ -lgcc \
8870c26e 107 -lwinspool -lwinmm -lshell32 \
b4fe5125
JS
108 -lcomctl32 -lctl3d32 -lodbc32 -ladvapi32 \
109 -lole32 -loleaut32 -luuid \
110 -lodbc32 -lwsock32# -loldnames
111
112#WINLIBS=-lstdc++ -lgcc \
113# -lwinspool -lwinmm -lshell32 \
114# -lcomctl32 -lctl3d32 -lodbc32 -ladvapi32 -lwsock32 # -loldnames
2bda0e17
KB
115
116# Shouldn't need to change these...
6a570331
RR
117WXSRC=$(WXDIR)/src/msw
118WXINC=$(WXDIR)/include
119WXBASESRC=$(WXDIR)/src/common
120WXLIB=$(WXDIR)/lib/$(LIBPREFIX)wx.$(LIBSUFF)
f3ef286f
JS
121
122ifeq ($(MINGW32),1)
123INC = -I$(WXINC) -I$(WXDIR)/src/png -I$(WXDIR)/src/jpeg -I$(WXDIR)/src/zlib $(EXTRAINC) $(COMPPATHS)
124else
125INC = -I$(WXINC) -I$(WXDIR)/src/png -I$(WXDIR)/src/jpeg -I$(WXDIR)/src/zlib $(EXTRAINC) $(COMPPATHS) -I$(WXDIR)/include/wx/msw/gnuwin32
126endif
127
6a570331 128RCLFLAGS=-cpp "cpp -lang-c++ -DWIN32 -D_WIN32 -DRCL_INVOKED -I$(WXWIN)/include"
2bda0e17 129
dbda9e86 130LIBS = $(WXLIB) $(WINLIBS) $(COMPLIBS) $(EXTRALIBS)
2bda0e17
KB
131
132WINFLAGS=-D_X86_=1 -DWIN32 -D_WIN32 $(WINVERSION)
133
134#for windows 95
135XINCLUDE=$(WINFLAGS)
136XLIB=$(LIBS)
137LDLIBS = $(LIBS)
138
139# Directory for object files (don't change)
dbda9e86 140# OBJDIR = objects$(GUISUFFIX)
881eba2c 141OBJDIR = .
2bda0e17
KB
142
143# You shouldn't need to change these...
dbda9e86
JS
144CPPFLAGS = $(XINCLUDE) $(INC) $(OPTIONS) $(GUI) $(DEBUGFLAGS) $(WARN) $(OPT) $(EXTRACPPFLAGS)
145CFLAGS = $(XINCLUDE) $(INC) $(OPTIONS) $(GUI) $(DEBUGFLAGS) $(WARN) $(OPT) $(EXTRACFLAGS)
57c208c5 146WINDOWSLDFLAGS=-Wl,--subsystem,windows -mwindows
dbda9e86 147LDFLAGS = $(WINDOWSLDFLAGS) -L$(WXDIR)/lib $(EXTRALDFLAGS)
2bda0e17 148
2bda0e17
KB
149.SUFFIXES: .rc .$(RESSUFF) .$(RSCSUFF) .cpp .c
150
2bda0e17
KB
151.$(SRCSUFF).$(OBJSUFF):
152 $(CC) -c $(CPPFLAGS) -o $@ $*.$(SRCSUFF)
153
154.c.o:
155 $(CC) -c $(CPPFLAGS) -o $@ $*.c
156
157