Dozens of senior officials, military leaders and businessmen queued to greet the US president in Saudi Arabia.