Support gflags/google namespace changes

Quick hack to support gflags 2.0 and 2.1, for issue #309.