Windows build settings reference
Configure and build your application for Windows.
Read time 4 minutesLast updated 12 days ago
Use these settings to configure how Unity builds your application for Windows platform. You can update your Windows build settings from the Build Profiles window.
Property | Description |
|---|---|
Architecture | Select the CPU to build for (only applies to Build And Run).
|
Build and Run on | Select the target device or transport to deploy and launch the app during Build And Run.
|
Copy PDB files | Enable this setting to include Microsoft program database (PDB) files in the built Player. PDB files contain debugging information for your application, but might increase the size of your Player. |
Create Visual Studio Solution | Enable this setting to generate Visual Studio Solution files for your Project, so you can build your final executable in Visual Studio. |
Development Build | Include scripting debug symbols and the Profiler in your build. Use this setting when you want to test your application. When you select this option, Unity sets the For more information, refer to Platform dependent compilation. |
Autoconnect Profiler | Automatically connect the Unity Profiler to your build. For more information, refer to Profiler. Note: This option is available only if you select Development Build. |
Deep Profiling | Allow the Profiler to process all your script code and record every function call, returning detailed profiling data. For more information, refer to Deep Profiling. This property is available only if you enable Development Build. Note: Enabling Deep Profiling might slow down script execution. |
Script Debugging | Attach script debuggers to the Player remotely. This property is available only if you enable Development Build. |
Wait for Managed Debugger | Make the Player wait for a debugger to be attached before it executes any script code. This property is visible only if you enable Script Debugging. |
Compression Method | Specifies the method Unity uses to compress the data in your Project when it builds the Player. This includes Assets, Scenes, Player settings, and GI data.
|
Windows Player build binaries
When you build a Unity title on the Windows platform, Unity produces the following files, where is the name of your application:
ProjectName- - The project executable file, that's your project application. This contains the program entry point which calls into the Unity engine when launched. The path to the source code for
ProjectName.exeis in theProjectName.exefolder:WindowsPlayer.Editor\Data\PlaybackEngines\WindowsStandaloneSupport\Source\WindowsPlayer - - The DLL file that contains all the native Unity engine code. It's signed with the Unity Technologies certificate, which lets you verify that no malicious entities have tampered with your engine.
UnityPlayer.dll - - Symbol files for debugging. Unity copies these to the build directory if you enable Copy PDB files in the Build Profiles window.
*.pdb files - - This DLL enables Introducing PIX on Windows (beta) support. Unity only creates this file if you enable the
WinPixEventRuntime.dlloption in the Build Profiles window.Development Build?
- - This folder contains all the data needed to run your application.
ProjectName_Data folder
Modify and rebuild your application
To modify your application or distribute the built code (for example, if you want to sign it or modify the built executable metadata), you must rebuild your project and place the output in your built game directory.
Modifying the built executable metadata, such as the publisher or company name is necessary to ensure that your application is correctly identified by the system. For example, various operating system tools and dialogs, such as Windows firewall use the executable metadata to display your application's information, such as the publisher or company name. The Unity Player executable included with the Unity installation is pre-built and might not reflect details specific your application. In this case, you can modify the executable metadata to include your application's information.
To modify the metadata, follow these steps:
- Enable the Create Visual Studio Solution setting to generate Visual Studio Solution files for your project and build your project in the Unity Editor.
- Open the build folder and locate a subfolder with the same name as your project. In the subfolder, find the file and open it with a text editor.
WindowsPlayerVersion.rc - Remove the lines of code that include conditional compilation directive and the corresponding
#if defined(BUILDING_UNITY_PLAYER_DLL).#endif - Modify any metadata, such as ,
CompanyName,FileVersion, orFileDescriptionas required. For more information on these fields, refer to the documentation on StringFileInfo BLOCK Statement.ProductName - Open the Visual Studio Solution from the build folder using Visual Studio and rebuild your project.