I’ve found a diplomatic solution to the Gibraltar problem: we tell the Spanish that we’d be happy to return the rock to its rightful owners. Its rightful owners, of course, are the people who controlled it for 700 years, and agreed to give it up only under duress: the Moors.
This would leave us only with the task of finding the modern day successors to the Caliphate. I think Al-Qaida have a strong case, since their aim is to establish a new one; Gibraltar would be an excellent base for such an endeavour.
As a next step, Spain ought to cede control of Andalusia, which was stolen from the Moors at the same time (perhaps Al-Qaida could somehow persuade the Spanish people that this would be a good idea). With the Gibraltan and Andalusian problems solved, southern Europe could enter a new era of peace and prosperity.
This also seems like an opportunity to mention my plan that we give the Malvinas back to Argentina, on the condition that the Argentinians all move there and give the mainland back to the four remaining Indians that their ancestors forgot to slaughter. I had a similar plan for dealing with Hong Kong, but it fell down on the (in my opinion minor) grounds that it would have led to global nuclear war and the death of everyone in the UK.
To summarise, I’d be marginally better than the current US administration at running foreign policy.
(thanks to libertarian lunatics Francis Turner and Ed Thomas for facts and inspiration).