Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

"Failed to load il2cpp" when starting Linux build on Mint

Discussion in 'Linux' started by Koksny, Jan 25, 2020.

  1. Koksny

    Koksny

    Joined:
    Nov 15, 2017
    Posts:
    15
    One of our Linux users reported that game doesn't start on Linux Mint. After starting, it only generates "Failed to load il2cpp" message into log.

    Clang, mono-complete and dotnet-runtime are installed.

    There are no issue with exactly same build on neither Ubuntu, Arch and Manjaro. We also can't get Unity Editor to compile empty project with Mint. Any hint? We're using latest 2019.3 pre-release to create the build in question, but it seems to also fail on our older il2cpp builds.
     
  2. Koksny

    Koksny

    Joined:
    Nov 15, 2017
    Posts:
    15
    Issue is only present on Linux Mint 18.3, build works in latest Mint, thread can be closed.
     
  3. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,504
    This issue happens as a result of Unity currently using whatever sysroot is installed on your machine at the time you export the build from the Unity Editor and if it's not compatible with certain operating systems, the build will crash on startup on those systems.

    We're working on shipping a functional sysroot for Linux IL2CPP in coming 2019.3 builds.
     
  4. tonic-joel

    tonic-joel

    Joined:
    Nov 9, 2018
    Posts:
    2
    Hi is there any update on this issue. I'm currently building linux il2cpp builds using 2019.3.9. They run fine on my local Ubuntu installation, but fail wait the error "Failed to load il2cpp" run I attempt to run the builds on my server.

    I have configure the sysRoot using the code in this post (which allows me to build the game) https://forum.unity.com/threads/uni...e-built-with-linux-error.822210/#post-5633977


    Are there any work around for getting il2cpp builds running on specific Linux installations, or any further development on the functional sysroot?
     
  5. xiaobohappy

    xiaobohappy

    Joined:
    Dec 22, 2020
    Posts:
    1
    Hi , upload_2020-12-22_18-38-43.png I can build an export sucess but run error in linux
    Unity2019 4.13 (Host Win10)with IL2CPP to Linux Target
    "com.unity.sysroot": "version": "0.1.17-preview
    "com.unity.toolchain.win-x86_64-linux-x86_64": "version": "0.1.17-preview"

    The Linux version : 3.10.0-862.el7.x86_64 (builder@kbuilder.dev.centos.org) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-28) (GCC) ) #1 SMP Fri Apr 20 16:44:24 UTC 2018


    How do I fix this mistake? What should I do ?
     
  6. Laur3nt1u

    Laur3nt1u

    Joined:
    Apr 30, 2014
    Posts:
    23
    same problem with Unity 2020.3 and 2021.1 but it works with 2019.4.22
     
    JoeStrout and deus0 like this.
  7. deus0

    deus0

    Joined:
    May 12, 2015
    Posts:
    256
    Will this ever be fixed :/
     
    vich94 and Claytonious like this.
  8. JoeStrout

    JoeStrout

    Joined:
    Jan 14, 2011
    Posts:
    9,841
    Just ran into this same issue myself. I'm using 2021.3.15f1, building on macOS (10.13) for Linux with IL2CPP. The resulting build works fine on my Ubuntu box running under VMware, but as soon as I posted the build, a user on a (real, not VM) kubuntu box reported a failure to launch. The Player.log is attached, but I think the key bit is the first line: "Failed to load il2cpp".

    This is a major problem... I am not able to drop back to 2019.4. Is there any newer version where this is known to work correctly?

    [EDIT: I did find that turning of IL2CPP, clearing the build folder, and then building again seems to work around the problem.]
     

    Attached Files:

    Last edited: Jul 2, 2023
  9. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,504
    Adding the linux sysroot package to your project should fix it. Does the build window not offer you to install it?