Check the step in section 6. of this article. It should solve your problem:
Thanks a lot!
Of course, I had the version of System.ComponentModel.Composistion.dll that is installed with .NET 4.0 referenced, replacing this reference with the one included in the EPiServer installation solved the problem.
I'm trying to add an initialization module to a new .NET 4.0 project, but compile fails after adding the [InitializableModule] attribute to the class, stating that:
1. The type 'System.ComponentModel.Composition.ExportAttribute' is defined in an assembly that is not referenced by EPiServer.Framework.dll
2. EPiServer.Framework.InitializableModuleAttribute is not an attribute class.