]> git.sesse.net Git - vlc/blob - Makefile.opts.in
* on win32 the rc plugin opens a new console.
[vlc] / Makefile.opts.in
1 ###############################################################################
2 # vlc (VideoLAN Client) options Makefile
3 # (c)1998 VideoLAN
4 ###############################################################################
5
6 HAVE_MAKEFILE_OPTS = 1
7
8 ###############################################################################
9 # Configuration
10 ###############################################################################
11
12
13 # Plugins to build
14 # WARNING: if you do not have a dynamic loader on your platform, remove
15 # the plugins in this line and put them as built-ins, otherwise your
16 # application won't be able to load them.
17
18 PLUGINS :=@PLUGINS@
19
20
21 # Built-in modules to build
22 # WARNING: do NOT put gtk and gnome together in this rule.
23
24 BUILTINS :=@BUILTINS@
25
26
27 # Additional build options
28
29 SYS = @SYS@
30 ALIASES =@ALIASES@
31 INSTALL = @INSTALL@
32 ARCH = @ARCH@
33
34 #
35 # Compilation options
36 #
37 DEBUG = @DEBUG@
38 CPROF = @CPROF@
39 GPROF = @GPROF@
40 OPTIMS = @OPTIMS@
41 TUNING = @TUNING@
42 RELEASE = @RELEASE@
43
44
45 # Build environment
46
47 CC = @CC@
48 CFLAGS = @CFLAGS@
49 SHELL = @SHELL@
50 RANLIB = @RANLIB@
51 STRIP = @STRIP@
52 MOC = @MOC@
53 WINDRES = @WINDRES@
54 BCBUILDER = @BCBUILDER@
55
56
57 # Installation environment
58
59 exec_prefix = @exec_prefix@
60 prefix = @prefix@
61 bindir = @bindir@
62 datadir = @datadir@
63 libdir = @libdir@
64 includedir = @includedir@
65
66 #
67 # CFLAGS for special cases
68 #
69 vlc_CFLAGS = @vlc_CFLAGS@
70 plugins_CFLAGS := @plugins_CFLAGS@
71 builtins_CFLAGS := @builtins_CFLAGS@
72
73 a52_CFLAGS = @a52_CFLAGS@
74 arts_CFLAGS = @arts_CFLAGS@
75 dvd_CFLAGS = @dvd_CFLAGS@
76 dvdread_CFLAGS = @dvdread_CFLAGS@
77 mpeg_ts_dvbpsi_CFLAGS = @mpeg_ts_dvbpsi_CFLAGS@
78 directx_CFLAGS = @directx_CFLAGS@
79 esd_CFLAGS = @esd_CFLAGS@
80 ffmpeg_CFLAGS = @ffmpeg_CFLAGS@
81 glide_CFLAGS = @glide_CFLAGS@
82 gnome_CFLAGS = @gnome_CFLAGS@
83 gtk_CFLAGS = @gtk_CFLAGS@
84 kde_CFLAGS = @kde_CFLAGS@
85 idctaltivec_CFLAGS = @idctaltivec_CFLAGS@
86 mad_CFLAGS = @mad_CFLAGS@
87 memcpyaltivec_CFLAGS = @memcpyaltivec_CFLAGS@
88 motionaltivec_CFLAGS = @motionaltivec_CFLAGS@
89 qt_CFLAGS = @qt_CFLAGS@
90 sdl_CFLAGS = @sdl_CFLAGS@
91 x11_CFLAGS = @x11_CFLAGS@
92 xvideo_CFLAGS = @xvideo_CFLAGS@
93
94 #
95 # Libraries for special cases
96 #
97 vlc_LDFLAGS = @vlc_LDFLAGS@
98 plugins_LDFLAGS += @plugins_LDFLAGS@
99 builtins_LDFLAGS += @builtins_LDFLAGS@
100
101 a52_LDFLAGS = @a52_LDFLAGS@
102 aa_LDFLAGS = @aa_LDFLAGS@
103 alsa_LDFLAGS = @alsa_LDFLAGS@
104 arts_LDFLAGS = @arts_LDFLAGS@
105 beos_LDFLAGS = @beos_LDFLAGS@
106 chroma_i420_rgb_LDFLAGS = @chroma_i420_rgb_LDFLAGS@
107 directx_LDFLAGS = @directx_LDFLAGS@
108 dsp_LDFLAGS = @dsp_LDFLAGS@
109 dvd_LDFLAGS = @dvd_LDFLAGS@
110 dvdread_LDFLAGS = @dvdread_LDFLAGS@
111 mpeg_ts_dvbpsi_LDFLAGS = @mpeg_ts_dvbpsi_LDFLAGS@
112 esd_LDFLAGS = @esd_LDFLAGS@
113 filter_distort_LDFLAGS = @filter_distort_LDFLAGS@
114 ffmpeg_LDFLAGS = @ffmpeg_LDFLAGS@
115 ggi_LDFLAGS = @ggi_LDFLAGS@
116 glide_LDFLAGS = @glide_LDFLAGS@
117 gnome_LDFLAGS = @gnome_LDFLAGS@
118 gtk_LDFLAGS = @gtk_LDFLAGS@
119 idctaltivec_LDFLAGS = @idctaltivec_LDFLAGS@
120 imdct_LDFLAGS = @imdct_LDFLAGS@
121 imdct3dn_LDFLAGS = @imdct3dn_LDFLAGS@
122 imdctsse_LDFLAGS = @imdctsse_LDFLAGS@
123 ipv4_LDFLAGS = @ipv4_LDFLAGS@
124 kde_LDFLAGS = @kde_LDFLAGS@
125 lirc_LDFLAGS = @lirc_LDFLAGS@
126 macosx_LDFLAGS = @macosx_LDFLAGS@
127 mad_LDFLAGS = @mad_LDFLAGS@
128 memcpyaltivec_LDFLAGS = @memcpyaltivec_LDFLAGS@
129 motionaltivec_LDFLAGS = @motionaltivec_LDFLAGS@
130 ncurses_LDFLAGS = @ncurses_LDFLAGS@
131 qnx_LDFLAGS = @qnx_LDFLAGS@
132 qt_LDFLAGS = @qt_LDFLAGS@
133 rc_LDFLAGS = @rc_LDFLAGS@
134 sdl_LDFLAGS = @sdl_LDFLAGS@
135 vcd_LDFLAGS = @vcd_LDFLAGS@
136 vorbis_LDFLAGS = @vorbis_LDFLAGS@
137 waveout_LDFLAGS = @waveout_LDFLAGS@
138 x11_LDFLAGS = @x11_LDFLAGS@
139 xvideo_LDFLAGS = @xvideo_LDFLAGS@
140
141 #
142 # Other special cases
143 #
144 NEED_GETOPT = @NEED_GETOPT@
145
146 ###############################################################################
147 # Configuration pre-processing
148 ###############################################################################
149
150 # PROGRAM_OPTIONS is an identification string of the compilation options
151 PROGRAM_OPTIONS = $(SYS) $(ARCH)
152 ifeq ($(DEBUG),1)
153 PROGRAM_OPTIONS += DEBUG
154 CFLAGS += -DDEBUG
155 endif
156 ifeq ($(CPROF),1)
157 PROGRAM_OPTIONS += CPROF
158 CFLAGS += -DCPROF
159 endif
160 ifeq ($(GPROF),1)
161 PROGRAM_OPTIONS += GPROF
162 CFLAGS += -DGPROF
163 endif
164
165 # PROGRAM_BUILD is a complete identification of the build
166 # (we can't use fancy options with date since OSes like Solaris
167 # or FreeBSD have strange date implementations)
168 ifeq ($(SYS),beos)
169 # XXX: beos does not support hostname (how lame...)
170 PROGRAM_BUILD = `date` $(USER)
171 else
172 PROGRAM_BUILD = `date` $(USER)@`hostname`
173 endif
174
175 # On Linux and Solaris, activate 64-bit off_t (by default under BSD)
176 CFLAGS += -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98 -D_LARGEFILE64_SOURCE
177
178 # Gettext support
179 CFLAGS += -DLOCALEDIR=\"$(datadir)/locale\"
180
181 # Data and plugin location
182 CFLAGS += -DDATA_PATH=\"@prefix@/share/videolan\"
183 CFLAGS += -DPLUGIN_PATH=\"@prefix@/lib/videolan/vlc\"
184
185 ###############################################################################
186 # Tuning and other variables - do not change anything except if you know
187 # exactly what you are doing
188 ###############################################################################
189
190 #
191 # C headers directories
192 #
193 CFLAGS += -Iinclude -Iextras
194
195 #
196 # C compiler flags: mainstream compilation
197 #
198 CFLAGS += -D_REENTRANT
199 CFLAGS += -D_GNU_SOURCE
200
201 ifeq ($(RELEASE),1)
202 CFLAGS += -DHAVE_RELEASE
203 endif
204
205 # Optimizations : don't compile debug versions with them
206 ifeq ($(OPTIMS),1)
207 CFLAGS += @CFLAGS_OPTIM@
208 ifneq ($(DEBUG),1)
209 ifneq ($(GPROF),1)
210 ifneq ($(CPROF),1)
211 CFLAGS += @CFLAGS_OPTIM_NODEBUG@
212 endif
213 endif
214 endif
215
216 ifneq (,$(findstring powerpc,$(ARCH)))
217 # Optimizations for PowerPC
218 CFLAGS += -mmultiple -mhard-float -mstring -mcpu=powerpc
219 ifneq (,$(TUNING))
220 CFLAGS += -mtune=$(TUNING)
221 endif
222 else
223 ifneq (,$(findstring sparc,$(ARCH)))
224 # Optimizations for Sparc
225 CFLAGS += -mhard-float
226 ifneq (,$(TUNING))
227 CFLAGS += -mcpu=$(TUNING)
228 endif
229 else
230 # Generic optimizations
231 ifneq (,$(TUNING))
232 CFLAGS += -mcpu=$(TUNING)
233 endif
234 endif
235 endif
236
237 #end of optimisations
238 endif
239
240 #
241 # C compiler flags: linking
242 #
243 LDFLAGS += @LDFLAGS@
244 LDFLAGS += -Wall
245 ifneq ($(DEBUG),1)
246 ifneq ($(GPROF),1)
247 ifneq ($(CPROF),1)
248 #LDFLAGS += -s
249 endif
250 endif
251 endif
252
253 #
254 # C compiler flags: plugins and builtins compilation
255 #
256 vlc_CFLAGS += -D__VLC__
257 plugins_CFLAGS += -D__VLC__ -D__PLUGIN__ -I../../include -I../../extras
258 builtins_CFLAGS += -D__VLC__ -D__BUILTIN__ -I../../include -I../../extras
259
260 #
261 # Linker flags: plugins and builtins linking
262 #
263 builtins_LDFLAGS += $(patsubst %,$$%_LDFLAGS,$(BUILTINS))
264
265 #
266 # Debugging and profiling support
267 #
268 ifeq ($(DEBUG),1)
269 CFLAGS += -g
270 endif
271
272 ifeq ($(CPROF),1)
273 CFLAGS += -finstrument-functions
274 endif
275
276 ifeq ($(GPROF),1)
277 CFLAGS += -pg
278 endif
279
280