Thanks for the answer.
This is the result of my research:
Starting from VS2010 Microsoft changed the rules mechanism. It extended the concept of rules and instead of one file (.rules), now you have three files (.xml, .targets, .props). Also, the default locations for the "rules" is no more VS Installation Dir\VC\VCProjectDefaults but
..MSbuild\Microsoft.Cpp\v4.0\BuildCustomizations\.
How did I proceed:
Is there a way to create these new three files from the old .rules file?
Yes. The only tool available is VS itself. First of all, make a working copy of your project. Second, before removing the nasm.rules file from VCProjectDefaults folder, copy it into your project folder (whatever project you have that uses nasm). Reload your project from VS2008. Right click on the workspace | project |Custom Build Rules...
Uncheck the previous nasm rules option if there is still available. Click on Find Existing button and select the nasm.rules you copied into the project folder and check it. Save all and close VS2008. In this way we have the project .vcproj depending directly from the rules that resides in the project folder. VS2010/2012 conversion utility seems to have problems if the rules resides into VCProjectDefaults folder.
Load the VS2008 project from VS2010 or VS2012. After project conversion, VS should have created three new files, .xml, .targets, .props.
At this point you can leave the three files in your project folder or you can copy them into MSbuild\Microsoft.Cpp\v4.0\BuildCustomizations\ MSbuild folder. In either case you need: right click on the workspace | project |Build Custmizations... menu itemand check the nasm rules option.
Issues:
- In my opinion the conversion utility doesn't work well. In any case I was able to process the file with nasm as I did with VS2008.
Open the .targets file and replace the "%gt;" with ">".
- there is a very little difference in one file (of the three) between VS2010 and VS2012 utilities conversion. You can see it with a diff tool (like WinMerge).
- If you right click on the workspace | project | properties and go to Netwide Macro Assembler | Command Line settings you can see bad characters like mine "nasm.exe -Xvc -o "MyRawImageFile.img" -D -U -l "" -I" instead of "nasm.exe -Xvc -o "MyRawImageFile.img" -f bin" from VS2008. It's only a presentation problem, since when you go to assemble the file it works well.
My test PC:
-Win7 64 bit
-VS2008 prof
-VS2010 prof
-VS2012 express.
I think with a little work one can fix the issues list above but I'm not an expert of the new Microsoft (.props, .xml, .targets) mechanism and actually I don't have time. Maybe someone else can fix those.
My files:
http://sdrv.ms/XLv6uRLet me know if you are unable to see and download the files.
EDIT: fixed some English words above.