Don't emit sourceURL unless output differs from input.

Add test.
Fixes #1583