How do you digitally make a wave?
And I'm not sure what the point of your original question was; square sound waves do not exist so it is a non-sensical question. Sound is a harmonic phenomenon (in the linear range of normal sound pressure levels), so there are only sine waves in sound. Nothing else. No square sound "waves", no triangular sound "waves" etc.
The second you pump the output of a function generator's "square" function into a sound transducer, it becomes a bunch of superimposed harmonic (sine) sound waves. That's how a compressible gas medium works.
Edit: for the avoidance of confusion, the above is directed at @theveterans, not @VNandor. I'm sure VNandor realises that, but visitors to this forum might not.
Audacity or Adobe Audition
My point is using a square wave input, you can actually see differences between DACs (some will have a more ripple aka a bunch of sine wave overlaps using sinc function). But since you can't hear beyond 20 KHz, the 7KHz square wave will sound exactly like a 7KHz sine wave.
This is where anything above 48 KHz to even (16fs) 768 KHz and you can see differences (not in bandwidth since nobody can hear beyond 20 KHz) but on an illegal input like square waves