[tracing] Support tracing all entry points via embind.
misc tools/shared improvements
preparations for emscripten-ports support; #2404
determine SDL system include paths in system_libs.py; #2404
Merge pull request #2893 from waywardmonkeys/trace-embind-entry-points

[tracing] Support tracing all entry points via embind.
move all ports specific code into separate files under tools/ports/ #2404
Qick & dirty fix for #2836
refactor an sdl1 test
add ports sanity check; #2404
port some tests to SDL2; combined patch including all the tests work of Charlie Birks <admin@daftgames.net> and Sathyanarayanan Gunasekaran <gsathya.ceg@gmail.com>, and some final integration tweaks (-lSDL2 => -s USE_SDL=2), keep tests disabled for now; #2404
fix port includes handling in sdl2, and make them accessible at SDL2/
enable browser.test_sdl2_key
enable all passing sdl2 tests; #2404
gl proxying improvements: framebuffer binding cache and uniform4f
emcc --clear-ports option
link to youtube video of cppcon talk
sdl_image integration
mention each port once in each process
enable all passing sdl2-image tests
Make tools/emterpretify.py import-safe by only executing itself "if __name__ == '__main__':". On Windows when using Python multiprocessing, the child processes will import the main module at launch. This means that any module that uses multiprocessing needs to be importable as a library without executing its 'task'. For reference, see http://stackoverflow.com/questions/18204782/runtimeerror-on-windows-trying-python-multiprocessing . Fixes a bug where a Windows system would hang when running emterpretify.py due to creating an avalanche of thousands of python processes.