Cannot remove a reference in Visual Studio 2013
Question: I am building ironpython3 with Visual Studio 2013. In the references Visual
Studio shows a yellow triangle on Microsoft.Scripting.Core reference. Since I
read this reference has been moved to System.Core I simply removed the
reference to Microsoft.Scripting.Core. The project builds just fine without
this reference. But after ending Visual Studio and opening the project again,
the reference is just back. I removed all references I found (Strg-Shift-F)
from the sources, but still no change. I had a look in the .csproj file but
did not find any references there. I simply cannot remove the reference
permanently. Any ideas where to look to permanently remove the reference?
Thank you.


Answer: As Pawel said, IronPython uses a complex build system to handle all of the
platforms it supports and make it easy-ish to add new ones (at least until
IronPython and the DLR can be refactored into portable libraries ... sometime
around 2016). In this case you need to dig through a couple of levels of
imports to find where it's defined (`Build/Common.proj`).

The reason this happen is that even though the Reference is conditional (and
handled correctly) in MSBuild, VS ignores the conditional check and displays
any Reference elements it finds. Moving the Reference into `Build/net35.props`
instead should fix the display, since VS does a much better job of handling
imports.

