Bug 136158

Summary: [GTK] WebKit has a new required dependency on GnuTLS
Product: WebKit Reporter: Martin Robinson <mrobinson>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: berto, commit-queue, dbates, elima, oleg_smirnov
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description Martin Robinson 2014-08-22 10:17:11 PDT
We should not be adding required dependencies, so WebCrypto should be disabled when GnuTLS is not found:

--  WTF_USE_TILED_BACKING_STORE               OFF
--  ENABLE_PLUGIN_PROCESS_GTK2 .............. ON
-- checking for module 'libsecret-1'
--   package 'libsecret-1' not found
-- Could NOT find LIBSECRET (missing:  LIBSECRET_INCLUDE_DIRS LIBSECRET_LIBRARIES)
CMake Error at /home/guijemont/.local/share/cmake-3.0/Modules/FindPackageHandleStandardArgs.cmake:136 (message):
  Could NOT find GnuTLS: Found unsuitable version "2.12.14", but required is
  at least "3.0.0" (found /usr/lib/x86_64-linux-gnu/libgnutls.so)
Call Stack (most recent call first):
  /home/guijemont/.local/share/cmake-3.0/Modules/FindPackageHandleStandardArgs.cmake:341 (_FPHSA_FAILURE_MESSAGE)
  /home/guijemont/.local/share/cmake-3.0/Modules/FindGnuTLS.cmake:69 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  Source/cmake/OptionsGTK.cmake:383 (find_package)
  CMakeLists.txt:159 (include)
Comment 1 Alberto Garcia 2014-09-24 02:34:41 PDT
cmake only complains if you explicitly enable SUBTLE_CRYPTO and it fails to find the required dependencies. I understand that's the correct behavior.

It is build-webkit that sets ENABLE_SUBTLE_CRYPTO by default, if you call cmake directly instead it works fine.

So maybe we should disable subtle-crypto by default in build-webkit?
Comment 2 Oleg Smirnov 2014-11-29 16:53:03 PST
Created attachment 242286 [details]
Patch
Comment 3 Alberto Garcia 2014-12-07 09:33:04 PST
Comment on attachment 242286 [details]
Patch

The patch looks good to me, r+ anyone?
Comment 4 Martin Robinson 2014-12-07 09:42:12 PST
If this if provided by the JHBuild, I don't think it's necessary. If it's not provided by the JHBuild, perhaps it should be?
Comment 5 Alberto Garcia 2014-12-07 09:52:13 PST
Actually Tools/gtk/install-dependencies is already installing
libgnutls-dev, so maybe there's nothing to fix here?

WebCrypto is already disabled when we use cmake directly, so I don't
think distributors/end users are really required to install gnutls.
Comment 6 Martin Robinson 2014-12-07 10:18:15 PST
(In reply to comment #5)
> Actually Tools/gtk/install-dependencies is already installing
> libgnutls-dev, so maybe there's nothing to fix here?
> 
> WebCrypto is already disabled when we use cmake directly, so I don't
> think distributors/end users are really required to install gnutls.

Probably it should be one of those features that's enabled only when the dependency is found. I think Safari is shipping it so we can probably start as well.
Comment 7 Alberto Garcia 2014-12-07 10:32:37 PST
Created attachment 242754 [details]
Patch

Ok, here it goes
Comment 8 WebKit Commit Bot 2014-12-07 11:23:41 PST
Comment on attachment 242754 [details]
Patch

Clearing flags on attachment: 242754

Committed r176928: <http://trac.webkit.org/changeset/176928>
Comment 9 WebKit Commit Bot 2014-12-07 11:23:45 PST
All reviewed patches have been landed.  Closing bug.