Inkscape build problem on Fedora rawhide(f25)

Bug #1567485 reported by Gwyn Ciesla
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
High
Mc

Bug Description

The following affects both 0.91 and trunk. . .

g++ -DHAVE_CONFIG_H -I. -I.. -I../cxxtest -I./extension/dbus -I/usr/include/freetype2 -pthread -I/usr/include/gnome-vfs-2.0 -I/usr/lib64/gnome-vfs-2.0/include -I/usr/include/gconf/2 -I.................c -o ui/clipboard.o ui/clipboard.cpp
In file included from ./2geom/geom.h:43:0,
                 from ./snapped-point.h:17,
                 from ./snapper.h:20,
                 from ./line-snapper.h:13,
                 from ./guide-snapper.h:14,
                 from ./snap.h:21,
                 from ./sp-namedview.h:21,
                 from ui/clipboard.cpp:84:
./2geom/line.h: In member function 'void Geom::Line::setPoints(const Geom::Point&, const Geom::Point&)':
./2geom/line.h:148:13: warning: statement is indented as if it were guarded by... [-Wmisleading-indentation]
             m_versor.normalize();
             ^~~~~~~~
./2geom/line.h:146:9: note: ...this 'else' clause, but it is not
         else
         ^~~~
ui/clipboard.cpp: In member function 'void Inkscape::UI::ClipboardManagerImpl::_inkscape_wait_for_targets(std::__cxx11::list<Glib::ustring>&)':
ui/clipboard.cpp:1405:22: error: 'ScopedPtr' is not a member of 'Glib'
             target = Glib::ScopedPtr<char>(atom_name).get(); //This frees the gchar*.
                      ^~~~
ui/clipboard.cpp:1405:38: error: expected primary-expression before 'char'
             target = Glib::ScopedPtr<char>(atom_name).get(); //This frees the gchar*.
                                      ^~~~
Makefile:8045: recipe for target 'ui/clipboard.o' failed

Tags: build
Revision history for this message
Mc (mc...) wrote :

hi,

Which version of libglibmm do you have ?

su_v (suv-lp)
tags: added: build
Revision history for this message
Gwyn Ciesla (limburgher) wrote :

2.48.0

Revision history for this message
Mc (mc...) wrote :

I just saw that ScopedPtr was deprecated (an unavailable with GLIBMM_DISABLE_DEPRECATED)...
http://fossies.org/dox/glibmm-2.48.1/classGlib_1_1ScopedPtr.html recommends replacing with make_unique_ptr_gfree , but that probably require c++11.

so replacing

target = Glib::ScopedPtr<char>(atom_name).get();

with

target = Glib::make_unique_ptr_gfree(atom_name).get();

might be enough to compile.

Also, the whole_inkscape_wait_for_targets function was a workaround to a bug in gtkmm :

// GTKMM's clipboard::wait_for_targets is buggy and might return bogus, see
//
// https://bugs.launchpad.net/inkscape/+bug/296778
// http://mail.gnome.org/archives/gtk-devel-list/2009-June/msg00062.html
//
// for details. Until this has been fixed upstream we will use our own implementation

does anyone know if the underlying function was fixed ? This way we can just throw away the whole function and use Glib::wait_for_targets instead

Revision history for this message
Mc (mc...) wrote :

Update : since it seems fixed since glibmm2.16 (2009) we could just remove that part

( https://bugzilla.gnome.org/show_bug.cgi?id=586626 )

Revision history for this message
Gwyn Ciesla (limburgher) wrote :

Yes, that path applies cleany and fixes the build. Thanks!

Revision history for this message
Gwyn Ciesla (limburgher) wrote :

Cleanly. Oy. :)

Revision history for this message
Mc (mc...) wrote :

Pushed to rev 14766.

Changed in inkscape:
status: New → Fix Committed
assignee: nobody → Mc (mc...)
milestone: none → 0.92
Revision history for this message
su_v (suv-lp) wrote :

AFAICT rev 14766 may break experimental GTK3 build - it did succeed with attached diff; no runtime tests have been done though. Please review.

Revision history for this message
Mc (mc...) wrote :

Problem confirmed, patch compiled, tested, and committed (14768). Thanks su_v !

su_v (suv-lp)
tags: added: backport-proposed
Revision history for this message
Alex Valavanis (valavanisalex) wrote :

This has now hit the stable PPA for Ubuntu Yakkety, so bumping to high priority for backport

Changed in inkscape:
importance: Undecided → High
Revision history for this message
DHermit (dhermit) wrote :

I accidentially clicked on the status, but now have no rights to reverse it ... could anyone with more rights fix this?

Changed in inkscape:
status: Fix Committed → Fix Released
jazzynico (jazzynico)
Changed in inkscape:
status: Fix Released → Fix Committed
Revision history for this message
Martin Owens (doctormo) wrote :

Gtk3 fixes are not being backported, 0.92 is a Gtk2 release.

tags: removed: backport-proposed
Bryce Harrington (bryce)
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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