Merge pull request #51 from vMcJohn/master

codegen now only runs when needed
Fix libvogltrace64 crashing bash

- Could repro via this command:

LD_PRELOAD=$(readlink -f libvogltrace64.so) bash -i -c "if true; then
echo blah; fi"

- Problem was our global constructors allocating memory before our
memory system initialized.
- Signal handlers getting called and constructors getting called
again.
- Assert code allocing memory (which is bad when memory code is
asserting).

Killed most of the static constructors. Since we are a library
being loaded into other applications, we should not use them.

http://llvm.org/docs/CodingStandards.html#do-not-use-static-constructors

- Enable global-constructors warning by default with Clang.
- Add Wno-global-constructors to vogleditor makefile.
- g_gl_enums -> get_gl_enums()
- g_get_desc -> get_gl_get_desc()
- g_vogl_internal_texture_formats -> get_vogl_internal_texture_formats()
- g_internal_format_hash_map -> get_internal_format_hash_map
- g_dynamic_module_cache
- Move g_well_known_string_hashes to local function.
- g_vogl_capture_path, g_vogl_capture_basename -> get_vogl_intercept_data()
- g_vogl_trace_mutex -> get_vogl_trace_mutex()
- g_vogl_trace_writer -> get_vogl_trace_writer()
- g_context_manager -> get_context_manager

- COMPILER_GCC -> COMPILER_GCCLIKE for JPGD_NORETURN

- Switch g_vogl_has_been_initialized to bool (doesn't need
to be atomic w/ pthread_once).
- Add create_if_not_set param to vogl_context
get_current().

There are still several global ctor warnings that I
need to go through and fix.
Add comment about static init/deinit order.
Set g_number_of_processors for gcc like compilers, not just gcc.
Clean up some vogl_debug_break code.
Use vogl_deinit for vogl_deinit().
Disable vogl remoting until debug out warning spew.
Kill check_for_sse_4_1_support, clean up reliable tsc check.
Kill m_output_funcs global constructor.
Kill g_empty_dynamic_string global constructor.
Kill get_null_json_value global constructor.
Fix cr-lf endings in vogl_json.inl.
Kill g_vertical_cross_image_offsets global constructor.l
Kill g_random,g_fast_random,g_thread_safe_random global constructors.
Kill uuid global constructors, fix whitespace.
Kill g_vogl_process_gl_ctypes,g_vogl_entrypoint_hashmap global constructors.
Kill g_command_line_params global constructors.
Kill g_quad_tri_verts global constructors.
Add vogl_core_init()
- Explicitly use this instead of relying on global constructors.
  They don't work well with static libraries (can get optimized out).

 http://www.gamedev.net/topic/622861-how-to-force-global-variable-which-define-in-a-static-library-to-initialize/

- Kill vogl_global_initializer.
- Kill global_heap_constructor.
- Add VOGL_CONSTRUCTOR_FUNCTION macro.
- Fix g_number_of_processors check on Linux.
Fix m_block_y_mcu shadow and extra m_block_y_mcu memset.