Inkscape aqua does not compile without X11

Bug #721424 reported by Gellule
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
High
Gellule

Bug Description

Inkscape 0.48.1 on OS X.
Trying to compile inkscape with the aqua version of GTK, and without any reference to X11. This fails because of -lX11 added to INKSCAPE_LIBS in configure.ac:

INKSCAPE_LIBS="$INKSCAPE_LIBS -lpng -lz -lX11 -lxml2 -ldl"

Could either the availability of X11 be checked before adding -lX11, or a --without-x11 option be added?

Compiling inkscape +aqua +no_x11 with macports, and adding a patch that removes the offending -lX11 makes inkscape compile.

su_v (suv-lp)
tags: added: build gtk-osx
Changed in inkscape:
importance: Undecided → High
Revision history for this message
su_v (suv-lp) wrote :

JFTR: In revision 9617 (lp:inkscape) '-lX11' had been added to allow building/linking on Fedora 13 (see bug #595872).

Changed in inkscape:
status: New → Triaged
Revision history for this message
su_v (suv-lp) wrote :

Related downstream ticket for MacPorts:
Ticket 28458 "inkscape +aqua +no_x11 does not compile"
<https://trac.macports.org/ticket/28458>

Revision history for this message
Gellule (gellule-xg) wrote :

Not a patch, just a workaround for removing X11 library.

Revision history for this message
Gellule (gellule-xg) wrote :

This patch add -lX11 to INKSCAPE_LDFLAGS based on the backend target used by gtk+. Only when gtk+ is built for the x11 backend, will X11 be added.

Rationale:
The only section of code in inkscape that requires X11 is in ege-color-prof-tracker.cpp, and is guarded by an "#ifdef GDK_WINDOWING_X11", only set when gtk+ uses the X11 backend target.

Gellule (gellule-xg)
Changed in inkscape:
assignee: nobody → Gellule (gellule-xg)
Revision history for this message
Gellule (gellule-xg) wrote :
Changed in inkscape:
status: Triaged → Fix Committed
Revision history for this message
su_v (suv-lp) wrote :

With regard to r10382 - there has been a report of link failure (on irc) due to lowercase 'x11' added in the modified configure.ac:

> |12:48| < houz> hi, i have trouble compiling inkscape, one of the
> last commits seemed to introduce linking against x11, which of
> course should be X11 (-lx11 vs. -lX11)

The commit log says:
Add -lX11 to INKSCAPE_LIBS only when gtk is compiled for X11 backend target.

The actual change for r10382 however is
  INKSCAPE_LIBS="$INKSCAPE_LIBS -lx11"

Could you verify the commit and update accordingly?

Revision history for this message
Gellule (gellule-xg) wrote : Re: [Bug 721424] Re: Inkscape aqua does not compile without X11

Should be able to get to it in 10 minutes. Thanks for letting me know.

-Julien

On Jun 29, 2011, at 3:27, ~suv <email address hidden> wrote:

> With regard to r10382 - there has been a report of link failure (on irc)
> due to lowercase 'x11' added in the modified configure.ac:
>
>> |12:48| < houz> hi, i have trouble compiling inkscape, one of the
>> last commits seemed to introduce linking against x11, which of
>> course should be X11 (-lx11 vs. -lX11)
>
>
> The commit log says:
> Add -lX11 to INKSCAPE_LIBS only when gtk is compiled for X11 backend target.
>
> The actual change for r10382 however is
> INKSCAPE_LIBS="$INKSCAPE_LIBS -lx11"
>
>
> Could you verify the commit and update accordingly?
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/721424
>
> Title:
> Inkscape aqua does not compile without X11
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/inkscape/+bug/721424/+subscriptions

Revision history for this message
Gellule (gellule-xg) wrote :
Revision history for this message
su_v (suv-lp) wrote :

Julien - would you consider it save to backport (some of) your recent commits to the 0.48.x branch (mainly so that these changes will be available to MacPorts users who want to test upcoming inkscape 0.48.2 with gtk2+no_x11+quartz)?

Related reports/revisions:
bug #721424: r10382, 10837
bug #487144: r10384
bug #791709: r10383
bug #251982: r10381

If so - could you add the tag 'backport-proposed' to those reports?

(Note: I'm aware that backing out the buggy ige-mac-menu part still requires patching the sources via MacPorts' Portfile)

Revision history for this message
Gellule (gellule-xg) wrote :

Taged all backport-proposed, plus #640985, without #791709 (cosmetic).
Finally found where you posted that backport-proposed thing. Comment #9 above! :D

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

> Taged all backport-proposed, plus #640985, without #791709 (cosmetic).

Thx. Setting the milestone to 0.49 for now - it will be changed to 0.48.2 one the backport has been done and confirmed.

Changed in inkscape:
milestone: none → 0.49
Revision history for this message
Krzysztof Kosinski (tweenk) wrote :

Backported to stable in 9860

Changed in inkscape:
milestone: 0.49 → 0.48.3
tags: removed: backport-proposed
Revision history for this message
su_v (suv-lp) wrote :

With regard to the linked trac ticket in MacPorts: even with the backported changes, Inkscape 0.48.3 built with the Quartz backend of gtk+ will be highly unstable with a partially defunct global menu (causing varies crashes) as long as the old ige-mac-menu.* code is not removed (see bug #721448 - among others).

Ted Gould (ted)
Changed in inkscape:
status: Fix Committed → Fix Released
su_v (suv-lp)
tags: added: gtk-quartz
removed: gtk-osx
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related blueprints

Remote bug watches

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