Use hash to check if command is available in mkimage scripts.

Apart from having more predictable return codes on various operating
systems, it additionally caches the path to application.
mkimage-arch: provide and use own pacman.conf