Fix errors in ARM build