To comply with the law.
No, I don't like it either, but I also don't like the idea of corporations having the ability to flout the laws of sovereign nations because they disagree with them.
> The course of action they followed implicitly supports human rights violations
This is not a "course of action" anymore than not committing a crime is a public service. Enforcing human rights laws is not Apple or Google's job, full stop. They are corporations who's goal is to make money, and that's it. Enforcing human rights is what Governments are for.
Instead of asking "why aren't Apple and Google helping activists in Pakistan?" ask "why is Pakistan allowed to abuse it's citizenry in 2021?"