Conflict between 'legend specfile' and 'plot -l'

Well, you are actually not giving any spec file - you are expecting legend to somehow know it should read stdin. If you instead save that info to a file and pass it to legend and use -M then both things show.