(thrift) perfect forwarding for FunctionRunner

Summary: So you can move `function`s in if you want.
@override-unit-failures

Test Plan: unit tests and contbuild

Reviewed By: davejwatson@fb.com

Subscribers: net-systems@, alandau, bmatheny, exa

FB internal diff: D1393077

Tasks: 3789661
Fixed Double and Float Coercion

Summary: The way that `Float`s and `Double`s were being serialized and deserialized was incorrect.  This fix introduces an endianness conversion so that floating point numbers are correctly read and written to and from the network

Test Plan: `fbconfig -r thrift/lib/hs && fbmake runtests_dev`

Reviewed By: smarlow@fb.com

Subscribers: alandau, bmatheny, jcoens, davejwatson, akr

FB internal diff: D1397957

Tasks: 4533818
Locking mappings opened with frozen::mapFrozen()

Summary: Frozen depends on random-access performance, which requires that the memory is actually locked.

Test Plan: Unit tests

Reviewed By: mhx@fb.com, lucian@fb.com

Subscribers: mhx, alandau, bmatheny

FB internal diff: D1406269
Change Round Trip tests to QuickCheck Property

Summary: This library was previously tested using arbitrary hard-coded values.  I changed the implmentation to use a QuickCheck property instead to get more coverage

Test Plan: fbmake -r thrift/lib/hs && runtests_dev

Reviewed By: bnitka@fb.com

Subscribers: davejwatson, watashi, alandau, bmatheny, jcoens

FB internal diff: D1404416

Tasks: 4533818
Add TMultiplexedProtocol (C++)

Summary:
This adds the classes needed to support TMultiplexedProtocol on Thrift/C++, as on https://issues.apache.org/jira/browse/THRIFT-1902

Minor changes were needed to build it on fbcode's version of thrift (boost::shared_ptr -> std::shared_ptr, a few methods added, etc)

Test Plan: compileandship

Reviewed By: andrewcox@fb.com

Subscribers: alandau, bmatheny

FB internal diff: D1404058

Tasks: 4556144
fix build break

Summary: fix oss build break from D1404058

Test Plan: watch jenkins.  Still need to hook it up to phab somehow

Reviewed By: paulocosta@fb.com

Subscribers: doug, alandau, bmatheny

FB internal diff: D1409347

Blame Revision: D1404058
Refactor IO Buffers

Summary: The IO Buffers defined in `thrift/lib/hs/Thrift/Transport/IOBuffer.hs` are useful for multiple applications.  This code was originally repeated in both `thrift/lib/hs/Thrift/Transport/HttpClient.hs` and `thrift/lib/hs/Thrift/Transport/Framed.hs`.  In revision D1395144 I removed it from `Framed.hs` and imported it from `HttpClient.hs`.  However, it did not make sense to have `Framed.hs` depend on `HttpClient.hs`, so I factored the code into its own file.  In addition to this, I modified it to use the `Data.ByteString.Builder` library for performance reasons.

Test Plan: fbmake -r thrift/lib/hs && runtests_dev

Reviewed By: smarlow@fb.com

Subscribers: watashi, alandau, davejwatson, bmatheny, smarlow, akr, jcoens

FB internal diff: D1398766

Tasks: 4533818
Codemod: use #include angle brackets in folly and thrift

Summary: Also changed the thrift compilers to emit code with <...>.

Test Plan: fbconfig -r folly thrift && fbmake opt && fbmake runtests_opt

Reviewed By: davejwatson@fb.com

Subscribers: ruibalp, nli, shilin, tjackson, fugalh, alandau, bmatheny, njormrod

FB internal diff: D1411225
autotools 'make install'

Summary: Makes autotools' 'make install' work for fbthrift.  Also adds a 'make installcheck' target to test that all the headers were installed correctly (so jenkins will break when one is forgotten)

Test Plan: make install; make installcheck on ubuntu, using a --prefix=/tmp/thrift

Reviewed By: tudorb@fb.com

Subscribers: doug, ruibalp, alandau, bmatheny

FB internal diff: D1408300
Only numa if available

Summary: Some systems don't support numa, make the check automatic

Test Plan: ???

Reviewed By: adhipgupta@fb.com

Subscribers: doug, alandau, bmatheny

FB internal diff: D1413394
Move thrift2 python to thrift_compiler Python package

Summary:
Because in the OSS world, a Python package can only come from one source
(so package thrift can only map to one directory), and both compiler
and thrift/lib/py want to use package thrift.

NOTE TO SELF: DO NOT FORGET TO REBUILD THE FBBUILD PACKAGE AND UPDATE VERSION

Test Plan: compiled thrift/test

Reviewed By: davejwatson@fb.com

Subscribers: simpkins, ruibalp, agallagher, alandau

FB internal diff: D1412519
Fix autoconf for thrift

Summary:
Compiling thrift2 in tree now works without resorting to hard-coding the Python
version (we add a level of indirection... I wanted to use "setup.py develop"
but that's only available with setuptools, not distutils)

Test Plan: built in OSS env

Reviewed By: davejwatson@fb.com

Subscribers: ruibalp, alandau, bmatheny

FB internal diff: D1412990