I want to start by adding to the many tributes which have been paid to Liam Cosgrave. He was, I know, a giant of Irish politics – someone whose life spanned the lifetime of the Irish state; who was foreign minister when Ireland joined the United Nations; and who became Taoiseach in 1973 as Ireland was beginning, in his words, "a new career of progress and development in the context of Europe". I am sure that all of us today are thinking of his children and loved ones.

I also want to add my congratulations to Jim and to Dublin for winning this magnificent Sam Maguire Cup for a third consecutive year. It is an outstanding and of course historic achievement.

I hope you'll forgive me, though, if I confess that my thoughts this evening are more with current events at Hampden Park rather than recent ones at Croke Park.

I've been discreetly trying to receive regular updates on Scotland's world cup qualifier against Slovakia – I'm grateful to the chambers for scheduling my speech to start straight after the final whistle!

Those of you who are aware of Scotland's group position will understand that I am also closely following England's game against Slovenia - everybody in Scotland is passionately supporting England tonight, which, of course, is always the case!

And finally, and very very importantly, I also of course wish Ireland well in your match against Moldova tomorrow night.

In some ways it is appropriate that I'm starting my remarks - unusually for me - with some football references. I understand that the last Scottish person before me to deliver the keynote address at this dinner was Sir Alex Ferguson, in 2014. Unlike Sir Alex, however, I will try to stay away from divisive and controversial subjects - such as Roy Keane - and stick instead to safer, more consensual ground - such as Brexit…

Before I do that, however, let me say what an honour it is to address this annual dinner – the largest and most prestigious gathering in Ireland's business calendar.

I understand that the Dublin Chamber of Commerce has been in existence since 1783, when tumultuous political times – such as the end of the War of American Independence - were thought to require "a general union among trades and a constant unwearied attention to their commercial interests."

For over 200 years that unwearied attention has benefited Dublin's business community and this city more generally.

That's something which, of course, matters deeply to all of you. But actually, it matters to me and to Scotland as well.

I have lived all of my adult life in Glasgow. And so I see every single day the extent to which Scotland is shaped by the bonds we share with Dublin and with Ireland. Those ties - of trade, friendship, culture and kinship - enrich both of our countries.

I've just come from a meeting with the Taoiseach. And one point we both absolutely agreed on is that those ties now are not just stronger than ever - they are also more important than ever.

That's partly because of the shared challenge that Ireland and Scotland face in Brexit. But it's also because of the shared opportunities we have for economic co-operation. So the main message I want to convey tonight is that there are major benefits – for businesses in both our countries – if we can build even closer connections together.

However as you might expect I will start by commenting on Brexit. As I'm sure many of you know, 62% of the people who voted in the EU referendum in Scotland chose to remain in the EU.

That's maybe not surprising, especially perhaps from an Irish perspective. As a small nation, Scotland has been pooling sovereignty, in one form or another, for many years – and that wouldn't change if we became independent. We've become comfortable with the idea of overlapping identities – whether those identities are Scottish, British, European, Celtic, Polish or Pakistani.

And the sense that small countries can be equals in a partnership of many, is something that appeals to us.

And so in Scotland –and this is contrary to a point the Prime Minister made in Florence two weeks ago –many people in recent decades have felt absolutely at home in Europe.

The fact that the UK Government is committed to leaving the EU means that that Scotland – like Ireland, and like Northern Ireland – now faces a dilemma which is not of our choosing. We want to remain a full member of the EU but face being taken out against our will.

We deeply regret that. However we believe that if the UK is determined to leave the European Union, it should remain a member of the single market and the customs union.

In my view, that is the obvious compromise solution. It's democratically justified – the vote to leave was a very narrow one across the UK, and two of the four nations of the UK chose to remain.

It's also clearly economically desirable. Leaving the single market will be deeply damaging for Scotland's businesses, for our universities, for trade and for jobs.

In addition, the difficulty of attempting to find solutions outside the single market is becoming clearer by the month.

I watched the Prime Minister's Florence speech two weeks ago. Like many of you, I suspect, I welcomed some elements of that speech.

The acceptance of the need for a transition period was long overdue. There was also finally some recognition that the UK must agree a financial settlement. And the high level aspirations that the Prime Minister expressed in relation to Ireland were vitally important and were also, I am sure, ones that all of us share.

But regrettably, there is still very little detail about how the UK Government's proposals might work in practice.

Part of that is because of the inherent complexity involved in trying to achieve the UK Government's aims. As it is discovering, it is very difficult to leave the single market while also forming a "comprehensive and ambitious economic partnership with the rest of Europe".

But in addition, the UK Government has taken a remarkably long time to face up to issues which could have been addressed more quickly - such as the financial settlement, and even more importantly, the rights of EU citizens. And failure to address these issues - and the rights of EU citizens is a moral as well as a practical issue. I feel very strongly that people who have chosen, whether they come from Ireland or Germany or any other part of the European Union, if they've chosen to make my country, Scotland, their home then they are welcome there and we are thankful for their contribution. So that is a moral issue. The failure, even in a practical sense, to resolve these issues inevitably delays the proper consideration of detailed technical issues that require to be resolved.

The impact of those delays is particularly important here in Ireland. There is widespread agreement on key aims – such as preserving the gains of the Good Friday agreement, and ensuring there is no physical border between the north and south. But the UK Government's vagueness – more than 15 months after the referendum - makes it hard to understand how those aims will be achieved. That needs to change quickly.

I mentioned earlier that I've just come from talking to the Taoiseach. I was reminded that the first time he was ever eligible to vote, was in the 1998 referendum which ratified the Good Friday Agreement.

I was very struck by that – partly, I have to say, because it's quite rare for me to meet national leaders who are younger than I am! So it was slightly disheartening to realise that by the time the Taoiseach was casting his first vote, I had already stood as a candidate – unsuccessfully, I may add – in two UK Parliamentary elections!

But more importantly, I was struck by that point because it's a reminder of the extent to which the Good Friday Agreement has become part of the fabric of everyday life in Ireland. It's been in place for the entirety of many people's adult lives.

It's the vital importance of it that makes it so shameful how little attention was paid and still is paid – in discussions in the UK media and the Westminster parliament – to the possible implications of Brexit for Ireland and for Northern Ireland. In fact to my mind, one of the strongest of many strong arguments for remaining in the Customs Union, is that it will make the issues facing this island easier to resolve.

And so I suppose my first message to you all is this. On virtually every issue of substance relating to Brexit, the Irish Government – and the Irish business community as a whole – has an ally in Scotland.

Like you, we didn't want Brexit. Like you, we support single market and Customs Union membership. And like you, we know that Ireland's circumstances require particular and careful attention, and we will argue strongly for an open border. We believe that those positions are in the best interests of Scotland, of Ireland, and of everybody on these islands.

There's one further issue relating to Brexit which I want to raise this evening, since it links to the economic points I'm about to come onto.

The UK's vote to leave the EU had many causes. But it seems likely that one of them was economic inequality – inequality which feeds a sense of disillusionment and disenfranchisement among many people.

That sense of disillusionment is not confined to the UK. John Simpson was the keynote speaker at this dinner last year. I understand that he made a prediction about the US elections. He said "I personally don't think he's going to get elected. I really don't."

John Simpson was of course expressing a widely held opinion – and maybe also a widely held hope! The political events of the last 2 years have taken many people by surprise. But actually, if too many people feel left behind by the status quo - if they don't feel that they benefit from a global economy – then we really shouldn't be surprised if that is reflected in how they vote.

That's why I think that political developments around the world have posed a challenge for those of us who support trade, who welcome immigration and who believe that the benefits of globalisation, if properly managed, should outweigh the costs. They challenge us to do even more to build a fair and inclusive society. It is the best, and perhaps the only, way to sustain support for a dynamic and open economy.

In Scotland, inclusive growth is already a key part of our economic strategy. One element of that is that we recognize that there is a strong economic imperative behind many of our key social policies – such as expanding childcare, and improving attainment in education.

We also understand the importance of housing. In fact, housing – together with homelessness – is one of the issues I've just discussed with the Taoiseach. I'm well aware that it is a major issue here in Dublin. Scotland has a reasonably good record. We are building new homes at a faster rate than anywhere else in the UK - but we know we need to continue investing.

We also need to do more to make sure that work pays and that people who work hard feel that work is fair. And we are doing that in many ways in Scotland, not least through promotion of a proper living wage. We have a living wage accreditation programme in Scotland, encouraging companies to do the right thing and then be accredited for it.

When I became First Minister in 2014, there were approximately 50 accredited living wage employers in Scotland. Now, there are more than 900. A higher proportion of employees in Scotland are paid the living wage, than in any other country in the UK.

Scotland certainly hasn't got everything right, but - like Ireland - I think that we are at least facing up to the right issues. That's important from a political, social and moral perspective – and it's also crucial to ensuring that our economic policies are successful and sustainable.

In addition, Scotland, like Ireland, is not going to win from a global race to the bottom. We need to compete instead on quality, innovation and high skills levels.

Last month, the Scottish Government's Programme for the year ahead set out how we intend to do that. A key point about our programme was that in many ways, it wasn't just a set of proposals for the next year – it was a plan for the coming decades.

There are some parallels here to the work the Chambers is doing to think about what Dublin will look like in 2050.

And in fact, I was quite struck by a comment made last year by Derry Gray when he was talking about that work. He acknowledged that nobody can predict the future, but then said - "it's not about being right, it's about being ready".

Scotland, too, is making itself ready for the decades ahead. For example last month we announced plans for all new cars in Scotland to be electric or ultra-low emission vehicles by 2032. We are making infrastructure decisions now – for example when widening or building roads - to make that change possible.

We see environmental benefits in that step. And we see big economic benefits too. Scotland already has strong capabilities in technologies such as smart grids and battery storage – and if we set a clear ambition to lead technological change, not trail in its wake, we will better position ourselves to be the inventor and producer of new technologies, not just the consumer of them.

We are taking other steps to promote innovation. We're significantly expanding our support for business research and development – an area where Scotland currently lags quite a long way behind Ireland. We're also establishing a National Investment Bank to provide long term patient capital for businesses in Scotland. And we're supporting sectors - such as fintech and the screen industry - where Scotland clearly has major growth opportunities.

In all of this – even as we look to the future - Scotland starts from a position of significant strength.

We have outperformed every part of the UK apart from London for attracting inward investment. We have a highly skilled workforce, and more world class universities per head of population than any country in the world, except for Luxembourg.

We have an international reputation in established sectors such as advanced manufacturing, financial services, oil and gas, life sciences, food and drink and tourism.

And we also have key strengths in important areas for the future – such as informatics, data analysis, sensor systems and renewable energy. If you look at renewable energy, for example, Scotland has extraordinary capabilities. We're already home to the world's largest tidal power array, and in two weeks' time, I will open the world's largest floating windfarm.

But we still need to do more. We must build on our strengths, not rest on our laurels. And I believe that Scotland, like Ireland, is well placed to meet the challenges of the decades ahead.

Because of that – and this links back to my views on why Brexit is such a mistake – we want Scotland to be an outward-looking, internationalist, dynamic economy. We want to export goods around the world, and we want to attract talent from the rest of the world.

That is reflected in Scotland's approach to immigration. We benefit hugely from the fact that so many people from around the world – including 15,000 people from Ireland - have chosen to live and work in Scotland. We are delighted that they do us the honour of making their home in Scotland.

There are similarities there with Ireland. But whereas Ireland and particularly Dublin are planning for significant population increases, Scotland faces a risk – because of Brexit - that we could have a declining working population again. That's why we are now arguing for immigration powers to be devolved to Scotland.

And, as well as encouraging people to come into Scotland, we are encouraging Scottish businesses to look outwards. In recent years we have expanded our enterprise agencies' presence in key markets around the world.

Since the EU referendum, we have placed a particular emphasis on Europe. So we are doubling the number of people employed on mainland Europe by Scottish Development International.

We are also establishing innovation and investment hubs in Berlin and Paris, to complement those we have already established in London and here in Dublin. Despite Brexit, we want to strengthen rather than diminish the links we have with some of our closest neighbours and biggest trading partners.

And few places are more important to us than Ireland.

Ireland is already Scotland's 6th biggest export market. More than 100 Irish companies currently invest in Scotland. Many of you are represented here tonight. I thank you for the work you do in Scotland.

These connections are already bringing benefits to employees and customers in both Scotland and Ireland.

For example, I mentioned renewable energy earlier. When I came to Dublin last year, I visited the headquarters of SSE Airtricity. While I was there, I heard about their Galway wind farm project. It is helping Ireland to meet its renewable energy targets.

Meanwhile, Irish firms are helping Scotland to meet our targets. Mainstream Renewable Power has been given consent to build a major offshore wind farm off the East coast of Scotland. When it is completed, it will provide enough energy to supply almost 300,000 homes.

Now, there will inevitably be occasions when Scotland and Ireland are competitors – for example when we seek inward investment. But the opportunities for mutual benefit are far more numerous. I believe we can build much stronger links – a Celtic Business Corridor, if you will – which would benefit all of us.

There is certainly the political will to develop closer connections.

But of course the key to closer economic links lies with all of you and with your businesses. That's why I'm delighted that the West Lothian and South Dublin Chambers of Commerce - who signed a memorandum of understanding last month – are both in the room tonight. We also have a delegation here from the Scottish Chambers of Commerce, who are discussing how they can work more closely with the Dublin Chamber of Commerce.

And I know that PWC are organizing an event in Dublin next week. It will bring together companies and leaders from the Scottish and Irish financial services sector. Several of Scotland's fund management and fintech firms will be there – as will Derek Mackay, the Scottish Government's Cabinet Secretary for Finance and the Constitution. The companies will be thinking about the scope for future collaboration, for example in the development of supply chains.

There are many other sectors where Scotland has key strengths and where Ireland also has important interests – for example tourism, creative industries and digital technology. Irish investors play a big part in Scotland's food and drink industry – which has been a huge success story in recent years. In all of these areas, a sense of enlightened mutual self-interest might guide us to work more closely together.

After all, when you consider our geographical proximity, our historic and cultural ties, and also the many economic opportunities and challenges we share– when you consider all of those, I believe that co-operating more closely is not just desirable, but essential.

At the start of this speech I mentioned the fact that these Dublin Chambers were established in the same year that the American War of Independence ended. The connections between Ireland and the USA are of course an enduring part of Ireland's story, and they are relevant to the quote I want to end with tonight.

One of the finest speeches given in Ireland's post war history was the one delivered by President Kennedy to the Dail Eireann in 1963. He was speaking at a time when, as he put it, "modern economics, weapons and communications have made us realise more than ever that we are one human family and this one planet is our home."

In that context, he spoke approvingly of Ireland's role as a "prospective member of an expanded European Common Market". And he expressed the view that Ireland's "remarkable combination of hope, confidence and imagination... is needed more than ever today."

Those words seem to me to be as relevant now as they were in 1963.

Brexit will undoubtedly cause Ireland difficulties in the years ahead, just as it will cause difficulties for Scotland. However in my view, our anxiety about those difficulties should be balanced with optimism – optimism about the immense potential of our nations: based on our international reputation, our natural resources, and most of all, our people.

So let's work together – with hope, confidence and imagination - to maximise that potential. Let's devote "unwearied attention" to developing the links between our nations . And let's work ever harder – not just to address the challenges of the modern world, but to seize the countless opportunities we have for economic and social progress.

By doing that, we can bring benefits to Scotland and to Ireland, and hopefully to all of the peoples of these islands.