You are missing my point. I agree you need to know the in-room frequency response to accurately measure the relative distortion levels, and as @
sergeauckland said you need to know the response independent of the room or as I said must compensate for the room's response. The problem is you cannot measure the room without using your speakers to do it, so their distortion (plus whatever else is added by the signal chain, including the mic and preamp back into the PC) is added to (embedded in) the measured result. You need a scheme that separates speaker distortion from the room's response.
You can use manufacturer's or reviewer's measurements to provide a baseline for your speakers, which are often taken in an anechoic chamber or use a time-gated measurement to "take out" the room's effects.
Let me try again, then I have to get back to work: Send pink noise or a swept tone at a low level through the system and measure the response. Make it low enough that speaker distortion is negligible and record the response. Assume the ripples are due to the room and not the speakers, or at least not from speaker distortion (ripples due to drivers and such will be included but those are not nonlinear distortions). Now increase the level to the desired measurement level and repeat. SCale the room's response to the new power level and back out its effects.
Using numbers: Play a low-level set of tones at 1 kHz, 2 kHz, and 3 kHz. Say the 1 kHz is at 60 dB, 2 kHz at 66 dB (6 dB high), 3 kHz at 55 dB (5 dB low). Now play a 1 kHz tone at 90 dB and again check the 2 and 3 kHz terms (second and third harmonics). You must reduce the 2 kHz measurement by 6 dB and increase the 3 kHz level by 5 dB to determine (roughly) the actual second and third harmonic distortion terms independent of (compensating for) the in-room response. This assumes nothing changed except signal amplitude between readings. Repeat for all the other frequencies and positions desired.
HTH - Don