rethinkdb: fix dependencies, simplify build options and add head

When installing on some installations, node wrongly complains about an external npm. I added a patch to #15315