Title: [139769] trunk
Revision
139769
Author
zandober...@gmail.com
Date
2013-01-15 11:49:50 -0800 (Tue, 15 Jan 2013)

Log Message

[Autotools] Add support for WebKit2-only builds
https://bugs.webkit.org/show_bug.cgi?id=106889

Patch by Zan Dobersek <zandober...@gmail.com> on 2013-01-15
Reviewed by Gustavo Noronha Silva.

.: 

* GNUmakefile.am: Only copy the WebKit1 documentation into the destination
directory if building WebKit1.
* configure.ac: Add a configuration option for disabling the WebKit1 build.
Only conditionally copy WebKit1-specific targets from the input files. Some
small style changes to the WebKit2 configuration flag included as well.

Source/WebKit/gtk: 

* GNUmakefile.am: Only build the WebKit1-specific targets if actually
building WebKit1. This puts the libwebkitgtk library, the pkg-config file
and the WebKit1-specific unit tests under the ENABLE_WEBKIT1 Automake
conditional.

Tools: 

* GNUmakefile.am: Only build the GtkLauncher and DumpRenderTree if building WebKit1.
* Scripts/build-webkit: Pass along the information on whether to build WebKit1 when
building the GTK port through build-webkit.
* Scripts/webkitdirs.pm:
(buildAutotoolsProject): Add the --disable-webkit1 configuration flag to the build
arguments when not building WebKit1.
(buildGtkProject): Pass along the information on whether to build WebKit1 when building
through the Autotools build system.

Modified Paths

Diff

Modified: trunk/ChangeLog (139768 => 139769)


--- trunk/ChangeLog	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/ChangeLog	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1,3 +1,16 @@
+2013-01-15  Zan Dobersek  <zandober...@gmail.com>
+
+        [Autotools] Add support for WebKit2-only builds
+        https://bugs.webkit.org/show_bug.cgi?id=106889
+
+        Reviewed by Gustavo Noronha Silva.
+
+        * GNUmakefile.am: Only copy the WebKit1 documentation into the destination
+        directory if building WebKit1.
+        * configure.ac: Add a configuration option for disabling the WebKit1 build.
+        Only conditionally copy WebKit1-specific targets from the input files. Some
+        small style changes to the WebKit2 configuration flag included as well.
+
 2013-01-14  Nate Chapin  <jap...@chromium.org>
 
         Enable reuse of cached main resources

Modified: trunk/GNUmakefile.am (139768 => 139769)


--- trunk/GNUmakefile.am	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/GNUmakefile.am	2013-01-15 19:49:50 UTC (rev 139769)
@@ -356,10 +356,12 @@
 dist-hook: doc-dist-hook
 doc-dist-hook: docs-build.stamp
 	cp $(WebKit)/NEWS $(distdir)
+if ENABLE_WEBKIT1
 	@mkdir -p $(distdir)/Documentation/webkitgtk/html
 	@mkdir -p $(distdir)/Documentation/webkitgtk/tmpl
 	@-cp ./Documentation/webkitgtk/tmpl/*.sgml $(distdir)/Documentation/webkitgtk/tmpl
 	@cp ./Documentation/webkitgtk/html/* $(distdir)/Documentation/webkitgtk/html
+endif
 if ENABLE_WEBKIT2
 	@mkdir -p $(distdir)/Documentation/webkit2gtk/html
 	@mkdir -p $(distdir)/Documentation/webkit2gtk/tmpl

Modified: trunk/Source/WebKit/gtk/ChangeLog (139768 => 139769)


--- trunk/Source/WebKit/gtk/ChangeLog	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Source/WebKit/gtk/ChangeLog	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1,3 +1,15 @@
+2013-01-15  Zan Dobersek  <zandober...@gmail.com>
+
+        [Autotools] Add support for WebKit2-only builds
+        https://bugs.webkit.org/show_bug.cgi?id=106889
+
+        Reviewed by Gustavo Noronha Silva.
+
+        * GNUmakefile.am: Only build the WebKit1-specific targets if actually
+        building WebKit1. This puts the libwebkitgtk library, the pkg-config file
+        and the WebKit1-specific unit tests under the ENABLE_WEBKIT1 Automake
+        conditional.
+
 2013-01-11  Carlos Garcia Campos  <cgar...@igalia.com>
 
         Unreviewed. Update NEWS and configure.ac for 1.11.4 release

Modified: trunk/Source/WebKit/gtk/GNUmakefile.am (139768 => 139769)


--- trunk/Source/WebKit/gtk/GNUmakefile.am	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Source/WebKit/gtk/GNUmakefile.am	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1,5 +1,7 @@
+if ENABLE_WEBKIT1
 lib_LTLIBRARIES += \
 	libwebkitgtk-@WEBKITGTK_API_MAJOR_VERSION@.@WEBKITGTK_API_MINOR_VERSION@.la
+endif
 
 nodist_libwebkitgtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_SOURCES = \
 	$(webkitgtk_built_sources)
@@ -278,6 +280,7 @@
 	Source/WebKit/gtk/webkit/webkitwebwindowfeatures.cpp \
 	Source/WebKit/gtk/webkit/webkitwebwindowfeaturesprivate.h
 
+if ENABLE_WEBKIT1
 pkgconfig_DATA += Source/WebKit/gtk/@WEBKITGTK_PC_NAME@-@WEBKITGTK_API_VERSION@.pc
 
 if ENABLE_INTROSPECTION
@@ -335,6 +338,7 @@
 CLEANFILES += $(JSCORE_GIRSOURCES) $(WEBKIT_GIRSOURCES) $(typelibs_DATA)
 
 endif
+endif
 
 EXTRA_DIST += $(top_builddir)/Source/WebKit/gtk/JSCore-@WEBKITGTK_API_VERSION@.gir
 
@@ -446,6 +450,7 @@
 	-no-install \
 	-no-fast-install
 
+if ENABLE_WEBKIT1
 noinst_PROGRAMS += \
 	Programs/unittests/testapplicationcache \
 	Programs/unittests/testcontextmenu \
@@ -475,6 +480,7 @@
 	Programs/unittests/testwebview \
 	Programs/unittests/testkeyevents \
 	Programs/unittests/testcopyandpaste
+endif
 
 # Add additional tests here
 Programs_unittests_testapplicationcache_SOURCES = Source/WebKit/gtk/tests/testapplicationcache.c

Modified: trunk/Tools/ChangeLog (139768 => 139769)


--- trunk/Tools/ChangeLog	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Tools/ChangeLog	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1,5 +1,21 @@
 2013-01-15  Zan Dobersek  <zandober...@gmail.com>
 
+        [Autotools] Add support for WebKit2-only builds
+        https://bugs.webkit.org/show_bug.cgi?id=106889
+
+        Reviewed by Gustavo Noronha Silva.
+
+        * GNUmakefile.am: Only build the GtkLauncher and DumpRenderTree if building WebKit1.
+        * Scripts/build-webkit: Pass along the information on whether to build WebKit1 when
+        building the GTK port through build-webkit.
+        * Scripts/webkitdirs.pm:
+        (buildAutotoolsProject): Add the --disable-webkit1 configuration flag to the build
+        arguments when not building WebKit1.
+        (buildGtkProject): Pass along the information on whether to build WebKit1 when building
+        through the Autotools build system.
+
+2013-01-15  Zan Dobersek  <zandober...@gmail.com>
+
         [GTK] Enable Performance Timeline, Resource Timing, Navigation Timing features
         https://bugs.webkit.org/show_bug.cgi?id=106197
 

Modified: trunk/Tools/GNUmakefile.am (139768 => 139769)


--- trunk/Tools/GNUmakefile.am	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Tools/GNUmakefile.am	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1,8 +1,12 @@
 noinst_PROGRAMS += \
-	Programs/DumpRenderTree \
-	Programs/GtkLauncher \
 	Programs/ImageDiff
 
+if ENABLE_WEBKIT1
+noinst_PROGRAMS += \
+	Programs/DumpRenderTree \
+	Programs/GtkLauncher
+endif
+
 # GtkLauncher
 Programs_GtkLauncher_CPPFLAGS = \
 	-I$(srcdir)/Source/WebKit/gtk \
@@ -340,6 +344,7 @@
 	-@rmdir Documentation
 
 install-data-local:
+if ENABLE_WEBKIT1
 	@installfiles=`echo ./Documentation/webkitgtk/html/*`; \
 	if test "$$installfiles" = './Documentation/webkitgtk/html/*'; \
 	then echo 1>&2 'No documentation to install' ; \
@@ -360,6 +365,7 @@
 	      $${installdir}/webkitgtk-$(DOC_MODULE_VERSION).devhelp2; \
 	  fi; \
 	fi
+endif
 if ENABLE_WEBKIT2
 	@installfiles=`echo ./Documentation/webkit2gtk/html/*`; \
 	if test "$$installfiles" = './Documentation/webkit2gtk/html/*'; \
@@ -385,6 +391,7 @@
 	@$(AM_V_GEN)$(PYTHON) $(srcdir)/Tools/gtk/generate-gtkdoc --rebase --virtual-root=$${DESTDIR}
 
 uninstall-local:
+if ENABLE_WEBKIT1
 	@DOC_MODULE_VERSION=`cat ./Documentation/webkitgtk/version.xml`; \
 	if test -n "$(DOC_MODULE_VERSION)"; then \
 	  installdir="$(DESTDIR)$(HTML_DIR)/webkitgtk-$(DOC_MODULE_VERSION)"; \
@@ -392,6 +399,7 @@
 	  installdir="$(DESTDIR)$(HTML_DIR)/webkitgtk"; \
 	fi; \
 	rm -rf $${installdir}
+endif
 if ENABLE_WEBKIT2
 	@DOC_MODULE_VERSION=`cat ./Documentation/webkit2gtk/version.xml`; \
 	if test -n "$(DOC_MODULE_VERSION)"; then \

Modified: trunk/Tools/Scripts/build-webkit (139768 => 139769)


--- trunk/Tools/Scripts/build-webkit	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Tools/Scripts/build-webkit	2013-01-15 19:49:50 UTC (rev 139769)
@@ -359,7 +359,7 @@
 
     my $project = basename($dir);
     if (isGtk()) {
-        $result = buildGtkProject($project, $clean, $prefixPath, $makeArgs, $noWebKit2, @features);
+        $result = buildGtkProject($project, $clean, $prefixPath, $makeArgs, $noWebKit1, $noWebKit2, @features);
     } elsif (isAppleMacWebKit()) {
         my @local_options = @options;
         push @local_options, XcodeCoverageSupportOptions() if $coverageSupport && $project ne "ANGLE";

Modified: trunk/Tools/Scripts/webkitdirs.pm (139768 => 139769)


--- trunk/Tools/Scripts/webkitdirs.pm	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/Tools/Scripts/webkitdirs.pm	2013-01-15 19:49:50 UTC (rev 139769)
@@ -2005,7 +2005,7 @@
 
 sub buildAutotoolsProject($@)
 {
-    my ($project, $clean, $prefix, $makeArgs, $noWebKit2, @features) = @_;
+    my ($project, $clean, $prefix, $makeArgs, $noWebKit1, $noWebKit2, @features) = @_;
 
     my $make = 'make';
     my $dir = productDir();
@@ -2026,6 +2026,9 @@
     }
 
     my @buildArgs = @ARGV;
+    if ($noWebKit1) {
+        unshift(@buildArgs, "--disable-webkit1");
+    }
     if ($noWebKit2) {
         unshift(@buildArgs, "--disable-webkit2");
     }
@@ -2443,13 +2446,13 @@
 
 sub buildGtkProject
 {
-    my ($project, $clean, $prefix, $makeArgs, $noWebKit2, @features) = @_;
+    my ($project, $clean, $prefix, $makeArgs, $noWebKit1, $noWebKit2, @features) = @_;
 
     if ($project ne "WebKit" and $project ne "_javascript_Core" and $project ne "WTF") {
         die "Unsupported project: $project. Supported projects: WebKit, _javascript_Core, WTF\n";
     }
 
-    return buildAutotoolsProject($project, $clean, $prefix, $makeArgs, $noWebKit2, @features);
+    return buildAutotoolsProject($project, $clean, $prefix, $makeArgs, $noWebKit1, $noWebKit2, @features);
 }
 
 sub buildChromiumMakefile($$@)

Modified: trunk/configure.ac (139768 => 139769)


--- trunk/configure.ac	2013-01-15 19:47:31 UTC (rev 139768)
+++ trunk/configure.ac	2013-01-15 19:49:50 UTC (rev 139769)
@@ -1054,12 +1054,18 @@
    AC_SUBST([COVERAGE_LDFLAGS])
 fi
 
+# WebKit1
+AC_MSG_CHECKING([whether to build WebKit1])
+AC_ARG_ENABLE(webkit1,
+    AC_HELP_STRING([--enable-webkit1], [build WebKit1 [default=yes]]),
+    [], [enable_webkit1="yes"])
+
 # WebKit2
 # If you change the default here, please also make sure the assumptions made
 # in Tools/Scripts/webkitdirs.pm:buildAutotoolsProject still make sense.
-AC_MSG_CHECKING([whether to build Webkit2])
+AC_MSG_CHECKING([whether to build WebKit2])
 AC_ARG_ENABLE(webkit2,
-    AC_HELP_STRING([--enable-webkit2], [build webkit2 [default=yes]]),
+    AC_HELP_STRING([--enable-webkit2], [build WebKit2 [default=yes]]),
     [], [enable_webkit2="yes"])
 AC_MSG_RESULT([$enable_webkit2])
 if test "$enable_webkit2" = "yes"; then
@@ -1155,6 +1161,7 @@
 AM_CONDITIONAL([ENABLE_FAST_MALLOC],[test "$enable_fast_malloc" = "yes"])
 AM_CONDITIONAL([ENABLE_WEB_AUDIO],[test "$enable_web_audio" = "yes"])
 AM_CONDITIONAL([ENABLE_OPCODE_STATS],[test "$enable_opcode_stats" = "yes"])
+AM_CONDITIONAL([ENABLE_WEBKIT1],[test "$enable_webkit1" = "yes"])
 AM_CONDITIONAL([ENABLE_WEBKIT2],[test "$enable_webkit2" = "yes"])
 AM_CONDITIONAL([ENABLE_SPELLCHECK],[test "$enable_spellcheck" = "yes"])
 AM_CONDITIONAL([ENABLE_CSS_FILTERS],[test "$enable_css_filters" = "yes"])
@@ -1166,23 +1173,31 @@
 AC_CONFIG_FILES([
 GNUmakefile
 ])
- 
 
 AC_CONFIG_FILES([
-Source/WebKit/gtk/webkit/webkitversion.h
-Source/WebKit/gtk/po/POTFILES
 DerivedSources/WebCore/UserAgentGtk.h:Source/WebCore/platform/gtk/UserAgentGtk.h.in
 ])
 
 AC_CONFIG_FILES([
-Source/WebKit/gtk/${WEBKITGTK_PC_NAME}-${WEBKITGTK_API_VERSION}.pc:Source/WebKit/gtk/webkit.pc.in
+Source/_javascript_Core/_javascript_coregtk-${WEBKITGTK_API_VERSION}.pc:Source/_javascript_Core/_javascript_coregtk.pc.in
 Source/WebKit/gtk/JSCore-${WEBKITGTK_API_VERSION}.gir:Source/WebKit/gtk/JSCore.gir.in
-Source/_javascript_Core/_javascript_coregtk-${WEBKITGTK_API_VERSION}.pc:Source/_javascript_Core/_javascript_coregtk.pc.in
 ]
 ,[WEBKITGTK_API_VERSION=$WEBKITGTK_API_VERSION,WEBKITGTK_PC_NAME=$WEBKITGTK_PC_NAME]
 )
 
+if test "$enable_webkit1" = "yes"; then
+    AC_CONFIG_FILES([
+    Source/WebKit/gtk/webkit/webkitversion.h
+    Source/WebKit/gtk/po/POTFILES
+    ])
 
+    AC_CONFIG_FILES([
+    Source/WebKit/gtk/${WEBKITGTK_PC_NAME}-${WEBKITGTK_API_VERSION}.pc:Source/WebKit/gtk/webkit.pc.in
+    ]
+    ,[WEBKITGTK_API_VERSION=$WEBKITGTK_API_VERSION,WEBKITGTK_PC_NAME=$WEBKITGTK_PC_NAME]
+    )
+fi
+
 if test "$enable_webkit2" = "yes"; then
     AC_CONFIG_FILES([
     DerivedSources/WebKit2/webkit2gtk/webkit2/WebKitVersion.h:Source/WebKit2/UIProcess/API/gtk/WebKitVersion.h.in
@@ -1212,6 +1227,7 @@
 
 Features:
 =======
+ WebKit1 support                                          : $enable_webkit1
  WebKit2 support                                          : $enable_webkit2
  Accelerated Compositing                                  : $enable_accelerated_compositing
  Gamepad support                                          : $enable_gamepad
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to