You wouldn’t build ships on the surface of mars because you couldn’t lift a large ship to orbit.
However if you want to print structures on mars with martian “concrete” using the abundant martian sulfur mixed with native sand and gravel. Sulfur melts to liquid at a low temperature and solidifies rock hard pretty quickly. You could probably print it into structural walls.
NASA funded experiments have shown that Sulfur concrete is too unstable when heated in Sunlight, and is too massive and brittle for usage in structures requiring certain heavy load bearing stresses. Instead, metal powders sintered with regolith has promise for certain types of ground structures and road surfaces, but would be economically challenging for some such applications.
Spacecraft need to be constructed from iron, steel, aluminum, titanium, other metals, and plastics mined and forged in the asteroids in order to be economically feasible to build and operate outside of the gravity wells.