diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-07-08 01:05:28 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-07-08 01:05:28 +0200 |
commit | 5d1b39f7e7381a2e837b9b6d43dede7de528da3c (patch) | |
tree | 5d0f96c4324c637d436e1aaf2f45aee1eb9f99b6 | |
parent | ebd1edf36c81155e2817edaa056b0bc9eb21e8f5 (diff) | |
parent | 2f138f0b7c36fe50b51e0d74bc913d14aea00c5e (diff) | |
download | ffmpeg-5d1b39f7e7381a2e837b9b6d43dede7de528da3c.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
build: clean up library installation rules
vf_drawtext: Remove some write-only variables.
libgsm: Drop const qualifier to silence compiler warning.
docs: Remove needless configure options
docs: Don't recommend adding --enable-memalign-hack
libvo-amrwbenc: Add braces to shut up gcc warning.
adts: Fix PCE copying.
Conflicts:
configure
doc/general.texi
subdir.mak
Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rwxr-xr-x | configure | 22 | ||||
-rw-r--r-- | doc/general.texi | 4 | ||||
-rw-r--r-- | libavcodec/libgsm.c | 2 | ||||
-rw-r--r-- | libavcodec/libvo-amrwbenc.c | 2 | ||||
-rw-r--r-- | libavfilter/vf_drawtext.c | 17 | ||||
-rw-r--r-- | libavformat/adtsenc.c | 4 | ||||
-rw-r--r-- | subdir.mak | 16 |
7 files changed, 30 insertions, 37 deletions
@@ -1690,6 +1690,8 @@ SLIBNAME='$(SLIBPREF)$(FULLNAME)$(SLIBSUF)' SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBVERSION)' SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)' LIB_INSTALL_EXTRA_CMD='$$(RANLIB) "$(LIBDIR)/$(LIBNAME)"' +SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)' +SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR) $(SLIBNAME)' AS_O='-o $@' CC_O='-o $@' @@ -2455,12 +2457,11 @@ case $target_os in SLIBSUF=".dll" SLIBNAME_WITH_VERSION='$(SLIBPREF)$(FULLNAME)-$(LIBVERSION)$(SLIBSUF)' SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME)-$(LIBMAJOR)$(SLIBSUF)' - SLIB_EXTRA_CMD='-lib.exe /machine:$(LIBTARGET) /def:$$(@:$(SLIBSUF)=.def) /out:$(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib)' - SLIB_INSTALL_EXTRA_CMD='-install -m 644 $(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib) "$(SHLIBDIR)/$(SLIBNAME:$(SLIBSUF)=.lib)"; \ - install -m 644 $(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib) "$(SHLIBDIR)/$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib)"; \ - install -d "$(LIBDIR)"; \ - install -m 644 $(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) "$(LIBDIR)/lib$(SLIBNAME:$(SLIBSUF)=.dll.a)"' - SLIB_UNINSTALL_EXTRA_CMD='rm -f "$(SHLIBDIR)/$(SLIBNAME:$(SLIBSUF)=.lib)"' + SLIB_EXTRA_CMD='-lib.exe /machine:$(LIBTARGET) /def:$$(@:$(SLIBSUF)=.def) /out:$(SUBDIR)$(SLIBNAME:$(SLIBSUF)=.lib)' + SLIB_INSTALL_NAME='$(SLIBNAME_WITH_MAJOR)' + SLIB_INSTALL_LINKS= + SLIB_INSTALL_EXTRA_SHLIB='$(SLIBNAME:$(SLIBSUF)=.lib)' + SLIB_INSTALL_EXTRA_LIB='lib$(SLIBNAME:$(SLIBSUF)=.dll.a) $(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.def)' SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.def) -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base' objformat="win32" enable dos_paths @@ -2518,8 +2519,7 @@ case $target_os in emxexp -o $(OBJS) >> $(SUBDIR)$(NAME).def' SLIB_EXTRA_CMD='emximp -o $(SUBDIR)$(LIBPREF)$(NAME)_dll.a $(SUBDIR)$(NAME).def; \ emximp -o $(SUBDIR)$(LIBPREF)$(NAME)_dll.lib $(SUBDIR)$(NAME).def;' - SLIB_INSTALL_EXTRA_CMD='install -m 644 $(SUBDIR)$(LIBPREF)$(NAME)_dll.a $(SUBDIR)$(LIBPREF)$(NAME)_dll.lib "$(LIBDIR)"' - SLIB_UNINSTALL_EXTRA_CMD='rm -f "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.a "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.lib' + SLIB_INSTALL_EXTRA_LIB='$(LIBPREF)$(NAME)_dll.a $(LIBPREF)$(NAME)_dll.lib' enable dos_paths ;; gnu/kfreebsd) @@ -3324,8 +3324,10 @@ SLIBNAME_WITH_VERSION=${SLIBNAME_WITH_VERSION} SLIBNAME_WITH_MAJOR=${SLIBNAME_WITH_MAJOR} SLIB_CREATE_DEF_CMD=${SLIB_CREATE_DEF_CMD} SLIB_EXTRA_CMD=${SLIB_EXTRA_CMD} -SLIB_INSTALL_EXTRA_CMD=${SLIB_INSTALL_EXTRA_CMD} -SLIB_UNINSTALL_EXTRA_CMD=${SLIB_UNINSTALL_EXTRA_CMD} +SLIB_INSTALL_NAME=${SLIB_INSTALL_NAME} +SLIB_INSTALL_LINKS=${SLIB_INSTALL_LINKS} +SLIB_INSTALL_EXTRA_LIB=${SLIB_INSTALL_EXTRA_LIB} +SLIB_INSTALL_EXTRA_SHLIB=${SLIB_INSTALL_EXTRA_SHLIB} SAMPLES:=${samples:-\$(FATE_SAMPLES)} EOF diff --git a/doc/general.texi b/doc/general.texi index 8e3d4af706..f2f8ed4631 100644 --- a/doc/general.texi +++ b/doc/general.texi @@ -1037,7 +1037,7 @@ diffutils Then run @example -./configure --enable-static --disable-shared +./configure @end example to make a static build. @@ -1084,7 +1084,7 @@ and add some special flags to your configure invocation. For a static build run @example -./configure --target-os=mingw32 --enable-static --disable-shared --extra-cflags=-mno-cygwin --extra-libs=-mno-cygwin +./configure --target-os=mingw32 --extra-cflags=-mno-cygwin --extra-libs=-mno-cygwin @end example and for a build with shared libraries diff --git a/libavcodec/libgsm.c b/libavcodec/libgsm.c index 1f76f82d55..45cb256fcf 100644 --- a/libavcodec/libgsm.c +++ b/libavcodec/libgsm.c @@ -139,7 +139,7 @@ AVCodec ff_libgsm_ms_encoder = { static int libgsm_decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt) { - const uint8_t *buf = avpkt->data; + uint8_t *buf = avpkt->data; int buf_size = avpkt->size; *data_size = 0; /* In case of error */ if(buf_size < avctx->block_align) return -1; diff --git a/libavcodec/libvo-amrwbenc.c b/libavcodec/libvo-amrwbenc.c index ec23aeb7f8..31964e66c3 100644 --- a/libavcodec/libvo-amrwbenc.c +++ b/libavcodec/libvo-amrwbenc.c @@ -34,7 +34,7 @@ typedef struct AMRWBContext { } AMRWBContext; static const AVOption options[] = { - { "dtx", "Allow DTX (generate comfort noise)", offsetof(AMRWBContext, allow_dtx), FF_OPT_TYPE_INT, 0, 0, 1, AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_ENCODING_PARAM }, + { "dtx", "Allow DTX (generate comfort noise)", offsetof(AMRWBContext, allow_dtx), FF_OPT_TYPE_INT, { 0 }, 0, 1, AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_ENCODING_PARAM }, { NULL } }; diff --git a/libavfilter/vf_drawtext.c b/libavfilter/vf_drawtext.c index f495f68424..7d8372b886 100644 --- a/libavfilter/vf_drawtext.c +++ b/libavfilter/vf_drawtext.c @@ -424,15 +424,10 @@ static inline int draw_glyph_yuv(AVFilterBufferRef *picref, FT_Bitmap *bitmap, u { int r, c, alpha; unsigned int luma_pos, chroma_pos1, chroma_pos2; - uint8_t src_val, dst_pixel[4]; + uint8_t src_val; for (r = 0; r < bitmap->rows && r+y < height; r++) { for (c = 0; c < bitmap->width && c+x < width; c++) { - /* get pixel in the picref (destination) */ - dst_pixel[0] = picref->data[0][ c+x + (y+r) * picref->linesize[0]]; - dst_pixel[1] = picref->data[1][((c+x) >> hsub) + ((y+r) >> vsub) * picref->linesize[1]]; - dst_pixel[2] = picref->data[2][((c+x) >> hsub) + ((y+r) >> vsub) * picref->linesize[2]]; - /* get intensity value in the glyph bitmap (source) */ src_val = GET_BITMAP_VAL(r, c); if (!src_val) @@ -460,18 +455,10 @@ static inline int draw_glyph_rgb(AVFilterBufferRef *picref, FT_Bitmap *bitmap, { int r, c, alpha; uint8_t *p; - uint8_t src_val, dst_pixel[4]; + uint8_t src_val; for (r = 0; r < bitmap->rows && r+y < height; r++) { for (c = 0; c < bitmap->width && c+x < width; c++) { - /* get pixel in the picref (destination) */ - dst_pixel[0] = picref->data[0][(c+x + rgba_map[0]) * pixel_step + - (y+r) * picref->linesize[0]]; - dst_pixel[1] = picref->data[0][(c+x + rgba_map[1]) * pixel_step + - (y+r) * picref->linesize[0]]; - dst_pixel[2] = picref->data[0][(c+x + rgba_map[2]) * pixel_step + - (y+r) * picref->linesize[0]]; - /* get intensity value in the glyph bitmap (source) */ src_val = GET_BITMAP_VAL(r, c); if (!src_val) diff --git a/libavformat/adtsenc.c b/libavformat/adtsenc.c index a03e128d96..43e719b5ea 100644 --- a/libavformat/adtsenc.c +++ b/libavformat/adtsenc.c @@ -59,6 +59,10 @@ int ff_adts_decode_extradata(AVFormatContext *s, ADTSContext *adts, uint8_t *buf av_log(s, AV_LOG_ERROR, "Scalable configurations are not allowed in ADTS\n"); return -1; } + if (get_bits(&gb, 1)) { + av_log(s, AV_LOG_ERROR, "Extension flag is not allowed in ADTS\n"); + return -1; + } if (!adts->channel_conf) { init_put_bits(&pb, adts->pce_data, MAX_PCE_SIZE); diff --git a/subdir.mak b/subdir.mak index e49eb0fd63..6adc305b50 100644 --- a/subdir.mak +++ b/subdir.mak @@ -60,13 +60,12 @@ distclean:: clean install-lib$(NAME)-shared: $(SUBDIR)$(SLIBNAME) $(Q)mkdir -p "$(SHLIBDIR)" - $$(INSTALL) -m 755 $$< "$(SHLIBDIR)/$(SLIBNAME_WITH_VERSION)" - $$(STRIP) "$(SHLIBDIR)/$(SLIBNAME_WITH_VERSION)" - $(Q)cd "$(SHLIBDIR)" && \ - $(LN_S) $(SLIBNAME_WITH_VERSION) $(SLIBNAME_WITH_MAJOR) - $(Q)cd "$(SHLIBDIR)" && \ - $(LN_S) $(SLIBNAME_WITH_VERSION) $(SLIBNAME) - $(SLIB_INSTALL_EXTRA_CMD) + $$(INSTALL) -m 755 $$< "$(SHLIBDIR)/$(SLIB_INSTALL_NAME)" + $$(STRIP) "$(SHLIBDIR)/$(SLIB_INSTALL_NAME)" + $(Q)$(foreach F,$(SLIB_INSTALL_LINKS),cd "$(SHLIBDIR)" && $(LN_S) $(SLIB_INSTALL_NAME) $(F);) + $(if $(SLIB_INSTALL_EXTRA_SHLIB),$$(INSTALL) -m 644 $(SLIB_INSTALL_EXTRA_SHLIB:%=$(SUBDIR)%) "$(SHLIBDIR)") + $(if $(SLIB_INSTALL_EXTRA_LIB),$(Q)mkdir -p "$(LIBDIR)") + $(if $(SLIB_INSTALL_EXTRA_LIB),$$(INSTALL) -m 644 $(SLIB_INSTALL_EXTRA_LIB:%=$(SUBDIR)%) "$(LIBDIR)") install-lib$(NAME)-static: $(SUBDIR)$(LIBNAME) $(Q)mkdir -p "$(LIBDIR)" @@ -85,7 +84,8 @@ uninstall-libs:: -$(RM) "$(SHLIBDIR)/$(SLIBNAME_WITH_MAJOR)" \ "$(SHLIBDIR)/$(SLIBNAME)" \ "$(SHLIBDIR)/$(SLIBNAME_WITH_VERSION)" - -$(SLIB_UNINSTALL_EXTRA_CMD) + -$(RM) $(SLIB_INSTALL_EXTRA_SHLIB:%="$(SHLIBDIR)"%) + -$(RM) $(SLIB_INSTALL_EXTRA_LIB:%="$(LIBDIR)"%) -$(RM) "$(LIBDIR)/$(LIBNAME)" uninstall-headers:: |