OK, now I just pass different compiliation flags based on the detected OS.