After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 778507 - g-ir-scanner: fix wrong order of -L options in libtool invocation
g-ir-scanner: fix wrong order of -L options in libtool invocation
Status: RESOLVED FIXED
Product: gobject-introspection
Classification: Platform
Component: g-ir-scanner
unspecified
Other All
: Normal normal
: ---
Assigned To: gobject-introspection Maintainer(s)
gobject-introspection Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2017-02-11 20:51 UTC by Sebastian
Modified: 2017-03-26 15:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
g-ir-scanner: fix wrong order of -L options in libtool invocation (1.67 KB, patch)
2017-02-11 20:51 UTC, Sebastian
none Details | Review

Description Sebastian 2017-02-11 20:51:44 UTC
This patch fixes an issue in dumper.py, which causes a wrong oder of -L options to be passed to libtool. This
in turn can cause build failures if old library files are present in the linked library directories.
Comment 1 Sebastian 2017-02-11 20:51:48 UTC
Created attachment 345536 [details] [review]
g-ir-scanner: fix wrong order of -L options in libtool invocation
Comment 2 Sebastian 2017-02-11 21:01:49 UTC
P.S. The issue leading to this patch can be found in this mailing list thread:

https://mail.gnome.org/archives/desktop-devel-list/2017-February/msg00017.html

most details are in the this mail:

https://mail.gnome.org/archives/desktop-devel-list/2017-February/msg00033.html

Cheers
Comment 3 Emmanuele Bassi (:ebassi) 2017-02-14 15:48:49 UTC
Adding Fan to the Cc, as he's the person that touched this code last.

Ideally, I think this is correct, but we went through a bunch of reviews and test cycles last time this code was updated, especially when it came to portability on Windows and *BSDs, so I'd like more input.
Comment 4 Fan, Chun-wei 2017-02-14 16:32:56 UTC
Hi,

I don't think I will be able to say much about libtool-related items, since I am more into dealing with Windows/Visual Studio (which means no libtool).

Along the way that I was updating the code, I worked with Ting-wei Lan (and Colin for additional suggestions) to ensure all is well during the process, so I think it is best to add him to the CC list as well, so that he can try out the changes here.

With blessings, and cheers!
---
Ting-wei Lan:這部分要麻煩你一起幫忙看了,多謝!
Comment 5 Tim-Philipp Müller 2017-02-14 16:55:19 UTC
Local dirs should always come first IMHO, same as for includes.
Comment 6 Sebastian 2017-02-18 19:28:57 UTC
Hello Ting-wei Lan,

If you have some time in the next days, could you maybe take a look at my patch?

Thanks Sebastian

---
如果这几天你有空、麻烦你帮我看一下我写的Patch好吗? 谢谢你。
Comment 7 Ting-Wei Lan 2017-02-19 06:08:03 UTC
I remember that I did see linking failure caused by wrong -L order in projects using cmake, including WebKitGTK+ and evolution-data-server. It is the reason that both projects workaround the problem by unsetting LDFLAGS before running g-ir-scanner and moving -L options in LDFLAGS to g-ir-scanner command line.

The patch looks correct, but I have not tested it. Unfortunately, I probably won't have time to test it before 2017-03-05.

---
我正在服替代役,兩天前基礎訓練結束放假,今天晚上收假,得再回去成功嶺。我可能還是要等三月初分發以後才會比較有時間幫忙測試 patch。
Comment 8 Sebastian 2017-03-21 06:41:02 UTC
Giving this a bump. Ting-Wei-Lan will you have some time in the comming week to take a look?
Comment 9 Michael Catanzaro 2017-03-21 12:21:26 UTC
Just push it, it fixes something and he says it looks correct. ;)
Comment 10 Ting-Wei Lan 2017-03-22 15:30:28 UTC
(In reply to Michael Catanzaro from comment #9)
> Just push it, it fixes something and he says it looks correct. ;)

Yes, I think it is safe to push it. If it really causes errors, I will reopen the bug and report it here.

Since I was unable to maintain GNOME build on FreeBSD in the past 6 weeks, several new build issues caused by new commits are kept unresolved. I have to spend a few days fixing other build issues before I can check whether the g-ir-scanner patch causes any new problem.
Comment 11 Sebastian 2017-03-26 12:24:16 UTC
rebased to master and committed as: d95834ca0e5ccaa00ea2d28129ca8e89d37641f7