1 ################################################################################
2 # vlc (VideoLAN Client) main makefile
4 ################################################################################
5 # This makefile is the main makefile for the VideoLAN client.
6 ################################################################################
8 ################################################################################
10 ################################################################################
12 # Debugging mode on or off (set to 1 to activate)
22 exec_prefix=@exec_prefix@
35 #----------------- do not change anything below this line ----------------------
37 ################################################################################
38 # Configuration pre-processing
39 ################################################################################
41 # PROGRAM_OPTIONS is an identification string of the compilation options
42 PROGRAM_OPTIONS = $(SYS) $(ARCH)
44 PROGRAM_OPTIONS += DEBUG
48 PROGRAM_OPTIONS += DEBUG
52 # PROGRAM_BUILD is a complete identification of the build
53 # (we can't use fancy options with date since OSes like Solaris
54 # or FreeBSD have strange date implementations)
55 PROGRAM_BUILD = `date` $(USER)
56 # XXX: beos does not support hostname (how lame...)
57 #PROGRAM_BUILD = `date` $(USER)@`hostname`
59 # DEFINE will contain some of the constants definitions decided in Makefile,
60 # including SYS_xx. It will be passed to C compiler.
61 DEFINE += -DSYS_$(shell echo $(SYS) | sed 's/-.*//' | tr a-z. A-Z_)
63 # On Linux activate 64-bit off_t (by default under BSD)
64 ifneq (,$(findstring linux,$(SYS)))
65 DEFINE += -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98
68 ################################################################################
69 # Tuning and other variables - do not change anything except if you know
70 # exactly what you are doing
71 ################################################################################
74 # C headers directories
76 INCLUDE += -Iinclude -I/usr/local/include -I/usr/X11R6/include
85 ifneq (,$(findstring bsd,$(SYS)))
86 LIB += -pthread -lgnugetopt
87 LIB += -L/usr/local/lib
90 ifneq (,$(findstring linux,$(SYS)))
94 ifneq (,$(findstring solaris,$(SYS)))
95 LIB += -ldl -lsocket -lnsl -lpthread
99 LIB += -lbe -lroot -lgame
105 # C compiler flags: mainstream compilation
107 CFLAGS += $(DEFINE) $(INCLUDE)
108 CFLAGS += -Wall -Winline
109 CFLAGS += -D_REENTRANT
110 CFLAGS += -D_GNU_SOURCE
112 # flags needed for clean beos compilation
114 CFLAGS += -Wno-multichar -Wno-ctor-dtor-privacy -Woverloaded-virtual
117 # Optimizations : don't compile debug versions with them
120 CFLAGS += -ffast-math -funroll-loops
121 CFLAGS += -fomit-frame-pointer
123 # Optimizations for x86 familiy
124 ifneq (,$(findstring 86,$(ARCH)))
125 # Optional Pentium Pro optimizations
126 ifneq (,$(findstring ppro,$(ARCH)))
127 CFLAGS += -march=pentiumpro -mcpu=pentiumpro
129 CFLAGS += -march=pentium -mcpu=pentium
133 # Optimizations for PowerPC
134 ifneq (,$(findstring powerpc,$(ARCH)))
136 CFLAGS += -mcpu=604e -mmultiple -mhard-float -mstring
138 #CFLAGS += -mcpu=750 -mmultiple -mhard-float -mstring
140 #CFLAGS += -mcpu=7400 -mmultiple -mhard-float -mstring
143 # Optimizations for Sparc
144 ifneq (,$(findstring sparc,$(ARCH)))
145 CFLAGS += -mhard-float
148 #end of optimisations
151 # Optional MMX optimizations for x86
152 ifneq (,$(findstring mmx,$(ARCH)))
157 # C compiler flags: plugin compilation
162 # C compiler flags: dependancies
164 DCFLAGS += $(INCLUDE)
168 # C compiler flags: linking
175 # Debugging and profiling support (unless optimisations are active)
181 #################################################################################
183 #################################################################################
188 INTERFACE = src/interface/main.o \
189 src/interface/interface.o \
190 src/interface/intf_msg.o \
191 src/interface/intf_cmd.o \
192 src/interface/intf_ctrl.o \
193 src/interface/intf_plst.o \
194 src/interface/intf_channels.o \
195 src/interface/intf_console.o
197 INPUT = src/input/input_ext-dec.o \
198 src/input/input_ext-intf.o \
199 src/input/input_dec.o \
200 src/input/input_programs.o \
201 src/input/input_netlist.o \
202 src/input/input_clock.o \
204 src/input/mpeg_system.o
206 AUDIO_OUTPUT = src/audio_output/audio_output.o
208 VIDEO_OUTPUT = src/video_output/video_output.o \
209 src/video_output/video_text.o \
210 src/video_output/video_spu.o \
211 src/video_output/video_yuv.o
213 AC3_DECODER = src/ac3_decoder/ac3_decoder_thread.o \
214 src/ac3_decoder/ac3_decoder.o \
215 src/ac3_decoder/ac3_parse.o \
216 src/ac3_decoder/ac3_exponent.o \
217 src/ac3_decoder/ac3_bit_allocate.o \
218 src/ac3_decoder/ac3_mantissa.o \
219 src/ac3_decoder/ac3_rematrix.o \
220 src/ac3_decoder/ac3_imdct.o \
221 src/ac3_decoder/ac3_downmix.o \
222 src/ac3_decoder/ac3_downmix_c.o
224 LPCM_DECODER = src/lpcm_decoder/lpcm_decoder_thread.o \
225 src/lpcm_decoder/lpcm_decoder.o
227 AUDIO_DECODER = src/audio_decoder/audio_decoder.o \
228 src/audio_decoder/adec_generic.o \
229 src/audio_decoder/adec_layer1.o \
230 src/audio_decoder/adec_layer2.o \
231 src/audio_decoder/adec_math.o
233 SPU_DECODER = src/spu_decoder/spu_decoder.o
235 #GEN_DECODER = src/generic_decoder/generic_decoder.o
237 VIDEO_PARSER = src/video_parser/video_parser.o \
238 src/video_parser/vpar_headers.o \
239 src/video_parser/vpar_blocks.o \
240 src/video_parser/vpar_synchro.o \
241 src/video_parser/video_fifo.o
243 VIDEO_DECODER = src/video_decoder/video_decoder.o
245 MISC = src/misc/mtime.o \
247 src/misc/rsc_files.o \
252 C_OBJ = $(INTERFACE) \
270 CPP_OBJ = src/misc/beos_specific.o
276 ifneq (,$(findstring 86,$(ARCH)))
277 ifneq (,$(findstring mmx,$(ARCH)))
285 PLUGIN_ALSA = plugins/alsa/alsa.o \
286 plugins/alsa/aout_alsa.o
288 PLUGIN_BEOS = plugins/beos/beos.o \
289 plugins/beos/aout_beos.o \
290 plugins/beos/intf_beos.o \
291 plugins/beos/vout_beos.o
293 PLUGIN_DSP = plugins/dsp/dsp.o \
294 plugins/dsp/aout_dsp.o
296 PLUGIN_DUMMY = plugins/dummy/dummy.o \
297 plugins/dummy/aout_dummy.o \
298 plugins/dummy/intf_dummy.o \
299 plugins/dummy/vout_dummy.o
301 PLUGIN_DVD = plugins/dvd/dvd.o \
302 plugins/dvd/input_dvd.o \
303 plugins/dvd/dvd_ioctl.o \
304 plugins/dvd/dvd_ifo.o \
305 plugins/dvd/dvd_udf.o \
306 plugins/dvd/dvd_css.o
308 PLUGIN_ESD = plugins/esd/esd.o \
309 plugins/esd/aout_esd.o
311 PLUGIN_FB = plugins/fb/fb.o \
314 PLUGIN_GGI = plugins/ggi/ggi.o \
315 plugins/ggi/vout_ggi.o
317 PLUGIN_GLIDE = plugins/glide/glide.o \
318 plugins/glide/vout_glide.o
320 PLUGIN_GNOME = plugins/gnome/gnome.o \
321 plugins/gnome/intf_gnome.o \
322 plugins/gnome/gnome_callbacks.o \
323 plugins/gnome/gnome_interface.o \
324 plugins/gnome/gnome_support.o
326 PLUGIN_KDE = plugins/kde/kde.o \
327 plugins/kde/intf_kde.o \
330 PLUGIN_IDCT = plugins/idct/idct.o \
331 plugins/idct/idct_common.o
333 PLUGIN_IDCTCLASSIC = plugins/idct/idctclassic.o \
334 plugins/idct/idct_common.o
336 PLUGIN_IDCTMMX = plugins/idct/idctmmx.o \
337 plugins/idct/idct_common.o
339 PLUGIN_IDCTMMXEXT = plugins/idct/idctmmxext.o \
340 plugins/idct/idct_common.o
342 PLUGIN_MGA = plugins/mga/mga.o \
343 plugins/mga/vout_mga.o
345 PLUGIN_MOTION = plugins/motion/motion.o \
346 plugins/motion/vdec_motion_common.o \
347 plugins/motion/vdec_motion_inner.o
349 PLUGIN_MOTIONMMX = plugins/motion/motionmmx.o \
350 plugins/motion/vdec_motion_common.o \
351 plugins/motion/vdec_motion_inner_mmx.o
353 PLUGIN_MOTIONMMXEXT = plugins/motion/motionmmxext.o \
354 plugins/motion/vdec_motion_common.o \
355 plugins/motion/vdec_motion_inner_mmxext.o
357 PLUGIN_NCURSES = plugins/text/ncurses.o \
358 plugins/text/intf_ncurses.o
360 PLUGIN_NULL = plugins/null/null.o
362 PLUGIN_PS = plugins/mpeg/ps.o \
363 plugins/mpeg/input_ps.o
365 PLUGIN_SDL = plugins/sdl/sdl.o \
366 plugins/sdl/vout_sdl.o \
367 plugins/sdl/aout_sdl.o
369 PLUGIN_TS = plugins/mpeg/ts.o \
370 plugins/mpeg/input_ts.o
372 PLUGIN_X11= plugins/x11/x11.o \
373 plugins/x11/vout_x11.o
375 PLUGIN_YUV = plugins/yuv/yuv.o \
376 plugins/yuv/video_yuv.o \
377 plugins/yuv/transforms_yuv.o
379 PLUGIN_YUVMMX = plugins/yuv/yuvmmx.o \
380 plugins/yuv/video_yuvmmx.o \
381 plugins/yuv/transforms_yuvmmx.o
392 $(PLUGIN_IDCTCLASSIC) \
394 $(PLUGIN_IDCTMMXEXT) \
397 $(PLUGIN_MOTIONMMX) \
398 $(PLUGIN_MOTIONMMXEXT) \
409 STD_PLUGIN_COMMON = plugins/idct/idct_common.o \
410 plugins/motion/vdec_motion_common.o
412 # filter out duplicates from the plugin object lists
413 STD_PLUGIN_OBJ := $(filter-out $(STD_PLUGIN_COMMON), \
414 $(STD_PLUGIN_OBJ)) $(STD_PLUGIN_COMMON)
416 NONSTD_PLUGIN_OBJ = \
420 NONSTD_CPP_PLUGIN_OBJ = \
425 # Other lists of files
427 objects := $(C_OBJ) $(ASM_OBJ) $(STD_PLUGIN_OBJ) $(NONSTD_PLUGIN_OBJ)
428 cdependancies := $(objects:%.o=.dep/%.d)
429 cppobjects := $(CPP_OBJ) $(NONSTD_CPP_PLUGIN_OBJ)
430 cppdependancies := $(cppobjects:%.o=.dep/%.dpp)
432 # All symbols must be exported
435 ################################################################################
437 ################################################################################
442 all: vlc @ALIASES@ plugins
445 rm -f $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ) $(STD_PLUGIN_OBJ)
446 rm -f plugins/*/*.o src/*/*.o lib/*.so
450 rm -f src/*/*.o plugins/*/*.o **/*~ *.log
451 rm -f Makefile include/defs.h include/config.h
452 rm -f config.status config.cache config.log
453 rm -f gmon.out core build-stamp
457 mkdir -p $(DESTDIR)$(bindir)
458 $(INSTALL) vlc $(DESTDIR)$(bindir)
460 for alias in "" @ALIASES@ ; do if test $$alias ; then rm -f $(DESTDIR)$(bindir)/$$alias && ln -s vlc $(DESTDIR)$(bindir)/$$alias ; fi ; done
461 mkdir -p $(DESTDIR)$(libdir)/videolan/vlc
462 $(INSTALL) -m 644 $(PLUGINS:%=lib/%.so) $(DESTDIR)$(libdir)/videolan/vlc
463 mkdir -p $(DESTDIR)$(datadir)/videolan
464 $(INSTALL) -m 644 share/*.psf $(DESTDIR)$(datadir)/videolan
465 $(INSTALL) -m 644 share/*.png $(DESTDIR)$(datadir)/videolan
469 @echo CFLAGS: $(CFLAGS)
470 @echo DCFLAGS: $(DCFLAGS)
471 @echo LCFLAGS: $(LCFLAGS)
472 @echo C_OBJ: $(C_OBJ)
473 @echo CPP_OBJ: $(CPP_OBJ)
474 @echo STD_PLUGIN_OBJ: $(STD_PLUGIN_OBJ)
475 @echo NONSTD_PLUGIN_OBJ: $(NONSTD_PLUGIN_OBJ)
476 @echo NONSTD_CPP_PLUGIN_OBJ: $(NONSTD_CPP_PLUGIN_OBJ)
477 @echo objects: $(objects)
478 @echo cppobjects: $(cppobjects)
480 # ugliest of all, but I have no time to do it -- sam
482 rm -rf /tmp/vlc-@VLC_VERSION@ /tmp/vlc-@VLC_VERSION@nocss
483 # copy archive in /tmp
484 find -type d | while read i ; \
485 do mkdir -p /tmp/vlc-@VLC_VERSION@/$$i ; \
487 find debian -mindepth 1 -maxdepth 1 -type d | grep -v CVS | \
488 while read i ; do rm -rf /tmp/vlc-@VLC_VERSION@/$$i ; done
490 find . -type f | grep CVS | while read i ; \
491 do cp $$i /tmp/vlc-@VLC_VERSION@/$$i ; \
494 find include src plugins -type f -name '*.[chi]*' | while read i ; \
495 do cp $$i /tmp/vlc-@VLC_VERSION@/$$i ; \
498 cp vlc.spec AUTHORS COPYING ChangeLog INSTALL README TODO \
499 Makefile.in Makefile.dep configure configure.in install-sh \
500 config.sub config.guess todo.pl \
501 /tmp/vlc-@VLC_VERSION@/
502 for file in control vlc-gnome.menu vlc.copyright vlc.docs changelog \
503 rules vlc.1 vlc.dirs vlc.menu ; do \
504 cp debian/$$file /tmp/vlc-@VLC_VERSION@/debian/ ; done
505 for file in default8x16.psf default8x9.psf gvlc.png vlc.png ; do \
506 cp share/$$file /tmp/vlc-@VLC_VERSION@/share/ ; done
508 # build css-enabled archives
509 (cd /tmp ; tar cf vlc-@VLC_VERSION@.tar vlc-@VLC_VERSION@ ; \
510 bzip2 -f -9 < vlc-@VLC_VERSION@.tar \
511 > vlc-@VLC_VERSION@.tar.bz2 ; \
512 gzip -f -9 vlc-@VLC_VERSION@.tar )
513 mv /tmp/vlc-@VLC_VERSION@.tar.gz /tmp/vlc-@VLC_VERSION@.tar.bz2 ..
516 # find /tmp/vlc-@VLC_VERSION@ -type f -name '*css*' | xargs rm -f
517 # for x in Makefile.in src/input/input_dvd.c src/input/input_dvd.h ; do \
518 # rm -f /tmp/vlc-@VLC_VERSION@/$$x ; \
519 # perl -ne 'if (/^#e(lse|ndif)/) { $$i=0; } \
520 # if (/^#if.*DVD/) { $$i=1; print "#if 0\n"; } \
521 # elsif (!$$i || /^#/) { print $$_; }' \
522 # < $$x | grep -vi css >| /tmp/vlc-@VLC_VERSION@/$$x ; \
524 # rm -f /tmp/vlc-@VLC_VERSION@/debian/changelog
525 # sed 's/\(^vlc ([^-]*\)-/\1nocss-/' < debian/changelog \
526 # > /tmp/vlc-@VLC_VERSION@/debian/changelog
528 # # build nocss archives
529 # (cd /tmp ; mv vlc-@VLC_VERSION@ vlc-@VLC_VERSION@nocss ; \
530 # tar cf vlc-@VLC_VERSION@nocss.tar vlc-@VLC_VERSION@nocss ; \
531 # bzip2 -f -9 < vlc-@VLC_VERSION@nocss.tar \
532 # > vlc-@VLC_VERSION@nocss.tar.bz2 ; \
533 # gzip -f -9 vlc-@VLC_VERSION@nocss.tar )
534 # mv /tmp/vlc-@VLC_VERSION@nocss.tar.gz \
535 # /tmp/vlc-@VLC_VERSION@nocss.tar.bz2 ..
538 rm -rf /tmp/vlc-@VLC_VERSION@*
540 plugins: $(PLUGINS:%=lib/%.so)
545 # Gnome and Framebuffer aliases - don't add new aliases which could bloat
549 rm -f $@ && ln -s vlc $@
553 # Generic rules (see below)
555 $(cdependancies): %.d: FORCE
556 @$(MAKE) -s --no-print-directory -f Makefile.dep $@
558 $(cppdependancies): %.dpp: FORCE
559 @$(MAKE) -s --no-print-directory -f Makefile.dep $@
561 $(C_OBJ): %.o: Makefile.dep
562 $(C_OBJ): %.o: .dep/%.d
564 $(CC) $(CFLAGS) -c -o $@ $<
566 $(CPP_OBJ): %.o: Makefile.dep
567 $(CPP_OBJ): %.o: .dep/%.dpp
568 $(CPP_OBJ): %.o: %.cpp
569 $(CC) $(CFLAGS) -c -o $@ $<
571 $(ASM_OBJ): %.o: Makefile.dep
573 $(CC) $(CFLAGS) -c -o $@ $<
575 $(STD_PLUGIN_OBJ): %.o: Makefile.dep
576 $(STD_PLUGIN_OBJ): %.o: .dep/%.d
577 $(STD_PLUGIN_OBJ): %.o: %.c
578 $(CC) $(CFLAGS) $(PCFLAGS) -c -o $@ $<
580 $(PLUGIN_GNOME): %.o: Makefile.dep
581 $(PLUGIN_GNOME): %.o: .dep/%.d
582 $(PLUGIN_GNOME): %.o: %.c
583 $(CC) $(CFLAGS) $(PCFLAGS) `gnome-config --cflags gnomeui` -c -o $@ $<
585 $(PLUGIN_GLIDE): %.o: Makefile.dep
586 $(PLUGIN_GLIDE): %.o: .dep/%.d
587 $(PLUGIN_GLIDE): %.o: %.c
588 $(CC) $(CFLAGS) $(PCFLAGS) -I/usr/include/glide -c -o $@ $<
590 $(PLUGIN_KDE): %.o: Makefile.dep
591 $(PLUGIN_KDE): %.o: .dep/%.dpp
592 $(PLUGIN_KDE): %.o: %.cpp
593 $(CC) $(CFLAGS) $(PCFLAGS) -I/usr/include/kde -I/usr/include/qt -fno-rtti -c -o $@ $<
595 $(PLUGIN_BEOS): %.o: Makefile.dep
596 $(PLUGIN_BEOS): %.o: .dep/%.dpp
597 $(PLUGIN_BEOS): %.o: %.cpp
598 $(CC) $(CFLAGS) $(PCFLAGS) -c -o $@ $<
601 # Main application target
604 vlc: $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
606 $(CC) $(CFLAGS) $(LCFLAGS) -Xlinker -soname=_APP_ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
607 rm -f ./plugins/_APP_
608 ln -s ../vlc ./plugins/_APP_
610 $(CC) $(CFLAGS) $(LCFLAGS) --export-dynamic @DYNAMIC_FLAG@ -o $@ $(C_OBJ) $(CPP_OBJ) $(ASM_OBJ)
617 lib/beos.so: $(PLUGIN_BEOS)
618 $(CC) $(PCFLAGS) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_ -lbe -lgame -lroot
620 lib/esd.so: $(PLUGIN_ESD)
621 ifneq (,$(findstring bsd,$(SYS)))
622 $(CC) $(PCFLAGS) -shared -o $@ $^ -lesd
624 $(CC) $(PCFLAGS) -shared -o $@ $^ -laudiofile -lesd
627 lib/dsp.so: $(PLUGIN_DSP)
628 $(CC) $(PCFLAGS) -shared -o $@ $^
630 lib/kde.so: $(PLUGIN_KDE)
631 $(CC) $(PCFLAGS) -shared -o $@ $^ -lkdeui -lkdecore -lqt -ldl
633 lib/alsa.so: $(PLUGIN_ALSA)
634 $(CC) $(PCFLAGS) -shared -o $@ $^ -lasound
636 lib/fb.so: $(PLUGIN_FB)
637 $(CC) $(PCFLAGS) -shared -o $@ $^
639 lib/x11.so: $(PLUGIN_X11)
640 $(CC) $(PCFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
642 lib/mga.so: $(PLUGIN_MGA)
643 $(CC) $(PCFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lX11 -lXext
645 lib/gnome.so: $(PLUGIN_GNOME)
646 $(CC) $(PCFLAGS) -shared -o $@ $^ `gnome-config --libs gnomeui | sed 's,-rdynamic,,'`
648 lib/glide.so: $(PLUGIN_GLIDE)
649 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_GLIDE)
651 lib/ggi.so: $(PLUGIN_GGI)
652 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_GGI)
654 lib/sdl.so: $(PLUGIN_SDL)
655 $(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_SDL)
657 lib/ncurses.so: $(PLUGIN_NCURSES)
658 $(CC) $(PCFLAGS) -shared -o $@ $^ -lcurses
661 lib/null.so: $(PLUGIN_NULL)
662 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
664 lib/ps.so: $(PLUGIN_PS)
665 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
667 lib/ts.so: $(PLUGIN_TS)
668 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
670 lib/dvd.so: $(PLUGIN_DVD)
671 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
673 lib/dummy.so: $(PLUGIN_DUMMY)
674 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
676 lib/yuv.so: $(PLUGIN_YUV)
677 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
679 lib/yuvmmx.so: $(PLUGIN_YUVMMX)
680 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
682 lib/motion.so: $(PLUGIN_MOTION)
683 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
685 lib/motionmmx.so: $(PLUGIN_MOTIONMMX)
686 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
688 lib/motionmmxext.so: $(PLUGIN_MOTIONMMXEXT)
689 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
691 lib/idct.so: $(PLUGIN_IDCT)
692 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
694 lib/idctclassic.so: $(PLUGIN_IDCTCLASSIC)
695 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
697 lib/idctmmx.so: $(PLUGIN_IDCTMMX)
698 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
700 lib/idctmmxext.so: $(PLUGIN_IDCTMMXEXT)
701 $(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
703 lib/null.so: $(PLUGIN_NULL)
704 $(CC) $(PCFLAGS) -shared -o $@ $^
706 lib/ps.so: $(PLUGIN_PS)
707 $(CC) $(PCFLAGS) -shared -o $@ $^
709 lib/ts.so: $(PLUGIN_TS)
710 $(CC) $(PCFLAGS) -shared -o $@ $^
712 lib/dvd.so: $(PLUGIN_DVD)
713 $(CC) $(PCFLAGS) -shared -o $@ $^
715 lib/dummy.so: $(PLUGIN_DUMMY)
716 $(CC) $(PCFLAGS) -shared -o $@ $^
718 lib/yuv.so: $(PLUGIN_YUV)
719 $(CC) $(PCFLAGS) -shared -o $@ $^
721 lib/yuvmmx.so: $(PLUGIN_YUVMMX)
722 $(CC) $(PCFLAGS) -shared -o $@ $^
724 lib/motion.so: $(PLUGIN_MOTION)
725 $(CC) $(PCFLAGS) -shared -o $@ $^
727 lib/motionmmx.so: $(PLUGIN_MOTIONMMX)
728 $(CC) $(PCFLAGS) -shared -o $@ $^
730 lib/motionmmxext.so: $(PLUGIN_MOTIONMMXEXT)
731 $(CC) $(PCFLAGS) -shared -o $@ $^
733 lib/idct.so: $(PLUGIN_IDCT)
734 $(CC) $(PCFLAGS) -shared -o $@ $^
736 lib/idctclassic.so: $(PLUGIN_IDCTCLASSIC)
737 $(CC) $(PCFLAGS) -shared -o $@ $^
739 lib/idctmmx.so: $(PLUGIN_IDCTMMX)
740 $(CC) $(PCFLAGS) -shared -o $@ $^
742 lib/idctmmxext.so: $(PLUGIN_IDCTMMXEXT)
743 $(CC) $(PCFLAGS) -shared -o $@ $^
746 ################################################################################
747 # Note on generic rules and dependancies
748 ################################################################################
750 # Note on dependancies: each .c file is associated with a .d file, which
751 # depends of it. The .o file associated with a .c file depends of the .d, of the
752 # .c itself, and of Makefile. The .d files are stored in a separate .dep/
754 # The dep directory should be ignored by CVS.
756 # Note on inclusions: depending of the target, the dependancies files must
757 # or must not be included. The problem is that if we ask make to include a file,
758 # and this file does not exist, it is made before it can be included. In a
759 # general way, a .d file should be included if and only if the corresponding .o
760 # needs to be re-made.
762 # Two makefiles are used: the main one (this one) has regular generic rules,
763 # except for .o files, for which it calls the object Makefile. Dependancies
764 # are not included in this file.
765 # The object Makefile known how to make a .o from a .c, and includes
766 # dependancies for the target, but only those required.