[PATCH] TOOLS: Makefile instead of c (was: Re: [MPlayer-dev-eng] documentation of TOOLS directory)

Diego Biurrun diego at biurrun.de
Tue Aug 3 03:28:07 CEST 2004


Shachar Raindel writes:
> On Mon, 2 Aug 2004 22:43:31 +0200 (CEST), VMiklos <mamajom at axelero.hu> wrote:
> > On Sat, 31 Jul 2004, VMiklos wrote:
> > 
> > > On Fri, 30 Jul 2004, VMiklos wrote:
> > >
> > > > > I guess this would be better handled by a Makefile.  Any volunteers?
> > > > ok, i'll write one
> > >
> > > here it is
> > 
> > any comments on this patch?
> 
> I am just a sick, idiotic programmer, but don't you want to have a
> different target for each of the files, makeing all build only these
> which were changed (the way makefiles should be used), instead of
> making all of them rebuilt whenever the developer type make?

Would something like the following be more to your taste?

Diego


all: asfinfo avi-fix bios2dump cpuinfo dump_mp4 mem2dump movinfo png2raw

asfinfo:
	gcc asfinfo.c   -o asfinfo

avi-fix:
	gcc avi-fix.c   -o avi-fix

bios2dump:
	gcc bios2dump.c -o bios2dump

cpuinfo:
	gcc cpuinfo.c   -o cpuinfo

dump_mp4:
	gcc dump_mp4.c  -o dump_mp4

mem2dump:
	gcc mem2dump.c  -o mem2dump

movinfo:
	gcc movinfo.c   -o movinfo

png2raw:
	gcc png2raw.c   -o png2raw -lpng

subrip:
	gcc subrip.c    -o subrip -I.. -l/usr/src/mplayer/main/vobsub.o

vivodump:
	gcc vivodump.c  -o vivodump -I.. ../libmpdemux/muxer.o

fastmemcpybench:
	gcc -g ../libvo/aclib.o -DNAME=\"mmx\"      -DHAVE_MMX fastmemcpybench.c -o fastmem-mmx
	gcc -g ../libvo/aclib.o -DNAME=\"k6\ \"     -DHAVE_3DNOW -DHAVE_MMX fastmemcpybench.c -o fastmem-k6
	gcc -g ../libvo/aclib.o -DNAME=\"k7\ \"     -DHAVE_MMX2  -DHAVE_3DNOW -DHAVE_MMX fastmemcpybench.c -o fastmem-k7
	gcc -g ../libvo/aclib.o -DNAME=\"sse\"      -DHAVE_MMX2  -DHAVE_SSE -DHAVE_MMX fastmemcpybench.c -o fastmem-sse
	gcc -g ../libvo/aclib.o -DNAME=\"mga-mmx\"  -DHAVE_MGA   -DHAVE_MMX fastmemcpybench.c -o fastmem2-mmx
	gcc -g ../libvo/aclib.o -DNAME=\"mga-k6\ \" -DHAVE_MGA   -DHAVE_3DNOW -DHAVE_MMX fastmemcpybench.c -o fastmem2-k6
	gcc -g ../libvo/aclib.o -DNAME=\"mga-k7\ \" -DHAVE_MGA   -DHAVE_MMX2 -DHAVE_3DNOW -DHAVE_MMX fastmemcpybench.c -o fastmem2-k7
	gcc -g ../libvo/aclib.o -DNAME=\"mga-sse\"  -DHAVE_MGA   -DHAVE_MMX2 -DHAVE_SSE -DHAVE_MMX fastmemcpybench.c -o fastmem2-sse

clean:
	rm -f asfinfo avi-fix bios2dump cpuinfo dump_mp4 mem2dump movinfo png2raw subrip vivodump
	rm -f fastmem-mmx fastmem-k6 fastmem-k7 fastmem-sse fastmem2-mmx fastmem2-k6 fastmem2-k7 fastmem2-sse




More information about the MPlayer-dev-eng mailing list