Support FreeBSD in the gr script.