Fix configure function