Jump to content
Excelsior Forums

GTK+ in Modula 2

Recommended Posts

OK, looking over FreePascal mailing list archives, it turns out that they also had the same problem.  One of the developers inadvertently uncommented some lines, which caused the error.

The friendly people on #fpc on irc.freenode.net pointed me towards:

http://fpc64.firmos.at:8060/changelog/FPC/?cs=11627 which shows:

155	155	 	
156	156	 	// new GtkFileChooser Widget
157	157	 	{$include gtkfilechooser.inc}
158	 	-	{$include gtkfilechooserdefault.inc}
	158	+	//{$include gtkfilechooserdefault.inc} - no exports
159	159	 	{$include gtkfilechooserdialog.inc}
160	 	-	{$include gtkfilechooserembed.inc}
161	 	-	{$include gtkfilechooserentry.inc}
	160	+	//{$include gtkfilechooserembed.inc} - no exports
	161	+	//{$include gtkfilechooserentry.inc} - no exports
162	162	 	{$include gtkfilechooserprivate.inc}
163	163	 	{$include gtkfilechooserutils.inc}
164	164	 	{$include gtkfilechooserwidget.inc}

This led me to comment out the appropriate lines in gtk2.def and gtk2.mod

In gtk2.def:  basically everything from (approximately line 14051) [tt]-- from gtkfilechooserdefault.inc[/tt] through the line just before [tt]-- from gtkiconview.inc[/tt]

in gtk2.mod: basically everything from (approximately line 8681) [tt] -- from gtkfilechooserdefault.inc [/tt]  through the line just before [tt]-- from gtkiconview.inc [/tt]

After this, Hello.prj successfully built, However, running ./Hello doesn't work yet, giving this:


terry@dorsai:~/xds-gtk2$ ./Hello

#RTS: unhandled exception #3: invalid location

            Source file              LineNo  CodeOffset    Procedure name

src/pango.mod                            193    08067a7d  PANGO_CONTEXT_GET_CLASS:F

Hello.mod                                59    0804fdb8  main:F   


Which I haven't looked in to yet.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now