AdaCore / gnatstudio

GNAT Studio is a powerful and lightweight IDE for Ada and SPARK.
399 stars 52 forks source link

Latests release (20230501) crashes at start-up on Windows 11; libglib2.0-0.dll with exception 0x400000015 #165

Closed aiunderstand closed 1 year ago

aiunderstand commented 1 year ago

The previous gnatstudio release (20220512) runs fine. Anyone else seeing this issue?

aiunderstand commented 1 year ago

Log files found in C:\Users[username].gnatstudio

For previous version:

[GPS.MAIN.GPS] GNAT Studio 23.0w (20220512) hosted on x86_64-w64-mingw32 (14:59:57.121) [GPS.MAIN.GPS] Gtk+ static version: 3.24.31 (14:59:57.121) [GPS.MAIN.GPS] Gtk+ dynamic version: 3.24.31 (14:59:57.121) [GPS.KERNEL.DEFAULT_PREFS] Theme search path is C:\Users\maxde.themes;D:\Programs\GNATstudio\share\themes (14:59:57.138) [GPS.KERNEL.DEFAULT_PREFS] System's default theme is (14:59:57.138) [GPS.KERNEL.DEFAULT_PREFS] Theme search path not found on disk: C:\Users\maxde.themes (14:59:57.138) [GPS.KERNEL.DEFAULT_PREFS] Load new style preferences from C:\Users\maxde.gnatstudio\preferences.xml (14:59:57.278) [GPS.KERNEL.GPS_KERNEL] Loading histories.xml (14:59:57.281) [GPS.KERNEL.CLIPBOARD] Loading C:\Users\maxde.gnatstudio\clipboards.xml (14:59:57.288) [GPS.KERNEL.STOCK] Icon size Local Toolbar => 12x 12 (14:59:58.043) ... etc

For latest version:

[GPS.MAIN.GPS] GNAT Studio 24.0w (20230501) hosted on x86_64-w64-mingw32 (15:01:02.289) [GPS.MAIN.GPS] Gtk+ static version: 3.24.36 (15:01:02.289) [GPS.MAIN.GPS] Gtk+ dynamic version: 3.24.36 (15:01:02.289) [GPS.KERNEL.DEFAULT_PREFS] Theme search path is C:\Users\maxde.themes;C:\GNATIDE\share\themes (15:01:02.305) [GPS.KERNEL.DEFAULT_PREFS] System's default theme is (15:01:02.305) [GPS.KERNEL.DEFAULT_PREFS] Theme search path not found on disk: C:\Users\maxde.themes (15:01:02.305) [GPS.KERNEL.DEFAULT_PREFS] Load new style preferences from C:\Users\maxde.gnatstudio\preferences.xml (15:01:02.412) [GPS.KERNEL.GPS_KERNEL] Loading histories.xml (15:01:02.413) [GPS.KERNEL.CLIPBOARD] Loading C:\Users\maxde.gnatstudio\clipboards.xml (15:01:02.420)

so the error starts after loading the clipboard

aiunderstand commented 1 year ago

Some extra details. I installed the latest version on my old Windows 8.1 PC and there it runs fine. I noticed that the downloaded executable on both PC was equal in size (279.691 KB) but the folders after installation had different sizes. The working version had 17.030 Files, 1.827 Folders while the failing version had 16.866 Files, 1.808 Folders. I simply copied the working version folder over to the Windows 11 machine and ran the copied folder without issue.

A file comparison with WinMerge shows that most of the differences are pycache but the most interesting ones (presumably) are:

\registry-gnatstudio-24.0 -system.reg \registry-gnatstudio-24.0 -user.reg \lib\gdk-pixbuf-2.0\2.10.0\loaders.cache (different file size) \share\glib-2.0\schemas\ (8 files were missing !) \bin\default.gpr \bin\gpsauto.cgpr

I then proceeded to ignore the pycache and copy files over one by one from the copied folder to the failed folder and see when gnatstudio from the failed folder would run.

\lib\gdk-pixbuf-2.0\2.10.0\loaders.cache (different file size 1kb vs 3 kb) \share\glib-2.0\schemas\ (8 files were missing !) \bin\default.gpr \bin\gpsauto.cgpr

After copying these files it works. Any idea why my Windows 11 machine has a different installation folder than my Windows 8.1 machine?

aiunderstand commented 1 year ago

I did an installation of 24.0w with 35 students and none of them had this issue. Closing this issue as this is likely a very specific issue with my workstation. It can be fixed with the workaround described above.