Fix warnings in shared builds.