Cast to more specific types for cross-platform builds.
Fix linking order on linux.
Fix linux build.
Bump support submodule.