android-vlc 精簡

來源:互聯網
上載者:User

首先精簡ffmpeg rules.mak

改為:

# FFmpegHASH=HEAD#FFMPEG_SNAPURL := http://git.videolan.org/?p=ffmpeg.git;a=snapshot;h=$(HASH);sf=tgzFFMPEG_SNAPURL := http://git.libav.org/?p=libav.git;a=snapshot;h=$(HASH);sf=tgzFFMPEGCONF = \--cc="$(CC)" \--disable-doc \--enable-libgsm \--enable-libopenjpeg \--disable-debug \--disable-avdevice \--disable-devices \--disable-avfilter \--disable-filters \--disable-bsfs \--disable-bzlib# Those tools are named differently in FFmpeg and Libav#--disable-ffserver \#--disable-ffplay \#--disable-ffprobeDEPS_ffmpeg = zlib gsm openjpeg# Optional dependenciesifdef BUILD_ENCODERSFFMPEGCONF += --enable-libmp3lame --enable-libvpx --disable-decoder=libvpx --disable-decoder=libvpx_vp8 --disable-decoder=libvpx_vp9DEPS_ffmpeg += lame $(DEPS_lame) vpx $(DEPS_vpx)elseFFMPEGCONF += --disable-encoders --enable-encoder=pngFFMPEGCONF += --disable-decoders --enable-decoder=h264 FFMPEGCONF += --disable-muxersFFMPEGCONF += --disable-demuxers --enable-demuxer=rtp --enable-demuxer=rtspFFMPEGCONF += --disable-protocols --enable-protocol=rtp --enable-protocol=rtspFFMPEGCONF += --disable-parsers --enable-parser=h264 --enable-parser=mpeg4video endif# Small sizeifdef ENABLE_SMALLFFMPEGCONF += --enable-smallifeq ($(ARCH),arm)ifdef HAVE_ARMV7AFFMPEGCONF += --enable-thumbendifendifendififdef HAVE_CROSS_COMPILEFFMPEGCONF += --enable-cross-compileifndef HAVE_IOSFFMPEGCONF += --cross-prefix=$(HOST)-endifendif# ARM stuffifeq ($(ARCH),arm)FFMPEGCONF += --arch=armifdef HAVE_NEONFFMPEGCONF += --enable-neonendififdef HAVE_ARMV7AFFMPEGCONF += --cpu=cortex-a8endifendif# MIPS stuffifeq ($(ARCH),mipsel)FFMPEGCONF += --arch=mipsendif# x86 stuffifeq ($(ARCH),i386)ifndef HAVE_DARWIN_OSFFMPEGCONF += --arch=x86endifendif# Darwinifdef HAVE_DARWIN_OSFFMPEGCONF += --arch=$(ARCH) --target-os=darwinifneq ($(findstring $(ARCH),i386 x86_64),)FFMPEGCONF += --enable-memalign-hackendififeq ($(ARCH),x86_64)FFMPEGCONF += --cpu=core2endifendififdef HAVE_IOSifeq ($(ARCH),arm)FFMPEGCONF += --enable-pic --as="$(AS)"endifendif# Linuxifdef HAVE_LINUXFFMPEGCONF += --target-os=linux --enable-picendif# Windowsifdef HAVE_WIN32ifndef HAVE_MINGW_W64DEPS_ffmpeg += directxendifFFMPEGCONF += --target-os=mingw32 --enable-memalign-hackFFMPEGCONF += --enable-w32threads --enable-dxva2 \--disable-decoder=dcaifdef HAVE_WIN64FFMPEGCONF += --cpu=athlon64 --arch=x86_64else # !WIN64FFMPEGCONF+= --cpu=i686 --arch=x86endifelse # !WindowsFFMPEGCONF += --enable-pthreadsendif# BuildPKGS += ffmpegifeq ($(call need_pkg,"libavcodec >= 52.25.0 libavformat >= 52.30.0 libswscale"),)PKGS_FOUND += ffmpegendif$(TARBALLS)/ffmpeg-$(HASH).tar.gz:$(call download,$(FFMPEG_SNAPURL)).sum-ffmpeg: $(TARBALLS)/ffmpeg-$(HASH).tar.gz$(warning Not implemented.)touch $@ffmpeg: ffmpeg-$(HASH).tar.gz .sum-ffmpegrm -Rf $@ $@-$(HASH)mkdir -p $@-$(HASH)$(ZCAT) "$<" | (cd $@-$(HASH) && tar xv --strip-components=1)$(MOVE).ffmpeg: ffmpegcd $< && $(HOSTVARS) ./configure \--extra-ldflags="$(LDFLAGS)" $(FFMPEGCONF) \--prefix="$(PREFIX)" --enable-static --disable-sharedcd $< && $(MAKE) install-libs install-headerstouch $@

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.