BSD make support

Replacing GNU `$(actions)` with BSD's and splitting them out to BSDmakefile and GNUmakefile.
Added `$(OS_LIBS)` which will not contain `-ldl` on BSD systems
Using `.SUFFIXES` to turn the `%.so: %.c` GNUism into a `.so.c` rule supported by both gmake and make.