comparison Makefile @ 2817:b128802eb77b libavcodec

libavutil: Utility code from libavcodec moved to a separate library.
author al
date Mon, 01 Aug 2005 20:07:05 +0000
parents 95c35706acbb
children dae9760d1f12
comparison
equal deleted inserted replaced
2816:c6ab4b91a5c5 2817:b128802eb77b
5 include ../config.mak 5 include ../config.mak
6 6
7 VPATH=$(SRC_PATH)/libavcodec 7 VPATH=$(SRC_PATH)/libavcodec
8 8
9 # NOTE: -I.. is needed to include config.h 9 # NOTE: -I.. is needed to include config.h
10 CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE $(AMR_CFLAGS) 10 CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -I$(SRC_PATH)/libavutil -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE $(AMR_CFLAGS)
11 11
12 OBJS= bitstream.o utils.o mem.o allcodecs.o \ 12 OBJS= bitstream.o utils.o mem.o allcodecs.o \
13 mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o\ 13 mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o\
14 mpegaudio.o ac3enc.o mjpeg.o resample.o resample2.o dsputil.o \ 14 mpegaudio.o ac3enc.o mjpeg.o resample.o resample2.o dsputil.o \
15 motion_est.o imgconvert.o imgresample.o \ 15 motion_est.o imgconvert.o imgresample.o \
16 mpeg12.o mpegaudiodec.o pcm.o simple_idct.o \ 16 mpeg12.o mpegaudiodec.o pcm.o simple_idct.o \
17 ratecontrol.o adpcm.o eval.o error_resilience.o \ 17 ratecontrol.o adpcm.o eval.o error_resilience.o \
18 fft.o mdct.o raw.o golomb.o cabac.o\ 18 fft.o mdct.o raw.o golomb.o cabac.o\
19 dpcm.o adx.o rational.o faandct.o parser.o g726.o \ 19 dpcm.o adx.o faandct.o parser.o g726.o \
20 vp3dsp.o integer.o h264idct.o rangecoder.o pnm.o h263.o msmpeg4.o h263dec.o dvdsub.o dvbsub.o dvbsubdec.o 20 vp3dsp.o h264idct.o rangecoder.o pnm.o h263.o msmpeg4.o h263dec.o dvdsub.o dvbsub.o dvbsubdec.o
21 21
22 ifeq ($(CONFIG_AASC_DECODER),yes) 22 ifeq ($(CONFIG_AASC_DECODER),yes)
23 OBJS+= aasc.o 23 OBJS+= aasc.o
24 endif 24 endif
25 ifeq ($(CONFIG_ALAC_DECODER),yes) 25 ifeq ($(CONFIG_ALAC_DECODER),yes)
232 OBJS+= liba52/bit_allocate.o liba52/bitstream.o liba52/downmix.o \ 232 OBJS+= liba52/bit_allocate.o liba52/bitstream.o liba52/downmix.o \
233 liba52/imdct.o liba52/parse.o liba52/crc.o liba52/resample.o 233 liba52/imdct.o liba52/parse.o liba52/crc.o liba52/resample.o
234 endif 234 endif
235 endif 235 endif
236 236
237 EXTRALIBS += -L$(SRC_PATH)/libavutil -lavutil$(BUILDSUF)
238
237 # currently using libdts for dts decoding 239 # currently using libdts for dts decoding
238 ifeq ($(CONFIG_DTS),yes) 240 ifeq ($(CONFIG_DTS),yes)
239 OBJS+= dtsdec.o 241 OBJS+= dtsdec.o
240 CFLAGS += $(DTS_INC) 242 CFLAGS += $(DTS_INC)
241 EXTRALIBS += -ldts 243 EXTRALIBS += -ldts
373 375
374 SRCS := $(OBJS:.o=.c) $(ASM_OBJS:.o=.S) 376 SRCS := $(OBJS:.o=.c) $(ASM_OBJS:.o=.S)
375 OBJS := $(OBJS) $(ASM_OBJS) 377 OBJS := $(OBJS) $(ASM_OBJS)
376 378
377 LIB= $(LIBPREF)avcodec$(LIBSUF) 379 LIB= $(LIBPREF)avcodec$(LIBSUF)
380 LIBAVUTIL= $(SRC_PATH)/libavutil/$(LIBPREF)avutil$(LIBSUF)
378 ifeq ($(BUILD_SHARED),yes) 381 ifeq ($(BUILD_SHARED),yes)
379 SLIB= $(SLIBPREF)avcodec$(SLIBSUF) 382 SLIB= $(SLIBPREF)avcodec$(SLIBSUF)
380 endif 383 endif
381 TESTS= imgresample-test dct-test motion-test fft-test 384 TESTS= imgresample-test dct-test motion-test fft-test
382 385
444 cleanamrwbfloat: 447 cleanamrwbfloat:
445 $(MAKE) -C amrwb_float -f makefile.gcc clean 448 $(MAKE) -C amrwb_float -f makefile.gcc clean
446 449
447 # api example program 450 # api example program
448 apiexample: apiexample.c $(LIB) 451 apiexample: apiexample.c $(LIB)
449 $(CC) $(CFLAGS) -o $@ $< $(LIB) $(EXTRALIBS) -lm 452 $(CC) $(CFLAGS) -o $@ $< $(LIB) $(LIBAVUTIL) $(EXTRALIBS) -lm
450 453
451 # cpuid test 454 # cpuid test
452 cpuid_test: i386/cputest.c 455 cpuid_test: i386/cputest.c
453 $(CC) $(CFLAGS) -D__TEST__ -o $@ $< 456 $(CC) $(CFLAGS) -D__TEST__ -o $@ $<
454 457
462 465
463 motion-test: motion_test.o $(LIB) 466 motion-test: motion_test.o $(LIB)
464 $(CC) -o $@ $^ -lm 467 $(CC) -o $@ $^ -lm
465 468
466 fft-test: fft-test.o $(LIB) 469 fft-test: fft-test.o $(LIB)
467 $(CC) -o $@ $^ -lm 470 $(CC) -o $@ $^ $(LIBAVUTIL) -lm
468 471
469 ifeq ($(BUILD_SHARED),yes) 472 ifeq ($(BUILD_SHARED),yes)
470 install: all install-headers 473 install: all install-headers
471 ifeq ($(CONFIG_WIN32),yes) 474 ifeq ($(CONFIG_WIN32),yes)
472 install $(INSTALLSTRIP) -m 755 $(SLIB) "$(prefix)" 475 install $(INSTALLSTRIP) -m 755 $(SLIB) "$(prefix)"
487 install -m 644 $(LIB) "$(libdir)" 490 install -m 644 $(LIB) "$(libdir)"
488 491
489 install-headers: 492 install-headers:
490 mkdir -p "$(prefix)/include/ffmpeg" 493 mkdir -p "$(prefix)/include/ffmpeg"
491 install -m 644 $(SRC_PATH)/libavcodec/avcodec.h \ 494 install -m 644 $(SRC_PATH)/libavcodec/avcodec.h \
492 $(SRC_PATH)/libavcodec/common.h \
493 $(SRC_PATH)/libavcodec/rational.h \
494 "$(prefix)/include/ffmpeg" 495 "$(prefix)/include/ffmpeg"
495 install -d $(libdir)/pkgconfig 496 install -d $(libdir)/pkgconfig
496 install -m 644 ../libavcodec.pc $(libdir)/pkgconfig 497 install -m 644 ../libavcodec.pc $(libdir)/pkgconfig
497 498
498 # 499 #