Fixed library setup and references