Unity 5.1.1 error : dll is not allowed to be included or could not be found

I’m new to unity and upgrading one of my app using Unity 5.1.1. It was working fine with 4.6.2, but I’m getting following error after upgradation

ArgumentException: The Assembly UnityEditor is referenced by iGUI ('Assets/lib/igui/Runtime/iGUI.dll'). But the dll is not allowed to be included or could not be found. UnityEditor.AssemblyHelper.AddReferencedAssembliesRecurse (System.String assemblyPath, System.Collections.Generic.List\1 alreadyFoundAssemblies, System.String allAssemblyPaths, System.String foldersToSearch, System.Collections.Generic.Dictionary`2 cache, BuildTarget target) (at /Users/builduser/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:154)
UnityEditor.AssemblyHelper.AddReferencedAssembliesRecurse (System.String assemblyPath, System.Collections.Generic.List`1 alreadyFoundAssemblies, System.String allAssemblyPaths, System.String foldersToSearch, System.Collections.Generic.Dictionary`2 cache, BuildTarget target) (at /Users/builduser/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:160)
UnityEditor.AssemblyHelper.FindAssembliesReferencedBy (System.String paths, System.String foldersToSearch, BuildTarget target) (at /Users/builduser/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:192)
UnityEditor.HostView:OnGUI()`

I tried change compatibility from “.net 2.0 subset” to “.net 2.0”, but that didn’t worked.

Any help will be appreciated

Thanks in advance

UnityEditor is not allowed to be included in builds. It’s only allowed to be used in editor extensions.