diff -Naur HandBrake-0.9.9/A00-version-string.patch HandBrake-0.9.9-new/A00-version-string.patch
--- HandBrake-0.9.9/A00-version-string.patch	1970-01-01 02:00:00.000000000 +0200
+++ HandBrake-0.9.9-new/A00-version-string.patch	2014-03-16 22:40:43.155293373 +0200
@@ -0,0 +1,23 @@
+diff --git a/x264.h b/x264.h
+index 225a269..7ffcdda 100644
+--- a/x264.h
++++ b/x264.h
+@@ -41,7 +41,17 @@
+ 
+ #include "x264_config.h"
+ 
+-#define X264_BUILD 142
++/*
++ * Define the full version explicitly so that it survives a git --archive.
++ *
++ * Patch will break every time X264_BUILD changes, so that we don't forget to
++ * update it ;-)
++ */
++#ifdef  X264_VERSION
++#undef  X264_VERSION
++#endif
++#define X264_BUILD       142
++#define X264_VERSION " r2389 956c8d8"
+ 
+ /* Application developers planning to link against a shared library version of
+  * libx264 from a Microsoft Visual Studio or similar development environment
diff -Naur HandBrake-0.9.9/contrib/x264/A00-version-string.patch HandBrake-0.9.9-new/contrib/x264/A00-version-string.patch
--- HandBrake-0.9.9/contrib/x264/A00-version-string.patch	2013-05-17 20:01:44.000000000 +0300
+++ HandBrake-0.9.9-new/contrib/x264/A00-version-string.patch	2014-03-16 22:49:03.031605153 +0200
@@ -1,12 +1,12 @@
 diff --git a/x264.h b/x264.h
-index e5a1600..f635d9e 100644
+index 225a269..7ffcdda 100644
 --- a/x264.h
 +++ b/x264.h
 @@ -41,7 +41,17 @@
  
  #include "x264_config.h"
  
--#define X264_BUILD 130
+-#define X264_BUILD 142
 +/*
 + * Define the full version explicitly so that it survives a git --archive.
 + *
@@ -16,8 +16,8 @@
 +#ifdef  X264_VERSION
 +#undef  X264_VERSION
 +#endif
-+#define X264_BUILD       130
-+#define X264_VERSION " r2273 b3065e6"
++#define X264_BUILD       142
++#define X264_VERSION " r2389 956c8d8"
  
  /* Application developers planning to link against a shared library version of
   * libx264 from a Microsoft Visual Studio or similar development environment
diff -Naur HandBrake-0.9.9/contrib/x264/P00-darwin-configure-clang.patch HandBrake-0.9.9-new/contrib/x264/P00-darwin-configure-clang.patch
--- HandBrake-0.9.9/contrib/x264/P00-darwin-configure-clang.patch	1970-01-01 02:00:00.000000000 +0200
+++ HandBrake-0.9.9-new/contrib/x264/P00-darwin-configure-clang.patch	2014-03-16 22:49:03.031605153 +0200
@@ -0,0 +1,11 @@
+diff -ur x264.orig/configure x264/configure
+--- x264.orig/configure	2014-01-21 16:40:15.000000000 -0500
++++ x264/configure	2014-03-11 20:33:33.000000000 -0400
+@@ -467,7 +467,6 @@
+         ;;
+     darwin*)
+         SYS="MACOSX"
+-        CFLAGS="$CFLAGS -falign-loops=16"
+         libm="-lm"
+         if [ "$pic" = "no" ]; then
+             cc_check "" -mdynamic-no-pic && CFLAGS="$CFLAGS -mdynamic-no-pic"
diff -Naur HandBrake-0.9.9/contrib/x264/module.defs HandBrake-0.9.9-new/contrib/x264/module.defs
--- HandBrake-0.9.9/contrib/x264/module.defs	2013-02-27 23:42:33.000000000 +0200
+++ HandBrake-0.9.9-new/contrib/x264/module.defs	2014-03-16 22:49:03.032605133 +0200
@@ -1,15 +1,16 @@
 $(eval $(call import.MODULE.defs,X264,x264,YASM PTHREADW32))
 $(eval $(call import.CONTRIB.defs,X264))
 
-X264.FETCH.url = http://download.handbrake.fr/handbrake/contrib/x264-r2273-b3065e6.tar.gz
+X264.FETCH.url = http://download.handbrake.fr/handbrake/contrib/x264-r2389-956c8d8.tar.gz
 X264.EXTRACT.tarbase = x264
 
+X264.GCC.args.c_std =
+
 X264.CONFIGURE.deps   =
 X264.CONFIGURE.shared =
-X264.CONFIGURE.static =
 
-X264.CONFIGURE.extra = --disable-cli --enable-static --enable-strip
-X264.CONFIGURE.extra += --disable-gpac --disable-avs --disable-lavf --disable-ffms --disable-swscale
+X264.CONFIGURE.extra  = --bit-depth=8 --chroma-format=420
+X264.CONFIGURE.extra += --disable-lavf --disable-ffms --disable-avs --disable-swscale --disable-gpac --disable-lsmash --disable-cli
 
 ifeq (1-mingw,$(BUILD.cross)-$(BUILD.system))
     X264.CONFIGURE.extra += --cross-prefix=$(BUILD.spec)-
