Merge pull request #413 from ImperatorPrime/master

JK2 Support
[MP] Rewrote callvote to be far more robust
No need to include malloc on OS X.
Replaced malloc.h include with stdlib.h
Merge pull request #414 from MazterQyou/macfix

Replace inclusion of ``malloc.h`` with ``stdlib.h``.

``malloc.h`` is a deprecated header file, and specific to Linux (http://stackoverflow.com/a/12973361)
[MP] Fixed a few issues with vote code from previous commits.
Tweaked the team vote code to be a simplified but similar version of the new callvote code.
Added g_allowTeamVote, defaulted to 1 cvar to toggle team voting.
[MP] Sanity check callvote map against same checks that calling map directly on server would do.
Replaced a few erroneous instances of Com_sprintf with a single string format to Q_strncpyz in vote code.
[SP] Removed all the bg_lib.cpp, unused but still left in the jk2 cmake file.
[SP] Some JK2 work until things are a bit more clean.  May not compile.
[SP] Fixed missing endif in jk2 q_shared.h
[SP] JK2 g_client code fixes.
[MP] Plausible fix from q3mme/ent for avi record sync issues.
[SP] JK2 timeGetTime removal.
[MP] Fixed audio desync with avi record.
Fix JK2 build and runtime breaks.