Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2009-01

Workaround for #0011837 (FPC <= 2.2.2 with GTK >= 2.13)

8 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Michalis Kamburelis

In case someone wonders how to workaround this bug http://mantis.freepascal.org/view.php?id=11837
(occurs with GTK >= 2.13.4, e.g. on Ubuntu 8.10 we have GTK 2.14):

I found that the quick workaround that works is to pass --noinhibit-exec to ld, that is "-k--noinhibit-exec" to FPC command-line. The ld will then treat unresolved references as mere warnings, and will produce working executable (assuming your program doesn't actually call obsoleted GTK2 functions).

Of course, you can also upgrade to FPC from SVN. Above workaround is useful only if you have to stick to released FPC 2.2.2.

(I know, this is hardly a rocket science discovery :) Just sharing in case anyone else struggles with this, seeing as this is very common problem.)

Michalis

Vincent Snijders
to Michalis Kamburelis
Michalis Kamburelis wrote 16 lines
In case someone wonders how to workaround this bug http://mantis.freepascal.org/view.php?id=11837 (occurs with GTK >= 2.13.4, e.g. on Ubuntu 8.10 we have GTK 2.14): I found that the quick workaround that works is to pass --noinhibit-exec to ld, that is "-k--noinhibit-exec" to FPC command-line. The ld will then treat unresolved references as mere warnings, and will produce working executable (assuming your program doesn't actually call obsoleted GTK2 functions). Of course, you can also upgrade to FPC from SVN. Above workaround is useful only if you have to stick to released FPC 2.2.2. (I know, this is hardly a rocket science discovery :) Just sharing in case anyone else struggles with this, seeing as this is very common problem.)

Thanks, I will try to remember this.

Vincent

Giovanni Premuda
to Michalis Kamburelis: In case someone wonders how to workaround this bug…
Michalis Kamburelis wrote 13 lines
In case someone wonders how to workaround this bug http://mantis.freepascal.org/view.php?id=11837 (occurs with GTK >= 2.13.4, e.g. on Ubuntu 8.10 we have GTK 2.14): I found that the quick workaround that works is to pass --noinhibit-exec to ld, that is "-k--noinhibit-exec" to FPC command-line. The ld will then treat unresolved references as mere warnings, and will produce working executable (assuming your program doesn't actually call obsoleted GTK2 functions). Of course, you can also upgrade to FPC from SVN. Above workaround is useful only if you have to stick to released FPC 2.2.2.

Can anyone spread this all over the Lazarus site, the Lazarus readmes and release notes, the lazarus debs, sorceforge and everywhere else???

This has been a major block for anyone trying to use Lazarus under Intrepid. Patching fpc is not really the best way to start... :)

Giovanni

Vincent Snijders
to Giovanni Premuda
Giovanni Premuda wrote 17 lines
Michalis Kamburelis wrote: > In case someone wonders how to workaround this bug > http://mantis.freepascal.org/view.php?id=11837 > (occurs with GTK >= 2.13.4, e.g. on Ubuntu 8.10 we have GTK 2.14): > > I found that the quick workaround that works is to pass --noinhibit-exec > to ld, that is "-k--noinhibit-exec" to FPC command-line. The ld will > then treat unresolved references as mere warnings, and will produce > working executable (assuming your program doesn't actually call > obsoleted GTK2 functions). > > Of course, you can also upgrade to FPC from SVN. Above workaround is > useful only if you have to stick to released FPC 2.2.2. > Can anyone spread this all over the Lazarus site, the Lazarus readmes and release notes, the lazarus debs, sorceforge and everywhere else???

Yes, anybody can do that.

Vincent

Vincent Snijders
to Giovanni Premuda
Giovanni Premuda wrote 5 lines
Vincent Snijders wrote: > > Yes, anybody can do that. Sorry? I don't get it.

Anybody (also Giovanni Premuda) anyone spread this all over the Lazarus site by posting forum messages and submitting news items, anybody (also Giovanni Premuda) can edit the Lazarus readmes and release notes on the wiki, anybody (also Giovanni Premuda) can request updates of the debian debs in the debian bug tracker.

There are no notes on sourceforge to be edited or updated, so nobody can do that.

Anybody (also Giovanni Premuda) can spread this everywhere else.

Do you get it?

With kind regards,
Vincent

Giovanni Premuda
to Vincent Snijders
Vincent Snijders wrote
Anybody (also Giovanni Premuda) anyone spread this all over the Lazarus site

OK, I had the wrong impression that the lazarus docs where editable only by insiders, as the main site seems to be.

So:

by posting forum messages

Done

and submitting news items

How?

, anybody (also Giovanni Premuda) can edit the Lazarus readmes and release notes on the wiki

Done,
http://wiki.lazarus.freepascal.org/Installing_Lazarus#Ubuntu_.2F_Debian

anybody (also Giovanni Premuda) can request updates of the debian debs in the debian bug tracker.

I don't think this is necessary

There are no notes on sourceforge to be edited or updated, so nobody can do that.

Could be useful

Anybody (also Giovanni Premuda) can spread this everywhere else.

Done. (Ubuntu Forums)

Do you get it?

No, I would like to see this as a news item and on the FAQs on the main site.

But it looks like you are understimating the importance of this bug:

1. Potential user (i.e. potential contributor) install lazarus.
2. Potential user launches lazarus and sees an ugly interface
3. Potential user searches around and finds out that he can rebuild lazarus with GTK2 interface
4. Potential user rebuilds lazarus and... the rebuild doesn't work
5. Potential user thinks: I knew it was to good to be true
6. Potential user is neither user nor potential anymore

Servus,
Giovanni

Vincent Snijders
to Giovanni Premuda
Giovanni Premuda wrote 7 lines
Vincent Snijders wrote: > > Anybody (also Giovanni Premuda) anyone spread this all over the > Lazarus site OK, I had the wrong impression that the lazarus docs where editable only by insiders, as the main site seems to be.

Good, Lazarus is essentially a community project.

So: > by posting forum messages Done

Thanks.

> and submitting news items How?

I was about to point you to www.lazarus.freepascal.org, we are in a process to move that to another server. Creating news items is yet supported in that server, you can post a message in the announcement forum. That will show up on the future home page.

Show quoted text 7 lines
> , anybody (also Giovanni Premuda) can edit the Lazarus readmes and > release notes on the wiki Done, http://wiki.lazarus.freepascal.org/Installing_Lazarus#Ubuntu_.2F_Debian > anybody (also Giovanni Premuda) can request updates of the debian debs > in the debian bug tracker. I don't think this is necessary

No problem.

Show quoted text 7 lines
> > There are no notes on sourceforge to be edited or updated, so nobody > can do that. Could be useful > > Anybody (also Giovanni Premuda) can spread this everywhere else. Done. (Ubuntu Forums)

Thanks.

> > Do you get it? No, I would like to see this as a news item and on the FAQs on the main site.

You can edit the FAQ here: http://wiki.lazarus.freepascal.org/Lazarus_Faq

I will ask to update the link on www.lazarus.freepascal.org to this page. The other page has not been updated in a long time. It causes confusion that there are two Lazarus FAQ pages.

For the news items see above. We are working on it.

But it looks like you are understimating the importance of this bug:

I don't think I underestimate the importance of this bug, maybe I underestimate the influence of spreading such a note.

Show quoted text 5 lines
1. Potential user (i.e. potential contributor) install lazarus. 2. Potential user launches lazarus and sees an ugly interface 3. Potential user searches around and finds out that he can rebuild lazarus with GTK2 interface 4. Potential user rebuilds lazarus and... the rebuild doesn't work

With the note known to everybody all stays the same, until here.

5. Potential user thinks: I knew it was to good to be true

And is surprised by the rapid progress of Lazarus in 2009 when he tries it next year.

6. Potential user is neither user nor potential anymore

Let's just acknowledge the fact that Lazarus is not yet ready for him.

I propose a 5A and 6A.
5A. Potential user searches around and finds the note about ignoring linker errors and gets a gtk2 based Lazarus and creates gtk2 apps.

6A. He hits an annoying bug in the gtk2 based Lazarus, which is not present when using gtk1. He says, I knew it was too good to be true and potential user is no user anymore.

I rather prefer to spend my time on finding solutions.

1. Potential user (i.e. potential contributor) install lazarus. 2. Potential user launches lazarus and sees an ugly interface

That is why I am trying to help with the fpc 2.2.4 release, so that we can release Lazarus 0.9.28 with gtk2. Others have to improve the gtk2 support in Lazarus, I cannot do that.

3. Potential user searches around and finds out that he can rebuild lazarus with GTK2 interface

That is why I am preparing a 0.9.26.2 release (based on gtk1, because of stability reasons). If somebody prefers beauty over stability, then they can rebuild Lazarus with the gtk2 widget set, because the Makefiles and the IDE know how to add the linker flag for fpc 2.2.2.

4. Potential user rebuilds lazarus and ...

It remains to be seen how many will become Lazarus contributors. It is true that gtk(2) has no special maintainer, much unlike the other major widget sets (carbon, qt, win32 and wince).

Vincent