Fix static linking gflags and glog