Fixes Cython compilation errors, minor bugfixes

interface.pyx wasn't linking properly to the botting libraries; after
editiing the Makefile to use the proper flags for compiling and linking
all of our dynamic libraries, it is linked properly, but importing
libinterface.so from pure Python hangs, for some reason. db.* has been
renamed django_db.*, because there is already a libdb.so in the
LD_LIBRARY_PATH, which was causing our libraries to link incorrectly;
rather than deal with system specific configuration, I renamed the
library.