Over £5 million awarded to community groups to fight extremi