Unity linux build support

Linux Build Settings

To create a build for Linux, go to File > Build Settings from Unity’s main menu. In the Platform list, select Linux and then click Switch Platform.

When you have configured the Build Settings, choose from the following two options:

Linux build settings in Unity

  • Build builds your application into a Player
  • Build and Run builds your application in a Player, and opens that Player on your target platform.

Scenes in Build

The Scenes In Build pane displays a list of the Scenes from your Project that Unity includes in the build. If you can’t see any Scenes in this pane, select Add Open Scenes to add all the currently open Scenes to the build. You can also drag Scene Assets from your Project window A window that shows the contents of your Assets folder (Project tab) More info
See in Glossary into this window.

To exclude a Scene in the list from the build, clear the checkbox next to that scene. This removes the Scene from the build, but not from the list. To remove a Scene from the list, select it and press the Delete key on your keyboard.

When you select Build or Build and Run, Unity creates a build that includes all Scenes in the Scenes in Build list. Unity uses the list of Scenes to determine the order that it loads the Scenes in. To adjust the order of the Scenes, drag them up or down the list.

Platform list

The Platform pane lists all platforms available in your Unity Editor. The list displays the Unity icon next to the name of the platform currently selected as the target platform.

Unity determines the platforms available to you depending on the platform modules you have installed.

To install further platform modules to your Project, do the following:

  • Go to the Unity Hub and select the version of Unity you want to add the module to.
  • Click the vertical ellipses and select Add Modules.
Читайте также:  Linux top desktop environments

To change the target platform, select the platform you want to switch to, then select Switch Platforms. This might take some time, because Unity might need to re-import your Assets in formats that match your target platform.

When you select a platform, Unity displays a list of options that you can adjust for the build. Each platform has unique settings that are listed on each platform-specific manual page. Select the Windows, Mac, Linux build target to build standalone applications for most desktop platforms.

Build settings

Use these settings to configure how Unity builds your application.

Setting Function
Target platform Select Linux to build your app for the Linux platform.
Development Build A development build includes debug symbols and enables the Profiler. More info
See in Glossary
Enable this setting to include scripting debug symbols and the Profiler A window that helps you to optimize your game. It shows how much time is spent in the various areas of your game. For example, it can report the percentage of time spent rendering, animating, or in your game logic. More info
See in Glossary in your build. When you enable this, Unity sets the DEVELOPMENT_BUILD#define for testing purposes. When you select Development Build, Autoconnect Profiler, Deep Profiling Support, Script Debugging, and Wait for Managed Debugger settings also become available.
Autoconnect Profiler Enable this setting to automatically connect the Unity Profiler to your build.
Deep Profiling Support Enable this setting to switch Deep Profiling in the Profiler. This makes the Profiler instrument every function call in your application and returns more detailed profiling data. When you enable Deep Profiling Support, it might slow down script execution.
Script debugging Enable this setting to allow your script code to be debugged. Not available on WebGL A JavaScript API that renders 2D and 3D graphics in a web browser. The Unity WebGL build option allows Unity to publish content as JavaScript programs which use HTML5 technologies and the WebGL rendering API to run Unity content in a web browser. More info
See in Glossary .
Wait for Managed Debugger Enable this setting to be prompted to attach a debugger before Unity executes any script code.
Compression A method of storing data that reduces the amount of storage space it requires. See Texture Compression, Animation Compression, Audio Compression, Build Compression.
See in Glossary Method
(Not available on Lumin or WebGL platforms)
Compress the data in your Project when you build the Player. This includes Assets Any media or data that can be used in your game or project. An asset may come from a file created outside of Unity, such as a 3D Model, an audio file or an image. You can also create some asset types in Unity, such as an Animator Controller, an Audio Mixer or a Render Texture. More info
See in Glossary , Scenes A Scene contains the environments and menus of your game. Think of each unique Scene file as a unique level. In each Scene, you place your environments, obstacles, and decorations, essentially designing and building your game in pieces. More info
See in Glossary , Player settings, and GI data. Choose between the following methods:
Default On Windows, Mac, Linux, and iOS, there is no compression by default. On Android, the default compression is ZIP, which provides better compression results than LZ4HC; however, data is slower to decompress.
LZ4 A fast compression format that’s useful for development builds. For more information, see BuildOptions.CompressWithLz4.
LZ4HC A high compression variant of LZ4 that’s slower to build but produces better results for release builds. For more information, see BuildOptions.CompressWithLz4HC.
Читайте также:  Linux добавить команду path

Asset Import Overrides

The Asset Import Overrides section allows you to locally override all texture import settings to speed up import and platform switch time. You must avoid shipping your final build with any import overrides, but during development they can be useful to speed up iteration time, especially, if assets such as textures resulting in lower resolution is not of any concern.

This setting also disables the Crunch texture compression format on any textures that have it.

You can also set Asset import override settings using -overrideMaxTextureSize and -overrideTextureCompression Editor Command line arguments to change any initial project import.

Building your Linux application

To build your Linux application, select one of the following:

  • Build: Compile a Player. The default build is incremental, except for the first build, which is always a full non-incremental (clean) build. To force a clean build instead of an incremental build, select Clean Build from the dropdown menu.
  • Build and run: Compile a Player and open it in your native platform. This option always uses the incremental build.

Источник

Linux

Unity provides support for developing applications on Linux. You can build your application as a standalone executable and run it on Linux systems that support the same architecture that Unity supports. You can also build your application as a library and use it as a plug-in A set of code created outside of Unity that creates functionality in Unity. There are two kinds of plug-ins you can use in Unity: Managed plug-ins (managed .NET assemblies created with tools like Visual Studio) and Native plug-ins (platform-specific native code libraries). More info
See in Glossary in other applications.

Читайте также:  Linux status php fpm

Topic Description
Linux Player Settings Use Player Settings to set the different options required for the final game built by Unity applicable for the Linux platform. For a description of the general Player Settings, refer to Player Settings Settings that let you set various player-specific options for the final game built by Unity. More info
See in Glossary .
Linux Build Settings Use Build Settings to set up and begin the build process for your application on Linux. It contains settings to create development builds A development build includes debug symbols and enables the Profiler. More info
See in Glossary and for publishing your final build.
Troubleshooting Linux Editor issues Lists workaround for the known issues with the Linux Editor.

Additional resources:

Источник

Оцените статью
Adblock
detector