The presidents of Iran and Turkey discussed the war in Gaza and cooperation against Kurdish militants during a meeting on Wednesday, as the neighbors signed several agreements to boost cooperation from trade to energy.