3 # Common makefile settings for wxGTK programs. You have to set
4 # the WXDIR variable before including this file.
6 # This file is included by all the other makefiles, thus changes
7 # made here take effect everywhere (except where overriden).
12 ########################### General #################################
14 # The name of the GUI used in directory paths and library names
17 # The library version number
24 ########################### Programs #################################
32 # Compiler for lex/yacc .c programs
37 # Note: if using bison, use -y option for yacc compatibility
43 ############################ Switches #################################
45 # Debug/trace mode. 1 or more for debugging.
47 GUI_OPT = -D__WXGTK__ -D__UNIX__
49 ########################## Compiler flags #############################
52 CPP_EXTRA = -D_REENTRANT
53 C_EXTRA = -D_REENTRANT
54 LEX_EXTRA = -D_REENTRANT
57 CPP_OPT = -O2 -fno-strength-reduce -DGTK_NO_CHECK_CASTS -fno-rtti -fno-exceptions
58 C_OPT = -O2 -fno-strength-reduce -DGTK_NO_CHECK_CASTS
59 LEX_OPT = -O2 -fno-strength-reduce
62 CPP_DEBUG = -D__WXDEBUG__ # -g
63 C_DEBUG = -D__WXDEBUG__
64 LEX_DEBUG = -D__WXDEBUG__
68 C_WARN = -Wall -Wno-unused
74 ############################ Includes #################################
76 WX_INC = -I$(WXDIR)/include
77 GUI_INC = `gtk-config --cflags`
78 EXTRA_INC = -I$(WXDIR)/src/png -I$(WXDIR)/src/jpeg -I$(WXDIR)/src/zlib -I$(WXDIR)/src/odbc
80 ############################ Libraries ################################
82 WXLIB = $(WXDIR)/lib/libwx_$(GUI).a
84 LD_LIBS = $(WXLIB) `gtk-config --libs` -L/usr/lib -ldl -lpthread
86 ############################# Suffixes ################################
90 ####################### No changes below this line ####################
92 CPPFLAGS = $(GUI_OPT) $(CPP_EXTRA) $(CPP_OPT) $(CPP_DEBUG) $(CPP_WARN) $(WX_INC) $(EXTRA_INC) $(GUI_INC)
93 CFLAGS = $(GUI_OPT) $(C_EXTRA) $(C_OPT) $(C_DEBUG) $(C_WARN) $(WX_INC) $(EXTRA_INC) $(GUI_INC)
94 LDFLAGS = $(LD_EXTRA) $(LD_LIBS)
96 # Clears all default suffixes
100 $(CCC) -c $(CFLAGS) -o $@ $<
103 $(CC) -c $(CPPFLAGS) -o $@ $<
106 $(CC) -c $(CPPFLAGS) -o $@ $<