Search Unity

Linux Build of Game Does Not Find Mono...

Discussion in 'Linux' started by datahead8888, Jan 26, 2016.

  1. datahead8888

    datahead8888

    Joined:
    Nov 5, 2015
    Posts:
    55
    I built the example 2D platformer game from the asset store. I selected the Linux 64 bit option. I found that when I try to run it in Ubuntu 12 Linux, it says it cannot find Mono. I have tried installing Mono (package mono-complete), but it still cannot find it.

    This is the output:
    Code (csharp):
    1.  
    2. datahead@datahead-G750JW:~/Documents/TestBuilds/TestBuilds$ ls
    3. UnityPlatformer_Data  UnityPlatformer.x86_64
    4.  
    5. datahead@datahead-G750JW:~/Documents/TestBuilds/TestBuilds$ ./UnityPlatformer.x86_64
    6. Set current directory to /home/datahead/Documents/TestBuilds/TestBuilds
    7. Found path: /home/datahead/Documents/TestBuilds/TestBuilds/UnityPlatformer.x86_64
    8. Unable to load mono library from /home/datahead/Documents/TestBuilds/TestBuilds/UnityPlatformer_Data/Mono (x86_64)
    9. Failed to load mono
    10.  
     
  2. sumauma

    sumauma

    Joined:
    Aug 11, 2015
    Posts:
    17
  3. datahead8888

    datahead8888

    Joined:
    Nov 5, 2015
    Posts:
    55
    This is an issue with running a built game in Linux, not in using the MonoDevelop code editor in Linux. I don't think those steps will work for this.
     
    sumauma likes this.
  4. sumauma

    sumauma

    Joined:
    Aug 11, 2015
    Posts:
    17
    Sorry, misread the post.
     
  5. datahead8888

    datahead8888

    Joined:
    Nov 5, 2015
    Posts:
    55
    Does anyone else know how to get a Linux build of a Unity game to find Mono?
     
  6. SergeantG

    SergeantG

    Joined:
    Sep 12, 2015
    Posts:
    32
    Is
    present in
    or not?
     
  7. LukaKotar

    LukaKotar

    Joined:
    Sep 25, 2011
    Posts:
    394
    The 'Mono' folder (inside UnityPlatformer_Data) should contain two folders: etc and x86_64. x86_64 contains the file you've mentioned. Do you have the etc folder?
     
  8. datahead8888

    datahead8888

    Joined:
    Nov 5, 2015
    Posts:
    55
    Sorry for the very slow response. I had some things going on for a while.

    No, libmono.so is not present in the Mono/x86_64 directory. What might be preventing Unity from including this automatically if it is needed?

    Yes, I have a Mono/etc folder. For this built game, though, it is empty.
     
    Last edited: Apr 18, 2016
  9. knobby67

    knobby67

    Joined:
    Aug 30, 2015
    Posts:
    389
    have you went to edit->preferences->external tools, then from external script editor click on combo box and choose browse. Then go to usr/bin and select monodevelop ( some put mono in opt ). Restart unity.

    If this does work uninstall then reinstall mono. Then redo the step above.
     
  10. Tak

    Tak

    Joined:
    Mar 8, 2010
    Posts:
    1,001
    If libmono.so isn't getting deployed when you build your project, either something's going wrong with the build, or something went wrong with your Unity installation. Do you have libmono.so for each variation in Unity/Editor/PlaybackEngines/LinuxStandaloneSupport/ ?
     
  11. LukaKotar

    LukaKotar

    Joined:
    Sep 25, 2011
    Posts:
    394
    I just wanna point out that the path is Unity/Editor/Data/PlaybackEngines/LinuxStandaloneSupport/

    Anyway, to add to what Tak was saying, you can check if all the files are there by running this in a terminal (assuming Unity is installed in the /opt directory):
    ls -v /opt/Unity/Editor/Data/PlaybackEngines/LinuxStandaloneSupport/Variations/*/Data/Mono/x86*
    You should see libmono.so listed under each path.