Are they the same?
Longer version :
Say I wrote, in assembly, on a windows machine, a small app that all it does is add 1+1 and stores it in a register. THEN, I write the exact same code on a Linux machine. Would it work?
Im thinking yes, because at the hardware level, its the same machine, so the 'language of the hardware' (forgive the inexactness) would be the same.
So Im thinking a virus targeting windows but written in assembly wouldnt just be a windows virus.
A virus will most certainly need to interact with the operating system, and use its API. Hence it is highly platform-dependant.
In addition, an executable also has a header, and this will depend on the targeted OS. If you would create a more or less empty EXE file in Windows, this would not run (not even start) under Linux.