Unreal engine arm linux

Cross-Compiling for Linux (Legacy)

For engine versions older than 4.14, this page shows users how to set up cross-compilation for the Linux platform.

Choose your operating system:

This reference is an archive for users who need to set up their cross-compilation toolchains in Unreal Engine 4 (UE4) versions that were released prior to 4.14.

If you’re developing your project with Unreal Engine, version 4.14 (or newer), you’ll want to refer to our Cross-Compiling for Linux documentation.

Why Cross-Compilation

Cross-compilation makes it possible for game developers, working in a Windows-centric workflow, to target Linux. At this time, cross-compilation is only supported for Windows. Mac users currently have to resort to native compilation . We support, test, and provide the libraries and toolchains for the Linux-x86_64 platform.

Getting the Toolchain

Please use the following table to download the appropriate toolchain:

  • For toolchains -v8 through -v13 , there is no need to extract files or set the environment variable — just run the installer package.
  • For toolchains -v4 through -v7, we also provide the libraries and toolchains that enable you to compile for Linux ARM (original Raspberry Pi and up).
    • Note that this will require you to make a (minor) code change in UnrealBuildTool (UBT).

    From this point on, we assume that you are targeting x86_64 Linux, though most of the following information will apply to compiling for ARM as well (except for the different toolchain). Note that you can build your own toolchain if you want different versions of the tools, or if you want to target a different architecture.

    Setting up the Toolchain

    Add an environment variable named LINUX_ROOT , the value of which is the absolute path to your toolchain (without a trailing backslash):

    Control Panel->System->Advanced system settings->Advanced->Environment variables 

    After you make sure that the environment variable is set, regenerate UE4 project files (using GenerateProjectFiles.bat ) and restart Visual Studio. After this, you should have «Linux» available for Win32/Win64 configurations, and you should now be able to cross-compile for it.

    Setting up Packaging for Linux

    Note that binary release can only package content-only projects. If you want to package a code-based project for Linux (or a project that has non-default third party plugins), you will have to set up a source build. Otherwise, if you are fine with content-only, there’s no need to build anything because Linux binaries of UE4Game and CrashReportClient are bundled.

    To package for the Linux platform, you will need to build the following targets:

    • CrashReportClient
    • UE4Game (if you project is content-only, otherwise just build your project)
    • The editor itself (this is needed to get Linux target modules built, so that Unreal Editor and Unreal Frontend know how to cook/package games for Linux).
    • UnrealPak and ShaderCompileWorker (you probably have those built anyway, but we’re still mentioning it for completeness).

    Packaging for Linux

    The easiest way to package a project is to open it in the editor and then select File > Package To > Linux. This assumes that you have a cross-toolchain installed in the previous step, and Linux target modules are built for the editor in question. If you don’t see Linux in the list, then it’s likely that one of the former is not true, in which case see above. After some time (which depends on the project in question and is rather short for a sample project) you will have game assets and binaries in the directory you chose to package to.

    The details of the packaging process can be seen by clicking the Show Output Log link. If this process fails with the error message, «unable to find UnrealPak or ShaderCompileWorker» see above about building them for the host (Windows) platform.

    Secure copy ( scp ) or otherwise copy it to a target machine (mounting a Samba share — if you know how to do that — may be better if the target machine is low on disk space, which also reduces iteration times). Change mode ( chmod +x ) for the target executable, (which will be located in the LinuxNoEditor//Binaries/Linux/ directory) and run it.

    Changes for Linux-ARM Platforms

    With the release of Unreal Engine, version 4.14, there is a new (and easy to follow) way of packaging projects for the ARM platform. Check out our recently updated Cross-Compiling for Linux documentation to learn more.

    If you are using the Linux-ARM cross compile toolchain before running GenerateProjectFiles.bat below, edit the following file in the UE4 source code:

    . /UnrealEngine/Engine/Source/Programs/UnrealBuildTool/Linux/UEBuildLinux.cs 

    by commenting out the following line:

    static private string DefaultArchitecture = "x86_64-unknown-linux-gnu"; 

    and un-commenting the linux-arm architecture line just below it:

    //static private string DefaultArchitecture = "arm-unknown-linux-gnueabihf";

    An additional step is required for the packaged project to be runnable on Linux-ARM platforms. Assuming the packaged project is located at \foo\bar\SunTemple_Linux , open the following location:

    \foo\bar\SunTemple_Linux\LinuxNoEditor\Engine\Binaries\Linux

    and replace libopenal.so.1 with the version from:

    . \UnrealEngine\Engine\Source\ThirdParty\OpenAL\1.15.1\lib\Linux\arm-unknown-linux-gnueabihf\libopenal.so

    where . \UnrealEngine is the location of the UE4 source code. Please be sure to rename libopenal.so to libopenal.so.1 .

    Now the project can be copied over to the target machine, chmod+x the target executable and run it as instructed above.

    Источник

    Cross-Compiling for Linux (Legacy)

    For engine versions older than 4.14, this page shows users how to set up cross-compilation for the Linux platform.

    Choose your operating system:

    This reference is an archive for users who need to set up their cross-compilation toolchains in Unreal Engine 4 (UE4) versions that were released prior to 4.14.

    If you’re developing your project with Unreal Engine, version 4.14 (or newer), you’ll want to refer to our Cross-Compiling for Linux documentation.

    Why Cross-Compilation

    Cross-compilation makes it possible for game developers, working in a Windows-centric workflow, to target Linux. At this time, cross-compilation is only supported for Windows. Mac users currently have to resort to native compilation . We support, test, and provide the libraries and toolchains for the Linux-x86_64 platform.

    Getting the Toolchain

    Please use the following table to download the appropriate toolchain:

    • For toolchains -v8 through -v13 , there is no need to extract files or set the environment variable — just run the installer package.
    • For toolchains -v4 through -v7, we also provide the libraries and toolchains that enable you to compile for Linux ARM (original Raspberry Pi and up).
      • Note that this will require you to make a (minor) code change in UnrealBuildTool (UBT).

      From this point on, we assume that you are targeting x86_64 Linux, though most of the following information will apply to compiling for ARM as well (except for the different toolchain). Note that you can build your own toolchain if you want different versions of the tools, or if you want to target a different architecture.

      Setting up the Toolchain

      Add an environment variable named LINUX_ROOT , the value of which is the absolute path to your toolchain (without a trailing backslash):

      Control Panel->System->Advanced system settings->Advanced->Environment variables 

      After you make sure that the environment variable is set, regenerate UE4 project files (using GenerateProjectFiles.bat ) and restart Visual Studio. After this, you should have «Linux» available for Win32/Win64 configurations, and you should now be able to cross-compile for it.

      Setting up Packaging for Linux

      Note that binary release can only package content-only projects. If you want to package a code-based project for Linux (or a project that has non-default third party plugins), you will have to set up a source build. Otherwise, if you are fine with content-only, there’s no need to build anything because Linux binaries of UE4Game and CrashReportClient are bundled.

      To package for the Linux platform, you will need to build the following targets:

      • CrashReportClient
      • UE4Game (if you project is content-only, otherwise just build your project)
      • The editor itself (this is needed to get Linux target modules built, so that Unreal Editor and Unreal Frontend know how to cook/package games for Linux).
      • UnrealPak and ShaderCompileWorker (you probably have those built anyway, but we’re still mentioning it for completeness).

      Packaging for Linux

      The easiest way to package a project is to open it in the editor and then select File > Package To > Linux. This assumes that you have a cross-toolchain installed in the previous step, and Linux target modules are built for the editor in question. If you don’t see Linux in the list, then it’s likely that one of the former is not true, in which case see above. After some time (which depends on the project in question and is rather short for a sample project) you will have game assets and binaries in the directory you chose to package to.

      The details of the packaging process can be seen by clicking the Show Output Log link. If this process fails with the error message, «unable to find UnrealPak or ShaderCompileWorker» see above about building them for the host (Windows) platform.

      Secure copy ( scp ) or otherwise copy it to a target machine (mounting a Samba share — if you know how to do that — may be better if the target machine is low on disk space, which also reduces iteration times). Change mode ( chmod +x ) for the target executable, (which will be located in the LinuxNoEditor//Binaries/Linux/ directory) and run it.

      Changes for Linux-ARM Platforms

      With the release of Unreal Engine, version 4.14, there is a new (and easy to follow) way of packaging projects for the ARM platform. Check out our recently updated Cross-Compiling for Linux documentation to learn more.

      If you are using the Linux-ARM cross compile toolchain before running GenerateProjectFiles.bat below, edit the following file in the UE4 source code:

      . /UnrealEngine/Engine/Source/Programs/UnrealBuildTool/Linux/UEBuildLinux.cs 

      by commenting out the following line:

      static private string DefaultArchitecture = "x86_64-unknown-linux-gnu"; 

      and un-commenting the linux-arm architecture line just below it:

      //static private string DefaultArchitecture = "arm-unknown-linux-gnueabihf";

      An additional step is required for the packaged project to be runnable on Linux-ARM platforms. Assuming the packaged project is located at \foo\bar\SunTemple_Linux , open the following location:

      \foo\bar\SunTemple_Linux\LinuxNoEditor\Engine\Binaries\Linux

      and replace libopenal.so.1 with the version from:

      . \UnrealEngine\Engine\Source\ThirdParty\OpenAL\1.15.1\lib\Linux\arm-unknown-linux-gnueabihf\libopenal.so

      where . \UnrealEngine is the location of the UE4 source code. Please be sure to rename libopenal.so to libopenal.so.1 .

      Now the project can be copied over to the target machine, chmod+x the target executable and run it as instructed above.

      Источник

      Development Requirements

      This page contains the software development kit (SDK) and hardware requirements needed to develop Unreal Engine (UE) projects for Linux devices.

      Operating System

      clang 13.0.1 (5.1), clang 15.0.1 (5.2)

      Recommended Development Hardware

      Quad-core Intel or AMD, 2.5 GHz or faster

      NVIDIA GeForce 960 GTX or Higher with latest NVIDIA binary drivers

      RHI Version

      Operating System

      Any reasonable new Linux distro from CentOS 7.x and up

      Linux Kernel Version

      Additional Dependencies

      Cross-Compile Toolchain

      Cross-compiling makes it possible for game developers to target Linux from Windows. At this time, cross-compiling is only supported for Windows, and Mac users currently have to resort to Native Compiling . Additionally, we support, test, and provide libraries and toolchains for the Linux-x86_64 platform.

      Why Cross-Compilation

      Cross-compilation makes it possible for game developers, working in a Windows-centric workflow, to target Linux. At this time, cross-compilation is only supported for Windows. Mac users currently have to resort to native compilation . We support, test, and provide the libraries and toolchains for the Linux-x86_64 platform.

      Getting the Toolchain

      To download the Cross-Compilation Toolchain, refer to the download links in table in the Version History section below.

      Native Toolchain

      Unreal Engine’s setup shell script ( Setup.sh ) automatically downloads a native toolchain, which guarantees your compiler and linker to work with our codebase. With the native toolchain, you compile against a fixed sysroot ( glibc at the very least), so that, for example, if you compile a game on Ubuntu 18.04, you will be able to start the binary on CentOS 7.

      Version History

      Recommended Operating System

      Источник

      Читайте также:  Виды и назначение linux
Оцените статью
Adblock
detector