<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[177789] trunk/Tools</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/177789">177789</a></dd>
<dt>Author</dt> <dd>commit-queue@webkit.org</dd>
<dt>Date</dt> <dd>2014-12-29 04:53:19 -0800 (Mon, 29 Dec 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>[jhBuild] cairo build error (-flto)
https://bugs.webkit.org/show_bug.cgi?id=139056

Patch by Fabien Vallée &lt;fvallee@connected-labs.com&gt; on 2014-12-29
Reviewed by Philippe Normand.

cairo fails to link  with gcc 4.9 due to lto
related issue. This problem has been partially
addressed by cairo:
http://cgit.freedesktop.org/cairo/commit/?id=c3645d97ebd24c6f7ad850785d585aebc706a11c
use the cairo --disable-lto option and remove jhbuild
makeargs fixes the issue.

* gtk/jhbuild.modules:
* gtk/patches/cairo-1.12.8-add_disable-lto.patch: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsgtkjhbuildmodules">trunk/Tools/gtk/jhbuild.modules</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkToolsgtkpatchescairo1128add_disableltopatch">trunk/Tools/gtk/patches/cairo-1.12.8-add_disable-lto.patch</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (177788 => 177789)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2014-12-29 07:00:08 UTC (rev 177788)
+++ trunk/Tools/ChangeLog        2014-12-29 12:53:19 UTC (rev 177789)
</span><span class="lines">@@ -1,3 +1,20 @@
</span><ins>+2014-12-29  Fabien Vallée  &lt;fvallee@connected-labs.com&gt;
+
+        [jhBuild] cairo build error (-flto)
+        https://bugs.webkit.org/show_bug.cgi?id=139056
+
+        Reviewed by Philippe Normand.
+
+        cairo fails to link  with gcc 4.9 due to lto
+        related issue. This problem has been partially
+        addressed by cairo:
+        http://cgit.freedesktop.org/cairo/commit/?id=c3645d97ebd24c6f7ad850785d585aebc706a11c
+        use the cairo --disable-lto option and remove jhbuild
+        makeargs fixes the issue.
+
+        * gtk/jhbuild.modules:
+        * gtk/patches/cairo-1.12.8-add_disable-lto.patch: Added.
+
</ins><span class="cx"> 2014-12-27  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</span><span class="cx">         [Mac] Enable kerning, ligatures, and printer fonts 
</span><span class="cx">         https://bugs.webkit.org/show_bug.cgi?id=139970
</span></span></pre></div>
<a id="trunkToolsgtkjhbuildmodules"></a>
<div class="modfile"><h4>Modified: trunk/Tools/gtk/jhbuild.modules (177788 => 177789)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/gtk/jhbuild.modules        2014-12-29 07:00:08 UTC (rev 177788)
+++ trunk/Tools/gtk/jhbuild.modules        2014-12-29 12:53:19 UTC (rev 177789)
</span><span class="lines">@@ -59,9 +59,9 @@
</span><span class="cx">       href=&quot;http://download.savannah.gnu.org/releases/&quot;/&gt;
</span><span class="cx"> 
</span><span class="cx"> 
</span><del>-  &lt;autotools id=&quot;cairo&quot; autogen-sh=&quot;configure&quot;
-             autogenargs=&quot;--enable-gl=yes --enable-egl=yes --enable-glx=yes ac_cv_func_rsvg_pixbuf_from_file=no&quot;
-             makeargs=&quot;CFLAGS=-fno-lto CXXFLAGS=-fno-lto LDFLAGS=-fno-lto&quot;&gt;
</del><ins>+  &lt;autotools id=&quot;cairo&quot;
+             autogenargs=&quot;--enable-gl=yes --enable-egl=yes --enable-glx=yes ac_cv_func_rsvg_pixbuf_from_file=no --disable-lto&quot;
+             makeargs=&quot;&quot;&gt;
</ins><span class="cx">     &lt;dependencies&gt;
</span><span class="cx">       &lt;dep package=&quot;fontconfig&quot;/&gt;
</span><span class="cx">       &lt;dep package=&quot;pixman&quot;/&gt;
</span><span class="lines">@@ -71,6 +71,7 @@
</span><span class="cx">             repo=&quot;cairographics.org&quot;
</span><span class="cx">             hash=&quot;sha256:8fbb6fc66117ab4100bad830cb4479497e53c6f3facb98bf05c8d298554ebdd9&quot;
</span><span class="cx">             md5sum=&quot;8b3dcade859c44fb7e56fc68edfe9a45&quot;&gt;
</span><ins>+      &lt;patch file=&quot;cairo-1.12.8-add_disable-lto.patch&quot; strip=&quot;1&quot;/&gt;
</ins><span class="cx">     &lt;/branch&gt;
</span><span class="cx">   &lt;/autotools&gt;
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkToolsgtkpatchescairo1128add_disableltopatch"></a>
<div class="addfile"><h4>Added: trunk/Tools/gtk/patches/cairo-1.12.8-add_disable-lto.patch (0 => 177789)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/gtk/patches/cairo-1.12.8-add_disable-lto.patch                                (rev 0)
+++ trunk/Tools/gtk/patches/cairo-1.12.8-add_disable-lto.patch        2014-12-29 12:53:19 UTC (rev 177789)
</span><span class="lines">@@ -0,0 +1,52 @@
</span><ins>+From c3645d97ebd24c6f7ad850785d585aebc706a11c Mon Sep 17 00:00:00 2001
+From: Bryce Harrington &lt;b.harrington@samsung.com&gt;
+Date: Tue, 8 Jul 2014 13:14:20 -0700
+Subject: configure.ac: Add a --disable-lto configure option
+
+Link-Time Optimization seems to be stable enough with gcc 4.8 and 4.9,
+but has proven to be an issue in the past for many cairo users (webkit,
+efl, ubuntu, opensuse, gentoo, arch...) who carry patches to disable it.
+
+Gentoo's patch[1] adds a --disable-lto option to leave it enabled by
+default but give users the ability to work around lto related build
+problems (c.f. fdo #77060).  Patch appears to have been authored by
+Alexandre Rostovtsev[2].
+
+1: sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/x11-libs/cairo/files/cairo-1.12.16-lto-optional.patch
+2: https://bugs.gentoo.org/show_bug.cgi?id=509552
+
+Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=60852
+Signed-off-by: Bryce Harrington &lt;b.harrington@samsung.com&gt;
+Reviewed-by: Uli Schlachter &lt;psychon@znc.in&gt;
+
+diff --git a/build/configure.ac.warnings b/build/configure.ac.warnings
+index f984eb2..a72d948 100644
+--- a/build/configure.ac.warnings
++++ b/build/configure.ac.warnings
+@@ -38,13 +38,18 @@ dnl options.  Namely, the following:

+ dnl -flto working really needs a test link, not just a compile

+-safe_MAYBE_WARN=&quot;$MAYBE_WARN&quot;
+-MAYBE_WARN=&quot;$MAYBE_WARN -flto&quot;
+-AC_TRY_LINK([],[
++AC_ARG_ENABLE(lto,
++  AS_HELP_STRING([--disable-lto],
++                 [Do not try to use Link-Time Optimization]))
++if test &quot;x$enable_lto&quot; != &quot;xno&quot;; then
++   safe_MAYBE_WARN=&quot;$MAYBE_WARN&quot;
++   MAYBE_WARN=&quot;$MAYBE_WARN -flto&quot;
++   AC_TRY_LINK([],[
+         int main(int argc, char **argv) { return 0; }
+-],[],[
++   ],[],[
+         MAYBE_WARN=&quot;$safe_MAYBE_WARN&quot;
+-])
++   ])
++fi

+ MAYBE_WARN=&quot;$MAYBE_WARN -fno-strict-aliasing -fno-common&quot;

+-- 
+cgit v0.10.2
+
</ins></span></pre>
</div>
</div>

</body>
</html>