It is lucky for us Scots that over the centuries our forbears piled up so many stones in so many arresting ways.

That we are never more than a few miles from an ancient monument or an architectural gem greatly enhances the pride and pleasure of life in a country that, with its grey weather and sour tribal politics, can feel like an acquired taste.

This creative energy of previous generations was just as well for another reason. For millennia, at least until the birth of "conservation" in the 18th century, it was matched by diverse forces playing havoc with what we now call the "historic environment". These destructive energies - religious, military, social and natural - were nothing if not relentless.

Consider the fate of Elgin Cathedral, arguably the star attraction of Aberdeenshire: North And Moray, the latest in Yale University Press's Pevsner Architectural Guides: Buildings Of Scotland series. Along with Aberdeenshire: South And Aberdeen (due November), it is the first in The Buildings Of Scotland's 40-year history to cover a region described as "like a country in itself, quite distinct from other parts of Scotland".

Elgin Cathedral dates from 1224 when the Pope, clearly a micromanager, ordained that the episcopate should be based there rather than the alternative sites of Burnie, Lossiemouth and Spynie. To say this edifice has had it rough would be an understatement. In 1390, Alexander Stewart, aka the Earl of Buchan, aka the Wolf of Badenoch burned down the recently completed architectural wonder of the age, along with other church property in Elgin and Forres. Why? Because in a typically tortuous passage of medieval Scots shenanigans, the Bishop had "refused to continue paying for Buchan's protection".

Twelve years later in 1402 the precincts of the presumably newly restored cathedral were attacked again, this time by Alexander of the Isles, seemingly just for the hell of it (he did do penance afterwards). Then the Reformation in 1560 meant that the cathedral was made redundant overnight, the accretions of 300 years of Scots Catholic culture were "purged", and orders given to remove the lead from the roof, causing it to blow off in 1637.

More humiliation and vandalism followed in 1640 when a local Presbyterian ayatollah demanded that the then 400-year-old carved choir screen, most likely a beautiful artefact, should be taken out and burnt "as an object of superstition". Then in 1711 the great central tower collapsed, with mordant Scots comic timing, on Easter Sunday. By the time that Johnson and Boswell came visiting in 1773, "this venerable ruin" was well into its posthumous career as a romantic skeleton prey to canny Northeasteners recycling its stones.

Previous guides to Elgin Cathedral do of course have versions of that story, and do detail the accretions of the various mediaeval "building campaigns". But this is where now to turn for the definitive account of the making and unmaking of a Scottish icon, along with the inch-by-inch assessment of the remaining evidence and the artistic effect, all in the context of the contemporary buildings. It is a blend of the precisely technical cataloguing of detail (jambs, chamfers, quatrefoil piers and responds etc) combined with the subjective, engagingly chatty appraisal of aesthetic effect, the format that fans of The Buildings Of... series know and love.

Elgin is naturally one of the longest entries in the book's 700-page 'Gazeteer', in which the features of the Northeast's 5000 or so most notable buildings, ancient and modern, rich and poor, are minutely analysed and placed in a local, national and European context. The emphasis in this volume is on the seafaring burghs past and present - Findhorn, Lossiemouth, Buckie, MacDuff, Fraserburgh and Peterhead - that were for centuries the generators of regional wealth.

You don't have to be what Philip Larkin called a "ruin-bibber, randy for antique" to be absorbed in these comprehensive catalogues of the stone legacy of Scots history and sociology. While never departing from strict architectural professionalism, these entries speak volumes about who we are and where we come from. And of course, what our buildings "say" about us, is not the same as what their builders thought they said when they built them.

Take another of the book's bigger entries, James Playfair's "internationally important" Cairness House near Fraserburgh (1791-97), paid for, we learn in passing, by a legacy from a sugar plantation in Jamaica. I admit I'd never even heard of Cairness, whose weird Egyptian Masonic features are contemporary with those in Mozart's Magic Flute. It certainly has the authors in a scholarly lather as "the only house in Britain the design and construction of which reflected and evolved with the rapid advances in French Neoclassicism... its unusual compositional massing representing a new development in architecture in Britain".

A visitor who had not browsed these pages would not necessarily think of its wig-wearing architect as being as much of an international modernist in his day as Charles Rennie Mackintosh. Nor, but for this new research, might they know how Cairness, whose "unadorned planes [are] intentionally restrained to accentuate an intrinsically monumental character" was financed.

Interesting word "monumental". A monument to what exactly? To the wealth and prestige of the Byron-related Gordon family who commissioned it? To Playfair's avant-garde daring? Or perhaps to the form of labour that helped make Scotland great? The great blank granite face of this classical masterpiece looks different in the light of what we now know.

Fans of the series will know that while it is naturally weighted towards the region's great wealth of the old, the holy and the grand (fresh takes on Haddo, Brodie, Duff House and many others), it also takes in harbours, war memorials, schoolhouses, post offices, parks, post-war bungalows - all the taken-for-granted furniture around which daily life flows, such as a gas terminal in St Fergus, a host of utilitarian distillery buildings (including the brand new one at Roseisle), and a railway viaduct at Cullen.

While Scottish totems like the mighty Fyvie Castle (1599), "a rich and relatively late Scottish Renaissance expression of the indigenous martial style, married with classical symmetry recently brought over from the Continent", Spynie Palace (14th-15th century), "one of the finest mediaeval monuments in the country", and the beautifully set Pluscarden Abbey (1231), are definitively detailed, so too are the bare standing stones and seemingly nondescript crofting villages, towns and burghs: Rothes, Forres, Keith, Turriff, Ellon.

This great reference series will soon be completed with a Lanarkshire and Renfrewshire volume, and nothing captures better the "real Scotland", with its record of our past and present social structures, our cosmopolitanism, our priorities, the legacy of our atavistic compulsions. In an age of manipulative assertion and emotionalism, the precise and the actual count for more, because, as the novelist John Updike put it, "precision is where passion begins".

Aberdeenshire: North And Moray by David W Walker and Matthew Woodworth, Yale University Press, £35