After upgrading to 2019.3.0b4 and a long time since compiling, I found out that I am compiling a 330kb exe that says: "The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail." Of which is below in code-form.
I tried reinstalling C++ Redistributables, Visual Studios (between 2015, 2017, 2019).
I tried compiling with il2cpp and I get the same problem.
Tried running the exe on different other pcs and I get the same message.
Tried compiling on different other pcs and I get the same result.
Destroyed obj, temp, Library, csproj and still nothing.
I don’t know what else to do Can anybody help?
Edit: I narrowed the issue to one of the ProjectSettings being corrupted. Unity reads all of them properly but one of them (At least one) is broken.
Edit: Narrowed down the issue more to the game icon / cursor being set with my images. Worked fine till 2019.3. Trying out different images.
Are you on Windows? This can happen sometimes if you have Mandatory ASLR option turned on in Windows Exploit Protection settings. Might be worth giving it a try with that thing turned off.
I am on Windows, but does this affect compilation or running it?
I narrowed down the problem has HAVING ANY icon at the application icon field, right above the cursor field for a texture. If I remove that, it compiles fine.
It would probably affect running it, not sure about compilation. Side by side thing is referring to Windows/WinSxS, which is Windows’s way of finding the correct version of a system DLL based on an application’s manifest. Mandatory ASLR can throw that system off if the application is not accounting for it. When I have it on, I can’t even run Unity’s installer.
It could be that specifying an application icon requires specific dll access. It’s easy to test for. Turn ASLR off, restart (may not even be necessary) and try running it again.
While I understand and appreciate your suggestion, I cannot expect users to have to do this if it reproduces on their pcs (and I have reproduced it on 4 other window computers). Removing the icon from the Player, although using the Unity icon, works on my pc and the others! So it is definetly a Unity bug.
Oh yes, no argument there. I was just trying to help you pinpoint the cause. Another issue might be that the application manifest xml is malformed when Unity generates it. You can probably find the manifest in plain text form if you open the .exe file with a text editor like Notepad++. I’d check to see if the xml syntax is correct.
Hey could you report a bug with an image file that causes this issue? I tried a trivial example (just made a new icon in mspaint) and I couldn’t reproduce it.
YES!! If I use my builder .cs script within Unity, it will crash it. If i use normal Build or from a commandline -nographics, it won’t crash anything, but STILL make a corrupted exe with malformared manifest xml inside.
Bug was solved only partially. Although the exe is no longer corrupt, the result is a Windows icon instead of the one I have chosen (see it at the bottom of the image).
My exe is of course: “The Underground King.exe”
I exported this in 2019.3.0b6
Hi there, we are in the process of fixing the issue right now. The corrupt executable can result from adding a custom icon to the project. In your case, you were “lucky” that you didn’t crash, but in the meantime as a workaround, you can disable the image, and it should work correctly.
I had this issue when building into the same folder as I previously did with 2018.4 without deleting all of it’s previous content. I tried building to an empty folder and it works.