* removed useless includes in intf_gnome.c
[vlc.git] / Makefile.in
blob29721c0348b338d078b08ef3c245efeac029cef5
1 ################################################################################
2 # vlc (VideoLAN Client) main makefile
3 # (c)1998 VideoLAN
4 ################################################################################
5 # This makefile is the main makefile for the VideoLAN client.
6 ################################################################################
8 ################################################################################
9 # Configuration
10 ################################################################################
12 # Debugging mode on or off (set to 1 to activate)
13 DEBUG=@DEBUG@
14 STATS=@STATS@
15 OPTIMS=@OPTIMS@
17 SYS=@SYS@
18 PLUGINS=@PLUGINS@
19 INSTALL=@INSTALL@
20 ARCH=@ARCH@
21 prefix=@prefix@
22 CC=@CC@
23 SHELL=@SHELL@
25 LIB_SDL=@LIB_SDL@
26 LIB_GLIDE=@LIB_GLIDE@
27 LIB_GGI=@LIB_GGI@
29 #----------------- do not change anything below this line ----------------------
31 ################################################################################
32 # Configuration pre-processing
33 ################################################################################
35 # PROGRAM_OPTIONS is an identification string of the compilation options
36 PROGRAM_OPTIONS = $(SYS) $(ARCH)
37 ifeq ($(DEBUG),1)
38 PROGRAM_OPTIONS += DEBUG
39 DEFINE += -DDEBUG
40 endif
41 ifeq ($(STATS),1)
42 PROGRAM_OPTIONS += DEBUG
43 DEFINE += -DSTATS
44 endif
46 # PROGRAM_BUILD is a complete identification of the build
47 # (we can't use fancy options with date since OSes like Solaris
48 # or FreeBSD have strange date implementations)
49 PROGRAM_BUILD = `date` $(USER)
50 # XXX: beos does not support hostname (how lame...)
51 #PROGRAM_BUILD = `date` $(USER)@`hostname`
53 # DEFINE will contain some of the constants definitions decided in Makefile,
54 # including SYS_xx. It will be passed to C compiler.
55 DEFINE += -DSYS_$(shell echo $(SYS) | sed 's/-.*//' | tr a-z. A-Z_)
57 # On Linux activate 64-bit off_t (by default under BSD)
58 ifneq (,$(findstring linux,$(SYS)))
59 DEFINE += -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98
60 endif
62 ################################################################################
63 # Tuning and other variables - do not change anything except if you know
64 # exactly what you are doing
65 ################################################################################
68 # C headers directories
70 INCLUDE += -Iinclude -I/usr/local/include -I/usr/X11R6/include
73 # Libraries
75 ifeq ($(SYS),gnu)
76 LIB += -lthreads -ldl
77 endif
79 ifneq (,$(findstring bsd,$(SYS)))
80 LIB += -pthread -lgnugetopt
81 LIB += -L/usr/local/lib
82 endif
84 ifneq (,$(findstring linux,$(SYS)))
85 LIB += -lpthread -ldl
86 endif
88 ifneq (,$(findstring solaris,$(SYS)))
89 LIB += -ldl -lsocket -lnsl -lpthread
90 endif
92 ifeq ($(SYS),beos)
93 LIB += -lbe -lroot -lgame
94 else
95 LIB += -lm
96 endif
99 # C compiler flags: mainstream compilation
101 CFLAGS += $(DEFINE) $(INCLUDE)
102 CFLAGS += -Wall -Winline
103 CFLAGS += -D_REENTRANT
104 CFLAGS += -D_GNU_SOURCE
106 # flags needed for clean beos compilation
107 ifeq ($(SYS),beos)
108 CFLAGS += -Wno-multichar -Wno-ctor-dtor-privacy -Woverloaded-virtual
109 endif
111 # Optimizations : don't compile debug versions with them
112 ifeq ($(OPTIMS),1)
113 CFLAGS += -O3
114 CFLAGS += -ffast-math -funroll-loops
115 CFLAGS += -fomit-frame-pointer
117 # Optimizations for x86 familiy
118 ifneq (,$(findstring 86,$(ARCH)))
119 # Optional Pentium Pro optimizations
120 ifneq (,$(findstring ppro,$(ARCH)))
121 CFLAGS += -march=pentiumpro -mcpu=pentiumpro
122 else
123 CFLAGS += -march=pentium -mcpu=pentium
124 endif
125 endif
127 # Optimizations for PowerPC
128 ifneq (,$(findstring powerpc,$(ARCH)))
129 # 604e
130 CFLAGS += -mcpu=604e -mmultiple -mhard-float -mstring
131 # G3
132 #CFLAGS += -mcpu=750 -mmultiple -mhard-float -mstring
133 # G4
134 #CFLAGS += -mcpu=7400 -mmultiple -mhard-float -mstring
135 endif
137 # Optimizations for Sparc
138 ifneq (,$(findstring sparc,$(ARCH)))
139 CFLAGS += -mhard-float
140 endif
142 #end of optimisations
143 endif
145 # Optional MMX optimizations for x86
146 ifneq (,$(findstring mmx,$(ARCH)))
147 CFLAGS += -DHAVE_MMX
148 endif
151 # C compiler flags: plugin compilation
153 PCFLAGS += -fPIC
156 # C compiler flags: dependancies
158 DCFLAGS += $(INCLUDE)
159 DCFLAGS += -MM
162 # C compiler flags: linking
164 LCFLAGS += $(LIB)
165 LCFLAGS += -Wall
166 #LCFLAGS += -s
169 # Debugging and profiling support (unless optimisations are active)
171 ifneq ($(OPTIMS),1)
172 CFLAGS += -g
173 endif
175 #################################################################################
176 # Objects and files
177 #################################################################################
180 # C Objects
182 INTERFACE = src/interface/main.o \
183 src/interface/interface.o \
184 src/interface/intf_msg.o \
185 src/interface/intf_cmd.o \
186 src/interface/intf_ctrl.o \
187 src/interface/intf_plst.o \
188 src/interface/intf_channels.o \
189 src/interface/intf_console.o
191 INPUT = src/input/input_ext-dec.o \
192 src/input/input_ext-intf.o \
193 src/input/input_dec.o \
194 src/input/input_programs.o \
195 src/input/input_netlist.o \
196 src/input/input_clock.o \
197 src/input/input.o \
198 src/input/mpeg_system.o
200 AUDIO_OUTPUT = src/audio_output/audio_output.o
202 VIDEO_OUTPUT = src/video_output/video_output.o \
203 src/video_output/video_text.o \
204 src/video_output/video_spu.o \
205 src/video_output/video_yuv.o
207 AC3_DECODER = src/ac3_decoder/ac3_decoder_thread.o \
208 src/ac3_decoder/ac3_decoder.o \
209 src/ac3_decoder/ac3_parse.o \
210 src/ac3_decoder/ac3_exponent.o \
211 src/ac3_decoder/ac3_bit_allocate.o \
212 src/ac3_decoder/ac3_mantissa.o \
213 src/ac3_decoder/ac3_rematrix.o \
214 src/ac3_decoder/ac3_imdct.o \
215 src/ac3_decoder/ac3_downmix.o
217 LPCM_DECODER = src/lpcm_decoder/lpcm_decoder_thread.o \
218 src/lpcm_decoder/lpcm_decoder.o
220 AUDIO_DECODER = src/audio_decoder/audio_decoder.o \
221 src/audio_decoder/adec_generic.o \
222 src/audio_decoder/adec_layer1.o \
223 src/audio_decoder/adec_layer2.o \
224 src/audio_decoder/adec_math.o
226 SPU_DECODER = src/spu_decoder/spu_decoder.o
228 #GEN_DECODER = src/generic_decoder/generic_decoder.o
230 VIDEO_PARSER = src/video_parser/video_parser.o \
231 src/video_parser/vpar_headers.o \
232 src/video_parser/vpar_blocks.o \
233 src/video_parser/vpar_synchro.o \
234 src/video_parser/video_fifo.o
236 VIDEO_DECODER = src/video_decoder/video_decoder.o
238 MISC = src/misc/mtime.o \
239 src/misc/tests.o \
240 src/misc/rsc_files.o \
241 src/misc/modules.o \
242 src/misc/netutils.o
245 C_OBJ = $(INTERFACE) \
246 $(INPUT) \
247 $(VIDEO_OUTPUT) \
248 $(AUDIO_OUTPUT) \
249 $(AC3_DECODER) \
250 $(LPCM_DECODER) \
251 $(AUDIO_DECODER) \
252 $(SPU_DECODER) \
253 $(GEN_DECODER) \
254 $(VIDEO_PARSER) \
255 $(VIDEO_DECODER) \
256 $(MISC)
260 # CPP Objects
262 ifeq ($(SYS),beos)
263 CPP_OBJ = src/misc/beos_specific.o
264 endif
267 # Assembler Objects
269 ifneq (,$(findstring 86,$(ARCH)))
270 ifneq (,$(findstring mmx,$(ARCH)))
271 ASM_OBJ =
272 endif
273 endif
276 # Plugins
278 PLUGIN_ALSA = plugins/alsa/alsa.o \
279 plugins/alsa/aout_alsa.o
281 PLUGIN_BEOS = plugins/beos/beos.o \
282 plugins/beos/aout_beos.o \
283 plugins/beos/intf_beos.o \
284 plugins/beos/vout_beos.o
286 PLUGIN_DSP = plugins/dsp/dsp.o \
287 plugins/dsp/aout_dsp.o
289 PLUGIN_DUMMY = plugins/dummy/dummy.o \
290 plugins/dummy/aout_dummy.o \
291 plugins/dummy/intf_dummy.o \
292 plugins/dummy/vout_dummy.o
294 PLUGIN_DVD = plugins/dvd/dvd.o \
295 plugins/dvd/input_dvd.o \
296 plugins/dvd/dvd_ifo.o \
297 plugins/dvd/dvd_css.o
299 PLUGIN_ESD = plugins/esd/esd.o \
300 plugins/esd/aout_esd.o
302 PLUGIN_FB = plugins/fb/fb.o \
303 plugins/fb/intf_fb.o \
304 plugins/fb/vout_fb.o
306 PLUGIN_GGI = plugins/ggi/ggi.o \
307 plugins/ggi/intf_ggi.o \
308 plugins/ggi/vout_ggi.o
310 PLUGIN_GLIDE = plugins/glide/glide.o \
311 plugins/glide/intf_glide.o \
312 plugins/glide/vout_glide.o
314 PLUGIN_GNOME = plugins/gnome/gnome.o \
315 plugins/gnome/intf_gnome.o \
316 plugins/gnome/gnome_callbacks.o \
317 plugins/gnome/gnome_interface.o \
318 plugins/gnome/gnome_support.o
320 PLUGIN_IDCT = plugins/idct/idct.o \
321 plugins/idct/idct_common.o
323 PLUGIN_IDCTCLASSIC = plugins/idct/idctclassic.o \
324 plugins/idct/idct_common.o
326 PLUGIN_IDCTMMX = plugins/idct/idctmmx.o \
327 plugins/idct/idct_common.o
329 PLUGIN_IDCTMMXEXT = plugins/idct/idctmmxext.o \
330 plugins/idct/idct_common.o
332 PLUGIN_MGA = plugins/mga/mga.o \
333 plugins/mga/intf_mga.o \
334 plugins/mga/vout_mga.o
336 PLUGIN_MOTION = plugins/motion/motion.o \
337 plugins/motion/vdec_motion_common.o \
338 plugins/motion/vdec_motion_inner.o
340 PLUGIN_MOTIONMMX = plugins/motion/motionmmx.o \
341 plugins/motion/vdec_motion_common.o \
342 plugins/motion/vdec_motion_inner_mmx.o
344 PLUGIN_MOTIONMMXEXT = plugins/motion/motionmmxext.o \
345 plugins/motion/vdec_motion_common.o \
346 plugins/motion/vdec_motion_inner_mmxext.o
348 PLUGIN_NULL = plugins/null/null.o
350 PLUGIN_PS = plugins/mpeg/ps.o \
351 plugins/mpeg/input_ps.o
353 PLUGIN_SDL = plugins/sdl/sdl.o \
354 plugins/sdl/vout_sdl.o \
355 plugins/sdl/aout_sdl.o
357 PLUGIN_TS = plugins/mpeg/ts.o \
358 plugins/mpeg/input_ts.o
360 PLUGIN_X11= plugins/x11/x11.o \
361 plugins/x11/vout_x11.o
363 PLUGIN_YUV = plugins/yuv/yuv.o \
364 plugins/yuv/video_yuv.o \
365 plugins/yuv/transforms_yuv.o
367 PLUGIN_YUVMMX = plugins/yuv/yuvmmx.o \
368 plugins/yuv/video_yuvmmx.o \
369 plugins/yuv/transforms_yuvmmx.o
371 STD_PLUGIN_OBJ = \
372 $(PLUGIN_ALSA) \
373 $(PLUGIN_BEOS) \
374 $(PLUGIN_DSP) \
375 $(PLUGIN_DUMMY) \
376 $(PLUGIN_DVD) \
377 $(PLUGIN_ESD) \
378 $(PLUGIN_FB) \
379 $(PLUGIN_GGI) \
380 $(PLUGIN_IDCT) \
381 $(PLUGIN_IDCTCLASSIC) \
382 $(PLUGIN_IDCTMMX) \
383 $(PLUGIN_IDCTMMXEXT) \
384 $(PLUGIN_MGA) \
385 $(PLUGIN_MOTION) \
386 $(PLUGIN_MOTIONMMX) \
387 $(PLUGIN_MOTIONMMXEXT) \
388 $(PLUGIN_NULL) \
389 $(PLUGIN_PS) \
390 $(PLUGIN_SDL) \
391 $(PLUGIN_TS) \
392 $(PLUGIN_X11) \
393 $(PLUGIN_YUV) \
394 $(PLUGIN_YUVMMX)
396 NONSTD_PLUGIN_OBJ = \
397 $(PLUGIN_GLIDE) \
398 $(PLUGIN_GNOME)
400 # list duplicates
401 STD_PLUGIN_COMMON = plugins/idct/idct_common.o \
402 plugins/motion/vdec_motion_common.o
404 # filter out duplicates from the plugin object lists
405 STD_PLUGIN_OBJ := $(filter-out $(STD_PLUGIN_COMMON), \
406 $(STD_PLUGIN_OBJ)) $(STD_PLUGIN_COMMON)
409 # Other lists of files
411 objects := $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ) $(STD_PLUGIN_OBJ) $(NONSTD_PLUGIN_OBJ)
412 dependancies := $(objects:%.o=.dep/%.d)
414 # All symbols must be exported
415 export
417 ################################################################################
418 # Targets
419 ################################################################################
422 # Virtual targets
424 all: vlc @ALIASES@ plugins
426 clean:
427 rm -f $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ) $(STD_PLUGIN_OBJ)
428 rm -f plugins/*/*.o src/*/*.o lib/*.so
429 rm -f vlc @ALIASES@
431 distclean: clean
432 rm -f src/*/*.o plugins/*/*.o **/*~ *.log
433 rm -f Makefile include/defs.h include/config.h
434 rm -f config.status config.cache config.log
435 rm -f gmon.out core build-stamp
436 rm -rf .dep
438 install:
439 mkdir -p $(prefix)/bin
440 $(INSTALL) vlc $(prefix)/bin
441 # ugly
442 for alias in "" @ALIASES@ ; do if test $$alias ; then rm -f $(prefix)/bin/$$alias && ln -s vlc $(prefix)/bin/$$alias ; fi ; done
443 mkdir -p $(prefix)/lib/videolan/vlc
444 $(INSTALL) -m 644 $(PLUGINS:%=lib/%.so) $(prefix)/lib/videolan/vlc
445 mkdir -p $(prefix)/share/videolan
446 $(INSTALL) -m 644 share/*.psf $(prefix)/share/videolan
447 $(INSTALL) -m 644 share/*.png $(prefix)/share/videolan
449 show:
450 @echo CC: $(CC)
451 @echo CFLAGS: $(CFLAGS)
452 @echo DCFLAGS: $(DCFLAGS)
453 @echo LCFLAGS: $(LCFLAGS)
454 @echo STD_PLUGIN_OBJ: $(STD_PLUGIN_OBJ)
456 # ugliest of all, but I have no time to do it -- sam
457 snapshot:
458 rm -rf /tmp/vlc-@VLC_VERSION@ /tmp/vlc-@VLC_VERSION@nocss
459 # copy archive in /tmp
460 find -type d | while read i ; \
461 do mkdir -p /tmp/vlc-@VLC_VERSION@/$$i ; \
462 done
463 find debian -mindepth 1 -maxdepth 1 -type d | grep -v CVS | \
464 while read i ; do rm -rf /tmp/vlc-@VLC_VERSION@/$$i ; done
465 # CVS entries
466 find . -type f | grep CVS | while read i ; \
467 do cp $$i /tmp/vlc-@VLC_VERSION@/$$i ; \
468 done
469 # .c .h .in .cpp
470 find include src plugins -type f -name '*.[chi]*' | while read i ; \
471 do cp $$i /tmp/vlc-@VLC_VERSION@/$$i ; \
472 done
473 # copy misc files
474 cp vlc.spec AUTHORS COPYING ChangeLog INSTALL README TODO \
475 Makefile.in Makefile.dep configure configure.in install-sh \
476 config.sub config.guess todo.pl \
477 /tmp/vlc-@VLC_VERSION@/
478 for file in control vlc-gnome.menu vlc.copyright vlc.docs changelog \
479 rules vlc.1 vlc.dirs vlc.menu ; do \
480 cp debian/$$file /tmp/vlc-@VLC_VERSION@/debian/ ; done
481 for file in default8x16.psf default8x9.psf gvlc.png vlc.png ; do \
482 cp share/$$file /tmp/vlc-@VLC_VERSION@/share/ ; done
484 # build css-enabled archives
485 (cd /tmp ; tar cf vlc-@VLC_VERSION@.tar vlc-@VLC_VERSION@ ; \
486 bzip2 -f -9 < vlc-@VLC_VERSION@.tar \
487 > vlc-@VLC_VERSION@.tar.bz2 ; \
488 gzip -f -9 vlc-@VLC_VERSION@.tar )
489 mv /tmp/vlc-@VLC_VERSION@.tar.gz /tmp/vlc-@VLC_VERSION@.tar.bz2 ..
491 # removing CSS stuff
492 find /tmp/vlc-@VLC_VERSION@ -type f -name '*css*' | xargs rm -f
493 for x in Makefile.in src/input/input_dvd.c src/input/input_dvd.h ; do \
494 rm -f /tmp/vlc-@VLC_VERSION@/$$x ; \
495 perl -ne 'if (/^#e(lse|ndif)/) { $$i=0; } \
496 if (/^#if.*DVD/) { $$i=1; print "#if 0\n"; } \
497 elsif (!$$i || /^#/) { print $$_; }' \
498 < $$x | grep -vi css >| /tmp/vlc-@VLC_VERSION@/$$x ; \
499 done
500 rm -f /tmp/vlc-@VLC_VERSION@/debian/changelog
501 sed 's/\(^vlc ([^-]*\)-/\1nocss-/' < debian/changelog \
502 > /tmp/vlc-@VLC_VERSION@/debian/changelog
504 # build nocss archives
505 (cd /tmp ; mv vlc-@VLC_VERSION@ vlc-@VLC_VERSION@nocss ; \
506 tar cf vlc-@VLC_VERSION@nocss.tar vlc-@VLC_VERSION@nocss ; \
507 bzip2 -f -9 < vlc-@VLC_VERSION@nocss.tar \
508 > vlc-@VLC_VERSION@nocss.tar.bz2 ; \
509 gzip -f -9 vlc-@VLC_VERSION@nocss.tar )
510 mv /tmp/vlc-@VLC_VERSION@nocss.tar.gz \
511 /tmp/vlc-@VLC_VERSION@nocss.tar.bz2 ..
513 # clean up
514 rm -rf /tmp/vlc-@VLC_VERSION@nocss
516 plugins: $(PLUGINS:%=lib/%.so)
518 FORCE:
521 # Gnome and Framebuffer aliases - don't add new aliases which could bloat
522 # the namespace
524 gvlc fbvlc: vlc
525 rm -f $@ && ln -s vlc $@
529 # Generic rules (see below)
531 $(dependancies): %.d: FORCE
532 @$(MAKE) -s --no-print-directory -f Makefile.dep $@
534 $(C_OBJ): %.o: Makefile.dep
535 $(C_OBJ): %.o: .dep/%.d
536 $(C_OBJ): %.o: %.c
537 $(CC) $(CFLAGS) -c -o $@ $<
539 $(CPP_OBJ): %.o: %.cpp
540 $(CC) $(CFLAGS) -c -o $@ $<
542 $(ASM_OBJ): %.o: Makefile.dep
543 $(ASM_OBJ): %.o: %.S
544 $(CC) $(CFLAGS) -c -o $@ $<
546 $(STD_PLUGIN_OBJ): %.o: Makefile.dep
547 $(STD_PLUGIN_OBJ): %.o: .dep/%.d
548 $(STD_PLUGIN_OBJ): %.o: %.c
549 $(CC) $(CFLAGS) $(PCFLAGS) -c -o $@ $<
551 $(PLUGIN_GNOME): %.o: Makefile.dep
552 $(PLUGIN_GNOME): %.o: .dep/%.d
553 $(PLUGIN_GNOME): %.o: %.c
554 $(CC) $(CFLAGS) $(PCFLAGS) `gnome-config --cflags gnomeui` -c -o $@ $<
556 $(PLUGIN_GLIDE): %.o: Makefile.dep
557 $(PLUGIN_GLIDE): %.o: .dep/%.d
558 $(PLUGIN_GLIDE): %.o: %.c
559 $(CC) $(CFLAGS) $(PCFLAGS) -I/usr/include/glide -c -o $@ $<
562 # Main application target
565 vlc: $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
566 ifeq ($(SYS),beos)
567 $(CC) $(CFLAGS) $(LCFLAGS) -Xlinker -soname=_APP_ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
568 rm -f ./plugins/_APP_
569 ln -s ../vlc ./plugins/_APP_
570 else
571 $(CC) $(CFLAGS) $(LCFLAGS) --export-dynamic @DYNAMIC_FLAG@ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
572 endif
575 # Plugin targets
578 lib/beos.so: $(PLUGIN_BEOS)
579 $(CC) $(PCFLAGS) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
581 lib/esd.so: $(PLUGIN_ESD)
582 ifneq (,$(findstring bsd,$(SYS)))
583 $(CC) $(PCFLAGS) -shared -o $@ $^ -lesd
584 else
585 $(CC) $(PCFLAGS) -shared -o $@ $^ -laudiofile -lesd
586 endif
588 lib/dsp.so: $(PLUGIN_DSP)
589 $(CC) $(PCFLAGS) -shared -o $@ $^
591 lib/alsa.so: $(PLUGIN_ALSA)
592 $(CC) $(PCFLAGS) -shared -o $@ $^ -lasound
594 lib/fb.so: $(PLUGIN_FB)
595 $(CC) $(PCFLAGS) -shared -o $@ $^
597 lib/x11.so: $(PLUGIN_X11)
598 $(CC) $(PCFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
600 lib/mga.so: $(PLUGIN_MGA)
601 $(CC) $(PCFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
603 lib/gnome.so: $(PLUGIN_GNOME)
604 $(CC) $(PCFLAGS) -shared -o $@ $^ `gnome-config --libs gnomeui | sed 's,-rdynamic,,'`
606 lib/glide.so: $(PLUGIN_GLIDE)
607 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_GLIDE)
609 lib/ggi.so: $(PLUGIN_GGI)
610 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_GGI)
612 lib/sdl.so: $(PLUGIN_SDL)
613 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_SDL)
615 ifeq ($(SYS),beos)
616 lib/null.so: $(PLUGIN_NULL)
617 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
619 lib/ps.so: $(PLUGIN_PS)
620 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
622 lib/ts.so: $(PLUGIN_TS)
623 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
625 lib/dvd.so: $(PLUGIN_DVD)
626 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
628 lib/dummy.so: $(PLUGIN_DUMMY)
629 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
631 lib/yuv.so: $(PLUGIN_YUV)
632 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
634 lib/yuvmmx.so: $(PLUGIN_YUVMMX)
635 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
637 lib/motion.so: $(PLUGIN_MOTION)
638 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
640 lib/motionmmx.so: $(PLUGIN_MOTIONMMX)
641 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
643 lib/motionmmxext.so: $(PLUGIN_MOTIONMMXEXT)
644 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
646 lib/idct.so: $(PLUGIN_IDCT)
647 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
649 lib/idctclassic.so: $(PLUGIN_IDCTCLASSIC)
650 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
652 lib/idctmmx.so: $(PLUGIN_IDCTMMX)
653 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
655 lib/idctmmxext.so: $(PLUGIN_IDCTMMXEXT)
656 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
657 else
658 lib/null.so: $(PLUGIN_NULL)
659 $(CC) $(PCFLAGS) -shared -o $@ $^
661 lib/ps.so: $(PLUGIN_PS)
662 $(CC) $(PCFLAGS) -shared -o $@ $^
664 lib/ts.so: $(PLUGIN_TS)
665 $(CC) $(PCFLAGS) -shared -o $@ $^
667 lib/dvd.so: $(PLUGIN_DVD)
668 $(CC) $(PCFLAGS) -shared -o $@ $^
670 lib/dummy.so: $(PLUGIN_DUMMY)
671 $(CC) $(PCFLAGS) -shared -o $@ $^
673 lib/yuv.so: $(PLUGIN_YUV)
674 $(CC) $(PCFLAGS) -shared -o $@ $^
676 lib/yuvmmx.so: $(PLUGIN_YUVMMX)
677 $(CC) $(PCFLAGS) -shared -o $@ $^
679 lib/motion.so: $(PLUGIN_MOTION)
680 $(CC) $(PCFLAGS) -shared -o $@ $^
682 lib/motionmmx.so: $(PLUGIN_MOTIONMMX)
683 $(CC) $(PCFLAGS) -shared -o $@ $^
685 lib/motionmmxext.so: $(PLUGIN_MOTIONMMXEXT)
686 $(CC) $(PCFLAGS) -shared -o $@ $^
688 lib/idct.so: $(PLUGIN_IDCT)
689 $(CC) $(PCFLAGS) -shared -o $@ $^
691 lib/idctclassic.so: $(PLUGIN_IDCTCLASSIC)
692 $(CC) $(PCFLAGS) -shared -o $@ $^
694 lib/idctmmx.so: $(PLUGIN_IDCTMMX)
695 $(CC) $(PCFLAGS) -shared -o $@ $^
697 lib/idctmmxext.so: $(PLUGIN_IDCTMMXEXT)
698 $(CC) $(PCFLAGS) -shared -o $@ $^
699 endif
701 ################################################################################
702 # Note on generic rules and dependancies
703 ################################################################################
705 # Note on dependancies: each .c file is associated with a .d file, which
706 # depends of it. The .o file associated with a .c file depends of the .d, of the
707 # .c itself, and of Makefile. The .d files are stored in a separate .dep/
708 # directory.
709 # The dep directory should be ignored by CVS.
711 # Note on inclusions: depending of the target, the dependancies files must
712 # or must not be included. The problem is that if we ask make to include a file,
713 # and this file does not exist, it is made before it can be included. In a
714 # general way, a .d file should be included if and only if the corresponding .o
715 # needs to be re-made.
717 # Two makefiles are used: the main one (this one) has regular generic rules,
718 # except for .o files, for which it calls the object Makefile. Dependancies
719 # are not included in this file.
720 # The object Makefile known how to make a .o from a .c, and includes
721 # dependancies for the target, but only those required.