[Gtk-sharp-list] problems running gtk# app on windows
mkestner at gmail.com
Mon Apr 20 17:26:08 EDT 2009
On Mon, 2009-04-20 at 13:56 -0700, danieru wrote:
> I've run a couple of tests to narrow this problem down. I am able to run Mono
> compiled apps on .Net when they aren't trying to load Gtk, so that answers
> my first question. Having the error mention 'Mono.Posix' threw me off from
> thinking it was Gtk at first, but the call stack says 'at
> RoleDialog.Build()', which is the first Gtk call in my app, so this seems to
> indicate that it is a problem with Gtk. For some reason it's not finding Gtk
> on my Vista system, even though I've installed Gtk! So is there something I
> should be doing with my project in MD so that when I run it on .Net it can
> correctly find the Gtk assemblies? Don't quite know how to solve this, so
> any help would be appreciated.
The problem is most likely that translation is enable in an MD Gtk#
project. This causes a reference to Mono.Posix to be added to the
project and any user visible strings will use the Catalog class to
retrieve localized strings.
The Gtk# for .net installer does not currently ship Mono.Posix, though
it has been suggested recently that we should add it.
In the meantime, you have a few options I can think of:
1) if you aren't currently translating any of those UI strings, you
could disable translation via the MD project options.
2) grab a mono combined installer and manually gac the Mono.Posix
assembly from it using gacutil.
3) we will be releasing an installer in the next couple days which
contains Mono.Posix, Mono.GetOptions, monodoc, Mono.Addins and maybe a
couple other libs from the mono stack for use on .Net. This is part of
an effort to support building MonoDevelop on .Net.
Mike Kestner <mkestner at gmail.com>
More information about the Gtk-sharp-list