Fix bug #9952

.resource files are now generate in the intermediate build directory,
like xbuild does. This fixes bug #9952. The problem was happening when
a project was built with Visual Studio and then with XS. XS considered
the resources file to be generated, since it was generated in the
intermediate dir, but then it was trying to link it using a different
location.