The boundary data immersion method for compressible flows with application to aeroacoustics