[Bug 1049382] New: geany does not produce consistent output
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 Bug ID: 1049382 Summary: geany does not produce consistent output Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: Other OS: openSUSE 13.2 Status: NEW Severity: Normal Priority: P5 - None Component: GNOME Assignee: bnc-team-gnome@forge.provo.novell.com Reporter: bwiedemann@suse.com QA Contact: qa-bugs@suse.de Found By: Development Blocker: --- When the glfw package is built, it calls geany -v -c geany_config -g glfw.c.tags ...c but this produces varying results probably depending on some ordering in the filesystem. Diffing the build logs gave: - In file included from /tmp/tmp_F5J72Y.cpp:2:0: - ./src/wl_platform.h:30:10: fatal error: wayland-client.h: No such file or directory - #include <wayland-client.h> - ^~~~~~~~~~~~~~~~~~ + In file included from ./src/glx_context.c:28:0, + from /tmp/tmp_PQIPOZ.cpp:1: + ./src/internal.h:175:3: error: #error "No supported window creation API selected" + #error "No supported window creation API selected" + ^~~~~ + In file included from /tmp/tmp_PQIPOZ.cpp:6:0: + ./src/egl_context.h:50:3: error: #error "No supported EGL platform selected" + #error "No supported EGL platform selected" + ^~~~~ + In file included from /tmp/tmp_PQIPOZ.cpp:9:0: + ./src/mir_platform.h:34:10: fatal error: mir_toolkit/mir_client_library.h: No such file or directory + #include <mir_toolkit/mir_client_library.h> + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ compilation terminated. so it seems, the 'compilation terminated' happens in different places. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c1 Dominique Leuenberger <dimstar@opensuse.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dimstar@opensuse.org --- Comment #1 from Dominique Leuenberger <dimstar@opensuse.org> --- from glfw.spec: %build # generate geany tags %if %{with geany} geany -c geany_config -g glfw.c.tags $(find src \( ! -name CMakeFiles \) -type f \( -iname "*.c" -o -iname "*.h" \) \( ! -iname "win32*" \) \( ! -iname "cocoa*" \) ) include/GLFW/glfw3.h %endif Maybe just sorting the file list would be the right thing then? -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c2 --- Comment #2 from Bernhard Wiedemann <bwiedemann@suse.com> --- no, I tried sorting it, so the call is the same, but still the resulting glfw.c.tags files differ. geany -v -c geany_config -g glfw.c.tags $(find src \( ! -name CMakeFiles \) -type f \( -iname "*.c" -o -iname "*.h" \) \( ! -iname "win32*" \) \( ! -iname "cocoa*" \) | LC_ALL=C sort ) include/GLFW/glfw3.h -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c3 --- Comment #3 from Bernhard Wiedemann <bwiedemann@suse.com> --- Ran it with ltrace with little extra gain + main_lib(40, 0x7ffc4d0dd4e8, 0x7ffc4d0dd630, 928 <no return ...> --- SIGCHLD (Child exited) --- - In file included from /tmp/tmp_3P7ENZ.cpp:1: - ./src/egl_context.h:50:3: error: #error "No supported EGL platform selected" - #error "No supported EGL platform selected" - ^~~~~ - In file included from ./src/egl_context.c:28, - from /tmp/tmp_3P7ENZ.cpp:3: + In file included from ./src/wgl_context.c:28, + from /tmp/tmp_OWDHNZ.cpp:1: ./src/internal.h:175:3: error: #error "No supported window creation API selected" #error "No supported window creation API selected" ^~~~~ - In file included from /tmp/tmp_3P7ENZ.cpp:7: + In file included from /tmp/tmp_OWDHNZ.cpp:10: ./src/mir_platform.h:34:10: fatal error: mir_toolkit/mir_client_library.h: No such file or directory #include <mir_toolkit/mir_client_library.h> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ but these fatal errors could play a role here. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c4 --- Comment #4 from Bernhard Wiedemann <bwiedemann@suse.com> --- using strace -f showed that geany creates a /tmp/tmp_XXXXXX.cpp in src/tagmanager/tm_workspace.c and that uses a g_hash_table in its lookup_includes function to write .h files in indeterministic order into the tmp cpp file. There is also a tm_file_inode_hash function using the st_ino field from g_stat output - and inode numbers are certainly varying across builds. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c5 --- Comment #5 from Bernhard Wiedemann <bwiedemann@suse.com> --- Created attachment 779386 --> http://bugzilla.opensuse.org/attachment.cgi?id=779386&action=edit draft patch I tested that the attached patch fixed the unreproducibility of glfw (only when using find|sort to call it the same way) Now someone needs to work with upstream to make a proper fix from it (because this one will probably make the hash table as slow as a normal list) An alternative approach could be to sort the output of the hash. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c6 --- Comment #6 from Bernhard Wiedemann <bwiedemann@suse.com> --- Proposed fix upstream: https://github.com/geany/geany/pull/1989 -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c7 Bernhard Wiedemann <bwiedemann@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |IN_PROGRESS OS|openSUSE 13.2 |openSUSE Factory --- Comment #7 from Bernhard Wiedemann <bwiedemann@suse.com> --- This patch to upstream geany was merged: https://github.com/geany/geany/pull/1991 and is already in Factory. And with https://build.opensuse.org/request/show/670533 glfw finally becomes reproducible in Factory, 18 months after this bug was filed. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1049382 http://bugzilla.opensuse.org/show_bug.cgi?id=1049382#c10 Dominique Leuenberger <dimstar@opensuse.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|IN_PROGRESS |RESOLVED Resolution|--- |FIXED OS|openSUSE Factory |All --- Comment #10 from Dominique Leuenberger <dimstar@opensuse.org> --- (In reply to Bernhard Wiedemann from comment #7)
This patch to upstream geany was merged: https://github.com/geany/geany/pull/1991 and is already in Factory.
And with https://build.opensuse.org/request/show/670533 glfw finally becomes reproducible in Factory, 18 months after this bug was filed.
And another two years later I close the bug - seems all work was done by Bernhard -- You are receiving this mail because: You are on the CC list for the bug.
participants (2)
-
bugzilla_noreply@novell.com
-
bugzilla_noreply@suse.com