diff --git a/configure b/configure
index aa62831..3dbb211 100755
--- a/configure
+++ b/configure
@@ -2922,15 +2922,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 libtheora  && require  libtheora theora/theoraenc.h th_info_init -ltheoraenc -ltheoradec -logg
 enabled libvo_aacenc && require libvo_aacenc vo-aacenc/voAAC.h voGetAACEncAPI -lvo-aacenc
diff --git a/ffmpeg.c b/ffmpeg.c
index 80a67c1..ee46f52 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1464,21 +1464,21 @@ static void print_report(AVFormatContext **output_files,
     }
 
     if (verbose > 0 || is_last_report) {
-        int hours, mins, secs, us;
-        secs = pts / AV_TIME_BASE;
-        us = pts % AV_TIME_BASE;
-        mins = secs / 60;
-        secs %= 60;
-        hours = mins / 60;
-        mins %= 60;
+        //int hours, mins, secs, us;
+        //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);
+        //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 1f76f82..2040fb5 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 cc5b983..317bcdd 100644
--- a/libavcodec/libx264.c
+++ b/libavcodec/libx264.c
@@ -259,6 +259,8 @@ static av_cold int X264_init(AVCodecContext *avctx)
     x4->params.analyse.i_direct_mv_pred  = avctx->directpred;
 
     x4->params.analyse.b_weighted_bipred = avctx->flags2 & CODEC_FLAG2_WPRED;
+    if (!x4->profile)
+        x4->params.analyse.i_weighted_pred = avctx->weighted_p_pred;
 
     if (avctx->me_method == ME_EPZS)
         x4->params.analyse.i_me_method = X264_ME_DIA;
@@ -296,8 +298,8 @@ static av_cold int X264_init(AVCodecContext *avctx)
     x4->params.rc.f_pb_factor             = avctx->b_quant_factor;
     x4->params.analyse.i_chroma_qp_offset = avctx->chromaoffset;
 
-    if (!x4->preset)
-        check_default_settings(avctx);
+    //if (!x4->preset)
+    //    check_default_settings(avctx);
 
     if (x4->preset || x4->tune) {
         if (x264_param_default_preset(&x4->params, x4->preset, x4->tune) < 0)
diff --git a/libavcodec/libxvidff.c b/libavcodec/libxvidff.c
index 9b5c17c..b4cbfd8 100644
--- a/libavcodec/libxvidff.c
+++ b/libavcodec/libxvidff.c
@@ -239,6 +239,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/libavcodec/mpeg12.c b/libavcodec/mpeg12.c
index bd858a5..8538e3d 100644
--- a/libavcodec/mpeg12.c
+++ b/libavcodec/mpeg12.c
@@ -2340,7 +2340,7 @@ static int decode_chunks(AVCodecContext *avctx,
             if(s2->pict_type != AV_PICTURE_TYPE_B || avctx->skip_frame <= AVDISCARD_DEFAULT){
                 if(HAVE_THREADS && (avctx->active_thread_type & FF_THREAD_SLICE)){
                     int i;
-                    av_assert0(avctx->thread_count > 1);
+                    assert(avctx->thread_count > 1);
 
                     avctx->execute(avctx, slice_decode_thread,  &s2->thread_context[0], NULL, s->slice_count, sizeof(void*));
                     for(i=0; i<s->slice_count; i++)
@@ -2509,7 +2509,7 @@ static int decode_chunks(AVCodecContext *avctx,
 
                 if(HAVE_THREADS && (avctx->active_thread_type & FF_THREAD_SLICE)){
                     int threshold= (s2->mb_height*s->slice_count + avctx->thread_count/2) / avctx->thread_count;
-                    av_assert0(avctx->thread_count > 1);
+                    assert(avctx->thread_count > 1);
                     if(threshold <= mb_y){
                         MpegEncContext *thread_context= s2->thread_context[s->slice_count];
 
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index a57677c..9ea7062 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -635,8 +635,9 @@ AVFilter *avfilter_get_by_name(const char *name)
     int i;
 
     for (i = 0; registered_avfilters[i]; i++)
-        if (!strcmp(registered_avfilters[i]->name, name))
-            return registered_avfilters[i];
+        if (registered_avfilters[i]->name)
+            if (!strcmp(registered_avfilters[i]->name, name))
+                return registered_avfilters[i];
 
     return NULL;
 }
diff --git a/libavutil/opt.c b/libavutil/opt.c
index c0b529b..4ba817e 100644
--- a/libavutil/opt.c
+++ b/libavutil/opt.c
@@ -183,6 +183,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;
