Use gcc-ar instead of ar to support the -flto option.