Adjusted Makefiles for all backends.
Close to parity with upstream.