GNOME Bugzilla – Bug 778507
g-ir-scanner: fix wrong order of -L options in libtool invocation
Last modified: 2017-03-26 15:08:30 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.
Created attachment 345536 [details] [review] g-ir-scanner: fix wrong order of -L options in libtool invocation
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
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.
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:這部分要麻煩你一起幫忙看了,多謝!
Local dirs should always come first IMHO, same as for includes.
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好吗? 谢谢你。
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。
Giving this a bump. Ting-Wei-Lan will you have some time in the comming week to take a look?
Just push it, it fixes something and he says it looks correct. ;)
(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.
rebased to master and committed as: d95834ca0e5ccaa00ea2d28129ca8e89d37641f7