If you get the error message Component returned failure code: 0x80520012 when trying to install a greasemonkey script then you need to create a gm_scripts directory in your profile directory and then create an empty file called config.xml in this directory. I got the information from iPodWizard.net where someone had the same problem. I must admit that the solution is not very obvious from the error code.
As to the reason it happened? I think it’s because the restore of my firefox profile didn’t include that directory for some reason. It turns out that this is because I restored my profile using mozbackup which doesn’t backup this directory. I’ve requested this feature/bug in the next version.