If I'm understanding the problem correctly when you connect to iTunes it usually syncs automatically, but with no library file after the virus it will be unable to find the file so wipe the iPod. Can you not just set iTunes to manual sync only? Open iTunes on the computer, go to preferences, devices, tick the box that says 'Prevent iPods, iPhones, and iPads from syncing automatically'. All the stuff on the iPod should be fine after this and then you control what you put on there, not iTunes.
I'm only applying common sense here and can't guarantee it will work, but that's what I'd do. I've never synced automatically.