Search Unity

Unity Editor crush when calling a function from a shared library under Linux Platform

Discussion in 'Editor & General Support' started by LAFI, May 10, 2018.

  1. LAFI

    LAFI

    Joined:
    Sep 5, 2014
    Posts:
    47
    Hello,
    i have build a shared library and call a function from it.
    This function read a file that have a size from 80mb to 500mb, when i hit play in the Editor he crush, i have build the scene for Linux platform and test the executable and he work fine, but what i don't understand why he crush in Editor mode!

    Ps: I'm using unity for Linux, the file that the function from the shared library read it is under StreamingAsset Folder
     
  2. tsibiski

    tsibiski

    Joined:
    Jul 11, 2016
    Posts:
    604
    Can you go find the Editor.log file, and paste the end part of the log right after a crash? On a Mac, it is located in ~/Library/Logs/Unity

    On a PC, it is somewhere under %APPDATA%/Unity I think
     
  3. LAFI

    LAFI

    Joined:
    Sep 5, 2014
    Posts:
    47
    i'm using unity on Ubuntu, where i can find the log file please?
     
  4. LAFI

    LAFI

    Joined:
    Sep 5, 2014
    Posts:
    47
    here is the log after i run the function in the shared library:


    ----- Total AssetImport time: 0.052846s, AssetImport time: 0.000000s, Asset hashing: 0.000000s [0 B, 0.000000 mb/s]


    Packing sprites:
    [ 34 MB ]- Skipping packing - Sprite Packer (Legacy) is off.
    [ 34 MB ]Sprite Atlas Operation : " ## Packed All Sprite Atlases ## " took 0.000115 sec (current mem: 34 MB)
    Reloading assemblies for play mode.
    Begin MonoManager ReloadAssembly
    Registering platform support modules:
    Registered platform support modules in: 0.0495372s.
    Refreshing native plugins compatible for Editor in 0.54 ms, found 4 plugins.
    Preloading 1 native plugins for Editor in 0.15 ms.
    requesting resize 617 x 410
    resizing window to 617 x 410
    Desktop is 1366 x 768 @ 60 Hz
    Initializing Unity.PackageManager (PackageManager) v2017.2.0 for Unity v2017.2.0b11
    Registering platform support modules:
    Registered platform support modules in: 0.0447282s.
    Mono: successfully reloaded assembly
    - Completed reload, in 1.687 seconds
    Modules already registered, not loading
    Native extension for Facebook target not found
    Native extension for OSXStandalone target not found
    Native extension for WindowsStandalone target not found
    Native extension for LinuxStandalone target not found
    Native extension for WebGL target not found
    Native extension for SamsungTV target not found
    Native extension for Tizen target not found
    Native extension for iOS target not found
    Native extension for Android target not found
    Load scene 'Temp/__Backupscenes/0.backup' time: 0.349000 ms
    Refresh: detecting if any assets need to be imported or removed ... Refresh: elapses 0.132010 seconds
    Refreshing native plugins compatible for Editor in 0.62 ms, found 4 plugins.
    Preloading 1 native plugins for Editor in 0.11 ms.

    ----- Total AssetImport time: 0.092600s, AssetImport time: 0.000000s, Asset hashing: 0.000000s [0 B, 0.000000 mb/s]

    /*******************

    some log of the function in the shared library i have removed

    ***********************//

    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UsbDevices.cpp:UsbDevicesQuery
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent
    /***

    the result of the function call in the shared library(i have removed it also

    ****/
    Load scene 'Temp/__Backupscenes/0.backup' time: 285.261000 ms
    Unloading 16 Unused Serialized files (Serialized files now loaded: 0)
    System memory in use before: 33.9 MB.
    System memory in use after: 33.8 MB.

    Unloading 39 unused Assets to reduce memory usage. Loaded Objects now: 2926.
    Total: 5996.161000 ms (FindLiveObjects: 173.800000 ms CreateObjectMapping: 76.768000 ms MarkObjects: 5337.433000 ms DeleteObjects: 408.158000 ms)

    Refresh: detecting if any assets need to be imported or removed ... Refresh: elapses 17.637242 seconds
    Refreshing native plugins compatible for Editor in 1808.56 ms, found 4 plugins.
    Preloading 1 native plugins for Editor in 5078.49 ms.

    ----- Total AssetImport time: 24.115125s, AssetImport time: 0.000000s, Asset hashing: 0.000000s [0 B, 0.000000 mb/s]