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

IL2CPP WebGL build: error while loading shared libraries: libtinfo.so.5

Discussion in 'Editor & General Support' started by yosr481, Jul 8, 2021.

  1. yosr481

    yosr481

    Joined:
    Apr 27, 2016
    Posts:
    2
    Exception: Unity.IL2CPP.Building.BuilderFailedException: /home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
    /home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    ERROR:root:compiler frontend failed to generate LLVM bitcode, halting


    Invocation was: Executable: /usr/bin/python
    Arguments: -E "/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/em++" -Wno-unused-value -Wno-invalid-offsetof -nostdinc -fno-strict-overflow -Wno-null-conversion -std=c++11 -O3 -Oz -DIL2CPP_EXCEPTION_DISABLED=1 -DNET_4_0 -DUNITY_AOT -DIL2CPP_MONO_DEBUGGER_DISABLED -DGC_NOT_DLL -DRUNTIME_IL2CPP -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DNDEBUG -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/libil2cpp" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/libil2cpp" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/external/bdwgc/include" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/external/xxHash" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/external/baselib/Include" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/external/baselib/Platforms/WebGL/Include" -I"/home/yosr481/Unity/Hub/Editor/2020.3.13f1/Editor/Data/il2cpp/libil2cpp/pch" -I"/home/yosr481/Documents/D-Drive/Hidabroot Projects/Projects/City Blast/Library/Il2cppBuildCache/WebGL/il2cppOutput" "/home/yosr481/Documents/D-Drive/Hidabroot Projects/Projects/City Blast/Library/Il2cppBuildCache/WebGL/il2cppOutput/Il2CppCCalculateFieldValues.cpp" -o "/home/yosr481/Documents/D-Drive/Hidabroot Projects/Projects/City Blast/Library/il2cpp_cache/9AA6B5E1DB8374B00A096B926CB2BA73.o"

    at Unity.IL2CPP.Building.CppProgramBuilder.BuildAllCppFiles(IEnumerable`1 sourceFilesToCompile, IBuildStatisticsCollector statisticsCollector) in /Users/bokken/build/output/unity/il2cpp/Unity.IL2CPP.Building/CppProgramBuilder.cs:line 217
    at Unity.IL2CPP.Building.CppProgramBuilder.Build(IBuildStatistics& statistics) in /Users/bokken/build/output/unity/il2cpp/Unity.IL2CPP.Building/CppProgramBuilder.cs:line 149
    at il2cpp.Compilation.CompilationDriver.Run(RuntimePlatform platform, BuildingOptions buildingOptions, ReadOnlyCollection`1 matchedAssemblyMethodSourceFiles) in /Users/bokken/build/output/unity/il2cpp/il2cpp/Compilation/CompilationDriver.cs:line 65
    at il2cpp.Program.DoRun(String[] args, RuntimePlatform platform, BuildingOptions buildingOptions, Boolean throwExceptions) in /Users/bokken/build/output/unity/il2cpp/il2cpp/Program.cs:line 74
    UnityEditorInternal.Runner.RunProgram (UnityEditor.Utils.Program p, System.String exe, System.String args, System.String workingDirectory, UnityEditor.Scripting.Compilers.CompilerOutputParserBase parser) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/BuildUtils.cs:129)
    UnityEditorInternal.Runner.RunManagedProgram (System.String exe, System.String args, System.String workingDirectory, UnityEditor.Scripting.Compilers.CompilerOutputParserBase parser, System.Action`1[T] setupStartInfo) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/BuildUtils.cs:65)
    UnityEditorInternal.IL2CPPBuilder.RunIl2CppWithArguments (System.Collections.Generic.List`1[T] arguments, System.Action`1[T] setupStartInfo) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:804)
    UnityEditorInternal.IL2CPPBuilder.ConvertPlayerDlltoCpp (UnityEditor.Il2Cpp.Il2CppBuildPipelineData data) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:773)
    UnityEditorInternal.IL2CPPBuilder.Run () (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:599)
    UnityEditorInternal.IL2CPPUtils.RunIl2Cpp (System.String stagingAreaData, UnityEditorInternal.IIl2CppPlatformProvider platformProvider, System.Action`1[T] modifyOutputBeforeCompile, UnityEditor.RuntimeClassRegistry runtimeClassRegistry) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:276)
    UnityEditor.WebGL.WebGlBuildPostprocessor.CompileBuild (UnityEditor.Modules.BuildPostProcessArgs args) (at /Users/bokken/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:365)
    UnityEditor.WebGL.WebGlBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at /Users/bokken/buildslave/unity/build/PlatformDependent/WebGL/Extensions/Unity.WebGL.extensions/BuildPostprocessor.cs:913)
    UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at /home/bokken/buildslave/unity/build/Editor/Mono/Modules/DefaultBuildPostprocessor.cs:29)
    UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at /home/bokken/buildslave/unity/build/Editor/Mono/BuildPipeline/PostprocessBuildPlayer.cs:337)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&) (at /home/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

    I'm using Unity 2020.3.13f1 on Pop os 21.04.

    I've installed libtinfo5 & python & all the unity dependencies needed, I've soft linked libtinfo.so.6.2 and libtinfo.so.5.9 to libtinfo.so.5. nothing seemed to work.

    HELP PLEASE!!!
     
    ll3v3ll likes this.
  2. ll3v3ll

    ll3v3ll

    Joined:
    Nov 14, 2014
    Posts:
    11
    This is a BUG.
    Unity, PLEASE FIX THIS.
    I had to hack Freedesktop Sdk to make it work.


    Same issue: Unity 2020.3.27f1 via flatpak (PopShop) on Pop!_OS 21.04

    TL;DR: Skip to the SOLUTION (below)



    Exception: Unity.IL2CPP.Building.BuilderFailedException: /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/tools/shared.py:147: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    if self.returncode is not 0:
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/tools/shared.py:1687: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    if res.returncode is not 0:
    ERROR:root:compiler frontend failed to generate LLVM bitcode, halting

    Analysis:

    1. probably can ignore the SyntaxWarnings about "is not", but they should be addressed
    2. options.use_closure_compiler asm.js error might be a problem, but maybe not..
    3. the original problem is libtinfo.so.5


    $ locate libtinfo.so



    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform/x86_64/20.08/2857bbad6f429653e6bb3534568e1900eac395196bcac7641ef21f7950eb9898/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform/x86_64/20.08/2857bbad6f429653e6bb3534568e1900eac395196bcac7641ef21f7950eb9898/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform/x86_64/21.08/b27db466e56f7e49e794656b84153c8b81f929ca8b5b8400142b19bb48b9a63d/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform/x86_64/21.08/b27db466e56f7e49e794656b84153c8b81f929ca8b5b8400142b19bb48b9a63d/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform.Compat.i386/x86_64/20.08/3a7b919eddacbbdfe726dbfff2661991843f90f5df51b8e0c2456ff538a4ee01/files/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Platform.Compat.i386/x86_64/20.08/3a7b919eddacbbdfe726dbfff2661991843f90f5df51b8e0c2456ff538a4ee01/files/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/20.08/71208aa5f95930a2665f0019ba8135b9cfa6dec04a411797b9d3b9a1c5186fa2/files/lib/x86_64-linux-gnu/libtinfo.so
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/20.08/71208aa5f95930a2665f0019ba8135b9cfa6dec04a411797b9d3b9a1c5186fa2/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/20.08/71208aa5f95930a2665f0019ba8135b9cfa6dec04a411797b9d3b9a1c5186fa2/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/21.08/ae7e576a0187591ab0931eec30ea68d9907aacc16dc8bd7e6b2a96b73df6f18a/files/lib/x86_64-linux-gnu/libtinfo.so
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/21.08/ae7e576a0187591ab0931eec30ea68d9907aacc16dc8bd7e6b2a96b73df6f18a/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/21.08/ae7e576a0187591ab0931eec30ea68d9907aacc16dc8bd7e6b2a96b73df6f18a/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/3.38/454a79938e3ecb6ee3750055b1cfb2d28435b0ffe1ff5742b092917cf7efc8a1/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/3.38/454a79938e3ecb6ee3750055b1cfb2d28435b0ffe1ff5742b092917cf7efc8a1/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/40/94f9d99e25b631567732990838fbcd3f6148be8dfe8f38157f8acf9df9b9b2c1/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/40/94f9d99e25b631567732990838fbcd3f6148be8dfe8f38157f8acf9df9b9b2c1/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/41/f0dea6ae10e738332fc17bdb652e7ce35596d06bf5c55bdbc3ef09ff1a9d9832/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.gnome.Platform/x86_64/41/f0dea6ae10e738332fc17bdb652e7ce35596d06bf5c55bdbc3ef09ff1a9d9832/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.kde.Platform/x86_64/5.15/1cb4374f4cc2438ca9674ae683b38fb1dbe74704d28cd8508349c81f6228b3d3/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.kde.Platform/x86_64/5.15/1cb4374f4cc2438ca9674ae683b38fb1dbe74704d28cd8508349c81f6228b3d3/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/flatpak/runtime/org.kde.Platform/x86_64/5.15-21.08/1bd7d36c3d1aace6aa6887c533c3dc8565a883ab5a288c10ba019b640066d002/files/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.local/share/flatpak/runtime/org.kde.Platform/x86_64/5.15-21.08/1bd7d36c3d1aace6aa6887c533c3dc8565a883ab5a288c10ba019b640066d002/files/lib/x86_64-linux-gnu/libtinfo.so.6.2
    /home/self/.local/share/lutris/runtime/Ubuntu-18.04-i686/libtinfo.so.5
    /home/self/.local/share/lutris/runtime/Ubuntu-18.04-x86_64/libtinfo.so.5
    /home/self/.local/share/lutris/runtime/lib32/libtinfo.so.5
    /home/self/.local/share/lutris/runtime/lib64/libtinfo.so.5
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/soldier_platform_0.20220119.0/files/lib/i386-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/soldier_platform_0.20220119.0/files/lib/i386-linux-gnu/libtinfo.so.6.1
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/soldier_platform_0.20220119.0/files/lib/x86_64-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/soldier_platform_0.20220119.0/files/lib/x86_64-linux-gnu/libtinfo.so.6.1
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/i386-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/i386-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/pressure-vessel/overrides/lib/i386-linux-gnu/libtinfo.so.6
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/pressure-vessel/overrides/lib/x86_64-linux-gnu/libtinfo.so.6
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/x86_64-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/steamapps/common/SteamLinuxRuntime_soldier/var/tmp-XXCRG1/usr/lib/x86_64-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime/lib/i386-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime/lib/i386-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime/lib/x86_64-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime/lib/x86_64-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime.old/lib/i386-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime.old/lib/i386-linux-gnu/libtinfo.so.5.9
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime.old/lib/x86_64-linux-gnu/libtinfo.so.5
    /home/self/.steam/debian-installation/ubuntu12_32/steam-runtime.old/lib/x86_64-linux-gnu/libtinfo.so.5.9
    /usr/lib/i386-linux-gnu/libtinfo.so.6
    /usr/lib/i386-linux-gnu/libtinfo.so.6.2
    /usr/lib/x86_64-linux-gnu/libtinfo.so.6
    /usr/lib/x86_64-linux-gnu/libtinfo.so.6.2

    There is no libtinfo.so.5 in system,
    There is no libtinfo.so.5 in Unity directories,
    There is no libtinfo.so.5 in flatpak (there is, but it is in another application space)

    So we get the error


    Unity.IL2CPP.Building.BuilderFailedException: /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory


    Where are the other shared libraries that il2cpp might be looking for,
    where should unity locate libtinfo.so.5 ?
    Let's find the other shared libraries....


    ~/Unity/2020.3.27f1/Editor/Data$ find . -name *.so*



    ./il2cpp/build/deploy/netcoreapp3.1/libmscordbi.so
    ./il2cpp/build/deploy/netcoreapp3.1/libmscordaccore.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.IO.Compression.Native.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.Globalization.Native.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.Net.Security.Native.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.Net.Http.Native.so
    ./il2cpp/build/deploy/netcoreapp3.1/libcoreclr.so
    ./il2cpp/build/deploy/netcoreapp3.1/libcoreclrtraceptprovider.so
    ./il2cpp/build/deploy/netcoreapp3.1/libdbgshim.so
    ./il2cpp/build/deploy/netcoreapp3.1/libclrjit.so
    ./il2cpp/build/deploy/netcoreapp3.1/libhostfxr.so
    ./il2cpp/build/deploy/netcoreapp3.1/libhostpolicy.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.Security.Cryptography.Native.OpenSsl.so
    ./il2cpp/build/deploy/netcoreapp3.1/System.Native.so
    ./MonoEmbedRuntime/libmonobdwgc-2.0.so
    ./MonoEmbedRuntime/libmonosgen-2.0.so
    ./MonoEmbedRuntime/libMonoPosixHelper.so
    ./Resources/Licensing/Client/libmscordbi.so
    ./Resources/Licensing/Client/libmscordaccore.so
    ./Resources/Licensing/Client/System.IO.Compression.Native.so
    ./Resources/Licensing/Client/System.Globalization.Native.so
    ./Resources/Licensing/Client/System.Net.Security.Native.so
    ./Resources/Licensing/Client/System.Net.Http.Native.so
    ./Resources/Licensing/Client/libcoreclr.so
    ./Resources/Licensing/Client/libcoreclrtraceptprovider.so
    ./Resources/Licensing/Client/libdbgshim.so
    ./Resources/Licensing/Client/libclrjit.so
    ./Resources/Licensing/Client/libbindings.so
    ./Resources/Licensing/Client/libhostfxr.so
    ./Resources/Licensing/Client/libhostpolicy.so
    ./Resources/Licensing/Client/System.Security.Cryptography.Native.OpenSsl.so
    ./Resources/Licensing/Client/System.Native.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.AspNetCore.All/2.2.5/libuv.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.AspNetCore.All/2.2.5/libe_sqlite3.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libsosplugin.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libmscordbi.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libmscordaccore.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.IO.Compression.Native.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libsos.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.Globalization.Native.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.Net.Security.Native.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.Net.Http.Native.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libcoreclr.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libcoreclrtraceptprovider.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libdbgshim.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libclrjit.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/libhostpolicy.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.Security.Cryptography.Native.OpenSsl.so
    ./NetCore/Sdk-2.2.107/shared/Microsoft.NETCore.App/2.2.5/System.Native.so
    ./NetCore/Sdk-2.2.107/host/fxr/2.2.5/libhostfxr.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libmscordbi.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libmscordaccore.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.IO.Compression.Native.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.Globalization.Native.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.Net.Security.Native.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.Net.Http.Native.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libcoreclr.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libcoreclrtraceptprovider.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libdbgshim.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libclrjit.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/libhostpolicy.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.Security.Cryptography.Native.OpenSsl.so
    ./NetCore/runtime-317-linux-x64/shared/Microsoft.NETCore.App/3.1.7/System.Native.so
    ./NetCore/runtime-317-linux-x64/host/fxr/3.1.7/libhostfxr.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_nondevelopment_mono/Data/MonoBleedingEdge/x86_64/libmonobdwgc-2.0.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_nondevelopment_mono/Data/MonoBleedingEdge/x86_64/libMonoPosixHelper.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_nondevelopment_mono/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_nondevelopment_il2cpp/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_development_il2cpp/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_nondevelopment_mono/Data/MonoBleedingEdge/x86_64/libmonobdwgc-2.0.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_nondevelopment_mono/Data/MonoBleedingEdge/x86_64/libMonoPosixHelper.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_nondevelopment_mono/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_development_il2cpp/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_development_mono/Data/MonoBleedingEdge/x86_64/libmonobdwgc-2.0.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_development_mono/Data/MonoBleedingEdge/x86_64/libMonoPosixHelper.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_development_mono/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_development_mono/Data/MonoBleedingEdge/x86_64/libmonobdwgc-2.0.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_development_mono/Data/MonoBleedingEdge/x86_64/libMonoPosixHelper.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_withgfx_development_mono/UnityPlayer.so
    ./PlaybackEngines/LinuxStandaloneSupport/Variations/linux64_headless_nondevelopment_il2cpp/UnityPlayer.so
    ./Tools/libembree.so.2
    ./Tools/libtbbmalloc.so.2
    ./Tools/astcenc-sse42.so
    ./Tools/libtbb.so.2
    ./Tools/glslang.so
    ./Tools/astcenc-avx2.so
    ./Tools/Roslyn/libmscordbi.so
    ./Tools/Roslyn/libmscordaccore.so
    ./Tools/Roslyn/System.IO.Compression.Native.so
    ./Tools/Roslyn/System.Globalization.Native.so
    ./Tools/Roslyn/System.Net.Security.Native.so
    ./Tools/Roslyn/System.Net.Http.Native.so
    ./Tools/Roslyn/libcoreclr.so
    ./Tools/Roslyn/libcoreclrtraceptprovider.so
    ./Tools/Roslyn/libdbgshim.so
    ./Tools/Roslyn/libclrjit.so
    ./Tools/Roslyn/libhostfxr.so
    ./Tools/Roslyn/libhostpolicy.so
    ./Tools/Roslyn/System.Security.Cryptography.Native.OpenSsl.so
    ./Tools/Roslyn/System.Native.so
    ./Tools/libembree.so
    ./Tools/libOpenImageDenoise.so.0
    ./Tools/libOpenImageDenoise.so.1.1.0
    ./Tools/libfreeimage.so.3
    ./Tools/libCausticGLUT.so
    ./Tools/astcenc-sse2.so
    ./Tools/libCST.so
    ./Tools/FSBTool/libvorbisfile.so
    ./Tools/FSBTool/libvorbis.so.0
    ./Tools/FSBTool/libogg.so
    ./Tools/FSBTool/libvorbis.so
    ./Tools/FSBTool/libogg.so.0
    ./Tools/libRL.so
    ./Tools/libOpenImageDenoise.so
    ./MonoBleedingEdge/MonoEmbedRuntime/libmonobdwgc-2.0.so
    ./MonoBleedingEdge/MonoEmbedRuntime/libMonoPosixHelper.so

    Reading the list, I think libtinfo.so.5 should probably exist in ./Tools
    trying that ....


    $ sudo apt-get install libtinfo5

    Reading package lists... Done
    Building dependency tree... Done
    Reading state information... Done
    The following NEW packages will be installed:
    libtinfo5
    0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
    Need to get 82.8 kB of archives.
    After this operation, 538 kB of additional disk space will be used.
    Get:1 http://us.archive.ubuntu.com/ubuntu hirsute/universe amd64 libtinfo5 amd64 6.2+20201114-2build1 [82.8 kB]
    Fetched 82.8 kB in 0s (401 kB/s)
    Selecting previously unselected package libtinfo5:amd64.
    (Reading database ... 539380 files and directories currently installed.)
    Preparing to unpack .../libtinfo5_6.2+20201114-2build1_amd64.deb ...
    Unpacking libtinfo5:amd64 (6.2+20201114-2build1) ...
    Setting up libtinfo5:amd64 (6.2+20201114-2build1) ...
    Processing triggers for libc-bin (2.33-0ubuntu5) ...

    $ updatedb
    # this will update the 'locate' database
    $ locate libtinfo



    ...
    /usr/lib/i386-linux-gnu/libtinfo.so.6
    /usr/lib/i386-linux-gnu/libtinfo.so.6.2
    /usr/lib/x86_64-linux-gnu/libtinfo.so.5
    /usr/lib/x86_64-linux-gnu/libtinfo.so.5.9
    /usr/lib/x86_64-linux-gnu/libtinfo.so.6
    /usr/lib/x86_64-linux-gnu/libtinfo.so.6.2
    ...


    So,
    libtinfo.so.5 is now on the system...
    (probably could have just copied it, and put it in ./Tools, there may be a specific version that Unity wants..)
    Anyway, lets try to compile for WebGL, and see if clang++ will find libtinfo.so.5 on the system path...

    Answer: NO.


    Exception: Unity.IL2CPP.Building.BuilderFailedException: /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory


    Okay, lets put libtinfo.so.5 in the ./Tools directory ...


    ~/Unity/2020.3.27f1/Editor/Data/Tools$ ln -s /usr/lib/x86_64-linux-gnu/libtinfo.so.5 .


    Answer: No.

    Need to dive deeper. It is probably related to that fact that Unity is running inside a flatpak sandbox,
    and, inside that sandbox, there is no libtinfo.so.5.


    $ flatpak run --command=bash com.unity.UnityHub
    ~$ /usr/bin/python -E "/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/em++" -Wno-unused-value -Wno-invalid-offsetof -nostdinc -fno-strict-overflow -Wno-null-conversion -std=c++11 -O3 -Oz -DIL2CPP_EXCEPTION_DISABLED=1 -DNET_4_0 -DUNITY_AOT -DIL2CPP_MONO_DEBUGGER_DISABLED -DGC_NOT_DLL -DRUNTIME_IL2CPP -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DNDEBUG -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/bdwgc/include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/xxHash" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Platforms/WebGL/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp/pch" -I"/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput" "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput/Il2CppInvokerTable.cpp" -o "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/il2cpp_cache/FF48B8900D69F32F309A524A335269B1.o"
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']

    ==============================================================================
    Welcome to Emscripten!

    This is the first time any of the Emscripten tools has been run.

    A settings file has been copied to ~/.emscripten, at absolute path: /home/self/.emscripten

    It contains our best guesses for the important paths, which are:

    LLVM_ROOT = /usr/bin
    NODE_JS = node
    EMSCRIPTEN_ROOT = /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten

    Please edit the file if any of those are incorrect.

    This command will now exit. When you are done editing those paths, re-run it.
    ==============================================================================


    Editing the ~/.emscripten,
    found llvm in ... "PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux"
    setting the LLVM path to that...


    ...
    # this helps projects using emscripten find it
    EMSCRIPTEN_ROOT = os.path.expanduser(os.getenv('EMSCRIPTEN', '/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten')) # directory
    LLVM_ROOT = os.path.expanduser(os.getenv('LLVM', '/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux')) # directory
    BINARYEN_ROOT = os.path.expanduser(os.getenv('BINARYEN', '')) # if not set, we will use it from ports
    ...


    Retrying the compiler command.....


    ~$ /usr/bin/python -E "/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/em++" -Wno-unused-value -Wno-invalid-offsetof -nostdinc -fno-strict-overflow -Wno-null-conversion -std=c++11 -O3 -Oz -DIL2CPP_EXCEPTION_DISABLED=1 -DNET_4_0 -DUNITY_AOT -DIL2CPP_MONO_DEBUGGER_DISABLED -DGC_NOT_DLL -DRUNTIME_IL2CPP -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DNDEBUG -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/bdwgc/include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/xxHash" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Platforms/WebGL/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp/pch" -I"/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput" "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput/Il2CppInvokerTable.cpp" -o "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/il2cpp_cache/FF48B8900D69F32F309A524A335269B1.o"
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    INFO:root:generating system asset: is_vanilla.txt... (this will be cached in "/home/self/.emscripten_cache/is_vanilla.txt" for subsequent builds)
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
    INFO:root: - ok
    CRITICAL:root:Could not verify LLVM version: Command '['/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++', '-v']' returned non-zero exit status 127.
    INFO:root:Checking JS engine ['node'] failed. Check your config file. Details: [Errno 2] No such file or directory: 'node'
    WARNING:root:cannot check node version: [Errno 2] No such file or directory: 'node'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
    CRITICAL:root:fastcomp in use, but LLVM has not been built with the JavaScript backend as a target, llc reports:
    ===========================================================================
    (no targets could be identified: Command '['/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc', '--version']' returned non-zero exit status 127.)
    ===========================================================================
    CRITICAL:root:you can fall back to the older (pre-fastcomp) compiler core, although that is not recommended, see http://kripken.github.io/emscripten-site/docs/building_from_source/LLVM-Backend.html
    INFO:root:(Emscripten: Running sanity checks)
    ERROR:root:The JavaScript shell used for compiling (['node']) does not seem to work, check the paths in ~/.emscripten



    Aha!!! There is the ERROR!
    (still inside the UnityHub flatpak sandbox...)


    ~$ ls /usr/lib/x86_64-linux-gnu/libtinfo*
    /usr/lib/x86_64-linux-gnu/libtinfo.so /usr/lib/x86_64-linux-gnu/libtinfo.so.6.2 /usr/lib/x86_64-linux-gnu/libtinfow.so.6
    /usr/lib/x86_64-linux-gnu/libtinfo.so.6 /usr/lib/x86_64-linux-gnu/libtinfow.so /usr/lib/x86_64-linux-gnu/libtinfow.so.6.2


    No libtinfo.so.5 in the UnityHub flatpak sandbox !

    Find where in "flatpak land" is libtinfo?


    ~/.local/share/flatpak$ find . -name libtinfo.so.6
    ./runtime/org.kde.Platform/x86_64/5.15/1cb4374f4cc2438ca9674ae683b38fb1dbe74704d28cd8508349c81f6228b3d3/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.kde.Platform/x86_64/5.15-21.08/1bd7d36c3d1aace6aa6887c533c3dc8565a883ab5a288c10ba019b640066d002/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.gnome.Platform/x86_64/41/f0dea6ae10e738332fc17bdb652e7ce35596d06bf5c55bdbc3ef09ff1a9d9832/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.gnome.Platform/x86_64/3.38/454a79938e3ecb6ee3750055b1cfb2d28435b0ffe1ff5742b092917cf7efc8a1/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.gnome.Platform/x86_64/40/94f9d99e25b631567732990838fbcd3f6148be8dfe8f38157f8acf9df9b9b2c1/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.freedesktop.Platform.Compat.i386/x86_64/20.08/3a7b919eddacbbdfe726dbfff2661991843f90f5df51b8e0c2456ff538a4ee01/files/libtinfo.so.6
    ./runtime/org.freedesktop.Sdk/x86_64/20.08/71208aa5f95930a2665f0019ba8135b9cfa6dec04a411797b9d3b9a1c5186fa2/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.freedesktop.Sdk/x86_64/21.08/ae7e576a0187591ab0931eec30ea68d9907aacc16dc8bd7e6b2a96b73df6f18a/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.freedesktop.Platform/x86_64/20.08/2857bbad6f429653e6bb3534568e1900eac395196bcac7641ef21f7950eb9898/files/lib/x86_64-linux-gnu/libtinfo.so.6
    ./runtime/org.freedesktop.Platform/x86_64/21.08/b27db466e56f7e49e794656b84153c8b81f929ca8b5b8400142b19bb48b9a63d/files/lib/x86_64-linux-gnu/libtinfo.so.6


    That is sort of helpful, but which one is UnityHub using ??
    Which "root" system is UnityHub flatpak sandbox using ??


    /.local/share/flatpak/app/com.unity.UnityHub/current/active$ more metadata
    [Application]
    name=com.unity.UnityHub
    runtime=org.freedesktop.Sdk/x86_64/20.08
    sdk=org.freedesktop.Sdk/x86_64/20.08
    base=app/org.electronjs.Electron2.BaseApp/x86_64/20.08
    tags=proprietary;
    command=start-unityhub
    ...


    Answer: "org.freedesktop.Sdk/x86_64/20.08"


    $ cd ~/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/20.08/active/files/lib/x86_64-linux-gnu
    $ ls libtinfo*
    libtinfo.so libtinfo.so.6 libtinfo.so.6.2 libtinfow.so libtinfow.so.6 libtinfow.so.6.2

    # there is no libtinfo.so.5 here.
    # COPY IT from system into here.
    # still inside the same directory

    $ cp /usr/lib/x86_64-linux-gnu/libtinfo.so.5.9 .
    $ ln -s libtinfo.so.5.9 libtinfo.so.5
    $ chmod a+x libtinfo.so.5*
    $ ls -la libtinfo*
    lrwxrwxrwx 1 self self 13 Jan 26 12:11 libtinfo.so -> libtinfo.so.6
    lrwxrwxrwx 1 self self 15 Feb 16 04:36 libtinfo.so.5 -> libtinfo.so.5.9
    -rwxr-xr-x 1 self self 179744 Feb 16 04:35 libtinfo.so.5.9
    lrwxrwxrwx 1 self self 15 Jan 26 12:11 libtinfo.so.6 -> libtinfo.so.6.2
    -rwxr-xr-x 6 self self 250400 Dec 31 1969 libtinfo.so.6.2
    lrwxrwxrwx 1 self self 14 Jan 26 12:11 libtinfow.so -> libtinfow.so.6
    lrwxrwxrwx 1 self self 16 Jan 26 12:11 libtinfow.so.6 -> libtinfow.so.6.2
    -rwxr-xr-x 6 self self 250520 Dec 31 1969 libtinfow.so.6.2


    Answer: Now it is there !

    (Sanity check from within the freedesktop sdk flatpak sandbox....)


    $ flatpak run --command=bash org.freedesktop.Sdk/x86_64/20.08
    [ org.freedesktop.Sdk x86_64-linux-gnu]$ ls -l /lib/x86_64-linux-gnu/libtinfo*
    lrwxrwxrwx 1 self self 13 Jan 26 12:11 /lib/x86_64-linux-gnu/libtinfo.so -> libtinfo.so.6
    lrwxrwxrwx 1 self self 15 Feb 16 04:36 /lib/x86_64-linux-gnu/libtinfo.so.5 -> libtinfo.so.5.9
    -rwxr-xr-x 1 self self 179744 Feb 16 04:35 /lib/x86_64-linux-gnu/libtinfo.so.5.9
    lrwxrwxrwx 1 self self 15 Jan 26 12:11 /lib/x86_64-linux-gnu/libtinfo.so.6 -> libtinfo.so.6.2
    -rwxr-xr-x 6 self self 250400 Dec 31 1969 /lib/x86_64-linux-gnu/libtinfo.so.6.2
    lrwxrwxrwx 1 self self 14 Jan 26 12:11 /lib/x86_64-linux-gnu/libtinfow.so -> libtinfow.so.6
    lrwxrwxrwx 1 self self 16 Jan 26 12:11 /lib/x86_64-linux-gnu/libtinfow.so.6 -> libtinfow.so.6.2
    -rwxr-xr-x 6 self self 250520 Dec 31 1969 /lib/x86_64-linux-gnu/libtinfow.so.6.2


    Same result. Seems good?
    (Sanity check from within UnityHub flatpak sandbox...)


    $ flatpak run --command=bash com.unity.UnityHub
    ~$ ls -la /usr/lib/x86_64-linux-gnu/libtinfo*
    lrwxrwxrwx 1 self self 13 Jan 26 12:11 /usr/lib/x86_64-linux-gnu/libtinfo.so -> libtinfo.so.6
    lrwxrwxrwx 1 self self 15 Feb 16 04:36 /usr/lib/x86_64-linux-gnu/libtinfo.so.5 -> libtinfo.so.5.9
    -rwxr-xr-x 1 self self 179744 Feb 16 04:35 /usr/lib/x86_64-linux-gnu/libtinfo.so.5.9
    lrwxrwxrwx 1 self self 15 Jan 26 12:11 /usr/lib/x86_64-linux-gnu/libtinfo.so.6 -> libtinfo.so.6.2
    -rwxr-xr-x 6 self self 250400 Dec 31 1969 /usr/lib/x86_64-linux-gnu/libtinfo.so.6.2
    lrwxrwxrwx 1 self self 14 Jan 26 12:11 /usr/lib/x86_64-linux-gnu/libtinfow.so -> libtinfow.so.6
    lrwxrwxrwx 1 self self 16 Jan 26 12:11 /usr/lib/x86_64-linux-gnu/libtinfow.so.6 -> libtinfow.so.6.2
    -rwxr-xr-x 6 self self 250520 Dec 31 1969 /usr/lib/x86_64-linux-gnu/libtinfow.so.6.2


    Same result. Seems promising ???
    Try to compile again!!
    (Still inside the UnityHub flatpak sandbox...)



    ~$ /usr/bin/python -E "/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/em++" -Wno-unused-value -Wno-invalid-offsetof -nostdinc -fno-strict-overflow -Wno-null-conversion -std=c++11 -O3 -Oz -DIL2CPP_EXCEPTION_DISABLED=1 -DNET_4_0 -DUNITY_AOT -DIL2CPP_MONO_DEBUGGER_DISABLED -DGC_NOT_DLL -DRUNTIME_IL2CPP -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DNDEBUG -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/bdwgc/include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/xxHash" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Platforms/WebGL/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp/pch" -I"/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput" "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput/Il2CppInvokerTable.cpp" -o "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/il2cpp_cache/FF48B8900D69F32F309A524A335269B1.o"
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    CRITICAL:root:Could not verify LLVM version: Command '['/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/clang++', '-v']' returned non-zero exit status 1.
    INFO:root:Checking JS engine ['node'] failed. Check your config file. Details: [Errno 2] No such file or directory: 'node'
    WARNING:root:cannot check node version: [Errno 2] No such file or directory: 'node'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc: /usr/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by /usr/lib/x86_64-linux-gnu/libtinfo.so.5)
    CRITICAL:root:fastcomp in use, but LLVM has not been built with the JavaScript backend as a target, llc reports:
    ===========================================================================
    (no targets could be identified: Command '['/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc', '--version']' returned non-zero exit status 1.)
    ===========================================================================
    CRITICAL:root:you can fall back to the older (pre-fastcomp) compiler core, although that is not recommended, see http://kripken.github.io/emscripten-site/docs/building_from_source/LLVM-Backend.html
    INFO:root:(Emscripten: Running sanity checks)
    ERROR:root:The JavaScript shell used for compiling (['node']) does not seem to work, check the paths in ~/.emscripten


    Answer: SUCCESS !!
    libtinfo.so.5 was found by the compiler inside the UnityHub flatpak sandbox !
    BUT
    There is a new error, from libtinfo.so.5 itself


    llc: /usr/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by /usr/lib/x86_64-linux-gnu/libtinfo.so.5)


    HMMMMMMMMM

    So, there is a problem...
    the version of libtinfo5 that I installed on my system (21.04)
    expects a NEWER version of libc.so.6 than is in the sandbox !!


    ~$ ls -la /usr/lib/x86_64-linux-gnu/libc.so.6
    lrwxrwxrwx 1 self self 12 Jan 26 12:11 /usr/lib/x86_64-linux-gnu/libc.so.6 -> libc-2.31.so


    This is what I installed:

    https://packages.ubuntu.com/hirsute/libtinfo5
    Package: libtinfo5 (6.2+20201114-2build1) [universe]
    depends: libc6 (>= 2.33)
    GNU C Library: Shared libraries

    See above, when it installed, it read: "libtinfo5:amd64 (6.2+20201114-2build1)"
    but we need libtinfo5 that depends on libc-2.31.so

    This is what we need:
    https://packages.ubuntu.com/focal/libtinfo5
    Package: libtinfo5 (6.2-0ubuntu2) [universe]
    depends: libc6 (>= 2.16) [not arm64, ppc64el]
    GNU C Library: Shared libraries
    also a virtual package provided by libc6-udeb
    depends: libc6 (>= 2.17) [arm64, ppc64el]
    Soooooo......

    ---------------------------------------------------------------------------------------------------------------------------
    SOLUTION

    Download the Ubuntu binaries that are compatible with the Freedesktop 20.08 container
    (which is using libc6 GLIBC_2.31)

    https://packages.ubuntu.com/focal/amd64/libtinfo5/download
    http://mirrors.kernel.org/ubuntu/pool/universe/n/ncurses/libtinfo5_6.2-0ubuntu2_amd64.deb

    so that we can copy the binaries into the freedesktop sdk flatpak sandbox
    without installing it onto the system (root), need to get the contents of the package...

    https://blog.packagecloud.io/inspect-extract-contents-debian-packages/


    $ dpkg -c ./libtinfo5_6.2-0ubuntu2_amd64.deb
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./lib/
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./lib/x86_64-linux-gnu/
    -rw-r--r-- root/root 183824 2020-02-26 02:14 ./lib/x86_64-linux-gnu/libtinfo.so.5.9
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/lib/
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/lib/x86_64-linux-gnu/
    -rw-r--r-- root/root 67896 2020-02-26 02:14 ./usr/lib/x86_64-linux-gnu/libtic.so.5.9
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/share/
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/share/doc/
    drwxr-xr-x root/root 0 2020-02-26 02:14 ./usr/share/doc/libtinfo5/
    -rw-r--r-- root/root 2341 2020-02-26 02:14 ./usr/share/doc/libtinfo5/changelog.Debian.gz
    -rw-r--r-- root/root 6366 2019-10-21 12:45 ./usr/share/doc/libtinfo5/copyright
    lrwxrwxrwx root/root 0 2020-02-26 02:14 ./lib/x86_64-linux-gnu/libtinfo.so.5 -> libtinfo.so.5.9
    lrwxrwxrwx root/root 0 2020-02-26 02:14 ./usr/lib/x86_64-linux-gnu/libtic.so.5 -> libtic.so.5.9


    Extract the contents of the debian package...


    # inside ~/Downloads

    $ mkdir libtinfo5

    $ ar -xv ./libtinfo5_6.2-0ubuntu2_amd64.deb --output libtinfo5
    x - libtinfo5/debian-binary
    x - libtinfo5/control.tar.xz
    x - libtinfo5/data.tar.xz

    $ cd libtinfo5
    ~/Downloads/libtinfo5$ tar xaf data.tar.* .
    ~/Downloads/libtinfo5$ ls
    control.tar.xz data.tar.xz debian-binary lib usr

    $ cd lib/x86_64-linux-gnu
    ~/Downloads/libtinfo5/lib/x86_64-linux-gnu$ ldd -v libtinfo.so.5.9
    linux-vdso.so.1 (0x00007fffb41cc000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fbbabb10000)
    /lib64/ld-linux-x86-64.so.2 (0x00007fbbabd48000)

    Version information:
    ./libtinfo.so.5.9:
    libc.so.6 (GLIBC_2.3) => /lib/x86_64-linux-gnu/libc.so.6
    libc.so.6 (GLIBC_2.14) => /lib/x86_64-linux-gnu/libc.so.6
    libc.so.6 (GLIBC_2.16) => /lib/x86_64-linux-gnu/libc.so.6
    libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
    libc.so.6 (GLIBC_2.3.4) => /lib/x86_64-linux-gnu/libc.so.6
    libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6
    /lib/x86_64-linux-gnu/libc.so.6:
    ld-linux-x86-64.so.2 (GLIBC_2.2.5) => /lib64/ld-linux-x86-64.so.2
    ld-linux-x86-64.so.2 (GLIBC_2.3) => /lib64/ld-linux-x86-64.so.2
    ld-linux-x86-64.so.2 (GLIBC_PRIVATE) => /lib64/ld-linux-x86-64.so.2



    This version of libtinfo5 appears to be compatible with the freedesktop 20.08 libc version (2.31)
    Okay, lets copy it into the freedesktop Sdk flatpak sandbox....


    $ cd ~/.local/share/flatpak/runtime/org.freedesktop.Sdk/x86_64/20.08/active/files/lib/x86_64-linux-gnu

    # I needed to do this to remove the (libc ahead version) ones I copied in earlier
    $ rm libtinfo.so.5*

    $ cp ~/Downloads/libtinfo5/lib/x86_64-linux-gnu/libtinfo.so.5.9 .

    $ ln -s libtinfo.so.5.9 libtinfo.so.5

    $ chmod a+x libtinfo.so.5*

    $ ls -la libtinfo*

    lrwxrwxrwx 1 self self 13 Jan 26 12:11 libtinfo.so -> libtinfo.so.6
    lrwxrwxrwx 1 self self 15 Feb 16 06:09 libtinfo.so.5 -> libtinfo.so.5.9
    -rwxr-xr-x 1 self self 183824 Feb 16 06:08 libtinfo.so.5.9
    lrwxrwxrwx 1 self self 15 Jan 26 12:11 libtinfo.so.6 -> libtinfo.so.6.2
    -rwxr-xr-x 6 self self 250400 Dec 31 1969 libtinfo.so.6.2
    lrwxrwxrwx 1 self self 14 Jan 26 12:11 libtinfow.so -> libtinfow.so.6
    lrwxrwxrwx 1 self self 16 Jan 26 12:11 libtinfow.so.6 -> libtinfow.so.6.2
    -rwxr-xr-x 6 self self 250520 Dec 31 1969 libtinfow.so.6.2



    Fin. (this should now be the correct libtinfo5 version which is supported in the freedesktop sandbox 20.08)
    -------------------------------------------------------------------------------------------------
    Now, lets try to compile again !



    ~$ /usr/bin/python -E "/home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/em++" -Wno-unused-value -Wno-invalid-offsetof -nostdinc -fno-strict-overflow -Wno-null-conversion -std=c++11 -O3 -Oz -DIL2CPP_EXCEPTION_DISABLED=1 -DNET_4_0 -DUNITY_AOT -DIL2CPP_MONO_DEBUGGER_DISABLED -DGC_NOT_DLL -DRUNTIME_IL2CPP -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DNDEBUG -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/bdwgc/include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/xxHash" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/external/baselib/Platforms/WebGL/Include" -I"/home/self/Unity/2020.3.27f1/Editor/Data/il2cpp/libil2cpp/pch" -I"/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput" "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/Il2cppBuildCache/WebGL/il2cppOutput/Il2CppInvokerTable.cpp" -o "/home/self/Documents/GitHub/cathaven/UnityProjects/CatJam/Library/il2cpp_cache/FF48B8900D69F32F309A524A335269B1.o"
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:781: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:896: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [a for a in newargs if a is not '']
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:1157: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert options.use_closure_compiler is not 2, 'EMTERPRETIFY requires valid asm.js, and is incompatible with closure 2 which disables that'
    /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emcc.py:2360: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    newargs = [arg for arg in newargs if arg is not '']
    INFO:root:Checking JS engine ['node'] failed. Check your config file. Details: [Errno 2] No such file or directory: 'node'
    WARNING:root:cannot check node version: [Errno 2] No such file or directory: 'node'
    WARNING:root:did not see a source tree above or next to the LLVM root directory (guessing based on directory of /home/self/Unity/2020.3.27f1/Editor/Data/PlaybackEngines/WebGLSupport/BuildTools/Emscripten_FastComp_Linux/llc), could not verify version numbers match
    INFO:root:(Emscripten: Running sanity checks)
    ERROR:root:The JavaScript shell used for compiling (['node']) does not seem to work, check the paths in ~/.emscripten



    SUCCESS !!! THE libtinfo.so.5 ERROR IS FIXED !!!

    Of course, there is other errors, like it cant find "node" JS
    Unity will of course set all of the directories correctly
    Let's try to Build the WebGL in Unity now...

    (the build is taking waaaay longer now, which is perhaps a good sign ?)


    Build completed with a result of 'Succeeded' in 377 seconds (376982 ms)
    UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) (at /home/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)


    SUCCESS !!! THE BUILD COMPLETED !!!

    !!! UNITY !!! MAKE YOUR OWN GAMES !!!
     
    Last edited: Feb 16, 2022
    alfish and yosr481 like this.
  3. yosr481

    yosr481

    Joined:
    Apr 27, 2016
    Posts:
    2
    Wow! you dug deeper... I'll look into it when I have time.
    When I reached out to the unity team, this is what I got in response: