#
include ../config.mak
-# NOTE: -I.. is needed to include config.h
-CFLAGS=$(OPTFLAGS) -DHAVE_AV_CONFIG_H -I.. -I$(SRC_PATH)/libavutil \
+CFLAGS=-DHAVE_AV_CONFIG_H -I$(BUILD_ROOT) -I$(SRC_PATH)/libavutil $(OPTFLAGS) \
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE $(AMR_CFLAGS)
-OBJS= bitstream.o utils.o allcodecs.o \
- mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o\
- mjpeg.o resample.o resample2.o dsputil.o \
- motion_est.o imgconvert.o \
- mpeg12.o mpegaudiodec.o simple_idct.o \
- ratecontrol.o eval.o error_resilience.o \
- fft.o mdct.o raw.o golomb.o cabac.o\
- faandct.o parser.o \
- vp3dsp.o h264idct.o rangecoder.o pnm.o h263.o msmpeg4.o h263dec.o \
+OBJS= bitstream.o \
+ utils.o \
+ allcodecs.o \
+ mpegvideo.o \
+ jrevdct.o \
+ jfdctfst.o \
+ jfdctint.o\
+ mjpeg.o \
+ resample.o \
+ resample2.o \
+ dsputil.o \
+ motion_est.o \
+ imgconvert.o \
+ mpeg12.o \
+ mpegaudiodec.o \
+ simple_idct.o \
+ ratecontrol.o \
+ eval.o \
+ error_resilience.o \
+ fft.o \
+ mdct.o \
+ raw.o \
+ golomb.o \
+ cabac.o\
+ faandct.o \
+ parser.o \
+ vp3dsp.o \
+ h264idct.o \
+ rangecoder.o \
+ pnm.o \
+ h263.o \
+ msmpeg4.o \
+ h263dec.o \
opt.o \
bitstream_filter.o \
+ audioconvert.o \
-HEADERS = avcodec.h
+HEADERS = avcodec.h opt.h
ifneq ($(CONFIG_SWSCALER),yes)
HEADERS += swscale.h
endif
OBJS-$(CONFIG_VCR1_ENCODER) += vcr1.o
OBJS-$(CONFIG_VMDAUDIO_DECODER) += vmdav.o
OBJS-$(CONFIG_VMDVIDEO_DECODER) += vmdav.o
-OBJS-$(CONFIG_VORBIS_DECODER) += vorbis.o
+OBJS-$(CONFIG_VMNC_DECODER) += vmnc.o
+OBJS-$(CONFIG_VORBIS_DECODER) += vorbis.o vorbis_data.o
+OBJS-$(CONFIG_VORBIS_ENCODER) += vorbis_enc.o vorbis_data.o
OBJS-$(CONFIG_VP3_DECODER) += vp3.o
+OBJS-$(CONFIG_VP5_DECODER) += vp5.o vp56.o vp56data.o
+OBJS-$(CONFIG_VP6_DECODER) += vp6.o vp56.o vp56data.o
OBJS-$(CONFIG_VQA_DECODER) += vqavideo.o
+OBJS-$(CONFIG_WAVPACK_DECODER) += wavpack.o
OBJS-$(CONFIG_WMAV1_DECODER) += wmadec.o
OBJS-$(CONFIG_WMAV2_DECODER) += wmadec.o
OBJS-$(CONFIG_WMV3_DECODER) += vc1.o
# i386 mmx specific stuff
ifeq ($(TARGET_MMX),yes)
-OBJS += i386/fdct_mmx.o i386/cputest.o \
- i386/dsputil_mmx.o i386/mpegvideo_mmx.o \
- i386/idct_mmx.o i386/motion_est_mmx.o \
- i386/simple_idct_mmx.o i386/fft_sse.o i386/vp3dsp_mmx.o \
- i386/vp3dsp_sse2.o i386/fft_3dn.o i386/fft_3dn2.o i386/snowdsp_mmx.o
+OBJS += i386/fdct_mmx.o \
+ i386/cputest.o \
+ i386/dsputil_mmx.o \
+ i386/mpegvideo_mmx.o \
+ i386/motion_est_mmx.o \
+ i386/simple_idct_mmx.o \
+ i386/idct_mmx_xvid.o \
+ i386/fft_sse.o \
+ i386/vp3dsp_mmx.o \
+ i386/vp3dsp_sse2.o \
+ i386/fft_3dn.o \
+ i386/fft_3dn2.o \
+ i386/snowdsp_mmx.o \
+
ifeq ($(CONFIG_GPL),yes)
-OBJS += i386/idct_mmx_xvid.o
+OBJS += i386/idct_mmx.o
endif
ifeq ($(CONFIG_CAVS_DECODER),yes)
OBJS += i386/cavsdsp_mmx.o
# armv4l specific stuff
ASM_OBJS-$(TARGET_ARCH_ARMV4L) += armv4l/jrevdct_arm.o \
armv4l/simple_idct_arm.o \
- armv4l/dsputil_arm_s.o
+ armv4l/dsputil_arm_s.o \
+
OBJS-$(TARGET_ARCH_ARMV4L) += armv4l/dsputil_arm.o \
- armv4l/mpegvideo_arm.o
+ armv4l/mpegvideo_arm.o \
+
OBJS-$(TARGET_IWMMXT) += armv4l/dsputil_iwmmxt.o \
- armv4l/mpegvideo_iwmmxt.o
+ armv4l/mpegvideo_iwmmxt.o \
+
+ASM_OBJS-$(TARGET_ARMV5TE) += armv4l/simple_idct_armv5te.o \
# sun sparc
-OBJS-$(TARGET_ARCH_SPARC) += sparc/dsputil_vis.o
+OBJS-$(TARGET_ARCH_SPARC) += sparc/dsputil_vis.o \
+
sparc/dsputil_vis.o: CFLAGS += -mcpu=ultrasparc -mtune=ultrasparc
# sun mediaLib specific stuff
-OBJS-$(HAVE_MLIB) += mlib/dsputil_mlib.o
+OBJS-$(HAVE_MLIB) += mlib/dsputil_mlib.o \
# alpha specific stuff
OBJS-$(TARGET_ARCH_ALPHA) += alpha/dsputil_alpha.o \
alpha/mpegvideo_alpha.o \
alpha/simple_idct_alpha.o \
- alpha/motion_est_alpha.o
+ alpha/motion_est_alpha.o \
+
ASM_OBJS-$(TARGET_ARCH_ALPHA) += alpha/dsputil_alpha_asm.o \
- alpha/motion_est_mvi_asm.o
+ alpha/motion_est_mvi_asm.o \
+
+OBJS-$(TARGET_ARCH_POWERPC) += ppc/dsputil_ppc.o \
+ ppc/mpegvideo_ppc.o \
-OBJS-$(TARGET_ARCH_POWERPC) += ppc/dsputil_ppc.o ppc/mpegvideo_ppc.o
OBJS-$(TARGET_MMI) += ps2/dsputil_mmi.o \
ps2/idct_mmi.o \
- ps2/mpegvideo_mmi.o
+ ps2/mpegvideo_mmi.o \
+
OBJS-$(TARGET_ARCH_SH4) += sh4/idct_sh4.o \
sh4/dsputil_sh4.o \
- sh4/dsputil_align.o
+ sh4/dsputil_align.o \
+
OBJS-$(TARGET_ALTIVEC) += ppc/dsputil_altivec.o \
ppc/mpegvideo_altivec.o \
ppc/idct_altivec.o \
ppc/fft_altivec.o \
ppc/gmc_altivec.o \
ppc/fdct_altivec.o \
- ppc/h264_altivec.o \
- ppc/snow_altivec.o \
- ppc/vc1dsp_altivec.o
+ ppc/h264_altivec.o \
+ ppc/snow_altivec.o \
+ ppc/vc1dsp_altivec.o \
+ ppc/float_altivec.o \
+
+OBJS-$(TARGET_ARCH_BFIN) += bfin/dsputil_bfin.o \
CFLAGS += $(CFLAGS-yes)
OBJS += $(OBJS-yes)
ASM_OBJS += $(ASM_OBJS-yes)
-EXTRALIBS := -L../libavutil -lavutil$(BUILDSUF) $(EXTRALIBS)
-
NAME=avcodec
-LIBAVUTIL= $(SRC_PATH)/libavutil/$(LIBPREF)avutil$(LIBSUF)
ifeq ($(BUILD_SHARED),yes)
LIBVERSION=$(LAVCVERSION)
LIBMAJOR=$(LAVCMAJOR)
endif
-TESTS= imgresample-test dct-test motion-test fft-test
+TESTS= cpuid_test imgresample-test dct-test motion-test fft-test
include $(SRC_PATH)/common.mak
amrlibs:
$(MAKE) -C amr spclib fipoplib
-tests: apiexample cpuid_test $(TESTS)
-
-dsputil.o: dsputil.c dsputil.h
+tests: apiexample $(TESTS)
clean::
rm -f \
-$(MAKE) -C amr clean
-$(MAKE) -C amrwb_float -f makefile.gcc clean
-# api example program
-apiexample: apiexample.c $(LIB)
- $(CC) $(CFLAGS) -o $@ $< $(LIB) $(LIBAVUTIL) $(EXTRALIBS)
+apiexample: apiexample.o $(LIB)
-# cpuid test
cpuid_test: i386/cputest.c
$(CC) $(CFLAGS) -D__TEST__ -o $@ $<
-# testing progs
-
-imgresample-test: imgresample.c
- $(CC) $(CFLAGS) -DTEST -o $@ $^ -lm
+imgresample-test: imgresample.c $(LIB)
+ $(CC) $(CFLAGS) -DTEST -o $@ $^ $(EXTRALIBS)
dct-test: dct-test.o fdctref.o $(LIB)
- $(CC) -o $@ $^ -lm $(LIBAVUTIL)
motion-test: motion_test.o $(LIB)
- $(CC) -o $@ $^ -lm
fft-test: fft-test.o $(LIB)
- $(CC) -o $@ $^ $(LIBAVUTIL) -lm
+
+.PHONY: amrlibs tests