Revert "link and compile flags do not accumulate module after module, they are rest after each one. This prevents unwanted flags such as openmp being added."

This reverts commit 54d996817e94e7d4d81d3d3c8161184e80f8a655.