stripping not working

Easy Save 2 has been replaced by Easy Save 3, so is no longer supported.
laserpants
Posts: 7
Joined: Tue Mar 04, 2014 5:04 am

Re: stripping not working

Post by laserpants »

I've commented out any places I was saving or loading dicts, and that seems to have done the trick. I'll work on converting them to lists as a temporary workaround.
User avatar
Joel
Moodkie Staff
Posts: 4852
Joined: Wed Nov 07, 2012 10:32 pm

Re: stripping not working

Post by Joel »

Good news everyone!

I've managed to track down exactly where the bug is in Unity's stripping process (after three hours of commenting out code and recompiling), and I'm just in the process of submitting an update to the Asset Store which avoids the bug.

With any luck the update will be live before the end of the week (it'll be v2.35)

All the best,
Joel
laserpants
Posts: 7
Joined: Tue Mar 04, 2014 5:04 am

Re: stripping not working

Post by laserpants »

Sweet! Glad I procrastinated and didn't rewrite all my dicts yet. :)
chud575
Posts: 12
Joined: Sat Feb 15, 2014 7:02 pm

Re: stripping not working

Post by chud575 »

Hi Joel,

I'm running version 2.50 of ES2, and Unity 4.6 B20 (Equivalent to 4.5.4f1).

I was really hoping to not bump this thread, But i'm experiencing a similar problem, when compiling specifically to iOS (not PC/Mac).
I've tried very carefully to delete all the ES2 stuff, compiled (it works), then add ES2 back. Same problem. Here is the error.
Cross compilation job ES2.dll failed.
UnityEngine.UnityException: Failed AOT cross compiler: /Applications/Unity/Unity.app/Contents/PlaybackEngines/iOSSupport/Tools/OSX/mono-xcompiler --aot=full,asmonly,nodebug,ficall,static,outfile="ES2.dll.s" "ES2.dll" current dir : /Users/Chud/Documents/Unity/DTSQ_NewEZGUI/Temp/StagingArea/Data/Managed
Env: Apple_PubSub_Socket_Render = '/tmp/launch-D0tGBW/Render'
LOGNAME = 'Chud'
__CHECKFIX1436934 = '1'
MONO_PATH = '/Users/Chud/Documents/Unity/DTSQ_NewEZGUI/Temp/StagingArea/Data/Managed'
TMPDIR = '/var/folders/3m/5rk9nvg55970j1b_4l_kp6kw0000gn/T/'
USER = 'Chud'
SSH_AUTH_SOCK = '/tmp/launch-LMdmcW/Listeners'
GC_DONT_GC = 'yes please'
SHELL = '/bin/bash'
__CF_USER_TEXT_ENCODING = '0x1F5:0:0'
GAC_PATH = '/Users/Chud/Documents/Unity/DTSQ_NewEZGUI/Temp/StagingArea/Data/Managed'
HOME = '/Users/Chud'
PATH = '/usr/bin:/bin:/usr/sbin:/sbin'
result file exists: False. Timed out: False
stdout:
stderr:

at UnityEditor.MonoProcessUtility.RunMonoProcess (System.Diagnostics.Process process, System.String name, System.String resultingFile) [0x00000] in <filename unknown>:0
at UnityEditor.MonoCrossCompile.CrossCompileAOT (BuildTarget target, System.String crossCompilerAbsolutePath, System.String assembliesAbsoluteDirectory, CrossCompileOptions crossCompileOptions, System.String input, System.String output, System.String additionalOptions) [0x00000] in <filename unknown>:0
at UnityEditor.MonoCrossCompile+JobCompileAOT.ThreadPoolCallback (System.Object threadContext) [0x00000] in <filename unknown>:0
UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()
User avatar
Joel
Moodkie Staff
Posts: 4852
Joined: Wed Nov 07, 2012 10:32 pm

Re: stripping not working

Post by Joel »

Hi there,

We've been in contact with Unity and are hopefully going to come up with some sort of solution for us next week. At the moment the AOT compiler throws no useful errors so we're very limited by what we can do.

Out of interest, are you using Dictionaries in your code? And I presume you're using Byte Code Stripping?

All the best,
Joel
chud575
Posts: 12
Joined: Sat Feb 15, 2014 7:02 pm

Re: stripping not working

Post by chud575 »

Joel wrote:Hi there,

We've been in contact with Unity and are hopefully going to come up with some sort of solution for us next week. At the moment the AOT compiler throws no useful errors so we're very limited by what we can do.

Out of interest, are you using Dictionaries in your code? And I presume you're using Byte Code Stripping?

All the best,
Joel
Hi Joel,

Just stripping assemblies, and no I don't believe i'm using dictionaries at all. I use the the writer and reader to do all my saving.
Looking forward to the fix! thanks.
AxelF
Posts: 3
Joined: Wed Oct 08, 2014 9:43 am

Re: stripping not working

Post by AxelF »

Is there anything new on this subject?
User avatar
Joel
Moodkie Staff
Posts: 4852
Joined: Wed Nov 07, 2012 10:32 pm

Re: stripping not working

Post by Joel »

Hi Axel,

It's been a bit of a nightmare really. Communication with Unity is going a little slow (seems to be taking over a week to get a reply to each email).

We've also now encountered the problem of our Pro license spontaneously not working on our machines, and the Support team and Sales team can't quite decide who's responsibility it is to fix it (so we've been over 2 weeks without a Pro license now). An indie developer friend of ours has kindly let us use their machine and Pro license when their workload is a bit lower, so I'm going to take the 4 hour drive down to theirs as soon as they can accommodate me.

I can't apologise enough for the delay, we really do just want to get this sorted. We have projects which rely on stripping too so it's become doubly frustrating for us.

Thanks for your patience,
Joel
AxelF
Posts: 3
Joined: Wed Oct 08, 2014 9:43 am

Re: stripping not working

Post by AxelF »

Thanks for this update and your efforts!
User avatar
Joel
Moodkie Staff
Posts: 4852
Joined: Wed Nov 07, 2012 10:32 pm

Re: stripping not working

Post by Joel »

Stripping is finally working again!

It looks like Unity have fixed the main bug at their end in Unity 4.5.5f1, so if you're having problems with stripping, make sure you've put the link.xml in your Assets folder and have updated to the latest version of Unity and Easy Save. Also remember that stripping will always fail if you set it to use micro mscorlib.

BUT: There is one other stripping bug in Unity which causes AOT cross-compilation errors when saving arrays or 2D arrays. Basically saving 2D arrays doesn't work, and if you attempt to save an array without specifying the optional ES2Settings object, it will fail. i.e
// This doesn't work.
ES2.Save(new int[]{1,2,3}, "myArray");
// This works.
ES2.Save(new int[]{1,2,3}, "myArray", new ES2Settings());
We're releasing a fix for this in v2.53. The only caveat is that if you're saving 2D arrays, you'll need to use ES2.Save2DArray instead of ES2.Save.

Also a big thanks to Axel for helping me confirm that Unity had fixed the issue today. It really helped me get to the bottom of this!

All the best,
Joel
Locked