Added compilation function