made compile version more rubust