Most sources explain how the metal rings are woven to form the armor but never how they made those chains to begin with.
The rings were almost always made by alternating solid rings with rings that were riveted shut.
The solid rings were punched from a sheet of iron that was hammered out flat.
The riveted rings were made from wire, which was probably manufactured using a draw plate (a metal plate with increasingly narrow holes - you pull the wire through the holes in sequence, and it comes out thinner and thinner). The wire was then wrapped around a rod to give it the desired shape + diameter, and cut off the rod (probably with a chisel). The ends of the wire ring would be cut so that they overlapped; after the rings were woven together, these overlapped ends would be hammered together and secured with a small metal rivet.
A reenactor conducted some very thorough experiments in replicating the mail from the 9th century Gjermundbu grave (the same grave from which the famous 'viking' helmet with occulars was recovered). It's worth a look if you want to see some thoughtful discussion of the sources he used (he cites a number of useful archaeological references for tools and processes), and the technical issues he encountered and solutions he imagined to overcome them. It's what we'd call experimental archaeology - an attempt to reconstruct past processes that may or may not be precisely correct, but nevertheless gives us deeper insight into the material culture of the past.