[Solved]Unity 5.1 Doesn't Works On OS X 10.11

Hi there,
I just switch to OS X 10.11 after the WWDC, when I run Unity, it is able to run but not able to build any game.
When I build my game and target it to iOS , Unity shows me that :
2150337--141917--Screen Shot 2015-06-09 at 8.40.16 PM.png

So I am not able to build my game, if any one have the same problem please share your solution, I am not able to build any game now. (It looks like a change of API in OS X that make Unity not able to run, wondering when if there is an update.)

Thanks

EDIT: Now I got a solution here, posted on down there.

Plus : I am building for iOS

Is this the beta of El Capitan? Things are bound to be funky since it’s not released yet.

Yes.
I have tried to build for a number of platforms and only iOS doesn’t work.

But I am not able to switch back to Yosemite, could you please launch a new version that support 10.11?
I believe that many developers like me which updated to the beta of OS X will suffer this.

Thanks

Anyone here please help, :(:(:frowning:

5.1f2 is still unreleased version of 5.1, can you download it from the site now Start Your Creative Projects and Download the Unity Hub | Unity The full release being 5.1f3

I can’t guarantee this will work, since OSX 10.11 isn’t even a public beta, it’s usually not advisable to switch to beta software during development.

Thanks you I will give this a try, hope it will work, come back here later :slight_smile:

Abit of topic but if Unity plan to support El Capitan, please provide retina support and metal (If Adobe can do it so can Unity) not sure if Metal will provide Unity with a speed upgrade as rather slow app on Mac…
Of course you rushed QI, how can Unity upgrade that quick…

That is totally off topic, but yes, we plan on supporting Metal and we are currently working on retina too.

I wish if Unity support metal, it can enhance editor experience on Mac so we can works better :slight_smile:

Please keep this topic focused on the issue, there is a thread in the discussion forum.

Yeah I am trying to get the new version ready and give it a try.

build from script with BuildPipeline.BuildPlayer (that kinda works)

We are looking into this issue. But it will take 1-2 weeks until fix reaches patch releases for various Unity versions.
At the moment please try Alexey’s workaround.

Hi Alexey, I am trying to use you workaround, just wondering is there any way to let me get all scenes path via the build setting?

Hi there again. I figure this thing out myself and wrote a simple code that would able to workaround:

using UnityEditor;
using UnityEngine;

public class BuildForiOS : MonoBehaviour {

    [MenuItem("File/Build For iOS (Development)")]
    static void BuildForiOSDevelopment(){
        //Get all scenes from build setting UI.
        EditorBuildSettingsScene[] scenes = EditorBuildSettings.scenes;
        string[] scenesPath = new string[scenes.Length];
        for (int i = 0; i < scenesPath.Length; i++) scenesPath[i] = scenes[i].path;

        //Select where to save files
        string previousPath = EditorPrefs.GetString ("BuildForiOS.PreviousPath", Application.persistentDataPath);
        string destination = EditorUtility.SaveFilePanel ("Choose a destination", previousPath, EditorPrefs.GetString("BuildForiOS.Name",""), "");

        //Check if user canceled the action.
        if (!string.IsNullOrEmpty (destination)) {
            //Saving settings for the next build.
            string name = destination.Substring(destination.LastIndexOf("/") + 1);
            EditorPrefs.SetString ("BuildForiOS.PreviousPath", destination.Substring(0,destination.LastIndexOf("/")));
            EditorPrefs.SetString("BuildForiOS.Name", name);

            //Build the player
            BuildPipeline.BuildPlayer (scenesPath, destination, BuildTarget.iOS, BuildOptions.Development | BuildOptions.ShowBuiltPlayer | BuildOptions.Il2CPP);
        }

    }

}

This code performs a simple build action for iOS with development build and il2cpp option, you can custom it yourself.
Hope this will help someone that faced the same problem like me.

Notice : use this code to build a player will always replace your whole Xcode project, I didn’t find any option for “append” currently.

2 Likes

Add
BuildOptions.AcceptExternalModificationsToPlayer
to the BuildPlayer and it will append.

Thanks you very much, that works :slight_smile:

I have the same problem, but if I try the QI thing, I got an error:

Assets/BuildForiOS.cs(1,7): error CS0246: The type or namespace name `UnityEditor’ could not be found. Are you missing a using directive or an assembly reference?
and
Error building Player because scripts had compiler errors

I hope that Unity will make a Update soon…

Hi there ,I am not sure how you copy and pasted my code, but this code should not have any errors. And your error seems like the compiler could not find any namespace names “UnityEditor” which is definitely here. So I recommend you check your file carefully, you can try to create a empty file and paste the code the I have posted.

I am sure this code works because I am using this code to build since i updated to 10.11.