4 # Common makefile settings for wxWindows programs
5 # This file is included by all the other makefiles, thus changes
6 # made here take effect everywhere (except where overriden).
8 ########################### Programs #################################
10 # Replace this with your own path if necessary
11 WXDIR = /home/mon/src/wx20
14 CC = CC -n32 -D__SGI__ -D__SGI_CC__
17 CCC = cc -n32 -Xcpluscomm -D__SGI__ -D__SGI_CC__
19 # Compiler for lex/yacc .c programs
26 RANLIB = echo ranlib not required on SGI
28 ############################ Switches #################################
30 # Debug/trace mode. 1 or more for debugging.
32 GUI = -D__WXSTUBS__ -D__UNIX__
35 ########################## Compiler flags #############################
38 OPTIONS = -D__WXDEBUG__ # -DDEBUG='$(DEBUG)' # -DWXDEBUG
46 ############################ Includes #################################
48 # Compiler or system-specific include paths
50 XINCLUDE = -I/usr/include/X11 -I/usr/include/Xm \
51 -I/usr/include/X11/Xm -I/usr/include
52 XLIB = -L/usr/local/X11/lib -L/usr/X11/lib -L/usr/X11R6/lib
54 ############################ Libraries ################################
57 GUILDLIBS = -lwx_stubs $(COMPLIBS) -lXm -lXmu -lXt -lXpm -lX11 -lm
59 ############################# Suffixes ################################
61 # Change cpp to c if you want to use main.c instead of main.cpp.
62 # Edit wx_setup.h accordingly (USE_C_MAIN=1)
68 ####################### No changes below this line ####################
70 WXINC = $(WXDIR)/include
71 WXLIB = $(WXDIR)/lib/libwx$(GUISUFFIX).a
72 INC = -I$(WXINC) -I$(WXDIR)/src/png -I$(WXDIR)/src/zlib $(COMPPATHS)
74 # Directory for object files
75 OBJDIR = objects$(GUISUFFIX)
77 CPPFLAGS = $(EXTRACPPFLAGS) $(XINCLUDE) $(INC) $(OPTIONS) $(GUI) $(DEBUGFLAGS) $(WARN) $(OPT)
78 CFLAGS = $(EXTRACFLAGS) $(XINCLUDE) $(INC) $(COPTIONS) $(GUI) $(DEBUGFLAGS) $(CWARN) $(OPT)
79 LDFLAGS = $(EXTRALDFLAGS) $(XLIB) -L$(WXDIR)/lib
80 LDLIBS = $(EXTRALDLIBS) $(GUILDLIBS)
82 # Clears all default suffixes
86 $(CCC) -c $(CFLAGS) -o $@ $<
89 $(CC) -c $(CPPFLAGS) -o $@ $<
92 $(CC) -c $(CPPFLAGS) -o $@ $<
94 ####################### Targets to allow multiple GUIs ####################
97 echo Use a target: one of motif, stubs
100 make -f makefile.unx all GUI='-D__WXSTUBS__ -D__LINUX__ -D__UNIX__' GUISUFFIX='_stubs' GUILDLIBS='-lwx_stubs $(COMPLIBS) -lXm -lXmu -lXt -lX11 -lm'
103 make -f makefile.unx all GUI='-D__WXMOTIF__ -D__UNIX__' GUISUFFIX='_motif' GUILDLIBS='-lwx_motif $(COMPLIBS) -lXm -lXmu -lXt -lXpm -lX11 -lm'
106 make -f makefile.unx all GUI='-D__WXGTK__ -D__LINUX__ -D__UNIX__' GUISUFFIX='_gtk' GUILDLIBS='-lwx_gtk $(COMPLIBS) -lXm -lXmu -lXpm -lX11 -lm'
109 make -f makefile.unx clean GUI='-D__WXSTUBS__ -D__LINUX__ -D__UNIX__' GUISUFFIX='_stubs' GUILDLIBS='-lwx_stubs $(COMPLIBS) -lXm -lXmu -lXt -lX11 -lm'
112 make -f makefile.unx clean GUI='-D__WXMOTIF__ -D__LINUX__ -D__UNIX__' GUISUFFIX='_motif' GUILDLIBS='-lwx_motif $(COMPLIBS) -lXm -lXmu -lXt -lX11 -lm'