GNOME Bugzilla – Bug 558314
Tomboy can have problems if other GTK+ installs modify PATH and GTK_BASEPATH
Last modified: 2012-03-08 15:01:29 UTC
As reported by Michel Coutu at http://automorphic.blogspot.com/2008/10/tomboy-preview-for-windows-and-mac.html <quote> 2. Once installed, it kept crashing on me on 3 Windows machines... I suspected Pidgin with it GTK+ runtime libraries... I uninstalled Pidgin and its associated GTK+ runtime and Tomboy still crashed. So,... 3. I rebuild one of the Windows machine today with SP3. I installed the GTK# SDK and Tomboy and it all works like a charm. 4. Upon re-installing Pidgin back on that fresh install, the GTK+ runtime for Pidgin balked at me and crapped right out!!! It appears that Windows (or something in its bowels) does not like GTK# and GTK+ being there at the same time (???) </quote> Brad Taylor told me to expect these sorts of conflicts between Medsphere's GTK# installer and other installed GTK+ runtimes. At this time I don't know any details of the problems, except that it may be related to $PATH and $GTK_BASE_PATH being mangled. If that's the case, we may be able fix this in the Tomboy shortcuts we install?
*** Bug 572133 has been marked as a duplicate of this bug. ***
Updating summary to reflect real problem that needs to be solved. I am working on a solution which just modifies PATH and GTK_BASEPATH when Tomboy starts, and it works fine. The only problem is determining the install location of GTK# (may require a newer installer for it to work perfectly). From what I saw, the latest Pidgin installer doesn't actually put anything in those environment variables, and it does not conflict with Tomboy, so other GTK+/GTK# installs are the real problem here (plus the weird PATH errors described in bug 581381#8 ).
Hi Sandy, is there a quick workaround for this (even opening a command line and setting PATH or GTK_BASEPATH so some required value (what values are required?) an then launching tomboy). I need tomboy in my windows machine (hundreds of notes there!), plus I also have wireshark, pidgin, filezilla using gtk+ in this windows box. thanks a lot
Can you - install 0.15.0 and run it from a command window, providing us with the messages it writes before it crashes? - provide the values of both variables on your system? - try to fix errors/strange variable expansions in %PATH% (that was the problem for the last guy with a gtk error)? - tell us which gtk# version you are using?
Ariel, you can make sure that "C:\Program Files\GtkSharp\2.12\bin" is at the front of your path (assuming that's your install location), and that GTK_BASEPATH is set to "C:\Program Files\GtkSharp\2.12\". You could do this with a batch file and use the batch file to launch Tomboy. There are probably other clever ways to do it, too. Our solution will do it directly in the code (but it's not in git or any release yet).
Benjamin: There are no messages in the command window; after typing "tomboy.exe" I get windows' "send error report" dialog saying: Tomboy.exe has encountered a problem and needs to close. We are sorry for the inconvenience. This is with Tomboy-0.15.0.msi, gtk-sharp-2.12.8-1.win32.msi executing "set" I get: GTK_BASEPATH=C:\Program Files\GtkSharp\2.12\ Path=C:\Program Files\GtkSharp\2.12\bin;C:\Perl\bin\;C:\WINNT\System32\;C:\WINNT \;C:\WINNT\System32\wbem;C:\Program Files\vbapps\bin;C:\Program Files\Hummingbird\Connectivity\9.00\Accessories\;C:\Program Files\Common Files\GTK\2.0\bin;C:\Program Files\QuickTime\QT System\;C:\WINNT\system32;C:\WINNT; I don't fully understand what the third question means, - try to fix errors/strange variable expansions in %PATH% (that was the problem for the last guy with a gtk error)?
Hi - problem solved. I uninstalled gtkshark, then tomboy, then rebooted, then reinstalled gtksharp then tomboy 0.15, and now it works. Perhaps the problem was a fluke due to the upgrade. Anyhow, one more reason I dislike windows so much. Unfortunately I am forced to use it in the office.
(In reply to comment #7) > Hi - problem solved. I uninstalled gtkshark, then tomboy, then rebooted, then > reinstalled gtksharp then tomboy 0.15, and now it works. > Perhaps the problem was a fluke due to the upgrade. Glad it's finally working! Thanks for being persistent, we're gradually getting rid of all of these frustrating Windows install bugs. :-)
Gilad, with Tomboy 0.15.0, please share the following with me: * The value of your PATH environment variable * The value of your GTK_BASEPATH environment variable * The output received on the command line when you try to launch Tomboy.exe from a command window If you need help with any of this, please let me know.
PATH: c:\Program Files\GtkSharp\2.12\bin\;c:\Python25;C:\ZSP\bin;C:\Program Files\PC Connectivity Solution\;C:\Perl\bin\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\system32\wbem;c:\program files\ati technologies\ati control panel;C:\Program Files\MATLAB\R2008a\bin;C:\Program Files\MATLAB\R2008a\bin\win32;C:\Program Files\MATLAB\R2007a\bin;C:\Program Files\MATLAB\R2007a\bin\win32;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\MATLAB\MATLAB Compiler Runtime\v78\runtime\win32;C:\Program Files\Medsphere\Gtk# Runtime\bin;C:\Program Files\Medsphere\Gtk# SDK\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\doxygen\bin;C:\PROGRA~1\ATT\Graphviz\bin;%ICPP_COMPILER10%\IA32\Bin;c:\bin;C:\Gtk#SDK\bin;C:\Program Files\GtkSharp\Runtime\bin;C:\Program Files\GtkSharp\2.12\bin;C:\Program Files\NVIDIA Corporation\Cg\bin GTK_BASEPATH: C:\Program Files\GtkSharp\2.12\ Tomboy.exe output: Unhandled Exception: System.DllNotFoundException: Unable to load DLL 'libgtk-win 32-2.0-0.dll': The specified procedure could not be found. (Exception from HRESU LT: 0x8007007F) at Gtk.Application.gtk_init(Int32& argc, IntPtr& argv) at Gtk.Application.Init() at Tomboy.WindowsApplication.Initialize(String locale_dir, String display_nam e, String process_name, String[] args) in c:\Users\sandy\Desktop\gnome-git\tombo y\Tomboy\WindowsApplication.cs:line 51 at Tomboy.Application.Initialize(String locale_dir, String display_name, Stri ng process_name, String[] args) in c:\Users\sandy\Desktop\gnome-git\tomboy\Tombo y\Utils.cs:line 922 at Tomboy.Tomboy.Main(String[] args) in c:\Users\sandy\Desktop\gnome-git\tomb oy\Tomboy\Tomboy.cs:line 50
Interesting, do you actually have GTK files in c:\Program Files\GtkSharp\2.12\bin ? I know you said you had uninstalled/reinstalled, but still good to double-check. :-)
Can you fix your PATH and retry? First, save the current path (or use this bug as reference if you need to revert). Then - Remove duplicates (c:\Program Files\GtkSharp\2.12\bin is present more than once) - Check for invalid paths (What are those C:\Gtk#SDK paths used for?) and remove those - Check variable expansions: If "echo %ICPP_COMPILER10%\IA32\Bin" on a console doesn't look like a real path, remove it - Make sure that c:\Program Files\GtkSharp\2.12\bin is at the start of the PATH (as it is now) If you have some time on your hands and want to see if this is the real cause: Do it one by one and always restart tomboy inbetween, to find the problem. But that's probably overkill. You _might_ need to lock out/log in for changes to take effect, not sure.
Remove the duplicates and left with: c:\Program Files\GtkSharp\2.12\bin\;c:\Python25;C:\ZSP\bin;C:\Program Files\PC Connectivity Solution\;C:\Perl\bin\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\system32\wbem;c:\program files\ati technologies\ati control panel;C:\Program Files\MATLAB\R2008a\bin;C:\Program Files\MATLAB\R2008a\bin\win32;C:\Program Files\MATLAB\R2007a\bin;C:\Program Files\MATLAB\R2007a\bin\win32;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\MATLAB\MATLAB Compiler Runtime\v78\runtime\win32;C:\Program Files\TortoiseSVN\bin;C:\Program Files\doxygen\bin;%ICPP_COMPILER10%IA32\Bin;c:\bin;C:\Program Files\NVIDIA Corporation\Cg\bin Got the same error. Removed everything in the PATH but the: c:\Program Files\GtkSharp\2.12\bin\; Same error. Maybe it has something to do with the global assembly cache?
Hi Benjamin, Gilad, The %-sign in the PATH is exactly the issue I was facing -- making sure that there were no %-signs in my PATH was the way I resolved this error (fully described in bug #581381 , comment #8 ). However, the proposed check: If "echo %ICPP_COMPILER10%\IA32\Bin" on a console doesn't look like a real path, remove it isn't enough, because this _will_ provide a valid path on the command line. (The "%ICPP_COMPILER10%" variable might expand -- of course, if it doesn't expand to anything, you can delete this path!). The issue I ran into is that there is a pre-variable-substitution version of the PATH hidden away in system settings. That version can have errors that propagate to the PATH; in particular, double %-signs. Go to Control Panel / System / Advanced Tab / -- then click on the "Environment Variables" button near the bottom. In the lower scrollbox on the window that appears, scroll down until you see "Path", then click on it to select it, then click the "Edit" button immediately beneath it. (You may want to select everything in the Variable Value field and paste it in an editor to work with it. ) My guess is that you will see something like "%%ICPP_COMPILER10%%\IA32\Bin" somewhere in there. Delete one of each pair of %-signs , so you don't have any doubles. This is the fix that allowed my Windows XP Tomboy install to work. I agree with Benjamin about the paths containing "Gtk#" -- it may be that the #-sign is causing issues as well -- you might want to try a test without that in your path either. BTW in your reference to "got the same error", after you make changes and close this stack of windows, you need to start a _new_ command prompt to catch the new version of PATH. It's a good idea to do an echo %PATH% before installing Tomboy, just to make sure you have the corrected version. Good luck!
Greg: Great, thanks for sharing that again. Hope that solves this issue completely. Just for reference, if you want to check that the GAC is fine, this is my system, listing all gtk references. C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322>gacutil.exe gtk-dotnet, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195da b3c99f, Custom=null gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab 3c99f, Custom=null policy.2.10.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken =35e10195dab3c99f, Custom=null policy.2.10.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken= 35e10195dab3c99f, Custom=null policy.2.4.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken= 35e10195dab3c99f, Custom=null policy.2.4.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=3 5e10195dab3c99f, Custom=null policy.2.6.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken= 35e10195dab3c99f, Custom=null policy.2.6.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=3 5e10195dab3c99f, Custom=null policy.2.8.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken= 35e10195dab3c99f, Custom=null policy.2.8.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=3 5e10195dab3c99f, Custom=null
Thanks for the explanation. I did all that, after every PATH changed, opened a new console, Checked that the PATH is Correct. In the last attempt I only left the "c:\Program Files\GtkSharp\2.12\bin\" in the path, remove every thing else. here is the result again: C:\Program Files\Tomboy>PATH PATH=c:\Program Files\GtkSharp\2.12\bin\; C:\Program Files\Tomboy>tomboy C:\Program Files\Tomboy> Unhandled Exception: System.DllNotFoundException: Unable to load DLL 'libgtk-win 32-2.0-0.dll': The specified procedure could not be found. (Exception from HRESU LT: 0x8007007F) at Gtk.Application.gtk_init(Int32& argc, IntPtr& argv) at Gtk.Application.Init() at Tomboy.WindowsApplication.Initialize(String locale_dir, String display_nam e, String process_name, String[] args) in c:\Users\sandy\Desktop\gnome-git\tombo y\Tomboy\WindowsApplication.cs:line 51 at Tomboy.Application.Initialize(String locale_dir, String display_name, Stri ng process_name, String[] args) in c:\Users\sandy\Desktop\gnome-git\tomboy\Tombo y\Utils.cs:line 922 at Tomboy.Tomboy.Main(String[] args) in c:\Users\sandy\Desktop\gnome-git\tomb oy\Tomboy\Tomboy.cs:line 50 C:\Program Files\Tomboy>
Does this file exist? C:\Program Files\GtkSharp\2.12\bin\libgtk-win32-2.0-0.dll
My GTK related entries in the GAC: gtk-dotnet, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.10.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.10.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.4.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.4.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.6.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.6.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.8.gtk-dotnet, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f policy.2.8.gtk-sharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f Yes the file does exits. Microsoft Windows XP [Version 5.1.2600] (C) Copyright 1985-2001 Microsoft Corp. C:\Program Files\GtkSharp\2.12\bin>dir Volume in drive C is WindowsXP Volume Serial Number is 78FC-E0E4 Directory of C:\Program Files\GtkSharp\2.12\bin 03/25/2009 19:30 <DIR> . 03/25/2009 19:30 <DIR> .. 10/12/2008 15:32 11,776 asprintf.dll 02/02/2009 13:23 112,966 atksharpglue-2.dll 10/12/2008 15:32 67,584 bzip2.dll 10/12/2008 15:32 5,632 charset.dll 10/12/2008 15:32 434,971 freetype6.dll 10/12/2008 15:32 15,360 gdk-pixbuf-query-loaders.exe 02/02/2009 13:23 231,312 gdksharpglue-2.dll 10/12/2008 15:32 58,880 gettextlib.dll 10/12/2008 15:32 7,168 gettextpo.dll 10/12/2008 15:32 97,792 gettextsrc.dll 02/02/2009 13:23 211,289 gladesharpglue-2.dll 02/02/2009 13:23 97,567 glibsharpglue-2.dll 10/12/2008 15:32 9,216 gspawn-win32-helper.exe 10/12/2008 15:32 15,872 gtk-query-immodules-2.0.exe 02/02/2009 13:23 709,147 gtksharpglue-2.dll 10/12/2008 15:32 892,928 iconv.dll 10/12/2008 15:32 104,861 intl.dll 10/12/2008 15:32 128,512 jpeg62.dll 10/12/2008 15:32 112,640 libatk-1.0-0.dll 10/12/2008 15:32 2,520,927 libcairo-2.dll 10/12/2008 15:32 214,528 libcroco-0.6-3.dll 10/12/2008 15:32 147,456 libexpat.dll 10/12/2008 15:32 218,443 libfontconfig-1.dll 10/12/2008 15:32 603,648 libgdk-win32-2.0-0.dll 10/12/2008 15:32 89,088 libgdk_pixbuf-2.0-0.dll 10/12/2008 15:32 271,360 libgio-2.0-0.dll 10/12/2008 14:31 87,040 libglade-2.0-0.dll 10/12/2008 15:32 838,656 libglib-2.0-0.dll 10/12/2008 15:32 14,336 libgmodule-2.0-0.dll 10/12/2008 15:32 222,720 libgobject-2.0-0.dll 10/12/2008 15:32 173,056 libgsf-1-114.dll 10/12/2008 15:32 10,752 libgsf-win32-1-114.dll 10/12/2008 15:32 18,944 libgthread-2.0-0.dll 10/12/2008 15:32 3,838,464 libgtk-win32-2.0-0.dll 10/12/2008 15:32 224,768 libpango-1.0-0.dll 10/12/2008 15:32 33,280 libpangocairo-1.0-0.dll 10/12/2008 15:32 197,120 libpangoft2-1.0-0.dll 10/12/2008 15:32 51,200 libpangowin32-1.0-0.dll 10/12/2008 15:32 210,432 libpixman-1-0.dll 10/12/2008 15:32 130,048 libpng12-0.dll 10/12/2008 15:32 145,920 libpng12.dll 10/12/2008 15:32 145,920 libpng13.dll 10/12/2008 15:32 25,088 libpopt-0.dll 10/12/2008 15:32 208,384 librsvg-2-2.dll 10/12/2008 15:32 360,448 libtiff3.dll 10/12/2008 15:32 1,354,240 libxml2-2.dll 10/12/2008 15:32 1,291,264 libxml2.dll 10/12/2008 15:32 15,872 pango-querymodules.exe 02/02/2009 13:23 95,243 pangosharpglue-2.dll 10/12/2008 15:32 59,904 zlib1.dll 50 File(s) 17,144,022 bytes 2 Dir(s) 108,957,057,024 bytes free C:\Program Files\GtkSharp\2.12\bin>
Gilad, your PATH is missing some other important things, like: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem; I think that *might* be the real problem. Try adding that to the front of your path, instead of just having the gtk# bin path.
Well, it might be the problem *now*, at least (I just noticed you did have the system paths in your previous PATH).
Fixed in git master: http://git.gnome.org/cgit/tomboy/commit/?id=9c3f56e939aeb8382ace739d2e7f57064c80d53e Tomboy now searches in the registry for the following key: "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramework\AssemblyFolders\GtkSharp" It parses the GTK# bin path out of there, and prepends that value to PATH. GTK_BASEPATH it clears out. The can be overridden by setting TOMBOY_PATH_PREFIX and TOMBOY_GTK_BASEPATH environment variables. The implementation is a little ugly...I would like to refactor our native application abstraction layer to clean it up. This fix will be in Tomboy 0.15.1.
Perhaps very out of date, but a google search brought me here as I was having the same problem even after an upgrade to the latest version. The information in this thread helped me solve this problem, but it was in a way that was not very straightforward so I figured I'd provide my method here for anyone who comes after me. The problem (for me) ended up being an issue with my PATH variable and Windows 7 64bit. GTK# installed to "C:\Program Files (x86)\..." whereas the path variable pointed to "C:\Program files\..." Changing this caused tomboy to start up with absolutely no problems. Hope this serves to help some unlucky googler. :)
I realise this is closed, however if I follow these steps I can still reproduce the problem: 1. Install GTK# 2.12.10 2. Install Tomboy 1.8.3 3. Run Tomboy --> Crash If I change the working folder for the tomboy shortcut to the GTK# folder (i.e. to "C:\Program Files (x86)\GtkSharp\2.12\bin") or if I add the GTK# bin folder to the PATH, Tomboy works. However, I believe it would be better and less confusing users to make 3 changes to the Windows install: 1. Ask if you would like to install GTK# automatically (a-la Pidgin) if not already installed 2. Modify the PATH variable immediately upon install so a restart is not required 3. Gracefully catch the error if GTK# is not found and display a dialog describing the problem
(In reply to comment #23) > I realise this is closed, however if I follow these steps I can still reproduce > the problem: > > 1. Install GTK# 2.12.10 > 2. Install Tomboy 1.8.3 > 3. Run Tomboy > --> Crash > > If I change the working folder for the tomboy shortcut to the GTK# folder (i.e. > to "C:\Program Files (x86)\GtkSharp\2.12\bin") or if I add the GTK# bin folder > to the PATH, Tomboy works. > > However, I believe it would be better and less confusing users to make 3 > changes to the Windows install: > > 1. Ask if you would like to install GTK# automatically (a-la Pidgin) if not > already installed > 2. Modify the PATH variable immediately upon install so a restart is not > required > 3. Gracefully catch the error if GTK# is not found and display a dialog > describing the problem #21 explains how to fix this difficulty. To recap: 1. Create the registry key: -> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramework\AssemblyFolders\GtkSharp 2. Set it's value to where GtkSharp is installed. [example provided] -> C:\Program Files (x86)\GtkSharp\2.12 3. Tomboy should work without any problems. Cheers!