A compound of formula (I) wherein R1 to R5, A, B, Z, Z1 and Z2 are as defined in the claims or a pharmaceutically acceptable salt thereof is disclosed. The compounds of formula (I) possess utility as FGFR inhibitors and are useful in the treatment of a condition, where FGFR kinase inhibition is desired, such as cancer.