Try again with standalone libhash
C++ linkage by renaming
extern for C++
The build is broken for now, need to find a better way to use malloc