Donald Trump has sparked a wave of alarm across Europe and a call for solidarity from the head of NATO after warning that the US might not come to the defence of an alliance ally under attack from Russia if that country had not fulfilled its obligations to America.