In Canada the Prime Minister (or a Premier) does not have the power to fire Crown Counsel for political reasons - federal and provincial Crown Counsel are public servants and subject to the jurisdiction of the individual provincial law societies. Deputy AGs even usually stay on government change.

Per the Canons of Legal Ethics at 2.1-1 (b)

"When engaged as a Crown prosecutor, a lawyer’s primary duty is not to seek a conviction but to see that justice is done; to that end the lawyer should make timely disclosure to the defence of all facts and known witnesses whether tending to show guilt or innocence, or that would affect the punishment of the accused. " 

Per the BC Code of Conduct (there are similar provisions in other provinces):

"Duty as prosecutor

5.1-3  When acting as a prosecutor, a lawyer must act for the public and the administration of justice resolutely and honourably within the limits of the law while treating the tribunal with candour, fairness, courtesy and respect."