Smelting converts a metal oxide ore to the metal. The output is typically a standard-sized metal bar. It requires substantial thermal energy, and often some chemical input such as carbon (e.g. coke on Earth, but coke is not readily available on Mars) or hydrogen. Mars has abundant iron oxides and substantial aluminum oxides, and it's possible (though by no means certain) that good quality ores of other metals (e.g. copper oxide) may be found. Considerable separation of the desired ore from other Martian soil constituents will generally be required before it is suitable as smelter input.
For aluminum smelting thermal power is insufficient; high amounts of electrical power are required.
If a suitable native source of carbon can be found, small-scale smelting of iron ore requires only other small-scale crafts for its equipment and raw materials (brick-making for the furnace), thus qualifies as a small-scale craft suitable for a frontier town (small and largely self-sufficient) economy. The bars produced by smelting are the raw materials of the blacksmith. Alternatively, meteoric iron may be available, in which case small-scale iron smelting is not required, only the melting of the iron and casting into bars.