This is a common issue, and luckily its easily resolved.
For Wing Commander 1: Go to the GoG installation folder for Wing Commander 1 and open WINGCMDR.CFG (GoG.com > Wing Commander 1 and 2 > WC > WINGCMDR.cfg). There should be a line with just the letter 'r'. Replace 'r' with 'a552' and this will switch the default sound to SoundBlaster. The problem stems from the game being set by default to use the Roland MT-32 sound board, which DOSBox does not have the correct sound files for.
For Wing Commander 3: Open the shortcut for the DOSBox configuration file for Wing Commander III (GoG.com > Wing Commander 3 > dosboxWC3.conf). Scroll down to the bottom and add '- i'to WC3.exe in the autoexec section. This will cause the game to launch the installation menu first. There you can change the soundcard to General MIDI and this should restore the normal sounds. After you've done this, reopen the installation file and delete '- i' from WC3.exe so the game doesn't launch the configuration tool everytime you want to play.
These steps should solve your problems!