Bug 154104 - Fix the !(ENABLE(SVG_FONTS) || ENABLE(SVG_OTF_CONVERTER)) build after r196322
Summary: Fix the !(ENABLE(SVG_FONTS) || ENABLE(SVG_OTF_CONVERTER)) build after r196322
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Csaba Osztrogonác
URL:
Keywords:
Depends on:
Blocks: 153414
  Show dependency treegraph
 
Reported: 2016-02-11 03:26 PST by Csaba Osztrogonác
Modified: 2016-02-15 04:28 PST (History)
6 users (show)

See Also:


Attachments
Patch (1.48 KB, patch)
2016-02-11 03:33 PST, Csaba Osztrogonác
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Csaba Osztrogonác 2016-02-11 03:26:28 PST
http://trac.webkit.org/changeset/196322 broke the !(ENABLE(SVG_FONTS) || ENABLE(SVG_OTF_CONVERTER))
build, because CSSFontFaceSource::CSSFontFaceSource:m_svgFontFaceElement is declared
inside ifdef guards, but initialized uncionditionally in the init list of the constructor.
Comment 1 Csaba Osztrogonác 2016-02-11 03:33:20 PST
Created attachment 271055 [details]
Patch
Comment 2 Csaba Osztrogonác 2016-02-11 03:43:40 PST
Or should we declare m_svgFontFaceElement unconditionally?
( similar to bug154035 )
Comment 3 Alex Christensen 2016-02-11 08:57:40 PST
(In reply to comment #2)
> Or should we declare m_svgFontFaceElement unconditionally?
> ( similar to bug154035 )
I think that would be cleaner.
Comment 4 Darin Adler 2016-02-11 09:30:52 PST
(In reply to comment #3)
> (In reply to comment #2)
> > Or should we declare m_svgFontFaceElement unconditionally?
> > ( similar to bug154035 )
> I think that would be cleaner.

I agree.
Comment 5 Myles C. Maxfield 2016-02-11 13:31:28 PST
EWS was all green on http://trac.webkit.org/changeset/196322 :(
Comment 6 Csaba Osztrogonác 2016-02-12 02:02:53 PST
(In reply to comment #4)
> (In reply to comment #3)
> > (In reply to comment #2)
> > > Or should we declare m_svgFontFaceElement unconditionally?
> > > ( similar to bug154035 )
> > I think that would be cleaner.
> 
> I agree.

I checked it in details, it's impossible.

m_svgFontFaceElement has RefPtr<SVGFontFaceElement> type and 
SVGFontFaceElement class is defined inside ENABLE(SVG_FONTS) guard.

To be able to use RefPtr<SVGFontFaceElement> type, we have to
remove ENABLE(SVG_FONTS) guard from SVGFontFaceElement.h and
I think transitionally all ENABLE(SVG_FONTS) guards everywhere.

The question is if we want to support !ENABLE(SVG_FONTS) build or not.
If yes, we should land my previously proposed patch. If not, we should
remove all ENABLE(SVG_FONTS) guards.
Comment 7 Csaba Osztrogonác 2016-02-12 02:03:39 PST
Comment on attachment 271055 [details]
Patch

r? again, maybe we would like to keep !ENABLE(SVG_FONTS) build configuration work.
Comment 8 Myles C. Maxfield 2016-02-12 10:44:36 PST
(In reply to comment #6)
> (In reply to comment #4)
> > (In reply to comment #3)
> > > (In reply to comment #2)
> > > > Or should we declare m_svgFontFaceElement unconditionally?
> > > > ( similar to bug154035 )
> > > I think that would be cleaner.
> > 
> > I agree.
> 
> I checked it in details, it's impossible.
> 
> m_svgFontFaceElement has RefPtr<SVGFontFaceElement> type and 
> SVGFontFaceElement class is defined inside ENABLE(SVG_FONTS) guard.
> 
> To be able to use RefPtr<SVGFontFaceElement> type, we have to
> remove ENABLE(SVG_FONTS) guard from SVGFontFaceElement.h and
> I think transitionally all ENABLE(SVG_FONTS) guards everywhere.
> 
> The question is if we want to support !ENABLE(SVG_FONTS) build or not.
> If yes, we should land my previously proposed patch. If not, we should
> remove all ENABLE(SVG_FONTS) guards.

FWIW, I am very close to enabling the SVG font converter on Windows, and I hope the remaining ports will be quick to follow. I hope to remove all the SVG font code (in favor of the converter) in a few weeks.
Comment 9 WebKit Commit Bot 2016-02-15 04:28:20 PST
Comment on attachment 271055 [details]
Patch

Clearing flags on attachment: 271055

Committed r196576: <http://trac.webkit.org/changeset/196576>
Comment 10 WebKit Commit Bot 2016-02-15 04:28:25 PST
All reviewed patches have been landed.  Closing bug.