autodetect bin name