Only web projects are supported by some tooling with SQL Server Compact 4.0 - why do you want to add a database to a class library - if you want to create an EDMX model, you can use the SQL Server Compact Toolbox.
Microsoft is conducting an online survey to understand your opinion of the Msdn Web site. If you choose to participate, the online survey will be presented to you when you leave the Msdn Web site.