Reorganized backend and fixed install scripts