WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
130150
[EFL][GTK] Get CMake to find Freetype2 properly
https://bugs.webkit.org/show_bug.cgi?id=130150
Summary
[EFL][GTK] Get CMake to find Freetype2 properly
Thiago de Barros Lacerda
Reported
2014-03-12 11:52:41 PDT
Newer versions of CMake are not able to find Freetype2 correctly.
Attachments
Patch
(8.84 KB, patch)
2014-03-12 11:59 PDT
,
Thiago de Barros Lacerda
no flags
Details
Formatted Diff
Diff
Patch
(11.13 KB, patch)
2014-03-18 14:48 PDT
,
Thiago de Barros Lacerda
no flags
Details
Formatted Diff
Diff
Fix for Fretype version>=2.5.1
(11.26 KB, patch)
2014-03-20 13:22 PDT
,
Thiago de Barros Lacerda
no flags
Details
Formatted Diff
Diff
Fix for Fretype version>=2.5.1 and putting version back to 2.4.2
(11.26 KB, patch)
2014-03-20 13:34 PDT
,
Thiago de Barros Lacerda
no flags
Details
Formatted Diff
Diff
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
Thiago de Barros Lacerda
Comment 1
2014-03-12 11:59:19 PDT
Created
attachment 226542
[details]
Patch
Martin Robinson
Comment 2
2014-03-12 11:59:56 PDT
***
Bug 130107
has been marked as a duplicate of this bug. ***
Martin Robinson
Comment 3
2014-03-12 12:01:46 PDT
Comment on
attachment 226542
[details]
Patch It should be possible to properly use the version information with pkgconfig. See FindGeoclue.cmake for how we have done this in WebKitGTK+.
Thiago de Barros Lacerda
Comment 4
2014-03-18 14:48:04 PDT
Created
attachment 227113
[details]
Patch
Martin Robinson
Comment 5
2014-03-18 15:31:42 PDT
Comment on
attachment 227113
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=227113&action=review
> Source/cmake/FindFreetype2.cmake:2 > +# Copyright (C) 2013 Nokia Corporation and/or its subsidiary(-ies). > +#
For the purposes of GTK+, it is just sufficient to look at the pkgconfig file. I don't know about EFL.
> Source/cmake/OptionsGTK.cmake:173 > -find_package(Freetype 2.4.2 REQUIRED) > +find_package(Freetype2 2.4.11 REQUIRED)
I'm not sure I understand this change. You are raising the freetype dependency requirements. We cannot do that for GTK+ at least. My understanding of the situation is that the FreeType pkgconfig file lists the libtool version triple in it instead of the actual version. So here we need to figure out what the version listed in the FreeType 2.4.11 release is and then put that version here. It would also be good to put a comment explaining the situation.
Thiago de Barros Lacerda
Comment 6
2014-03-18 15:42:26 PDT
Comment on
attachment 227113
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=227113&action=review
>> Source/cmake/FindFreetype2.cmake:2 >> +# > > For the purposes of GTK+, it is just sufficient to look at the pkgconfig file. I don't know about EFL.
Huum... maybe you commented in the wrong line?
>> Source/cmake/OptionsGTK.cmake:173 >> +find_package(Freetype2 2.4.11 REQUIRED) > > I'm not sure I understand this change. You are raising the freetype dependency requirements. We cannot do that for GTK+ at least. My understanding of the situation is that the FreeType pkgconfig file lists the libtool version triple in it instead of the actual version. So here we need to figure out what the version listed in the FreeType 2.4.11 release is and then put that version here. It would also be good to put a comment explaining the situation.
2.4.11 is the version that GTK (and also EFL) is using in jhbuild.modules. Looking at the original FindFreetype.cmake (usually in /usr/share/cmake<version>/Modules) I noticed that it searches for the version in the freetype.h header, which is the same of the package in jhbuild.modules, not that number that is in freetype2.pc file. So we can use the version that is present in jhbuild.modules
Martin Robinson
Comment 7
2014-03-18 15:48:47 PDT
(In reply to
comment #6
)
> 2.4.11 is the version that GTK (and also EFL) is using in jhbuild.modules. Looking at the original FindFreetype.cmake (usually in /usr/share/cmake<version>/Modules) I noticed that it searches for the version in the freetype.h header, which is the same of the package in jhbuild.modules, not that number that is in freetype2.pc file. > So we can use the version that is present in jhbuild.modules
Okay. That seems better. In this case we don't need to raise the dependency at all.
Gyuyoung Kim
Comment 8
2014-03-18 20:58:44 PDT
Comment on
attachment 227113
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=227113&action=review
LGTM on EFL port side.
>>> Source/cmake/FindFreetype2.cmake:2 >>> +# >> >> For the purposes of GTK+, it is just sufficient to look at the pkgconfig file. I don't know about EFL. > > Huum... maybe you commented in the wrong line?
I'm not sure I understand what Martin said. It seems to me that Martin think we don't need to keep FindFreetype2.cmake. But, I think Changelog explains why FindFreetype2.cmake is needed, isn't it ?
Gyuyoung Kim
Comment 9
2014-03-18 20:59:43 PDT
Comment on
attachment 227113
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=227113&action=review
LGTM on EFL port side.
>>>> Source/cmake/FindFreetype2.cmake:2 >>>> +# >>> >>> For the purposes of GTK+, it is just sufficient to look at the pkgconfig file. I don't know about EFL. >> >> Huum... maybe you commented in the wrong line? > > I'm not sure I understand what Martin said. It seems to me that Martin think we don't need to keep FindFreetype2.cmake. But, I think Changelog explains why FindFreetype2.cmake is needed, isn't it ?
I'm not sure I understand what Martin said. It seems to me that Martin think we don't need to keep FindFreetype2.cmake. But, I think Changelog explains why FindFreetype2.cmake is needed, isn't it ?
Gyuyoung Kim
Comment 10
2014-03-18 21:02:50 PDT
Comment on
attachment 227113
[details]
Patch LGTM on EFL port side.
Gyuyoung Kim
Comment 11
2014-03-18 21:10:00 PDT
(In reply to
comment #10
)
> (From update of
attachment 227113
[details]
) > LGTM on EFL port side.
Oops, sorry for duplicated comments. My internet connection was weird for a while. :(
Thiago de Barros Lacerda
Comment 12
2014-03-19 06:01:24 PDT
(In reply to
comment #11
)
> (In reply to
comment #10
) > > (From update of
attachment 227113
[details]
[details]) > > LGTM on EFL port side. > > Oops, sorry for duplicated comments. My internet connection was weird for a while. :(
Looks like it is OK for both GTK and EFL. Who is going to r+? :)
Csaba Osztrogonác
Comment 13
2014-03-20 06:45:30 PDT
Comment on
attachment 227113
[details]
Patch r=me based on previous comments.
WebKit Commit Bot
Comment 14
2014-03-20 07:19:28 PDT
Comment on
attachment 227113
[details]
Patch Clearing flags on attachment: 227113 Committed
r165962
: <
http://trac.webkit.org/changeset/165962
>
WebKit Commit Bot
Comment 15
2014-03-20 07:19:35 PDT
All reviewed patches have been landed. Closing bug.
Martin Robinson
Comment 16
2014-03-20 08:13:07 PDT
This raised the Freetype2 dependency for GTK+ which is against our port policy. Why did it increase the version requirement?
Csaba Osztrogonác
Comment 17
2014-03-20 08:25:38 PDT
(In reply to
comment #16
)
> This raised the Freetype2 dependency for GTK+ which is against our port policy. Why did it increase the version requirement?
It didn' raise, GTK already uses 2.4.11 via jhbuild.modules as you agreed previously in
comment #7
.
Alberto Garcia
Comment 18
2014-03-20 08:28:35 PDT
The build is broken here since this patch: CMake Error at /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:108 (message): Could NOT find Freetype2 (missing: FREETYPE2_INCLUDE_DIRS) (Required is at least version "2.4.11")
Alberto Garcia
Comment 19
2014-03-20 08:31:35 PDT
The problem seems to be this one: find_path(FREETYPE2_ROOT_INCLUDE_DIR NAMES freetype/freetype.h HINTS ${PC_FREETYPE2_INCLUDE_DIRS} ${PC_FREETYPE2_INCLUDEDIR} ) There's no freetype/freetype.h since FreeType 2.5.1 See
bug 125074
Martin Robinson
Comment 20
2014-03-20 08:32:05 PDT
(In reply to
comment #17
)
> It didn' raise, GTK already uses 2.4.11 via jhbuild.modules > as you agreed previously in
comment #7
.
This patch causes everyone compiling WebKitGTK+ to have a newer version of FreeType. The version of FreeType in the JHBuild module is the one that developers and the bots use for testing.
WebKit Commit Bot
Comment 21
2014-03-20 08:32:33 PDT
Re-opened since this is blocked by
bug 130512
Martin Robinson
Comment 22
2014-03-20 08:33:46 PDT
(In reply to
comment #17
)
> (In reply to
comment #16
) > > This raised the Freetype2 dependency for GTK+ which is against our port policy. Why did it increase the version requirement? > > It didn' raise, GTK already uses 2.4.11 via jhbuild.modules > as you agreed previously in
comment #7
.
Ah, apologies about
comment 7
. I think we managed to talk past on another there. My conclusion was that we didn't need to raise the dependency.
Martin Robinson
Comment 23
2014-03-20 08:34:54 PDT
For the purposes of EFL and GTK+ can't we just accept the pkgconfig results? We are doing this for other packages. The only thing we need to do is to translate the versions to ones that are in the pkgconfig files.
Csaba Osztrogonác
Comment 24
2014-03-20 08:36:59 PDT
Sorry, I misundertood it, I thought you agreead about it. And I thought the version in jhbuild is the minimum required version. Good to know if it isn't. I rolled it out to unbreak the build.
Thiago de Barros Lacerda
Comment 25
2014-03-20 13:22:58 PDT
Created
attachment 227323
[details]
Fix for Fretype version>=2.5.1
Thiago de Barros Lacerda
Comment 26
2014-03-20 13:25:25 PDT
As Ossy said, I did not raised the version of freetype, I just used the one that is present on jhbuild. Anyway, I uploaded a new patch that is supposed to work with other versions. Can you guys check?
Martin Robinson
Comment 27
2014-03-20 13:28:54 PDT
Comment on
attachment 227323
[details]
Fix for Fretype version>=2.5.1 View in context:
https://bugs.webkit.org/attachment.cgi?id=227323&action=review
> Source/cmake/OptionsGTK.cmake:173 > -find_package(Freetype 2.4.2 REQUIRED) > +find_package(Freetype2 2.4.11 REQUIRED)
This is the line where you raise the freetype dependency.
Thiago de Barros Lacerda
Comment 28
2014-03-20 13:31:35 PDT
(In reply to
comment #27
)
> (From update of
attachment 227323
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=227323&action=review
> > > Source/cmake/OptionsGTK.cmake:173 > > -find_package(Freetype 2.4.2 REQUIRED) > > +find_package(Freetype2 2.4.11 REQUIRED) > > This is the line where you raise the freetype dependency.
OK, I will put it back to 2.4.2. Is that OK?
Martin Robinson
Comment 29
2014-03-20 13:32:22 PDT
(In reply to
comment #28
)
> (In reply to
comment #27
) > > (From update of
attachment 227323
[details]
[details]) > > View in context:
https://bugs.webkit.org/attachment.cgi?id=227323&action=review
> > > > > Source/cmake/OptionsGTK.cmake:173 > > > -find_package(Freetype 2.4.2 REQUIRED) > > > +find_package(Freetype2 2.4.11 REQUIRED) > > > > This is the line where you raise the freetype dependency. > > OK, I will put it back to 2.4.2. Is that OK?
Thanks. :)
Thiago de Barros Lacerda
Comment 30
2014-03-20 13:34:37 PDT
Created
attachment 227325
[details]
Fix for Fretype version>=2.5.1 and putting version back to 2.4.2
Thiago de Barros Lacerda
Comment 31
2014-03-20 19:49:56 PDT
Martin, Gyuyoung and Alberto, is that OK now? If so, Martin or Gyuyoung, could you r+? Thanks
WebKit Commit Bot
Comment 32
2014-03-20 20:47:57 PDT
Comment on
attachment 227325
[details]
Fix for Fretype version>=2.5.1 and putting version back to 2.4.2 Clearing flags on attachment: 227325 Committed
r166037
: <
http://trac.webkit.org/changeset/166037
>
WebKit Commit Bot
Comment 33
2014-03-20 20:48:05 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug