Build against external libgdl

Bug #792115 reported by Alex Valavanis on 2011-06-02
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Gnome Development Library
Fix Released
Medium
Inkscape
Wishlist
Alex Valavanis

Bug Description

** BLOCKED BY BUG #972797 <Port to GTK+ 3> **

There has been some discussion[1,2] about building against an external libgdl and removing
it from the Inkscape codebase. I have opened this report to track progress.

To start with, does anyone know where we stand regarding forwarding of local changes upstream? I attach a diff of the changes.

[1] http://thread.gmane.org/gmane.comp.graphics.inkscape.devel/36438
[2] http://thread.gmane.org/gmane.comp.graphics.inkscape.devel/36034/focus=36036

== Progress summary ==
All patches from Inkscape trunk have been forwarded upstream:
* Pixbuf icon patch (Accepted in GDL 3.4) https://bugzilla.gnome.org/show_bug.cgi?id=666969
* Focus grabbing/key binding patch (Accepted in GDL 3.4) https://bugzilla.gnome.org/show_bug.cgi?id=666984
* "CANT_DOCK" patch (Accepted in GDL 3.4) https://bugzilla.gnome.org/show_bug.cgi?id=666987
* Taskbar hint patch (Accepted in GDL 3.6) https://bugzilla.gnome.org/show_bug.cgi?id=666995
* GRelation replacement patch (Accepted in GDL 3.4) https://bugzilla.gnome.org/show_bug.cgi?id=670376

Once all these are accepted, we can introduce a conditional build against the appropriate external library version. Eventually, we'll be able to drop our fork entirely.

su_v (suv-lp) wrote :

Summary of the local changes by G. Broberg from 2009-02-24
<http://article.gmane.org/gmane.comp.graphics.inkscape.devel/29285>

tags: added: build
Alex Valavanis (valavanisalex) wrote :

Good find. Very useful, thanks :)

su_v (suv-lp) on 2011-06-02
Changed in inkscape:
importance: Undecided → Wishlist
milestone: none → 0.49
status: New → Confirmed
Alex Valavanis (valavanisalex) wrote :

I guess it would be nice to add an "experimental" configure flag to allow building against external gdl. This would let us test/develop a new branch.

Alex Valavanis (valavanisalex) wrote :

I did a little more digging. Unfortunately, a lot of changes were made to our copy of gdl before it was committed to inkscape trunk, so this makes the previous diff I uploaded less useful.

It seems that the common base of upstream gdl and our branch is here:

http://git.gnome.org/browse/gdl/tree/gdl?id=5c4b2533413684ab13c53b1e0cf1121b8a751fee

i.e. the commit dated 2007-06-22.

From this, we should be able to deduce exactly what changed :)

Alex Valavanis (valavanisalex) wrote :

Sorry, that date was meant to say 2007-07-19. It is the correct link, though.

Here is a diff, comparing the common base (2007-07-19) and the current version in Inkscape trunk.

Alex Valavanis (valavanisalex) wrote :

Oops! I was confused by a reversion in the upstream git repo. It turns out that we actually forked from gdl-0.7.7:

http://git.gnome.org/browse/gdl/tree/gdl?id=GDL_0_7_7

Alex Valavanis (valavanisalex) wrote :
Alex Valavanis (valavanisalex) wrote :

I have passed the diff upstream... waiting to see if the gdl developers have any suggestions!

Changed in gdl:
importance: Unknown → Medium
status: Unknown → New
Alex Valavanis (valavanisalex) wrote :

A good step for us would be to merge in a stable upstream version. This will bring our copy of the library into better compliance with GTK3, pull in all the nice bug fixes from upstream, and hopefully help us reduce the delta.

Here is a diff containing the changes between the upstream versions tagged GDL_0_7_7 and GNOME_2_30_0. I will give a merge a try.

Alex Valavanis (valavanisalex) wrote :

Note that I have only included changes to the C source files in the diff... I guess there's no point including any of the upstream packaging changes.

Changed in inkscape:
status: Confirmed → In Progress
assignee: nobody → Alex Valavanis (valavanisalex)
Changed in gdl:
status: New → Confirmed
Alex Valavanis (valavanisalex) wrote :

New branch linked, which builds against external gdl 2.30.1. Please test!

There are two regressions I have noticed:
* Docked dialogs no longer display any icon in the handle. In
principle, it should still be possible to create dialogs with an icon,
by registering the desired icon as a new stock icon. I have no
experience with doing this, however... and I don't know the best way
to tackle it in Inkscape!
* Docked dialogs no longer grab keyboard focus... this is a bit
annoying, because you cannot tab-select input fields.

Patches for both of these issues have been forwarded to upstream GDL. However, the question is... are these issues significant enough for us to continue using our fork of the library?

Alex Valavanis (valavanisalex) wrote :

Here's an updated diff from GDL 0.7.7 to the Inkscape fork. This takes into account all the recent gtk cleanup work.

Alex Valavanis (valavanisalex) wrote :

I have upgraded the gdl fork to include upstream changes in GDL_0_7_8. New delta attached. This change introduces a Glib Critical warning. However, this has been fixed upstream, and I will merge the fix into Inkscape shortly.

Alex Valavanis (valavanisalex) wrote :

Updated fork to gdl 0.7.9. Delta attached

Alex Valavanis (valavanisalex) wrote :

Updated to gdl 0.7.10. New delta attached. This fixes the Glib critical warning mentioned above

Alex Valavanis (valavanisalex) wrote :

(upgraded to gdl 2.23.90)

Alex Valavanis (valavanisalex) wrote :

(upgraded to gdl 2.24.0)

Alex Valavanis (valavanisalex) wrote :

(upgraded to gdl 2.26.0)

Alex Valavanis (valavanisalex) wrote :

Updated to GNOME_2_30_0 version of gdl. Note that the handle rendering code has changed, so I have temporarily disabled one of our incompatible patches until I figure out how to colour the handle.

Alex Valavanis (valavanisalex) wrote :

Minimal patch for GNOME_2_30_0 tagged version of gdl attached. This needs to be broken into manageable chunks, tested with gdl trunk and forwarded upstream.

Alex Valavanis (valavanisalex) wrote :
jazzynico (jazzynico) wrote :

@Alex - After you recent updates, building on Windows returns the following errors (no problem on Ubuntu):

--
Make error line 303: problem compiling: cc1.exe: warning: command line option "-Woverloaded-virtual" is valid for C++/ObjC++ but not for C
src/libgdl/test-combo-button.c:26:30: error: gdl-combo-button.h: No such file or directory
src/libgdl/test-combo-button.c:29: error: expected ')' before '*' token
src/libgdl/test-combo-button.c: In function 'main':
src/libgdl/test-combo-button.c:63: warning: implicit declaration of function 'gdl_combo_button_new'
src/libgdl/test-combo-button.c:63: warning: assignment makes pointer from integer without a cast
src/libgdl/test-combo-button.c:64: warning: implicit declaration of function 'gdl_combo_button_set_label'
src/libgdl/test-combo-button.c:64: warning: implicit declaration of function 'GDL_COMBO_BUTTON'
src/libgdl/test-combo-button.c:65: warning: implicit declaration of function 'gdl_combo_button_set_menu'
src/libgdl/test-combo-button.c:68: warning: implicit declaration of function 'gdl_combo_button_set_icon'
src/libgdl/test-combo-button.c:71: error: 'combo_button_activate_default_cb' undeclared (first use in this function)
src/libgdl/test-combo-button.c:71: error: (Each undeclared identifier is reported only once
src/libgdl/test-combo-button.c:71: error: for each function it appears in.)
src/libgdl/test-combo-button.c:85: warning: assignment makes pointer from integer without a cast
src/libgdl/test-combo-button.c:98: warning: assignment makes pointer from integer without a cast
---

Would you be willing to take a look? Thanks.

Alex Valavanis (valavanisalex) wrote :

Uh oh :S

Sorry about that. I'm afraid I don't really have easy access to Windows, so it may be easier to just revert some/all of my recent commits. Would you be willing to try building earlier revisions to figure out exactly which of my changes introduced the problem?

su_v (suv-lp) wrote :

Maybe the libgdl/test-* files can or need to be excluded in build.xml (they are not compiled on OS X - without Gnome - either)?

Alvin Penner (apenner) wrote :

on Windows XP, rev 10442, I was able to get rid of the errors that relate to test-combo-button.c by deleting this file. It is not listed in Makefile_insert, neither is the file test-dock.c. I assume this means they are not needed.

However, I still get errors from the file gdl-dock-layout.c (below). This file is also not listed in the file Makefile_insert. Is this deliberate or accidental?

Make error line 303: problem compiling: cc1.exe: warning: command line option "-
Woverloaded-virtual" is valid for C++/ObjC++ but not for C
src/libgdl/gdl-dock-layout.c: In function 'load_layout_cb':
src/libgdl/gdl-dock-layout.c:412:28: warning: unused parameter 'w'
src/libgdl/gdl-dock-layout.c: In function 'delete_layout_cb':
src/libgdl/gdl-dock-layout.c:434:30: warning: unused parameter 'w'
src/libgdl/gdl-dock-layout.c: In function 'show_toggled_cb':
src/libgdl/gdl-dock-layout.c:456:41: warning: unused parameter 'renderer'
src/libgdl/gdl-dock-layout.c: In function 'layout_ui_destroyed':
src/libgdl/gdl-dock-layout.c:505:33: warning: unused parameter 'user_data'
src/libgdl/gdl-dock-layout.c: In function 'master_locked_notify_cb':
src/libgdl/gdl-dock-layout.c:531:41: warning: unused parameter 'pspec'
src/libgdl/gdl-dock-layout.c: In function 'load_interface':
src/libgdl/gdl-dock-layout.c:558:34: error: 'GDL_UIDIR' undeclared (first use in
 this function)
src/libgdl/gdl-dock-layout.c:558:34: note: each undeclared identifier is reporte
d only once for each function it appears in
src/libgdl/gdl-dock-layout.c: In function 'cell_edited_cb':
src/libgdl/gdl-dock-layout.c:642:38: warning: unused parameter 'cell'
src/libgdl/gdl-dock-layout.c: In function 'gdl_dock_layout_setup_object':
src/libgdl/gdl-dock-layout.c:755:5: warning: missing initializer
src/libgdl/gdl-dock-layout.c:755:5: warning: (near initialization for 'serialize
d.data')
src/libgdl/gdl-dock-layout.c:839:23: warning: comparison between signed and unsi
gned integer expressions
src/libgdl/gdl-dock-layout.c:846:19: warning: comparison between signed and unsi
gned integer expressions
src/libgdl/gdl-dock-layout.c: In function 'gdl_dock_layout_foreach_object_save':

src/libgdl/gdl-dock-layout.c:960:5: warning: missing initializer
src/libgdl/gdl-dock-layout.c:960:5: warning: (near initialization for 'attr.data
')
src/libgdl/gdl-dock-layout.c:978:13: warning: missing initializer
src/libgdl/gdl-dock-layout.c:978:13: warning: (near initialization for 'v.data')

src/libgdl/gdl-dock-layout.c: In function 'gdl_dock_layout_layout_changed_cb':
src/libgdl/gdl-dock-layout.c:1112:51: warning: unused parameter 'master'
src/libgdl/gdl-dock-layout.c: In function 'gdl_dock_layout_run_manager':
src/libgdl/gdl-dock-layout.c:1287:16: warning: unused variable 'parent'

ScislaC (scislac) wrote :

Alvin: I'm looking into this and will post a comment here soon.

Alex Valavanis (valavanisalex) wrote :

test-* and gdl-dock-layout.* are not needed by Inkscape. The code compiles fine without them for me using GCC 4.6 so I have removed them from trunk. Please could someone check whether this builds OK in Windows?

Alvin Penner (apenner) wrote :

when I remove gdl-dock-layout.c, then I get the message:
- it seems that forward.h is expecting it.

##### Target : compile
##### compile the source to .o
--- compile / cc
    cc : compile of build/obj/libgdl/gdl-dock-layout.o required by included: src
/2geom/forward.h
============ cmd ============
mingw32-gcc -c -Wall -Wformat -Werror=format-security -W -Wpointer-arith -Wcast-
align -Wsign-compare -Woverloaded-virtual -Wswitch -O2 -mms-bitfields -fopenmp -
DVERSION=\"0.48+devel\" -DHAVE_CONFIG_H -D_INTL_REDIRECT_INLINE -DHAVE_SSL -DREL
AYTOOL_SSL="static const int libssl_is_present=1; static int __attribute__((unus
ed)) libssl_symbol_is_present(char *s){ return 1; }" -DPOPPLER_NEW_GFXFONT -I. -
Ic:\devlibs/include -Ic:\devlibs/include/gtkmm-2.4 -Ic:\devlibs/lib/gtkmm-2.4/in
clude -Ic:\devlibs/include/glibmm-2.4 -Ic:\devlibs/lib/glibmm-2.4/include -Ic:\
devlibs/include/glib-2.0 -Ic:\devlibs/lib/glib-2.0/include -mms-bitfields -Ic:\d
evlibs/include/sigc++-2.0 -Ic:\devlibs/lib/sigc++-2.0/include -Ic:\devlibs/inclu
de/giomm-2.4 -Ic:\devlibs/lib/giomm-2.4/include -Ic:\devlibs/include/gdkmm-2.4
-Ic:\devlibs/lib/gdkmm-2.4/include -Ic:\devlibs/include/pangomm-1.4 -Ic:\devlib
s/lib/pangomm-1.4/include -Ic:\devlibs/include/gtk-2.0 -Ic:\devlibs/lib/gtk-2.0/
include -Ic:\devlibs/include/pango-1.0 -Ic:\devlibs/include/pango-1.0 -Ic:\devli
bs/include/pango-1.0 -Ic:\devlibs/include/cairo -Ic:\devlibs/include/gdk-pixbuf-
2.0 -Ic:\devlibs/include/cairomm-1.0 -Ic:\devlibs/lib/cairomm-1.0/include -Ic:\
devlibs/include/atkmm-1.6 -Ic:\devlibs/include/atk-1.0 -Ic:\devlibs/include/gtk-
2.0 -mms-bitfields -Ic:\devlibs/include/gtk-2.0 -Ic:\devlibs/lib/gtk-2.0/include
 -Ic:\devlibs/include/ImageMagick -Ic:\devlibs/include/ImageMagick -fopenmp -D_M
AGICKDLL_ -Ic:\devlibs/include/libxml2 -Ic:\devlibs/include/freetype2 -Ic:\devli
bs/include -Ic:\devlibs/include/cairo -Ic:\devlibs/include/poppler -Ic:\devlibs/
include/gc -Ic:\devlibs/include/libwpg-0.1 -Ic:\devlibs/include/libwpd-0.8 -Ic:\
devlibs/include/libwpg-0.1 -Ic:\devlibs/include/libwpd-0.8 -Icxxtest -Ic:\devlib
s/python/include -Isrc/bind/javainc -Isrc/bind/javainc/win32 -Isrc -Isrc/2geom
 -Isrc/2geom/numeric -Isrc/bind -Isrc/debug -Isrc/dialogs -Isrc/display -Isrc/do
m -Isrc/dom/io -Isrc/dom/odf -Isrc/dom/util -Isrc/extension -Isrc/extension/impl
ementation -Isrc/extension/internal -Isrc/extension/internal/bitmap -Isrc/extens
ion/internal/filter -Isrc/extension/internal/pdfinput -Isrc/extension/script -Is
rc/filters -Isrc/helper -Isrc/io -Isrc/libavoid -Isrc/libcola -Isrc/libcroco -Is
rc/libgdl -Isrc/libnr -Isrc/libnrtype -Isrc/libvpsc -Isrc/libvpsc/pairingheap -I
src/livarot -Isrc/live_effects -Isrc/live_effects/parameter -Isrc/svg -Isrc/trac
e -Isrc/trace/potrace -Isrc/ui -Isrc/ui/cache -Isrc/ui/dialog -Isrc/ui/tool -Isr
c/ui/view -Isrc/ui/widget -Isrc/util -Isrc/widgets -Isrc/xml src/libgdl/gdl-dock
-layout.c -o build/obj/libgdl/gdl-dock-layout.o
=============================
Make error line 303: problem compiling: mingw32-gcc: src/libgdl/gdl-dock-layout.
c: No such file or directory
mingw32-gcc: no input files

ScislaC (scislac) wrote :

It's a false positive Alvin, you need to do btool clean... When we have build issues on win32, jumping to removing files is not the best course of action. It's almost always an issue with build.xml because btool is stupid (it defaults to compile everything it runs across).

Either way, this is fixed now Alex... (at least it was when I added those files as ones not to compile in build.xml)

Alvin Penner (apenner) wrote :

thanks, rev 10444 compiled perfectly on Windows XP

Alvin

Hey, I was working in gdl upstream some weeks ago, I would have no problem to review a patch against master and discuss about features needed etc

Alex Valavanis (valavanisalex) wrote :

Hi Ignacio,

Thanks for getting in touch. I have merged a lot of upstream GDL changes into Inkscape, so we are now using a version based on GDL 2.30.0. There is a minimal patch in comment #22 that ignores all the "general" fixes we made, like improving GTK+ 3 compliance. I have also prepared a patch for GDL master, that I can upload tomorrow.

There are a couple of outstanding issues that we still need to look into before we strongly promote particular patches being pushed upstream. Firstly, we need to consider using stock icons in dock items rather than pixbuf. This would let us just use the existing GdlDockItem API. Secondly, we need to be very careful with the focus grabbing, to avoid pushing any bugs upstream!

Alex Valavanis (valavanisalex) wrote :

I have merged a load of upstream changes into trunk 10789..10794. This has rebased our fork on upstream revision 871CA (2010-06-6), which fixes a lot of gtk+2.0 deprecated symbols, and reduces the size of our diff further.

Alex Valavanis (valavanisalex) wrote :

...and here's the updated minimal patch that needs forwarding upstream

Alex Valavanis (valavanisalex) wrote :

(Minimal patch forwarded upstream)

Alex Valavanis (valavanisalex) wrote :

@gustav - I subscribed you to this report... would you be able to split the patch into smaller chunks? The upstream developers would find it easier to deal with this if we can divide it into smaller patches that address the separate issues (pixbuf, focus handling, positioning etc). If you're too busy, I can have a go, but I imagine that you'd do a better job!

su_v (suv-lp) wrote :

With r10794 I get erratic, partially broken behavior on darwin with Inkscape's dockable dialogs:

A - Old (stable) 32bit build env (Mac OS X 10.5.8 (i386), Xcode 3.1.4):
glib2 2.28.8, gtk+/x11 2.24.4 and gtk+/quartz 2.24.8, gtkmm 2.24.0 gcc 4.2.1

1) optimized builds (-O3) seem to be ok
(both backends of gtk tested: x11 and quartz)

2) debug build (-g -O0) broken:
none of the dockable dialogs opens at all (not when clicking on a button, nor when using the menu command nor with keyboard shortcuts)

B - New (work-in-progress) 64bit build env (OS X 10.7.2 (x86_64), Xcode 4.2.1):
glib2 2.30.2, gtk+/x11 2.24.8, gtkmm 2.24.2, llvm-gcc-4.2

1) optimized builds ('-03', '-O2') show erratic behavior:
A random test string (apparently from the translatable messages) is output to the console when launching inkscape, and each time a docked or detached dockable dialog is closed, these kind of warnings from GDL are generated:
** (inkscape:12782): WARNING **: Something weird happened while getting the child placement for 0x7f8756408350 from parent 0x7f87554ffb20

2) debug build: works seemingly fine (but slow).
no random text output nor warnings when closing dockable dialogs.

(tested with default gtk theme (Raleigh), and default inkscape prefs,
 last tested prior revision: 10785 on 10.5.8, 10788 on 10.7.2)

su_v (suv-lp) wrote :

Attaching compiler warnings related to src/gdl (none fatal).

Alex Valavanis (valavanisalex) wrote :

Strange... I don't see this issue on Ubuntu 11.10 (Gtk+ 2.24.6) using standard (optimised) compilation. Also, the warnings look pretty much identical to those in r10762 (oldest version that works for me). I'll try a rebuild with debug flags, and see what happens.

I'm guessing everything was OK with r10788 then?.. any chance you could test a couple of my recent commits, to see if we can track the problem down to a specific patch?

su_v (suv-lp) wrote :

> I'm guessing everything was OK with r10788 then?

AFAICT yes - no issues with docked dialogs in either of the mentioned builds (revisions of latest archived builds varies depending on arch and build settings: 10783, 10785, 10788).

Possibly related: bug #907157 (similar opposite occurrence of an issue (Ubuntu vs OS X))
Maybe related: bug #885224 (the described problem there is how my latest 32bit debug build (r10794) behaves (but not the older ones - last tested was r10783), although there is not HD activity but a spike in CPU usage when trying to open a dockable dialog, and using different gtk themes (set in ~/.gtkrc-2.0) has no effect (no KDE/Qt desktop here, nor Gnome or Unity)).

> any chance you could test a couple of my recent commits

I'll to revert and test each commit (10789-10794) separately (with 32bit debug and 64bit optimized build).
(btw & off-topic: 'make clean' works for me without deleting 'po/inkscape.pot' if building outside the source tree, as described e.g. in <http://article.gmane.org/gmane.comp.graphics.inkscape.devel/37448>)

Alex Valavanis (valavanisalex) wrote :

Well, bug #907157 started happening before my recent gdl commits... I'm at a bit of a loss with that one!

Thanks also for the note about make clean... should be useful :)

Alex Valavanis (valavanisalex) wrote :

Rebased again on upstream commit 2648F. This should fix all remaining GTK deprecation issues.

su_v (suv-lp) wrote :

tests with r10788-10795 on OS X Lion (64bit, optimized build, llvm-gcc-4.2):

steps done for quick test:
  1 launch Inkscape (default prefs, default template, no gtkrc file)
  2 open fill&stroke (Shift+Ctrl+F)
  3 close fill&stroke
  4 open layers dialog (click on toolbar icon)
  5 detach layers dialog
  6 open fill&stroke dialog (click on toolbar icon)
  7 close fill&stroke dialog
  8 dock detached layers dialog
  9 close docked layers dialog
 10 quit inkscape

Chillida:bin su_v$ ll
-rwxr-xr-x 1 su_v staff 17073992 Dec 23 15:53 inkscape-rev-10788-O3-Wall*
-rwxr-xr-x 1 su_v staff 17073992 Dec 23 15:55 inkscape-rev-10789-O3-Wall*
-rwxr-xr-x 1 su_v staff 17073992 Dec 23 15:57 inkscape-rev-10790-O3-Wall*
-rwxr-xr-x 1 su_v staff 17074152 Dec 23 15:59 inkscape-rev-10791-O3-Wall*
-rwxr-xr-x 1 su_v staff 17074352 Dec 23 16:01 inkscape-rev-10792-O3-Wall*
-rwxr-xr-x 1 su_v staff 17074352 Dec 23 16:03 inkscape-rev-10793-O3-Wall*
-rwxr-xr-x 1 su_v staff 17091808 Dec 23 16:06 inkscape-rev-10794-O3-Wall*
-rwxr-xr-x 1 su_v staff 17091752 Dec 23 16:08 inkscape-rev-10795-O3-Wall*
Chillida:bin su_v$ ./inkscape-rev-10788-O3-Wall
Chillida:bin su_v$ ./inkscape-rev-10789-O3-Wall
Chillida:bin su_v$ ./inkscape-rev-10790-O3-Wall
Chillida:bin su_v$ ./inkscape-rev-10791-O3-Wall
Chillida:bin su_v$ ./inkscape-rev-10792-O3-Wall
Chillida:bin su_v$ ./inkscape-rev-10793-O3-Wall
** Message: Notify long_name: (null)
Chillida:bin su_v$ # message when detaching a docked dialog
Chillida:bin su_v$ ./inkscape-rev-10794-O3-Wall

** (inkscape-rev-10794-O3-Wall:7834): WARNING **: Something weird happened while getting the child placement for 0x7ff1097aa350 from parent 0x7ff109678540

** (inkscape-rev-10794-O3-Wall:7834): WARNING **: Something weird happened while getting the child placement for 0x7ff1097aa350 from parent 0x7ff109678540

** (inkscape-rev-10794-O3-Wall:7834): WARNING **: Something weird happened while getting the child placement for 0x7ff10b1fa5f0 from parent 0x7ff109678540
Chillida:bin su_v$ # warning when closing a docked or floating dialog
Chillida:bin su_v$ ./inkscape-rev-10795-O3-Wall

** (inkscape-rev-10795-O3-Wall:7835): WARNING **: Something weird happened while getting the child placement for 0x7faf4491c350 from parent 0x7faf41e78540

** (inkscape-rev-10795-O3-Wall:7835): WARNING **: Something weird happened while getting the child placement for 0x7faf4491c350 from parent 0x7faf41e78540

** (inkscape-rev-10795-O3-Wall:7835): WARNING **: Something weird happened while getting the child placement for 0x7faf449765e0 from parent 0x7faf41e78540
Chillida:bin su_v$ # warning when closing a docked or floating dialog
Chillida:bin su_v$

su_v (suv-lp) wrote :

The same warnings ("Something weird happened while getting the child placement…") also occur when minimizing a dialog in the dock, or when hiding the dock (F12).

su_v (suv-lp) wrote :

tests with r10788-10795 on Mac OS X Leopard (32bit, debug build, gcc-4.2):

steps for quick tests: see comment #45

LeWitt:bin suv$ ll ./inkscape-rev-*
-rwxr-xr-x 1 suv staff 32197428 Dec 24 15:50 ./inkscape-rev-10788-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32197428 Dec 24 15:52 ./inkscape-rev-10789-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32197428 Dec 24 15:57 ./inkscape-rev-10790-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32201812 Dec 24 15:59 ./inkscape-rev-10791-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32202088 Dec 24 16:00 ./inkscape-rev-10792-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32202088 Dec 24 16:02 ./inkscape-rev-10793-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32203988 Dec 24 16:06 ./inkscape-rev-10794-g-O0-32bit*
-rwxr-xr-x 1 suv staff 32203948 Dec 24 16:12 ./inkscape-rev-10795-g-O0-32bit*
LeWitt:bin suv$ ./inkscape-rev-10788-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ ./inkscape-rev-10789-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ ./inkscape-rev-10790-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ ./inkscape-rev-10791-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ ./inkscape-rev-10792-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ ./inkscape-rev-10793-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
** Message: Notify long_name: (null)
LeWitt:bin suv$ # message when detaching a docked dialog
LeWitt:bin suv$ ./inkscape-rev-10794-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ # none of the dockable dialogs opens at all
LeWitt:bin suv$ ./inkscape-rev-10795-g-O0-32bit
Xlib: extension "RANDR" missing on display "/tmp/launch-xEW8l4/org.x:0".
LeWitt:bin suv$ # none of the dockable dialogs opens at all
LeWitt:bin suv$

-> on both platforms, the issues started with r10793 (same message when detaching a docked dialog), and either fail (32bit debug) or produce warnings (64bit optimized) with r10794.

Other differences between my 32bit & 64bit builds:
32bit: glib2 2.28.8, gtk2 2.24.4, gtkmm 2.24.0, Apple's gcc 4.2.1
64bit: glib2 2.30.2, gtk2 2.24.8, gtkmm 2.24.2, Apple's llvm-gcc 4.2.1

Alex Valavanis (valavanisalex) wrote :

OK, I *think* I might have a clue about the issues reported above...

* Upstream commit 94FD2 (2010-04-24) [1] added a debug message "Notify long_name: ...". This was merged into Inkscape trunk with r10794. The message was removed in upstream E81A1 (2010-06-22) [2] and merged into Inkscape trunk with r10794.

* Upstream commit 7399A (2010-06-26) [3] introduced a bug,[4] in which the return value of the gdl_dock_object_child_placement function was potentially lost. This was merged into Inkscape trunk with r10794. The bug was fixed upstream in commit 73852 (2011-03-23)[5]. I have committed the fix in r10796, but I'm on a really crappy machine at the minute so I can't do any rigorous testing for a few days. Please let me know if the issue is fixed in trunk.

[1] http://git.gnome.org/browse/gdl/commit/?id=94fd2956f6a9bfb69f580b29354e29c7f8814ec2
[2] http://git.gnome.org/browse/gdl/commit/?id=e81a10983fbd58cf71b9a0265d5e6c63c0fe2a23
[3] http://git.gnome.org/browse/gdl/commit/gdl/gdl-dock-object.c?id=7399ad1ae0e48f6118559a99e77eff4b276d610f
[4] https://bugzilla.gnome.org/show_bug.cgi?id=645559
[5] http://git.gnome.org/browse/gdl/commit/gdl/gdl-dock-object.c?id=738525e88213c8f43c3e01a1076006d6b642936c

su_v (suv-lp) wrote :

r10796 seems to have fixed it: quick test (see comment #45) on Mac OS X Leopard and OS X Lion with
- 32bit optimized (gtk+/x11, gtk+/quartz)
- 32bit debug (gtk+/x11)
- 64bit optimized (gtk+/x11)
- 64bit debug (gtk+/x11)
no longer shows any notification or warning messages on the console and the docked dialogs are working as expected. Thx :)

Alex Valavanis (valavanisalex) wrote :

I have forwarded the pixbuf icon patch upstream.[1] This should be the only API change needed for us to eventually build against external GDL. I'll sort out the other patches (focus handling, key bindings etc) tomorrow, I hope.

[1] https://bugzilla.gnome.org/show_bug.cgi?id=666969

Alex Valavanis (valavanisalex) wrote :

Focus handling patch forwarded upstream:

https://bugzilla.gnome.org/show_bug.cgi?id=666984

Alex Valavanis (valavanisalex) wrote :

CANT_DOCK behaviour patch forwarded upstream:

https://bugzilla.gnome.org/show_bug.cgi?id=666987

Alex Valavanis (valavanisalex) wrote :

In r10801, I have dropped our placement-related patches, and fixes for minor gcc warnings. My reasoning is as follows:

* This reduces the delta against upstream considerably
* I don't think the UI changes are important enough to warrant us maintaining such a large diff
* There are probably better ways to fix the docked dialog placement in our own code rather than hacking upstream[1,2]
* We can push changes upstream later if we need to
* We can always revert if we find any horrible UI regressions

[1] http://article.gmane.org/gmane.comp.graphics.inkscape.devel/29285
[2] https://bugzilla.gnome.org/show_bug.cgi?id=652248

Alex Valavanis (valavanisalex) wrote :

"Skip taskbar hint" patch forwarded upstream:

https://bugzilla.gnome.org/show_bug.cgi?id=666995

This is the final patch. I guess our work in the Inkscape fork is now pretty much finished. Our job is now to liaise with upstream to help push changes. After that, we can finally kill our fork.

su_v (suv-lp) wrote :

@Alex - as was reported by cafuego on irc (he provides trunk PPAs for 10.04), some of the latest changes in 'src/libgdl' (r10799, maybe others) break building with GTK+ 2.20. The wiki page <http://wiki.inkscape.org/wiki/index.php/Tracking_Dependencies> still lists GTK+ 2.20 as requirement for trunk. Any chance we could keep trunk buildable on Lucid for now (the PPAs by cafuego include a newer version of cairo), similar to bug #800565?

Alex Valavanis (valavanisalex) wrote :

Oops... yes, this should be an easy fix. It's simply a case of the GDK key symbols changing their names from GTK+ 2.20 to 2.22. We just need to add a definition for the missing symbols for GDK+ <= 2.22. I'll take care of it tomorrow hopefully. Here is the buildlog from cafuego's PPA:

https://launchpadlibrarian.net/88734519/buildlog_ubuntu-lucid-amd64.inkscape_0.49~devel%2B10802%2B6~lucid1_FAILEDTOBUILD.txt.gz

Cafuego (cafuego) wrote :

I have a new Lucid r10809. Thanks, Alex! 8-)

Changed in inkscape:
status: In Progress → Fix Committed
status: Fix Committed → In Progress
Alex Valavanis (valavanisalex) wrote :

No worries... glad it's working again! I guess the bigger concern will be about what happens when the upstream GDL developers accept our changes. I suppose the "nicest" thing we could do for users would be to keep our fork, and check for availability of external GDL. If a suitable version is available, build against it. If not, use our fork. Eventually, when all recent distros support a suitable version (>1 year later), kill our fork.

The other, "cleaner" option would be to kill our fork immediately, and use whichever upstream GDL version is available. There has only been one real incompatible API change in our fork (pixbuf icons), and we can easily do a conditional build. However, distros with old GDL versions will have to put up with a few annoying UI issues (no focus in docked dialogs etc).

Alex Valavanis (valavanisalex) wrote :

"Can't dock" and "pixbuf" patches accepted upstream. "taskbar hint" and "focus grabbing" patches in progress.

ScislaC (scislac) wrote :

Awesome news Alex! Thank you so much for all of your time and work on this project!

Xortex (xortex) wrote :

Hey I don't know if this helps but when I tried to build from scratch i got the error message
"Could not find gdl-tools.h"

I took out the reference to gdl-tools.h and gdl-stock-icons.h in src/libgdl/CMakeLists.txt and everything went smoothly

Pls Find the diff attached if you need it

Alex Valavanis (valavanisalex) wrote :

Oops! I don't use cmake, so I didn't notice that problem... sorry about that! Yes, those files have been removed in recent versions of GDL. I'll fix the make list tonight, hopefully (assuming no one beats me to it!) Thanks for the patch :)

Alex Valavanis (valavanisalex) wrote :

Fixed CMake issue in r10833. Thanks for the patch!

Alex Valavanis (valavanisalex) wrote :

I've introduced a new patch in our fork to fix bug #933058 (attached). This has been forwarded upstream to https://bugzilla.gnome.org/show_bug.cgi?id=670376

description: updated
Alex Valavanis (valavanisalex) wrote :

Focus grabbing/key bindings patch & the GRelation patch have both been accepted in GDL 3.4

description: updated
description: updated
Alex Valavanis (valavanisalex) wrote :

In r11244, Inkscape attempts to build against external gdl (>=3.3.4), if the "--enable-gtk3-experimental" configuration option is used.

However, the GTK+3 build is still seriously broken! I won't mark this as "Fix Committed" until bug #972797 <Port to GTK+ 3> is fixed.

description: updated
Alex Valavanis (valavanisalex) wrote :

All of our patches are now accepted in upstream GDL 3.6. Now we just need to fix the GTK+ 3 build!

description: updated
Changed in gdl:
status: Confirmed → Fix Released
Alex Valavanis (valavanisalex) wrote :

GTK+ 3 build with external GDL works with lp:inkscape r11483

Changed in inkscape:
status: In Progress → Fix Committed
su_v (suv-lp) on 2012-10-23
description: updated
Bryce Harrington (bryce) on 2015-02-23
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.