If you are using Visual Studio (2010, for some reason) for Visual C++ Win32 project and if you want to remove the .NET Framework dependency (because VS won't let you opt-out from the start when you are creating a new project) all you have to do is to follow these steps.
1. Manually add these lines into your project file.
<PropertyGroup>
<AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences>
</PropertyGroup>
As per this KB article from Microsoft - https://support.microsoft.com/en-us/kb/2735477
2. According to the KB article "Also, in the setup project, open the Launch Condition editor and remove the “Microsoft .NET” launch condition. " but I can't find the Launch Condition editor, I'm guessing because of my VS 2010 Environment Settings, anyway if you can't see it either then just do this.
Open your project properties screen and go to the C/C++ General settings under the Configuration Properties section and make sure your Common Language RunTime Support field was set to "No Common Language RunTime Support".
3. Under your "Installer" project properties open up the "Prerequisites" screen and untick any .NET Framework stuff.
4. Now rebuild your "Installer" project (the installer project you've created for your project) and you shouldn't be seeing any more of the .NET Framework stuff under the "Detected Dependencies".
You shouldn't be seeing anymore of any ".NET" word on your "Installer" project build output logs. Otherwise you may have to remove and delete the installer project and create a new one again.
***NOTE: I am not sure if this is the case for the newer version of VS (hope it will be much more straight forward) I will try this at home with my later version of VS.
No comments:
Post a Comment