Fix compilation with OpenCL on MacOS X

Also fix crash in the case of OpenCL error during encoding.
Fix building with compilers without inline asm support

Also fix crash in high bit depth builds compiled with unaligned stack.
OpenCL cosmetics
Add "--stitchable" option for segmented encoding

Stops x264 from attempting to optimize global stream headers, ensuring that
different segments of a video will have identical headers when used with
identical encoding settings.