Add dirname so that OTP can be run from any path.