Using VisualStudio 2010 to create a SharePoint2010 solution, I want to deploy my solution to selected WebApplications (not to all). I can do this, by switching Assembly Deployment Target (Project Property) to WebApplication. But then, the assembly will not be deployed to the GAC.
Is there a setting which allows deployment to specific WebApplications, but deploys the Assembly to the GAC?
EDIT: Maybe the question is hard to understand, so here an example:
On a SharePoint Farm every customer hat one WebApplication. A custom feature, ordered by a specific customer, should only be usable on the WebApp of the customer. The feature should not appear in the SiteCollection features or WebSite features of other WebApps.
But the feature scope has to be Site or Web to be activated only in parts of the customers Portal.
Ok, now I got it: SharePoint will ask for a WebApplication to deploy to as soon as the WSP contains a SafeControl element. So if you add a dummy web part to the VS project or directly add a SafeControl element to the package in VS, the WSP will not be automatically globally deployed.