mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-04 14:08:51 +02:00
Merge all changes from trunk
This commit is contained in:
27
media-video/ffmpeg/ffmpeg-0.10.2-vlc.bep
Normal file
27
media-video/ffmpeg/ffmpeg-0.10.2-vlc.bep
Normal file
@@ -0,0 +1,27 @@
|
||||
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert and stream audio and video. It includes libavcodec - the leading audio/video codec library."
|
||||
HOMEPAGE="http://www.ffmpeg.org"
|
||||
SRC_URI="http://www.ffmpeg.org/releases/ffmpeg-0.10.2.tar.bz2"
|
||||
CHECKSUM_MD5="de1bd5fc4bbf3ef730a5361ee596fedd"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND="media-libs/libogg >= 1.3.0
|
||||
media-libs/speex >= 1.2rc1
|
||||
media-libs/libtheora >= 1.1.0
|
||||
media-libs/libvorbis >= 1.3.2
|
||||
media-libs/libvpx >= 1.0.0"
|
||||
BUILD {
|
||||
cd ffmpeg-0.10.2
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --enable-shared \
|
||||
--enable-libvorbis --enable-libspeex --enable-libtheora --enable-libvpx \
|
||||
--enable-gpl --datadir=`finddir B_COMMON_DATA_DIRECTORY`
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL {
|
||||
cd ffmpeg-0.10.2
|
||||
make install
|
||||
}
|
||||
|
||||
LICENSE="GNU GPL v2"
|
||||
COPYRIGHT="2000-2003 Fabrice Bellard
|
||||
2003-2012 the FFmpeg developers"
|
||||
28
media-video/ffmpeg/ffmpeg-0.10.2.bep
Normal file
28
media-video/ffmpeg/ffmpeg-0.10.2.bep
Normal file
@@ -0,0 +1,28 @@
|
||||
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert and stream audio and video. It includes libavcodec - the leading audio/video codec library."
|
||||
HOMEPAGE="http://www.ffmpeg.org"
|
||||
SRC_URI="http://www.ffmpeg.org/releases/ffmpeg-0.10.2.tar.bz2"
|
||||
CHECKSUM_MD5="de1bd5fc4bbf3ef730a5361ee596fedd"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND="media-libs/libogg >= 1.3.0
|
||||
media-libs/speex >= 1.2rc1
|
||||
media-libs/libtheora >= 1.1.0
|
||||
media-libs/libvorbis >= 1.3.2
|
||||
media-libs/libvpx >= 1.0.0"
|
||||
BUILD {
|
||||
cd ffmpeg-0.10.2
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --enable-shared \
|
||||
--enable-libvorbis --enable-libspeex --enable-libtheora --enable-libvpx \
|
||||
--datadir=`finddir B_COMMON_DATA_DIRECTORY`
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL {
|
||||
cd ffmpeg-0.10.2
|
||||
make install
|
||||
}
|
||||
|
||||
LICENSE="GNU LGPL v2.1
|
||||
GNU GPL v2"
|
||||
COPYRIGHT="2000-2003 Fabrice Bellard
|
||||
2003-2012 the FFmpeg developers"
|
||||
27
media-video/ffmpeg/ffmpeg-0.10.bep
Normal file
27
media-video/ffmpeg/ffmpeg-0.10.bep
Normal file
@@ -0,0 +1,27 @@
|
||||
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert and stream audio and video. It includes libavcodec - the leading audio/video codec library."
|
||||
HOMEPAGE="http://www.ffmpeg.org"
|
||||
SRC_URI="http://www.ffmpeg.org/releases/ffmpeg-0.10.tar.bz2"
|
||||
CHECKSUM_MD5="dc665cc599a739e3c5262ccdac13d129"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND="media-libs/libogg >= 1.3.0
|
||||
media-libs/speex >= 1.2rc1
|
||||
media-libs/libtheora >= 1.1.0
|
||||
media-libs/libvorbis >= 1.3.2
|
||||
media-libs/libvpx >= 1.0.0"
|
||||
BUILD {
|
||||
cd ffmpeg-0.10
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --enable-shared \
|
||||
--enable-libvorbis --enable-libspeex --enable-libtheora --enable-libvpx
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL {
|
||||
cd ffmpeg-0.10
|
||||
make install
|
||||
}
|
||||
|
||||
LICENSE="GNU LGPL v2.1
|
||||
GNU GPL v2"
|
||||
COPYRIGHT="2000-2003 Fabrice Bellard
|
||||
2003-2012 the FFmpeg developers"
|
||||
28
media-video/ffmpeg/ffmpeg-0.11.1.bep
Normal file
28
media-video/ffmpeg/ffmpeg-0.11.1.bep
Normal file
@@ -0,0 +1,28 @@
|
||||
DESCRIPTION="FFmpeg is a complete, cross-platform solution to record, convert and stream audio and video. It includes libavcodec - the leading audio/video codec library."
|
||||
HOMEPAGE="http://www.ffmpeg.org"
|
||||
SRC_URI="http://www.ffmpeg.org/releases/ffmpeg-0.11.1.tar.bz2"
|
||||
CHECKSUM_MD5="ff8cb914f657e164dd60ea1008b555a8"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND="media-libs/libogg >= 1.3.0
|
||||
media-libs/speex >= 1.2rc1
|
||||
media-libs/libtheora >= 1.1.0
|
||||
media-libs/libvorbis >= 1.3.2
|
||||
media-libs/libvpx >= 1.0.0"
|
||||
BUILD {
|
||||
cd ffmpeg-0.11.1
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --enable-shared \
|
||||
--enable-libvorbis --enable-libspeex --enable-libtheora --enable-libvpx \
|
||||
--datadir=`finddir B_COMMON_DATA_DIRECTORY`
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL {
|
||||
cd ffmpeg-0.11.1
|
||||
make install
|
||||
}
|
||||
|
||||
LICENSE="GNU LGPL v2.1
|
||||
GNU GPL v2"
|
||||
COPYRIGHT="2000-2003 Fabrice Bellard
|
||||
2003-2012 the FFmpeg developers"
|
||||
@@ -7,7 +7,7 @@ STATUS_HAIKU="stable"
|
||||
DEPEND=""
|
||||
BUILD {
|
||||
cd ffmpeg-0.5
|
||||
./configure --prefix=/boot/common --disable-debug --disable-mmx --enable-shared
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --disable-mmx --enable-shared
|
||||
make
|
||||
}
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ STATUS_HAIKU="stable"
|
||||
DEPEND=""
|
||||
BUILD {
|
||||
cd ffmpeg-0.6
|
||||
./configure --prefix=/boot/common --disable-debug --disable-mmx --enable-shared
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --disable-mmx --enable-shared
|
||||
make
|
||||
}
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ DEPEND=""
|
||||
BUILD {
|
||||
cd ffmpeg-23081
|
||||
chmod 777 configure
|
||||
./configure --prefix=/boot/common --disable-debug --disable-mmx --enable-shared --enable-gpl
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --disable-mmx --enable-shared --enable-gpl
|
||||
make
|
||||
}
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ DEPEND=""
|
||||
BUILD {
|
||||
cd ffmpeg-7407
|
||||
chmod 777 configure
|
||||
./configure --prefix=/boot/common --disable-debug --disable-mmx --enable-shared --enable-gpl --enable-pp
|
||||
./configure --prefix=`finddir B_COMMON_DIRECTORY` --disable-debug --disable-mmx --enable-shared --enable-gpl --enable-pp
|
||||
make
|
||||
}
|
||||
|
||||
|
||||
268
media-video/ffmpeg/patches/ffmpeg-0.10-gcc2.patch
Normal file
268
media-video/ffmpeg/patches/ffmpeg-0.10-gcc2.patch
Normal file
@@ -0,0 +1,268 @@
|
||||
diff --git a/cmdutils.c b/cmdutils.c
|
||||
index 386db3d..f918600 100644
|
||||
--- ffmpeg-0.10/cmdutils.c
|
||||
+++ ffmpeg-0.10/cmdutils.c
|
||||
@@ -89,7 +89,7 @@ static void log_callback_report(void *ptr, int level, const char *fmt, va_list v
|
||||
char line[1024];
|
||||
static int print_prefix = 1;
|
||||
|
||||
- va_copy(vl2, vl);
|
||||
+ __va_copy(vl2, vl);
|
||||
av_log_default_callback(ptr, level, fmt, vl);
|
||||
av_log_format_line(ptr, level, fmt, vl2, line, sizeof(line), &print_prefix);
|
||||
va_end(vl2);
|
||||
diff --git a/ffmpeg.c b/ffmpeg.c
|
||||
index 463e1f4..245e8b5 100644
|
||||
--- ffmpeg-0.10/ffmpeg.c
|
||||
+++ ffmpeg-0.10/ffmpeg.c
|
||||
@@ -1247,9 +1247,11 @@ need_realloc:
|
||||
av_fifo_size(ost->fifo) / (enc->channels * osize); // FIXME wrong
|
||||
|
||||
if (ost->audio_resample) {
|
||||
+ uint8_t *buftmp2[] = { buftmp };
|
||||
+ const uint8_t *buf2[] = { buf };
|
||||
buftmp = audio_buf;
|
||||
- size_out = swr_convert(ost->swr, ( uint8_t*[]){buftmp}, audio_buf_size / (enc->channels * osize),
|
||||
- (const uint8_t*[]){buf }, size / (dec->channels * isize));
|
||||
+ size_out = swr_convert(ost->swr, buftmp2, audio_buf_size / (enc->channels * osize),
|
||||
+ buf2, size / (dec->channels * isize));
|
||||
size_out = size_out * enc->channels * osize;
|
||||
} else {
|
||||
buftmp = buf;
|
||||
diff --git a/ffprobe.c b/ffprobe.c
|
||||
index ca6133e..43f9d39 100644
|
||||
--- ffmpeg-0.10/ffprobe.c
|
||||
+++ ffmpeg-0.10/ffprobe.c
|
||||
@@ -293,7 +293,9 @@ static void writer_print_time(WriterContext *wctx, const char *key,
|
||||
writer_print_string(wctx, key, "N/A", 1);
|
||||
} else {
|
||||
double d = ts * av_q2d(*time_base);
|
||||
- value_string(buf, sizeof(buf), (struct unit_value){.val.d=d, .unit=unit_second_str});
|
||||
+ struct unit_value value2 = {.unit=unit_second_str};
|
||||
+ value2.val.d = d;
|
||||
+ value_string(buf, sizeof(buf), value2);
|
||||
writer_print_string(wctx, key, buf, 0);
|
||||
}
|
||||
}
|
||||
@@ -1249,8 +1251,8 @@ static void writer_register_all(void)
|
||||
#define print_str_opt(k, v) writer_print_string(w, k, v, 1)
|
||||
#define print_time(k, v, tb) writer_print_time(w, k, v, tb)
|
||||
#define print_ts(k, v) writer_print_ts(w, k, v)
|
||||
-#define print_val(k, v, u) writer_print_string(w, k, \
|
||||
- value_string(val_str, sizeof(val_str), (struct unit_value){.val.i = v, .unit=u}), 0)
|
||||
+#define print_val(k, v, u) value2.val.i = v; value2.unit=u; writer_print_string(w, k, \
|
||||
+ value_string(val_str, sizeof(val_str), value2), 0);
|
||||
#define print_section_header(s) writer_print_section_header(w, s)
|
||||
#define print_section_footer(s) writer_print_section_footer(w, s)
|
||||
#define show_tags(metadata) writer_show_tags(w, metadata)
|
||||
@@ -1261,6 +1263,7 @@ static void show_packet(WriterContext *w, AVFormatContext *fmt_ctx, AVPacket *pk
|
||||
AVStream *st = fmt_ctx->streams[pkt->stream_index];
|
||||
struct print_buf pbuf = {.s = NULL};
|
||||
const char *s;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("packet");
|
||||
s = av_get_media_type_string(st->codec->codec_type);
|
||||
@@ -1404,6 +1407,7 @@ static void show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_i
|
||||
const char *s;
|
||||
AVRational display_aspect_ratio;
|
||||
struct print_buf pbuf = {.s = NULL};
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("stream");
|
||||
|
||||
@@ -1516,6 +1520,7 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
{
|
||||
char val_str[128];
|
||||
int64_t size = fmt_ctx->pb ? avio_size(fmt_ctx->pb) : -1;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("format");
|
||||
print_str("filename", fmt_ctx->filename);
|
||||
@@ -1524,9 +1529,9 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
print_str("format_long_name", fmt_ctx->iformat->long_name);
|
||||
print_time("start_time", fmt_ctx->start_time, &AV_TIME_BASE_Q);
|
||||
print_time("duration", fmt_ctx->duration, &AV_TIME_BASE_Q);
|
||||
- if (size >= 0) print_val ("size", size, unit_byte_str);
|
||||
+ if (size >= 0) { print_val ("size", size, unit_byte_str); }
|
||||
else print_str_opt("size", "N/A");
|
||||
- if (fmt_ctx->bit_rate > 0) print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str);
|
||||
+ if (fmt_ctx->bit_rate > 0) { print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str); }
|
||||
else print_str_opt("bit_rate", "N/A");
|
||||
show_tags(fmt_ctx->metadata);
|
||||
print_section_footer("format");
|
||||
diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c
|
||||
index 55f0286..35d5f1a 100644
|
||||
--- ffmpeg-0.10/libavcodec/aacenc.c
|
||||
+++ ffmpeg-0.10/libavcodec/aacenc.c
|
||||
@@ -223,8 +223,9 @@ WINDOW_FUNC(eight_short)
|
||||
const float *pwindow = sce->ics.use_kb_window[1] ? ff_aac_kbd_short_128 : ff_sine_128;
|
||||
const float *in = audio + 448;
|
||||
float *out = sce->ret;
|
||||
+ int w;
|
||||
|
||||
- for (int w = 0; w < 8; w++) {
|
||||
+ for (w = 0; w < 8; w++) {
|
||||
dsp->vector_fmul (out, in, w ? pwindow : swindow, 128);
|
||||
out += 128;
|
||||
in += 128;
|
||||
@@ -686,11 +687,12 @@ static av_cold int dsp_init(AVCodecContext *avctx, AACEncContext *s)
|
||||
|
||||
static av_cold int alloc_buffers(AVCodecContext *avctx, AACEncContext *s)
|
||||
{
|
||||
+ int ch;
|
||||
FF_ALLOCZ_OR_GOTO(avctx, s->buffer.samples, 3 * 1024 * s->channels * sizeof(s->buffer.samples[0]), alloc_fail);
|
||||
FF_ALLOCZ_OR_GOTO(avctx, s->cpe, sizeof(ChannelElement) * s->chan_map[0], alloc_fail);
|
||||
FF_ALLOCZ_OR_GOTO(avctx, avctx->extradata, 5 + FF_INPUT_BUFFER_PADDING_SIZE, alloc_fail);
|
||||
|
||||
- for(int ch = 0; ch < s->channels; ch++)
|
||||
+ for(ch = 0; ch < s->channels; ch++)
|
||||
s->planar_samples[ch] = s->buffer.samples + 3 * 1024 * ch;
|
||||
|
||||
return 0;
|
||||
diff --git a/libavutil/pixdesc.c b/libavutil/pixdesc.c
|
||||
index e73fbfe..3cde56c 100644
|
||||
--- ffmpeg-0.10/libavutil/pixdesc.c
|
||||
+++ ffmpeg-0.10/libavutil/pixdesc.c
|
||||
@@ -1096,12 +1096,6 @@ const AVPixFmtDescriptor av_pix_fmt_descriptors[PIX_FMT_NB] = {
|
||||
.log2_chroma_h = 1,
|
||||
.flags = PIX_FMT_HWACCEL,
|
||||
},
|
||||
- [PIX_FMT_VDA_VLD] = {
|
||||
- .name = "vda_vld",
|
||||
- .log2_chroma_w = 1,
|
||||
- .log2_chroma_h = 1,
|
||||
- .flags = PIX_FMT_HWACCEL,
|
||||
- },
|
||||
[PIX_FMT_GRAY8A] = {
|
||||
.name = "gray8a",
|
||||
.nb_components = 2,
|
||||
@@ -1110,16 +1104,6 @@ const AVPixFmtDescriptor av_pix_fmt_descriptors[PIX_FMT_NB] = {
|
||||
{ 0, 1, 2, 0, 7 }, /* A */
|
||||
},
|
||||
},
|
||||
- [PIX_FMT_GBR24P] = {
|
||||
- .name = "gbr24p",
|
||||
- .nb_components= 3,
|
||||
- .comp = {
|
||||
- { 1, 0, 1, 0, 7 }, /* B */
|
||||
- { 0, 0, 1, 0, 7 }, /* G */
|
||||
- { 2, 0, 1, 0, 7 }, /* R */
|
||||
- },
|
||||
- .flags = PIX_FMT_PLANAR | PIX_FMT_RGB,
|
||||
- },
|
||||
[PIX_FMT_GBRP] = {
|
||||
.name = "gbrp",
|
||||
.nb_components = 3,
|
||||
diff --git a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c
|
||||
index e1ba799..3820056 100644
|
||||
--- ffmpeg-0.10/libswscale/swscale_unscaled.c
|
||||
+++ ffmpeg-0.10/libswscale/swscale_unscaled.c
|
||||
@@ -370,30 +370,38 @@ static int planarRgbToRgbWrapper(SwsContext *c, const uint8_t* src[], int srcStr
|
||||
}
|
||||
|
||||
switch (c->dstFormat) {
|
||||
- case PIX_FMT_BGR24:
|
||||
- gbr24ptopacked24((const uint8_t* []) {src[1], src[0], src[2]}, (int []) {srcStride[1], srcStride[0], srcStride[2]},
|
||||
+ case PIX_FMT_BGR24: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked24(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
- case PIX_FMT_RGB24:
|
||||
- gbr24ptopacked24((const uint8_t* []) {src[2], src[0], src[1]}, (int []) {srcStride[2], srcStride[0], srcStride[1]},
|
||||
+ }
|
||||
+ case PIX_FMT_RGB24: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked24(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ARGB:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_RGBA:
|
||||
- gbr24ptopacked32((const uint8_t* []) {src[2], src[0], src[1]}, (int []) {srcStride[2], srcStride[0], srcStride[1]},
|
||||
+ case PIX_FMT_RGBA: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ABGR:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_BGRA:
|
||||
- gbr24ptopacked32((const uint8_t* []) {src[1], src[0], src[2]}, (int []) {srcStride[1], srcStride[0], srcStride[2]},
|
||||
+ case PIX_FMT_BGRA: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
default:
|
||||
av_log(c, AV_LOG_ERROR, "unsupported planar RGB conversion %s -> %s\n",
|
||||
av_get_pix_fmt_name(c->srcFormat), av_get_pix_fmt_name(c->dstFormat));
|
||||
diff --git a/configure b/configure
|
||||
--- ffmpeg-0.10/configure 2012-01-26 22:15:59.047710208 +0000
|
||||
+++ ffmpeg-0.10-haiku/configure 2012-03-28 22:30:34.330563584 +0000
|
||||
@@ -1359,7 +1359,6 @@
|
||||
|
||||
aligned_stack_if_any="ppc x86"
|
||||
fast_64bit_if_any="alpha ia64 mips64 parisc64 ppc64 sparc64 x86_64"
|
||||
-fast_clz_if_any="alpha armv5te avr32 mips ppc x86"
|
||||
fast_unaligned_if_any="armv6 ppc x86"
|
||||
|
||||
inline_asm_deps="!tms470"
|
||||
@@ -1866,7 +1865,7 @@
|
||||
CC_O='-o $@'
|
||||
CXX_O='-o $@'
|
||||
|
||||
-host_cflags='-D_ISOC99_SOURCE -O3 -g'
|
||||
+host_cflags='-D_ISOC99_SOURCE -O2 -g'
|
||||
host_libs='-lm'
|
||||
|
||||
target_path='$(CURDIR)'
|
||||
@@ -1948,6 +1947,7 @@
|
||||
done
|
||||
|
||||
enable $ARCH_EXT_LIST $ALL_TESTS
|
||||
+disable sse
|
||||
|
||||
die_unknown(){
|
||||
echo "Unknown option \"$1\"."
|
||||
@@ -2144,7 +2144,7 @@
|
||||
CC_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
AS_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
fi
|
||||
- speed_cflags='-O3'
|
||||
+ speed_cflags='-O2'
|
||||
size_cflags='-Os'
|
||||
elif $cc --version 2>/dev/null | grep -q Intel; then
|
||||
cc_type=icc
|
||||
@@ -2831,10 +2831,6 @@
|
||||
struct { int x; } __attribute__((packed)) x;
|
||||
EOF
|
||||
|
||||
-check_cc <<EOF && enable attribute_may_alias
|
||||
-union { int x; } __attribute__((may_alias)) x;
|
||||
-EOF
|
||||
-
|
||||
check_cc <<EOF || die "endian test failed"
|
||||
unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
|
||||
EOF
|
||||
@@ -3108,8 +3104,6 @@
|
||||
enabled vaapi && require vaapi va/va.h vaInitialize -lva
|
||||
|
||||
check_mathfunc cbrtf
|
||||
-check_mathfunc exp2
|
||||
-check_mathfunc exp2f
|
||||
check_mathfunc llrint
|
||||
check_mathfunc llrintf
|
||||
check_mathfunc log2
|
||||
268
media-video/ffmpeg/patches/ffmpeg-0.10.2-gcc2.patch
Normal file
268
media-video/ffmpeg/patches/ffmpeg-0.10.2-gcc2.patch
Normal file
@@ -0,0 +1,268 @@
|
||||
diff --git a/cmdutils.c b/cmdutils.c
|
||||
index 386db3d..f918600 100644
|
||||
--- ffmpeg-0.10.2/cmdutils.c
|
||||
+++ ffmpeg-0.10.2/cmdutils.c
|
||||
@@ -89,7 +89,7 @@ static void log_callback_report(void *ptr, int level, const char *fmt, va_list v
|
||||
char line[1024];
|
||||
static int print_prefix = 1;
|
||||
|
||||
- va_copy(vl2, vl);
|
||||
+ __va_copy(vl2, vl);
|
||||
av_log_default_callback(ptr, level, fmt, vl);
|
||||
av_log_format_line(ptr, level, fmt, vl2, line, sizeof(line), &print_prefix);
|
||||
va_end(vl2);
|
||||
diff --git a/ffmpeg.c b/ffmpeg.c
|
||||
index 463e1f4..245e8b5 100644
|
||||
--- ffmpeg-0.10.2/ffmpeg.c
|
||||
+++ ffmpeg-0.10.2/ffmpeg.c
|
||||
@@ -1247,9 +1247,11 @@ need_realloc:
|
||||
av_fifo_size(ost->fifo) / (enc->channels * osize); // FIXME wrong
|
||||
|
||||
if (ost->audio_resample) {
|
||||
+ uint8_t *buftmp2[] = { buftmp };
|
||||
+ const uint8_t *buf2[] = { buf };
|
||||
buftmp = audio_buf;
|
||||
- size_out = swr_convert(ost->swr, ( uint8_t*[]){buftmp}, audio_buf_size / (enc->channels * osize),
|
||||
- (const uint8_t*[]){buf }, size / (dec->channels * isize));
|
||||
+ size_out = swr_convert(ost->swr, buftmp2, audio_buf_size / (enc->channels * osize),
|
||||
+ buf2, size / (dec->channels * isize));
|
||||
size_out = size_out * enc->channels * osize;
|
||||
} else {
|
||||
buftmp = buf;
|
||||
diff --git a/ffprobe.c b/ffprobe.c
|
||||
index ca6133e..43f9d39 100644
|
||||
--- ffmpeg-0.10.2/ffprobe.c
|
||||
+++ ffmpeg-0.10.2/ffprobe.c
|
||||
@@ -293,7 +293,9 @@ static void writer_print_time(WriterContext *wctx, const char *key,
|
||||
writer_print_string(wctx, key, "N/A", 1);
|
||||
} else {
|
||||
double d = ts * av_q2d(*time_base);
|
||||
- value_string(buf, sizeof(buf), (struct unit_value){.val.d=d, .unit=unit_second_str});
|
||||
+ struct unit_value value2 = {.unit=unit_second_str};
|
||||
+ value2.val.d = d;
|
||||
+ value_string(buf, sizeof(buf), value2);
|
||||
writer_print_string(wctx, key, buf, 0);
|
||||
}
|
||||
}
|
||||
@@ -1249,8 +1251,8 @@ static void writer_register_all(void)
|
||||
#define print_str_opt(k, v) writer_print_string(w, k, v, 1)
|
||||
#define print_time(k, v, tb) writer_print_time(w, k, v, tb)
|
||||
#define print_ts(k, v) writer_print_ts(w, k, v)
|
||||
-#define print_val(k, v, u) writer_print_string(w, k, \
|
||||
- value_string(val_str, sizeof(val_str), (struct unit_value){.val.i = v, .unit=u}), 0)
|
||||
+#define print_val(k, v, u) value2.val.i = v; value2.unit=u; writer_print_string(w, k, \
|
||||
+ value_string(val_str, sizeof(val_str), value2), 0);
|
||||
#define print_section_header(s) writer_print_section_header(w, s)
|
||||
#define print_section_footer(s) writer_print_section_footer(w, s)
|
||||
#define show_tags(metadata) writer_show_tags(w, metadata)
|
||||
@@ -1261,6 +1263,7 @@ static void show_packet(WriterContext *w, AVFormatContext *fmt_ctx, AVPacket *pk
|
||||
AVStream *st = fmt_ctx->streams[pkt->stream_index];
|
||||
struct print_buf pbuf = {.s = NULL};
|
||||
const char *s;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("packet");
|
||||
s = av_get_media_type_string(st->codec->codec_type);
|
||||
@@ -1404,6 +1407,7 @@ static void show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_i
|
||||
const char *s;
|
||||
AVRational display_aspect_ratio;
|
||||
struct print_buf pbuf = {.s = NULL};
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("stream");
|
||||
|
||||
@@ -1516,6 +1520,7 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
{
|
||||
char val_str[128];
|
||||
int64_t size = fmt_ctx->pb ? avio_size(fmt_ctx->pb) : -1;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("format");
|
||||
print_str("filename", fmt_ctx->filename);
|
||||
@@ -1524,9 +1529,9 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
print_str("format_long_name", fmt_ctx->iformat->long_name);
|
||||
print_time("start_time", fmt_ctx->start_time, &AV_TIME_BASE_Q);
|
||||
print_time("duration", fmt_ctx->duration, &AV_TIME_BASE_Q);
|
||||
- if (size >= 0) print_val ("size", size, unit_byte_str);
|
||||
+ if (size >= 0) { print_val ("size", size, unit_byte_str); }
|
||||
else print_str_opt("size", "N/A");
|
||||
- if (fmt_ctx->bit_rate > 0) print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str);
|
||||
+ if (fmt_ctx->bit_rate > 0) { print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str); }
|
||||
else print_str_opt("bit_rate", "N/A");
|
||||
show_tags(fmt_ctx->metadata);
|
||||
print_section_footer("format");
|
||||
diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c
|
||||
index 55f0286..35d5f1a 100644
|
||||
--- ffmpeg-0.10.2/libavcodec/aacenc.c
|
||||
+++ ffmpeg-0.10.2/libavcodec/aacenc.c
|
||||
@@ -223,8 +223,9 @@ WINDOW_FUNC(eight_short)
|
||||
const float *pwindow = sce->ics.use_kb_window[1] ? ff_aac_kbd_short_128 : ff_sine_128;
|
||||
const float *in = audio + 448;
|
||||
float *out = sce->ret;
|
||||
+ int w;
|
||||
|
||||
- for (int w = 0; w < 8; w++) {
|
||||
+ for (w = 0; w < 8; w++) {
|
||||
dsp->vector_fmul (out, in, w ? pwindow : swindow, 128);
|
||||
out += 128;
|
||||
in += 128;
|
||||
@@ -686,11 +687,12 @@ static av_cold int dsp_init(AVCodecContext *avctx, AACEncContext *s)
|
||||
|
||||
static av_cold int alloc_buffers(AVCodecContext *avctx, AACEncContext *s)
|
||||
{
|
||||
+ int ch;
|
||||
FF_ALLOCZ_OR_GOTO(avctx, s->buffer.samples, 3 * 1024 * s->channels * sizeof(s->buffer.samples[0]), alloc_fail);
|
||||
FF_ALLOCZ_OR_GOTO(avctx, s->cpe, sizeof(ChannelElement) * s->chan_map[0], alloc_fail);
|
||||
FF_ALLOCZ_OR_GOTO(avctx, avctx->extradata, 5 + FF_INPUT_BUFFER_PADDING_SIZE, alloc_fail);
|
||||
|
||||
- for(int ch = 0; ch < s->channels; ch++)
|
||||
+ for(ch = 0; ch < s->channels; ch++)
|
||||
s->planar_samples[ch] = s->buffer.samples + 3 * 1024 * ch;
|
||||
|
||||
return 0;
|
||||
diff --git a/libavutil/pixdesc.c b/libavutil/pixdesc.c
|
||||
index e73fbfe..3cde56c 100644
|
||||
--- ffmpeg-0.10.2/libavutil/pixdesc.c
|
||||
+++ ffmpeg-0.10.2/libavutil/pixdesc.c
|
||||
@@ -1096,12 +1096,6 @@ const AVPixFmtDescriptor av_pix_fmt_descriptors[PIX_FMT_NB] = {
|
||||
.log2_chroma_h = 1,
|
||||
.flags = PIX_FMT_HWACCEL,
|
||||
},
|
||||
- [PIX_FMT_VDA_VLD] = {
|
||||
- .name = "vda_vld",
|
||||
- .log2_chroma_w = 1,
|
||||
- .log2_chroma_h = 1,
|
||||
- .flags = PIX_FMT_HWACCEL,
|
||||
- },
|
||||
[PIX_FMT_GRAY8A] = {
|
||||
.name = "gray8a",
|
||||
.nb_components = 2,
|
||||
@@ -1110,16 +1104,6 @@ const AVPixFmtDescriptor av_pix_fmt_descriptors[PIX_FMT_NB] = {
|
||||
{ 0, 1, 2, 0, 7 }, /* A */
|
||||
},
|
||||
},
|
||||
- [PIX_FMT_GBR24P] = {
|
||||
- .name = "gbr24p",
|
||||
- .nb_components= 3,
|
||||
- .comp = {
|
||||
- { 1, 0, 1, 0, 7 }, /* B */
|
||||
- { 0, 0, 1, 0, 7 }, /* G */
|
||||
- { 2, 0, 1, 0, 7 }, /* R */
|
||||
- },
|
||||
- .flags = PIX_FMT_PLANAR | PIX_FMT_RGB,
|
||||
- },
|
||||
[PIX_FMT_GBRP] = {
|
||||
.name = "gbrp",
|
||||
.nb_components = 3,
|
||||
diff --git a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c
|
||||
index e1ba799..3820056 100644
|
||||
--- ffmpeg-0.10.2/libswscale/swscale_unscaled.c
|
||||
+++ ffmpeg-0.10.2/libswscale/swscale_unscaled.c
|
||||
@@ -370,30 +370,38 @@ static int planarRgbToRgbWrapper(SwsContext *c, const uint8_t* src[], int srcStr
|
||||
}
|
||||
|
||||
switch (c->dstFormat) {
|
||||
- case PIX_FMT_BGR24:
|
||||
- gbr24ptopacked24((const uint8_t* []) {src[1], src[0], src[2]}, (int []) {srcStride[1], srcStride[0], srcStride[2]},
|
||||
+ case PIX_FMT_BGR24: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked24(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
- case PIX_FMT_RGB24:
|
||||
- gbr24ptopacked24((const uint8_t* []) {src[2], src[0], src[1]}, (int []) {srcStride[2], srcStride[0], srcStride[1]},
|
||||
+ }
|
||||
+ case PIX_FMT_RGB24: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked24(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ARGB:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_RGBA:
|
||||
- gbr24ptopacked32((const uint8_t* []) {src[2], src[0], src[1]}, (int []) {srcStride[2], srcStride[0], srcStride[1]},
|
||||
+ case PIX_FMT_RGBA: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ABGR:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_BGRA:
|
||||
- gbr24ptopacked32((const uint8_t* []) {src[1], src[0], src[2]}, (int []) {srcStride[1], srcStride[0], srcStride[2]},
|
||||
+ case PIX_FMT_BGRA: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0], srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
default:
|
||||
av_log(c, AV_LOG_ERROR, "unsupported planar RGB conversion %s -> %s\n",
|
||||
av_get_pix_fmt_name(c->srcFormat), av_get_pix_fmt_name(c->dstFormat));
|
||||
diff --git a/configure b/configure
|
||||
--- ffmpeg-0.10.2/configure 2012-01-26 22:15:59.047710208 +0000
|
||||
+++ ffmpeg-0.10-haiku/configure 2012-03-28 22:30:34.330563584 +0000
|
||||
@@ -1359,7 +1359,6 @@
|
||||
|
||||
aligned_stack_if_any="ppc x86"
|
||||
fast_64bit_if_any="alpha ia64 mips64 parisc64 ppc64 sparc64 x86_64"
|
||||
-fast_clz_if_any="alpha armv5te avr32 mips ppc x86"
|
||||
fast_unaligned_if_any="armv6 ppc x86"
|
||||
|
||||
inline_asm_deps="!tms470"
|
||||
@@ -1866,7 +1865,7 @@
|
||||
CC_O='-o $@'
|
||||
CXX_O='-o $@'
|
||||
|
||||
-host_cflags='-D_ISOC99_SOURCE -O3 -g'
|
||||
+host_cflags='-D_ISOC99_SOURCE -O2 -g'
|
||||
host_libs='-lm'
|
||||
|
||||
target_path='$(CURDIR)'
|
||||
@@ -1948,6 +1947,7 @@
|
||||
done
|
||||
|
||||
enable $ARCH_EXT_LIST $ALL_TESTS
|
||||
+disable sse
|
||||
|
||||
die_unknown(){
|
||||
echo "Unknown option \"$1\"."
|
||||
@@ -2144,7 +2144,7 @@
|
||||
CC_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
AS_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
fi
|
||||
- speed_cflags='-O3'
|
||||
+ speed_cflags='-O2'
|
||||
size_cflags='-Os'
|
||||
elif $cc --version 2>/dev/null | grep -q Intel; then
|
||||
cc_type=icc
|
||||
@@ -2831,10 +2831,6 @@
|
||||
struct { int x; } __attribute__((packed)) x;
|
||||
EOF
|
||||
|
||||
-check_cc <<EOF && enable attribute_may_alias
|
||||
-union { int x; } __attribute__((may_alias)) x;
|
||||
-EOF
|
||||
-
|
||||
check_cc <<EOF || die "endian test failed"
|
||||
unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
|
||||
EOF
|
||||
@@ -3108,8 +3104,6 @@
|
||||
enabled vaapi && require vaapi va/va.h vaInitialize -lva
|
||||
|
||||
check_mathfunc cbrtf
|
||||
-check_mathfunc exp2
|
||||
-check_mathfunc exp2f
|
||||
check_mathfunc llrint
|
||||
check_mathfunc llrintf
|
||||
check_mathfunc log2
|
||||
289
media-video/ffmpeg/patches/ffmpeg-0.11.1-gcc2.patch
Normal file
289
media-video/ffmpeg/patches/ffmpeg-0.11.1-gcc2.patch
Normal file
@@ -0,0 +1,289 @@
|
||||
diff --git a/cmdutils.c b/cmdutils.c
|
||||
index 386db3d..f918600 100644
|
||||
--- ffmpeg-0.11.1/cmdutils.c
|
||||
+++ ffmpeg-0.11.1/cmdutils.c
|
||||
@@ -89,7 +89,7 @@ static void log_callback_report(void *ptr, int level, const char *fmt, va_list v
|
||||
char line[1024];
|
||||
static int print_prefix = 1;
|
||||
|
||||
- va_copy(vl2, vl);
|
||||
+ __va_copy(vl2, vl);
|
||||
av_log_default_callback(ptr, level, fmt, vl);
|
||||
av_log_format_line(ptr, level, fmt, vl2, line, sizeof(line), &print_prefix);
|
||||
va_end(vl2);
|
||||
diff --git a/ffprobe.c b/ffprobe.c
|
||||
index ca6133e..43f9d39 100644
|
||||
--- ffmpeg-0.11.1/ffprobe.c
|
||||
+++ ffmpeg-0.11.1/ffprobe.c
|
||||
@@ -1249,8 +1251,8 @@ static void writer_register_all(void)
|
||||
#define print_str_opt(k, v) writer_print_string(w, k, v, 1)
|
||||
#define print_time(k, v, tb) writer_print_time(w, k, v, tb)
|
||||
#define print_ts(k, v) writer_print_ts(w, k, v)
|
||||
-#define print_val(k, v, u) writer_print_string(w, k, \
|
||||
- value_string(val_str, sizeof(val_str), (struct unit_value){.val.i = v, .unit=u}), 0)
|
||||
+#define print_val(k, v, u) value2.val.i = v; value2.unit=u; writer_print_string(w, k, \
|
||||
+ value_string(val_str, sizeof(val_str), value2), 0);
|
||||
#define print_section_header(s) writer_print_section_header(w, s)
|
||||
#define print_section_footer(s) writer_print_section_footer(w, s)
|
||||
#define show_tags(metadata) writer_show_tags(w, metadata)
|
||||
@@ -1261,6 +1263,7 @@ static void show_packet(WriterContext *w, AVFormatContext *fmt_ctx, AVPacket *pk
|
||||
AVStream *st = fmt_ctx->streams[pkt->stream_index];
|
||||
struct print_buf pbuf = {.s = NULL};
|
||||
const char *s;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("packet");
|
||||
s = av_get_media_type_string(st->codec->codec_type);
|
||||
@@ -1516,6 +1520,7 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
{
|
||||
char val_str[128];
|
||||
int64_t size = fmt_ctx->pb ? avio_size(fmt_ctx->pb) : -1;
|
||||
+ struct unit_value value2;
|
||||
|
||||
print_section_header("format");
|
||||
print_str("filename", fmt_ctx->filename);
|
||||
@@ -1524,9 +1529,9 @@ static void show_format(WriterContext *w, AVFormatContext *fmt_ctx)
|
||||
print_str("format_long_name", fmt_ctx->iformat->long_name);
|
||||
print_time("start_time", fmt_ctx->start_time, &AV_TIME_BASE_Q);
|
||||
print_time("duration", fmt_ctx->duration, &AV_TIME_BASE_Q);
|
||||
- if (size >= 0) print_val ("size", size, unit_byte_str);
|
||||
+ if (size >= 0) { print_val ("size", size, unit_byte_str); }
|
||||
else print_str_opt("size", "N/A");
|
||||
- if (fmt_ctx->bit_rate > 0) print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str);
|
||||
+ if (fmt_ctx->bit_rate > 0) { print_val ("bit_rate", fmt_ctx->bit_rate, unit_bit_per_second_str); }
|
||||
else print_str_opt("bit_rate", "N/A");
|
||||
show_tags(fmt_ctx->metadata);
|
||||
print_section_footer("format");
|
||||
diff --git a/libavutil/pixdesc.c b/libavutil/pixdesc.c
|
||||
index e73fbfe..3cde56c 100644
|
||||
--- ffmpeg-0.11.1/libavutil/pixdesc.c
|
||||
+++ ffmpeg-0.11.1/libavutil/pixdesc.c
|
||||
@@ -1096,12 +1096,6 @@ const AVPixFmtDescriptor av_pix_fmt_descriptors[PIX_FMT_NB] = {
|
||||
.log2_chroma_h = 1,
|
||||
.flags = PIX_FMT_HWACCEL,
|
||||
},
|
||||
- [PIX_FMT_VDA_VLD] = {
|
||||
- .name = "vda_vld",
|
||||
- .log2_chroma_w = 1,
|
||||
- .log2_chroma_h = 1,
|
||||
- .flags = PIX_FMT_HWACCEL,
|
||||
- },
|
||||
[PIX_FMT_GRAY8A] = {
|
||||
.name = "gray8a",
|
||||
.nb_components = 2,
|
||||
|
||||
diff --git a/configure b/configure
|
||||
--- ffmpeg-0.11.1/configure 2012-01-26 22:15:59.047710208 +0000
|
||||
+++ ffmpeg-0.10-haiku/configure 2012-03-28 22:30:34.330563584 +0000
|
||||
@@ -1359,7 +1359,6 @@
|
||||
|
||||
aligned_stack_if_any="ppc x86"
|
||||
fast_64bit_if_any="alpha ia64 mips64 parisc64 ppc64 sparc64 x86_64"
|
||||
-fast_clz_if_any="alpha armv5te avr32 mips ppc x86"
|
||||
fast_unaligned_if_any="armv6 ppc x86"
|
||||
|
||||
inline_asm_deps="!tms470"
|
||||
@@ -1866,7 +1865,7 @@
|
||||
CC_O='-o $@'
|
||||
CXX_O='-o $@'
|
||||
|
||||
-host_cflags='-D_ISOC99_SOURCE -O3 -g'
|
||||
+host_cflags='-D_ISOC99_SOURCE -O2 -g'
|
||||
host_libs='-lm'
|
||||
|
||||
target_path='$(CURDIR)'
|
||||
@@ -1948,6 +1947,7 @@
|
||||
done
|
||||
|
||||
enable $ARCH_EXT_LIST $ALL_TESTS
|
||||
+disable sse
|
||||
|
||||
die_unknown(){
|
||||
echo "Unknown option \"$1\"."
|
||||
@@ -2144,7 +2144,7 @@
|
||||
CC_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
AS_DEPFLAGS='-MMD -MF $(@:.o=.d) -MT $@'
|
||||
fi
|
||||
- speed_cflags='-O3'
|
||||
+ speed_cflags='-O2'
|
||||
size_cflags='-Os'
|
||||
elif $cc --version 2>/dev/null | grep -q Intel; then
|
||||
cc_type=icc
|
||||
@@ -2831,10 +2831,6 @@
|
||||
struct { int x; } __attribute__((packed)) x;
|
||||
EOF
|
||||
|
||||
-check_cc <<EOF && enable attribute_may_alias
|
||||
-union { int x; } __attribute__((may_alias)) x;
|
||||
-EOF
|
||||
-
|
||||
check_cc <<EOF || die "endian test failed"
|
||||
unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
|
||||
EOF
|
||||
@@ -3108,8 +3104,6 @@
|
||||
enabled vaapi && require vaapi va/va.h vaInitialize -lva
|
||||
|
||||
check_mathfunc cbrtf
|
||||
-check_mathfunc exp2
|
||||
-check_mathfunc exp2f
|
||||
check_mathfunc llrint
|
||||
check_mathfunc llrintf
|
||||
check_mathfunc log2
|
||||
diff a/libavfilter/af_aresample.c b/libavfilter/af_aresample.c
|
||||
--- ffmpeg-0.11.1/libavfilter/af_aresample.c 2012-08-06 22:49:06.681836544 +0000
|
||||
+++ ffmpeg-0.11.1/libavfilter/af_aresample.c 2012-08-06 22:52:24.251658240 +0000
|
||||
@@ -103,20 +103,23 @@
|
||||
ff_channel_layouts_ref(in_layouts, &inlink->out_channel_layouts);
|
||||
|
||||
if(out_rate > 0) {
|
||||
- out_samplerates = avfilter_make_format_list((int[]){ out_rate, -1 });
|
||||
+ int rate_tmp[] = { out_rate, -1 };
|
||||
+ out_samplerates = avfilter_make_format_list(rate_tmp);
|
||||
} else {
|
||||
out_samplerates = ff_all_samplerates();
|
||||
}
|
||||
avfilter_formats_ref(out_samplerates, &outlink->in_samplerates);
|
||||
|
||||
if(out_format != AV_SAMPLE_FMT_NONE) {
|
||||
- out_formats = avfilter_make_format_list((int[]){ out_format, -1 });
|
||||
+ int format_tmp[] = { out_format, -1 };
|
||||
+ out_formats = avfilter_make_format_list(format_tmp);
|
||||
} else
|
||||
out_formats = avfilter_make_all_formats(AVMEDIA_TYPE_AUDIO);
|
||||
avfilter_formats_ref(out_formats, &outlink->in_formats);
|
||||
|
||||
if(out_layout) {
|
||||
- out_layouts = avfilter_make_format64_list((int64_t[]){ out_layout, -1 });
|
||||
+ int64_t layout_tmp[] = { out_layout, -1 };
|
||||
+ out_layouts = avfilter_make_format64_list(layout_tmp);
|
||||
} else
|
||||
out_layouts = ff_all_channel_layouts();
|
||||
ff_channel_layouts_ref(out_layouts, &outlink->in_channel_layouts);
|
||||
diff a/libswresample/x86/swresample_x86.c b/libswresample/x86/swresample_x86.c
|
||||
--- ffmpeg-0.11.1/libswresample/x86/swresample_x86.c 2012-08-06 22:49:12.765984768 +0000
|
||||
+++ ffmpeg-0.11.1/libswresample/x86/swresample_x86.c 2012-08-06 22:57:04.826015744 +0000
|
||||
@@ -25,7 +25,7 @@
|
||||
#define PROTO2(pre, out, cap) PROTO(pre, int16, out, cap) PROTO(pre, int32, out, cap) PROTO(pre, float, out, cap)
|
||||
#define PROTO3(pre, cap) PROTO2(pre, int16, cap) PROTO2(pre, int32, cap) PROTO2(pre, float, cap)
|
||||
#define PROTO4(pre) PROTO3(pre, mmx) PROTO3(pre, sse) PROTO3(pre, sse2) PROTO3(pre, ssse3) PROTO3(pre, sse4) PROTO3(pre, avx)
|
||||
-PROTO4()
|
||||
+PROTO4( )
|
||||
PROTO4(_pack_2ch)
|
||||
PROTO4(_pack_6ch)
|
||||
PROTO4(_unpack_2ch)
|
||||
diff -u a/libavcodec/pngenc.c b/libavcodec/pngenc.c
|
||||
--- ffmpeg-0.11.1/libavcodec/pngenc.c 2012-08-06 22:49:04.337117184 +0000
|
||||
+++ ffmpeg-0.11.1/libavcodec/pngenc.c 2012-08-06 23:04:38.048758784 +0000
|
||||
@@ -55,8 +55,9 @@
|
||||
int x, mask, dst_x, j, b, bpp;
|
||||
uint8_t *d;
|
||||
const uint8_t *s;
|
||||
+ int mask_tmp[] = {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff};
|
||||
|
||||
- mask = (int[]){0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff}[pass];
|
||||
+ mask = mask_tmp[pass];
|
||||
switch(bits_per_pixel) {
|
||||
case 1:
|
||||
memset(dst, 0, row_size);
|
||||
diff -u a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c
|
||||
--- ffmpeg-0.11.1/libswscale/swscale_unscaled.c 2012-08-06 22:49:12.936902656 +0000
|
||||
+++ ffmpeg-0.11.1/libswscale/swscale_unscaled.c 2012-08-06 23:18:25.574095360 +0000
|
||||
@@ -472,38 +472,40 @@
|
||||
}
|
||||
|
||||
switch (c->dstFormat) {
|
||||
- case PIX_FMT_BGR24:
|
||||
- gbr24ptopacked24((const uint8_t *[]) { src[1], src[0], src[2] },
|
||||
- (int []) { srcStride[1], srcStride[0], srcStride[2] },
|
||||
- dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
+ case PIX_FMT_BGR24: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked24(src2, srcStride2, dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
- case PIX_FMT_RGB24:
|
||||
- gbr24ptopacked24((const uint8_t *[]) { src[2], src[0], src[1] },
|
||||
- (int []) { srcStride[2], srcStride[0], srcStride[1] },
|
||||
- dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
+ }
|
||||
+ case PIX_FMT_RGB24: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked24(src2, srcStride2, dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
srcSliceH, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ARGB:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_RGBA:
|
||||
- gbr24ptopacked32((const uint8_t *[]) { src[2], src[0], src[1] },
|
||||
- (int []) { srcStride[2], srcStride[0], srcStride[1] },
|
||||
+ case PIX_FMT_RGBA: {
|
||||
+ const uint8_t* src2[] = {src[2], src[0], src[1]};
|
||||
+ int srcStride2[] = {srcStride[2], srcStride[0], srcStride[1]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
case PIX_FMT_ABGR:
|
||||
alpha_first = 1;
|
||||
- case PIX_FMT_BGRA:
|
||||
- gbr24ptopacked32((const uint8_t *[]) { src[1], src[0], src[2] },
|
||||
- (int []) { srcStride[1], srcStride[0], srcStride[2] },
|
||||
+ case PIX_FMT_BGRA: {
|
||||
+ const uint8_t* src2[] = {src[1], src[0], src[2]};
|
||||
+ int srcStride2[] = {srcStride[1], srcStride[0], srcStride[2]};
|
||||
+ gbr24ptopacked32(src2, srcStride2,
|
||||
dst[0] + srcSliceY * dstStride[0], dstStride[0],
|
||||
srcSliceH, alpha_first, c->srcW);
|
||||
break;
|
||||
-
|
||||
+ }
|
||||
default:
|
||||
av_log(c, AV_LOG_ERROR,
|
||||
"unsupported planar RGB conversion %s -> %s\n",
|
||||
diff -u a/ffprobe.c b/ffprobe.c
|
||||
--- ffmpeg-0.11.1/ffprobe.c 2012-08-06 22:49:00.930873344 +0000
|
||||
+++ ffmpeg-0.11.1/ffprobe.c 2012-08-06 23:26:28.951844864 +0000
|
||||
@@ -312,7 +312,9 @@
|
||||
writer_print_string(wctx, key, "N/A", 1);
|
||||
} else {
|
||||
double d = ts * av_q2d(*time_base);
|
||||
- value_string(buf, sizeof(buf), (struct unit_value){.val.d=d, .unit=unit_second_str});
|
||||
+ struct unit_value value2 = {.unit=unit_second_str};
|
||||
+ value2.val.d = d;
|
||||
+ value_string(buf, sizeof(buf), value2);
|
||||
writer_print_string(wctx, key, buf, 0);
|
||||
}
|
||||
}
|
||||
@@ -1188,7 +1190,7 @@
|
||||
#define print_time(k, v, tb) writer_print_time(w, k, v, tb)
|
||||
#define print_ts(k, v) writer_print_ts(w, k, v)
|
||||
#define print_val(k, v, u) value2.val.i = v; value2.unit=u; writer_print_string(w, k, \
|
||||
- value_string(val_str, sizeof(val_str), value2), 0);
|
||||
+ value_string(val_str, sizeof(val_str), value2), 0);
|
||||
#define print_section_header(s) writer_print_section_header(w, s)
|
||||
#define print_section_footer(s) writer_print_section_footer(w, s)
|
||||
#define show_tags(metadata) writer_show_tags(w, metadata)
|
||||
@@ -1357,6 +1359,7 @@
|
||||
const char *s;
|
||||
AVRational display_aspect_ratio;
|
||||
AVBPrint pbuf;
|
||||
+ struct unit_value value2;
|
||||
|
||||
av_bprint_init(&pbuf, 1, AV_BPRINT_SIZE_UNLIMITED);
|
||||
|
||||
@@ -1447,7 +1450,7 @@
|
||||
print_fmt("time_base", "%d/%d", stream->time_base.num, stream->time_base.den);
|
||||
print_time("start_time", stream->start_time, &stream->time_base);
|
||||
print_time("duration", stream->duration, &stream->time_base);
|
||||
- if (dec_ctx->bit_rate > 0) print_val ("bit_rate", dec_ctx->bit_rate, unit_bit_per_second_str);
|
||||
+ if (dec_ctx->bit_rate > 0) { print_val ("bit_rate", dec_ctx->bit_rate, unit_bit_per_second_str); }
|
||||
else print_str_opt("bit_rate", "N/A");
|
||||
if (stream->nb_frames) print_fmt ("nb_frames", "%"PRId64, stream->nb_frames);
|
||||
else print_str_opt("nb_frames", "N/A");
|
||||
Reference in New Issue
Block a user