diff --git a/avconv.c b/avconv.c
index 7bb1d31..2ab4e84 100644
--- a/avconv.c
+++ b/avconv.c
@@ -1372,7 +1372,7 @@ static void print_report(OutputFile *output_files,
     int64_t pts = INT64_MAX;
     static int64_t last_time = -1;
     static int qp_histogram[52];
-    int hours, mins, secs, us;
+    //int hours, mins, secs, us;
 
     if (!is_last_report) {
         int64_t cur_time;
@@ -1449,20 +1449,21 @@ static void print_report(OutputFile *output_files,
                                       ost->st->time_base, AV_TIME_BASE_Q));
     }
 
-    secs = pts / AV_TIME_BASE;
-    us = pts % AV_TIME_BASE;
-    mins = secs / 60;
-    secs %= 60;
-    hours = mins / 60;
-    mins %= 60;
+    //secs = pts / AV_TIME_BASE;
+    //us = pts % AV_TIME_BASE;
+    //mins = secs / 60;
+    //secs %= 60;
+    //hours = mins / 60;
+    //mins %= 60;
 
     bitrate = pts ? total_size * 8 / (pts / 1000.0) : 0;
 
     snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
-             "size=%8.0fkB time=", total_size / 1024.0);
-    snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
-             "%02d:%02d:%02d.%02d ", hours, mins, secs,
-             (100 * us) / AV_TIME_BASE);
+             "size=%8.0fkB time=%0.2f ", total_size / 1024.0, (double)pts / AV_TIME_BASE);
+    //         "size=%8.0fkB time=", total_size / 1024.0);
+    //snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
+    //         "%02d:%02d:%02d.%02d ", hours, mins, secs,
+    //         (100 * us) / AV_TIME_BASE);
     snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
              "bitrate=%6.1fkbits/s", bitrate);
 
diff --git a/configure b/configure
index a3fdbff..0519189 100755
--- a/configure
+++ b/configure
@@ -3022,15 +3022,19 @@ enabled libdirac   && require_pkg_config dirac                          \
     "dirac_decoder_init dirac_encoder_init"
 enabled libfaac    && require2 libfaac "stdint.h faac.h" faacEncGetVersion -lfaac
 enabled libfreetype && require_pkg_config freetype2 "ft2build.h freetype/freetype.h" FT_Init_FreeType
-enabled libgsm     && require  libgsm gsm/gsm.h gsm_create -lgsm
+enabled libgsm     && require  libgsm gsm.h gsm_create -lgsm
 enabled libmp3lame && require  "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame
 enabled libnut     && require  libnut libnut.h nut_demuxer_init -lnut
 enabled libopencore_amrnb  && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb
 enabled libopencore_amrwb  && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb
-enabled libopencv  && require_pkg_config opencv opencv/cxcore.h cvCreateImageHeader
+enabled libopencv  && { check_lib opencv/cxcore.h cvCreateImageHeader -lcv210 -lcxcore210 -lflann -lopencv_lapack -lstdc++ ||
+                        die "ERROR: libopencv not found"; }
 enabled libopenjpeg && require libopenjpeg openjpeg.h opj_version -lopenjpeg
-enabled librtmp    && require_pkg_config librtmp librtmp/rtmp.h RTMP_Socket
-enabled libschroedinger && require_pkg_config schroedinger-1.0 schroedinger/schro.h schro_init
+enabled librtmp    && { check_lib librtmp/rtmp.h RTMP_Socket -lrtmp -lpolarssl -lwinmm -lws2_32 ||
+                        check_lib librtmp/rtmp.h RTMP_Socket -lrtmp -lssl -lcrypto -lwinmm -lws2_32 -lgdi32 ||
+                        die "ERROR: librtmp not found or RTMP_Socket() missing, librtmp version must be >= 2.2.f"; }
+enabled libschroedinger && { check_lib schroedinger/schro.h schro_init -lschroedinger-1.0 -lorc-0.4 ||
+                             die "ERROR: libschroedinger not found"; }
 enabled libspeex   && require  libspeex speex/speex.h speex_decoder_init -lspeex
 enabled libstagefright_h264  && require_cpp libstagefright_h264 "binder/ProcessState.h media/stagefright/MetaData.h
     media/stagefright/MediaBufferGroup.h media/stagefright/MediaDebug.h media/stagefright/MediaDefs.h
diff --git a/ffmpeg.c b/ffmpeg.c
index 0ced8f8..908c548 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1382,7 +1382,7 @@ static void print_report(OutputFile *output_files,
     int64_t pts = INT64_MAX;
     static int64_t last_time = -1;
     static int qp_histogram[52];
-    int hours, mins, secs, us;
+    //int hours, mins, secs, us;
 
     if (!is_last_report) {
         int64_t cur_time;
@@ -1459,20 +1459,21 @@ static void print_report(OutputFile *output_files,
                                       ost->st->time_base, AV_TIME_BASE_Q));
     }
 
-    secs = pts / AV_TIME_BASE;
-    us = pts % AV_TIME_BASE;
-    mins = secs / 60;
-    secs %= 60;
-    hours = mins / 60;
-    mins %= 60;
+    //secs = pts / AV_TIME_BASE;
+    //us = pts % AV_TIME_BASE;
+    //mins = secs / 60;
+    //secs %= 60;
+    //hours = mins / 60;
+    //mins %= 60;
 
     bitrate = pts ? total_size * 8 / (pts / 1000.0) : 0;
 
     snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
-             "size=%8.0fkB time=", total_size / 1024.0);
-    snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
-             "%02d:%02d:%02d.%02d ", hours, mins, secs,
-             (100 * us) / AV_TIME_BASE);
+             "size=%8.0fkB time=%0.2f ", total_size / 1024.0, (double)pts / AV_TIME_BASE);
+    //         "size=%8.0fkB time=", total_size / 1024.0);
+    //snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
+    //         "%02d:%02d:%02d.%02d ", hours, mins, secs,
+    //         (100 * us) / AV_TIME_BASE);
     snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
              "bitrate=%6.1fkbits/s", bitrate);
 
diff --git a/libavcodec/libgsm.c b/libavcodec/libgsm.c
index 1541b3b..52f29e7 100644
--- a/libavcodec/libgsm.c
+++ b/libavcodec/libgsm.c
@@ -28,7 +28,7 @@
 // The idiosyncrasies of GSM-in-WAV are explained at http://kbs.cs.tu-berlin.de/~jutta/toast.html
 
 #include "avcodec.h"
-#include <gsm/gsm.h>
+#include <gsm.h>
 
 // gsm.h misses some essential constants
 #define GSM_BLOCK_SIZE 33
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
index 94ca057..7b7c6ec 100644
--- a/libavcodec/libx264.c
+++ b/libavcodec/libx264.c
@@ -531,7 +531,7 @@ static const AVOption options[] = {
     { "psy-rd",        "Strength of psychovisual optimization, in <psy-rd>:<psy-trellis> format.", OFFSET(psy_rd), FF_OPT_TYPE_STRING,  {0 }, 0, 0, VE},
     { "rc-lookahead",  "Number of frames to look ahead for frametype and ratecontrol", OFFSET(rc_lookahead), FF_OPT_TYPE_INT, {-1 }, -1, INT_MAX, VE },
     { "weightb",       "Weighted prediction for B-frames.",               OFFSET(weightb),       FF_OPT_TYPE_INT,    {-1 }, -1, 1, VE },
-    { "weightp",       "Weighted prediction analysis method.",            OFFSET(weightp),       FF_OPT_TYPE_INT,    {-1 }, -1, INT_MAX, VE, "weightp" },
+    { "weightp",       "Weighted prediction analysis method.",            OFFSET(weightp),       FF_OPT_TYPE_INT,    { 0 }, -1, INT_MAX, VE, "weightp" },
     { "none",          NULL, 0, FF_OPT_TYPE_CONST, {X264_WEIGHTP_NONE},   INT_MIN, INT_MAX, VE, "weightp" },
     { "simple",        NULL, 0, FF_OPT_TYPE_CONST, {X264_WEIGHTP_SIMPLE}, INT_MIN, INT_MAX, VE, "weightp" },
     { "smart",         NULL, 0, FF_OPT_TYPE_CONST, {X264_WEIGHTP_SMART},  INT_MIN, INT_MAX, VE, "weightp" },
@@ -569,7 +569,7 @@ static const AVClass class = {
 
 static const AVCodecDefault x264_defaults[] = {
     { "b",                "0" },
-    { "bf",               "-1" },
+    { "bf",               "0" },
     { "flags2",           "0" },
     { "g",                "-1" },
     { "qmin",             "-1" },
diff --git a/libavcodec/libxvidff.c b/libavcodec/libxvidff.c
index d8d44bf..1030f15 100644
--- a/libavcodec/libxvidff.c
+++ b/libavcodec/libxvidff.c
@@ -240,6 +240,7 @@ static av_cold int xvid_encode_init(AVCodecContext *avctx)  {
     xvid_enc_create.num_zones = 0;
 
     xvid_enc_create.num_threads = avctx->thread_count;
+    xvid_enc_create.num_slices = avctx->slices;
 
     xvid_enc_create.plugins = plugins;
     xvid_enc_create.num_plugins = 0;
diff --git a/libavdevice/libcdio.c b/libavdevice/libcdio.c
index be1c516..506149e 100644
--- a/libavdevice/libcdio.c
+++ b/libavdevice/libcdio.c
@@ -37,6 +37,7 @@
 #undef free
 
 typedef struct CDIOContext {
+    AVClass *class;
     cdrom_drive_t       *drive;
     cdrom_paranoia_t *paranoia;
     int32_t last_sector;
diff --git a/libavutil/opt.c b/libavutil/opt.c
index d749259..ff51e03 100644
--- a/libavutil/opt.c
+++ b/libavutil/opt.c
@@ -184,6 +184,7 @@ int av_set_string3(void *obj, const char *name, const char *val, int alloc, cons
             if (o->type == FF_OPT_TYPE_FLAGS) {
                 if      (cmd=='+') d= av_get_int(obj, name, NULL) | (int64_t)d;
                 else if (cmd=='-') d= av_get_int(obj, name, NULL) &~(int64_t)d;
+                else if (buf[0]=='0' && buf[1]=='x') d= strtoul(buf, NULL, 16);
             } else {
                 if      (cmd=='+') d= notfirst*av_get_double(obj, name, NULL) + d;
                 else if (cmd=='-') d= notfirst*av_get_double(obj, name, NULL) - d;
diff --git a/tests/Makefile b/tests/Makefile
index ff0aaa0..ba98bf7 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -96,7 +96,7 @@ FATE_UTILS = base64 tiny_psnr
 
 TOOL = ffmpeg
 
-fate: $(FATE)
+fate test: $(FATE)
 
 $(FATE): $(TOOL)$(EXESUF) $(FATE_UTILS:%=tests/%$(HOSTEXESUF))
 	@echo "TEST    $(@:fate-%=%)"
