separating backend code into a library
adding `make install prefix=/path/` functionality