Check and convert passed ROOT_DIR