summaryrefslogtreecommitdiffstats
path: root/meta/packages
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages')
-rw-r--r--meta/packages/webkit/files/GNUmakefile.am314
-rw-r--r--meta/packages/webkit/files/WebKit.pri50
-rw-r--r--meta/packages/webkit/files/WebKit.pro14
-rw-r--r--meta/packages/webkit/files/autogen.sh40
-rw-r--r--meta/packages/webkit/files/configure.ac384
-rw-r--r--meta/packages/webkit/webkit-gtk_svn.bb12
-rw-r--r--meta/packages/webkit/webkit.inc4
7 files changed, 802 insertions, 16 deletions
diff --git a/meta/packages/webkit/files/GNUmakefile.am b/meta/packages/webkit/files/GNUmakefile.am
new file mode 100644
index 0000000000..f3ec252ee8
--- /dev/null
+++ b/meta/packages/webkit/files/GNUmakefile.am
@@ -0,0 +1,314 @@
1# Top-level Makefile rule for automake
2#
3# Variable conventions:
4#
5# _h_api = API headers that will be installed and included in the distribution
6# _cppflags = flags that will be passed to the C/CXX Preprocessor
7# _sources = sources that will be compiled and included in the distribution
8# _headers = header files that will be part of the distribution
9# _built_sources = files that will be autogenerated by the build system and
10# will be part of the _SOURCES primary
11# _built_nosources = files that are autogenerated but are not part of the
12# _SOURCES primary
13# _cleanfiles = files that will be removed by the clean target
14#
15# Sources, headers, flags, etc... should be added to the respective variables
16# with the above suffix, e.g, webcore-specific sources should go to
17# webcore_sources, gtk port-specific flags should go to webkitgtk_cppflags,
18# etc... The only exceptions are the global variables. See Global Variables below.
19#
20# Global Variables
21#
22# global_cppflags = CPPFLAGS that apply to JSC, WebCore, and to any
23# specific port
24# global_cflags = CFLAGS and CXXFLAGS that apply to JSC, WebCore, and to
25# any specific port
26
27srcdir = @srcdir@
28VPATH = @srcdir@
29
30# Directory for autogenerated sources
31GENSOURCES := $(top_builddir)/DerivedSources
32
33# Script for creating hash tables
34CREATE_HASH_TABLE = $(srcdir)/JavaScriptCore/kjs/create_hash_table
35
36# Libraries and support components
37noinst_LTLIBRARIES :=
38
39noinst_HEADERS :=
40
41noinst_PROGRAMS :=
42
43lib_LIBRARIES :=
44
45IDL_BINDINGS :=
46
47# Files that will be distributed
48EXTRA_DIST :=
49
50#
51# Global flags to CPP
52global_cppflags :=
53
54global_cppflags += \
55 -I $(srcdir)/JavaScriptCore \
56 -I $(srcdir)/JavaScriptCore/ForwardingHeaders \
57 -I $(srcdir)/JavaScriptCore/wtf \
58 -I $(srcdir)/JavaScriptCore/kjs \
59 -I $(top_builddir)/DerivedSources
60
61# Default compiler flags
62global_cflags := \
63 -Wall -W -Wcast-align -Wchar-subscripts -Wreturn-type \
64 -Wformat -Wformat-security -Wno-format-y2k -Wundef \
65 -Wmissing-format-attribute -Wpointer-arith -Wwrite-strings \
66 -Wno-unused-parameter -fno-exceptions -fno-strict-aliasing
67
68# Libraries
69lib_LTLIBRARIES = libJavaScriptCore.la libWebKitGtk.la
70
71#
72# JavaScriptCore
73javascriptcore_h_api :=
74javascriptcore_cppflags:=
75javascriptcore_sources :=
76javascriptcore_built_sources :=
77javascriptcore_built_nosources :=
78
79# The variables above are already included below so no need to touch
80# these variables unless you really have to
81libJavaScriptCore_ladir = $(prefix)/include/WebKit/JavaScriptCore
82libJavaScriptCore_la_HEADERS := $(javascriptcore_h_api)
83
84libJavaScriptCore_la_SOURCES := \
85 $(javascriptcore_built_sources) \
86 $(javascriptcore_sources)
87
88libJavaScriptCore_la_LDFLAGS := -lpthread
89
90libJavaScriptCore_la_CXXFLAGS := $(global_cflags)
91
92libJavaScriptCore_la_CFLAGS := $(global_cflags)
93
94libJavaScriptCore_la_CPPFLAGS := $(global_cppflags) $(javascriptcore_cppflags)
95
96#
97# WebCore
98webcore_cppflags :=
99webcore_sources :=
100webcore_headers :=
101webcore_built_sources :=
102webcore_built_nosources :=
103
104# WebKitGtk
105webkitgtk_h_api :=
106webkitgtk_headers :=
107webkitgtk_sources :=
108webkitgtk_cppflags :=
109webkitgtk_ldflags :=
110webkitgtk_built_sources :=
111webkitgtk_built_nosources :=
112webkitgtk_cleanfiles :=
113
114# No need to touch the following variables unless you have to. If you need to change the values
115# for the following variables, use the "webkitgtk_" variables above
116libWebKitGtk_ladir := $(prefix)/include/WebKit
117
118libWebKitGtk_la_HEADERS := $(webkitgtk_h_api)
119
120libWebKitGtk_la_SOURCES := \
121 $(webcore_built_sources) \
122 $(webcore_headers) \
123 $(webcore_sources) \
124 $(webkitgtk_built_sources) \
125 $(webkitgtk_headers) \
126 $(webkitgtk_sources)
127
128libWebKitGtk_la_CXXFLAGS := \
129 -fno-rtti \
130 $(global_cflags) \
131 $(DEPENDENCIES_CFLAGS) \
132 $(SQLITE3_CFLAGS) \
133 $(GSTREAMER_CFLAGS) \
134 $(LIBXSLT_CFLAGS) \
135 $(COVERAGE_CFLAGS)
136
137libWebKitGtk_la_CFLAGS := \
138 $(global_cflags) \
139 $(DEPENDENCIES_CFLAGS) \
140 $(SQLITE3_CFLAGS) \
141 $(GSTREAMER_CFLAGS) \
142 $(LIBXSLT_CFLAGS) \
143 $(COVERAGE_CFLAGS)
144
145libWebKitGtk_la_CPPFLAGS := \
146 $(global_cppflags) \
147 $(webcore_cppflags) \
148 $(webkitgtk_cppflags)
149
150libWebKitGtk_la_LIBADD := @LTLIBOBJS@ libJavaScriptCore.la
151
152libWebKitGtk_la_LDFLAGS := \
153 $(webkitgtk_ldflags) \
154 $(DEPENDENCIES_LIBS) \
155 $(ICU_LIBS) \
156 $(SQLITE3_LIBS) \
157 $(GSTREAMER_LIBS) \
158 $(LIBXSLT_LIBS) \
159 $(COVERAGE_LDFLAGS) \
160 -lpthread \
161 -ljpeg \
162 -version-info @LIBWEBKITGTK_VERSION@
163
164#
165# Extra checks and flags
166global_cppflags += \
167 -DBUILDING_GTK__=1 \
168 -DUSE_SYSTEM_MALLOC \
169 -DWTF_CHANGES
170
171if TARGET_X11
172global_cppflags += -DXP_UNIX
173endif
174
175if !ENABLE_DEBUG
176global_cppflags += -DNDEBUG
177else
178webkitgtk_cppflags += \
179 -DG_DISABLE_DEPRECATED \
180 -DGDK_PIXBUF_DISABLE_DEPRECATED \
181 -DGDK_DISABLE_DEPRECATED \
182 -DGTK_DISABLE_DEPRECATED \
183 -DPANGO_DISABLE_DEPRECATED \
184 -DGDK_MULTIHEAD_SAFE \
185 -DGTK_MULTIHEAD_SAFE
186endif
187
188if !ENABLE_DATABASE
189global_cppflags += -DENABLE_DATABASE=0
190endif
191
192if !ENABLE_ICONDATABASE
193global_cppflags += -DENABLE_ICONDATABASE=0
194endif
195
196if ENABLE_COVERAGE
197global_cppflags += \
198 -DGCC_GENERATE_TEST_COVERAGE_FILES \
199 -DGCC_INSTRUMENT_PROGRAM_FLOW_ARCS
200endif
201
202if ENABLE_VIDEO
203webkitgtk_ldflags += -lgstinterfaces-0.10 -lgstvideo-0.10
204endif
205
206#
207# WEBKIT GTK+
208webkitgtk_cppflags += \
209-I $(top_builddir)/WebKit/gtk/WebView \
210-DBUILDING_CAIRO__=1 \
211-DBUILD_WEBKIT
212
213webkitgtk_h_api += \
214 WebKit/gtk/WebView/webkit.h \
215 WebKit/gtk/WebView/webkitdefines.h \
216 WebKit/gtk/WebView/webkitnetworkrequest.h \
217 WebKit/gtk/WebView/webkitwebframe.h \
218 WebKit/gtk/WebView/webkitwebview.h
219
220webkitgtk_built_sources += \
221 WebKit/gtk/WebView/webkit-marshal.h \
222 WebKit/gtk/WebView/webkit-marshal.cpp
223
224webkitgtk_headers += \
225 WebKit/gtk/WebView/webkitprivate.h \
226 WebKit/gtk/WebView/webkitsettings.h \
227 WebKit/gtk/WebCoreSupport/ChromeClientGtk.h \
228 WebKit/gtk/WebCoreSupport/ContextMenuClientGtk.h \
229 WebKit/gtk/WebCoreSupport/DragClientGtk.h \
230 WebKit/gtk/WebCoreSupport/EditorClientGtk.h \
231 WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.h \
232 WebKit/gtk/WebCoreSupport/InspectorClientGtk.h \
233 WebKit/gtk/WebCoreSupport/PasteboardHelperGtk.h
234
235webkitgtk_sources += \
236 WebKit/gtk/WebView/webkitnetworkrequest.cpp \
237 WebKit/gtk/WebView/webkitprivate.cpp \
238 WebKit/gtk/WebView/webkitsettings.cpp \
239 WebKit/gtk/WebView/webkitwebframe.cpp \
240 WebKit/gtk/WebView/webkitwebview.cpp \
241 WebKit/gtk/WebCoreSupport/ChromeClientGtk.cpp \
242 WebKit/gtk/WebCoreSupport/ContextMenuClientGtk.cpp \
243 WebKit/gtk/WebCoreSupport/DragClientGtk.cpp \
244 WebKit/gtk/WebCoreSupport/EditorClientGtk.cpp \
245 WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp \
246 WebKit/gtk/WebCoreSupport/InspectorClientGtk.cpp \
247 WebKit/gtk/WebCoreSupport/PasteboardHelperGtk.cpp
248
249webkitgtk_cleanfiles += \
250 $(top_builddir)/Programs/GtkLauncher \
251 $(top_builddir)/WebKit/gtk/WebKitGtk.pc
252
253pkgconfigdir = $(libdir)/pkgconfig
254pkgconfig_DATA = WebKit/gtk/WebKitGtk.pc
255
256WEBKIT_MARSHAL = $(CURDIR)/WebKit/gtk/WebView/webkit-marshal
257WEBKIT_MARSHAL_LIST = $(srcdir)/WebKit/gtk/WebView/webkit-marshal.list
258
259stamp_files := \
260 stamp-webkit-marshal.cpp \
261 stamp-webkit-marshal.h
262
263WebKit/gtk/WebView/webkit-marshal.cpp: stamp-webkit-marshal.cpp
264 @true
265
266WebKit/gtk/WebView/webkit-marshal.h: stamp-webkit-marshal.h
267 @true
268
269stamp-webkit-marshal.cpp: $(WEBKIT_MARSHAL_LIST)
270 echo "extern \"C\" {" > $(WEBKIT_MARSHAL).cpp && \
271 $(GLIB_GENMARSHAL) --prefix=webkit_marshal $(WEBKIT_MARSHAL_LIST) --body >> $(WEBKIT_MARSHAL).cpp && echo '}' >> $(WEBKIT_MARSHAL).cpp && \
272 echo timestamp > $(@F)
273
274stamp-webkit-marshal.h: $(WEBKIT_MARSHAL_LIST)
275 $(GLIB_GENMARSHAL) --prefix=webkit_marshal $(WEBKIT_MARSHAL_LIST) --header > $(WEBKIT_MARSHAL).h && \
276 echo timestamp > $(@F)
277
278# END WEBKIT GTK+
279
280# Files that will be cleaned
281MAINTAINERCLEANFILES := $(stamp_files) $(BUILT_SOURCES)
282DISTCLEANFILES := $(stamp_files) $(BUILT_SOURCES)
283CLEANFILES := $(stamp_files) $(BUILT_SOURCES)
284
285# Include module makefiles
286include JavaScriptCore/GNUmakefile.am
287include WebCore/GNUmakefile.am
288include WebKitTools/GNUmakefile.am
289
290
291# Autogenerated sources
292BUILT_SOURCES := \
293 $(javascriptcore_built_sources) \
294 $(javascriptcore_built_nosources) \
295 $(webcore_built_sources) \
296 $(webcore_built_nosources) \
297 $(webkitgtk_built_sources) \
298 $(webkitgtk_built_nosources)
299
300# Project-wide clean rules
301CLEANFILES += \
302 $(webkitgtk_cleanfiles) \
303 $(top_builddir)/Programs/DumpRenderTree \
304 $(top_builddir)/Programs/testkjs \
305 $(top_builddir)/Programs/dftables \
306 $(GENSOURCES)
307
308MAINTAINERCLEANFILES += \
309 $(srcdir)/aconfig.h.in \
310 configure \
311 config.* \
312 GNUmakefile.in \
313 INSTALL \
314 README
diff --git a/meta/packages/webkit/files/WebKit.pri b/meta/packages/webkit/files/WebKit.pri
index 514023de57..640fa34174 100644
--- a/meta/packages/webkit/files/WebKit.pri
+++ b/meta/packages/webkit/files/WebKit.pri
@@ -11,12 +11,47 @@ qt-port:DEFINES += BUILDING_QT__=1
11qt-port:!building-libs { 11qt-port:!building-libs {
12 QMAKE_LIBDIR = $$OUTPUT_DIR/lib $$QMAKE_LIBDIR 12 QMAKE_LIBDIR = $$OUTPUT_DIR/lib $$QMAKE_LIBDIR
13 LIBS += -lQtWebKit 13 LIBS += -lQtWebKit
14 DEPENDPATH += $$PWD/WebKit/qt/Api
15}
16
17gtk-port:!building-libs {
18 QMAKE_LIBDIR = $$OUTPUT_DIR/lib $$QMAKE_LIBDIR
19 LIBS += -lWebKitGtk
20 DEPENDPATH += $$PWD/WebKit/gtk/WebView $$PWD/WebKit/gtk/WebCoreSupport
21}
22
23gtk-port {
24 CONFIG += link_pkgconfig
25
26 DEFINES += BUILDING_CAIRO__=1 BUILDING_GTK__=1
27
28 # We use FreeType directly with Cairo
29 PKGCONFIG += cairo-ft
30
31 directfb: PKGCONFIG += cairo-directfb gtk+-directfb-2.0
32 else: PKGCONFIG += cairo gtk+-2.0
33
34 # Set a CONFIG flag for the GTK+ target (x11, quartz, win32, directfb)
35 CONFIG += $$system(pkg-config --variable=target $$PKGCONFIG)
36
37 # We use the curl http backend on all platforms
38 PKGCONFIG += libcurl
39
40 LIBS += -lWebKitGtk -ljpeg -lpng
41
42 QMAKE_CXXFLAGS += $$system(icu-config --cppflags)
43 QMAKE_LIBS += $$system(icu-config --ldflags)
44
45 # This set of warnings is borrowed from the Mac build
46 QMAKE_CXXFLAGS += -Wall -W -Wcast-align -Wchar-subscripts -Wformat-security -Wmissing-format-attribute -Wpointer-arith -Wwrite-strings -Wno-format-y2k -Wno-unused-parameter -Wundef
47
48 # These flags are based on optimization experience from the Mac port:
49 # Helps code size significantly and speed a little
50 QMAKE_CXXFLAGS += -fno-exceptions -fno-rtti
51
52 DEPENDPATH += $$PWD/JavaScriptCore/API
53 INCLUDEPATH += $$PWD
14} 54}
15gtk-port:CONFIG += link_pkgconfig
16gtk-port:PKGCONFIG += cairo cairo-ft gdk-2.0 gtk+-2.0 libcurl
17gtk-port:DEFINES += BUILDING_GTK__=1 BUILDING_CAIRO__
18gtk-port:LIBS += -L$$OUTPUT_DIR/lib -lWebKitGtk $$system(icu-config --ldflags) -ljpeg -lpng
19gtk-port:QMAKE_CXXFLAGS += $$system(icu-config --cppflags)
20 55
21DEFINES += USE_SYSTEM_MALLOC 56DEFINES += USE_SYSTEM_MALLOC
22CONFIG(release) { 57CONFIG(release) {
@@ -32,11 +67,8 @@ gtk-port:INCLUDEPATH += \
32 $$BASE_DIR/WebCore/platform/graphics/cairo \ 67 $$BASE_DIR/WebCore/platform/graphics/cairo \
33 $$BASE_DIR/WebCore/loader/gtk \ 68 $$BASE_DIR/WebCore/loader/gtk \
34 $$BASE_DIR/WebCore/page/gtk \ 69 $$BASE_DIR/WebCore/page/gtk \
35 $$BASE_DIR/WebKit/gtk/Api \
36 $$BASE_DIR/WebKit/gtk/WebView \ 70 $$BASE_DIR/WebKit/gtk/WebView \
37 $$BASE_DIR/WebKit/gtk/WebCoreSupport \ 71 $$BASE_DIR/WebKit/gtk/WebCoreSupport
38 $$BASE_DIR/JavaScriptCore/ForwardingHeaders \
39 $$BASE_DIR
40INCLUDEPATH += \ 72INCLUDEPATH += \
41 $$BASE_DIR/JavaScriptCore/ \ 73 $$BASE_DIR/JavaScriptCore/ \
42 $$BASE_DIR/JavaScriptCore/kjs \ 74 $$BASE_DIR/JavaScriptCore/kjs \
diff --git a/meta/packages/webkit/files/WebKit.pro b/meta/packages/webkit/files/WebKit.pro
index aab0209a93..027017bd8d 100644
--- a/meta/packages/webkit/files/WebKit.pro
+++ b/meta/packages/webkit/files/WebKit.pro
@@ -3,9 +3,15 @@ CONFIG += ordered
3!gtk-port:CONFIG += qt-port 3!gtk-port:CONFIG += qt-port
4qt-port:!win32-*:SUBDIRS += WebKit/qt/Plugins 4qt-port:!win32-*:SUBDIRS += WebKit/qt/Plugins
5SUBDIRS += \ 5SUBDIRS += \
6 WebCore 6 WebCore \
7 JavaScriptCore/kjs/testkjs.pro
8
9qt-port {
10 SUBDIRS += WebKit/qt/QtLauncher
11
12 !win32-*: SUBDIRS += WebKitTools/DumpRenderTree/qt/DumpRenderTree.pro
13}
7 14
8qt-port:SUBDIRS += \
9 WebKit/qt/QtLauncher
10gtk-port:SUBDIRS += \ 15gtk-port:SUBDIRS += \
11 WebKitTools/GtkLauncher 16 WebKitTools/GtkLauncher \
17 WebKitTools/DumpRenderTree/gtk/DumpRenderTree.pro
diff --git a/meta/packages/webkit/files/autogen.sh b/meta/packages/webkit/files/autogen.sh
new file mode 100644
index 0000000000..b7f7d37b2f
--- /dev/null
+++ b/meta/packages/webkit/files/autogen.sh
@@ -0,0 +1,40 @@
1#! /bin/sh
2
3srcdir=`dirname $0`
4test -z "$srcdir" && srcdir=.
5
6cd $srcdir
7
8DIE=0
9
10(autoconf --version) < /dev/null > /dev/null 2>&1 || {
11 echo
12 echo "You must have autoconf installed to compile $PROJECT."
13 echo "Install the appropriate package for your distribution,"
14 echo "or get the source tarball at http://ftp.gnu.org/gnu/autoconf/"
15 DIE=1
16}
17
18(automake --version) < /dev/null > /dev/null 2>&1 || {
19 echo
20 echo "You must have automake installed to compile $PROJECT."
21 echo "Install the appropriate package for your distribution,"
22 echo "or get the source tarball at http://ftp.gnu.org/gnu/automake/"
23 DIE=1
24}
25
26if test "$DIE" -eq 1; then
27 exit 1
28fi
29
30rm -rf $top_srcdir/autom4te.cache
31
32touch README INSTALL
33
34aclocal || exit $?
35libtoolize --force || exit $?
36autoheader || exit $?
37automake --foreign --add-missing || exit $?
38autoconf || exit $?
39
40./configure $AUTOGEN_CONFIGURE_ARGS "$@" || exit $?
diff --git a/meta/packages/webkit/files/configure.ac b/meta/packages/webkit/files/configure.ac
new file mode 100644
index 0000000000..05c25b94a8
--- /dev/null
+++ b/meta/packages/webkit/files/configure.ac
@@ -0,0 +1,384 @@
1AC_INIT([WebKit],[0.1],[http://bugs.webkit.org/])
2
3AC_PREREQ(2.59)
4
5AC_CONFIG_HEADERS([aconfig.h])
6AC_CONFIG_SRCDIR([WebCore/config.h])
7
8# see http://www.gnu.org/software/libtool/manual.html#Versioning
9LIBWEBKITGTK_VERSION=1:0:0
10AC_SUBST([LIBWEBKITGTK_VERSION])
11
12AM_INIT_AUTOMAKE([1.9 foreign tar-ustar subdir-objects])
13
14AM_MAINTAINER_MODE
15
16AC_CANONICAL_HOST
17
18# host checking - inspired by the GTK+ configure.in
19# TODO: os_mac, os_bsd
20AC_MSG_CHECKING([for native Win32])
21case "$host" in
22 *-*-mingw*)
23 os_win32=yes
24 ;;
25 *)
26 os_win32=no
27 ;;
28esac
29AC_MSG_RESULT([$os_win32])
30
31case "$host" in
32 *-*-linux*)
33 os_linux=yes
34 ;;
35 *-*-freebsd*)
36 os_freebsd=yes
37 ;;
38esac
39
40# If CXXFLAGS and CFLAGS are unset, default to -O2
41# This is to tell automake not to include '-g' if CXXFLAGS is not set
42# For more info - http://www.gnu.org/software/automake/manual/autoconf.html#C_002b_002b-Compiler
43if test -z "$CXXFLAGS"; then
44 CXXFLAGS="-O2"
45fi
46if test -z "$CFLAGS"; then
47 CFLAGS="-O2"
48fi
49
50# programs
51AC_DISABLE_STATIC
52AM_PROG_LIBTOOL
53AC_PROG_INSTALL
54AM_PROG_CC_STDC
55AC_PROG_CXX
56AC_PROG_CXX_C_O
57AM_PROG_CC_C_O
58
59AC_PATH_PROG(PERL, perl)
60if test -z "$PERL"; then
61 AC_MSG_ERROR([You need 'perl' to compile WebKit])
62fi
63
64AC_PATH_PROG(BISON, bison)
65if test -z "$BISON"; then
66 AC_MSG_ERROR([You need the 'bison' parser generator to compile WebKit])
67fi
68
69AC_PATH_PROG(FLEX, flex)
70if test -z "$FLEX"; then
71 AC_MSG_ERROR([You need the 'flex' lexer generator to compile WebKit])
72fi
73
74AC_PATH_PROG(GPERF, gperf)
75if test -z "$GPERF"; then
76 AC_MSG_ERROR([You need the 'gperf' hash function generator to compile WebKit])
77fi
78
79AC_PATH_PROG(MV, mv)
80if test -z "$MV"; then
81 AC_MSG_ERROR([You need 'mv' to compile WebKit])
82fi
83
84# GTK+ port only
85# Check for glib-genmarshal and glib-mkenums
86AC_PATH_PROG([GLIB_GENMARSHAL], [glib-genmarshal])
87AC_PATH_PROG([GLIB_MKENUMS],[glib-mkenums])
88
89# Check whether a C++ was found (AC_PROG_CXX sets $CXX to "g++" even when it
90# doesn't exist)
91AC_LANG_PUSH([C++])
92AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],[],[AC_MSG_ERROR([No C++ compiler found])])
93AC_LANG_POP([C++])
94
95# C/C++ Language Features
96AC_C_CONST
97AC_C_INLINE
98AC_C_VOLATILE
99
100# C/C++ Headers
101AC_HEADER_STDC
102AC_HEADER_STDBOOL
103
104# pthread
105AC_CHECK_HEADERS([pthread.h],
106 AC_DEFINE([HAVE_PTHREAD_H],[1],[Define if pthread exist]),
107 AC_MSG_ERROR([pthread support is required to build WebKit]))
108
109# libjpeg headers
110AC_CHECK_HEADERS([jpeglib.h])
111
112# check for pkg-config
113AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
114if test "$PKG_CONFIG" = "no"; then
115 AC_MSG_ERROR([Cannot find pkg-config, make sure it is installed in your PATH])
116fi
117
118# check for icu-config
119AC_PATH_PROG(icu_config, icu-config, no)
120if test "$icu_config" = "no"; then
121 AC_MSG_ERROR([Cannot find icu-config. ICU library is needed.])
122fi
123ICU_CFLAGS=`$icu_config --cflags`
124ICU_LIBS=`$icu_config --ldflags`
125AC_SUBST([ICU_CFLAGS])
126AC_SUBST([ICU_LIBS])
127
128# determine the GDK/GTK+ target
129AC_MSG_CHECKING([the target for WebKit GTK+])
130AC_ARG_WITH(webkit_target,
131 AC_HELP_STRING([--with-webkit-target=@<:@x11/win32/quartz/directfb@:>@],
132 [Select webkit target [default=x11]]),
133 [],[with_webkit_target="x11"])
134
135case "$with_webkit_target" in
136 x11|win32|quartz|directfb) ;;
137 *) AC_MSG_ERROR([Invalid target: must be x11, quartz, win32, or directfb.]) ;;
138esac
139
140AC_MSG_RESULT([$with_webkit_target])
141
142# minimum base dependencies
143GLIB_REQUIRED_VERSION=2.0
144GOBJECT_REQUIRED_VERSION=2.0
145GTHREAD_REQUIRED_VERSION=2.0
146PANGO_REQUIRED_VERSION=1.0
147CAIRO_REQUIRED_VERSION=1.2
148FONTCONFIG_REQUIRED_VERSION=2.4
149FREETYPE2_REQUIRED_VERSION=9.0
150LIBCURL_REQUIRED_VERSION=7.15
151LIBXML_REQUIRED_VERSION=2.6
152
153# optional modules
154GTK_REQUIRED_VERSION=2.0
155LIBXSLT_REQUIRED_VERSION=1.1.7
156SQLITE_REQUIRED_VERSION=3.0
157GSTREAMER_REQUIRED_VERSION=0.10
158GNOME_VFS_REQUIRED_VERSION=2.0
159
160PKG_CHECK_MODULES([DEPENDENCIES],
161 [glib-2.0 >= $GLIB_REQUIRED_VERSION
162 gobject-2.0 >= $GOBJECT_REQUIRED_VERSION
163 gthread-2.0 >= $GTHREAD_REQUIRED_VERSION
164 gtk+-2.0 >= $GTK_REQUIRED_VERSION
165 pango >= $PANGO_REQUIRED_VERSION
166 libcurl >= $LIBCURL_REQUIRED_VERSION
167 cairo >= $CAIRO_REQUIRED_VERSION
168 cairo-ft,
169 fontconfig >= $FONTCONFIG_REQUIRED_VERSION
170 freetype2 >= $FREETYPE2_REQUIRED_VERSION
171 libxml-2.0 >= $LIBXML_REQUIRED_VERSION])
172AC_SUBST([DEPENDENCIES_CFLAGS])
173AC_SUBST([DEPENDENCIES_LIBS])
174
175# check whether to build with debugging enabled
176AC_MSG_CHECKING([whether to do a debug build])
177AC_ARG_ENABLE(debug,
178 AC_HELP_STRING([--enable-debug],
179 [turn on debugging [default=no]]),
180 [enable_debug="yes"],[enable_debug="no"])
181AC_MSG_RESULT([$enable_debug])
182
183# check whether to build with database support
184AC_MSG_CHECKING([whether to enable HTML5 client-side storage support])
185AC_ARG_ENABLE(database,
186 AC_HELP_STRING([--enable-database],
187 [enable HTML5 client-side storage support [default=no]]),
188 [],[enable_database="yes"])
189AC_MSG_RESULT([$enable_database])
190
191# check whether to build with icon database support
192AC_MSG_CHECKING([whether to enable icon database support])
193AC_ARG_ENABLE(icon_database,
194 AC_HELP_STRING([--enable-icon-database],
195 [enable icon database [default=no]]),
196 [],[enable_icon_database="no"])
197AC_MSG_RESULT([$enable_icon_database])
198
199# check whether to enable HTML5 audio/video support
200AC_MSG_CHECKING([whether to enable HTML5 video support])
201AC_ARG_ENABLE(video,
202 AC_HELP_STRING([--enable-video],
203 [enable HTML5 video support [default=no]]),
204 [enable_video="yes"],[enable_video="no"])
205AC_MSG_RESULT([$enable_video])
206
207# check whether to enable XPath support
208AC_MSG_CHECKING([whether to enable XPath support])
209AC_ARG_ENABLE(xpath,
210 AC_HELP_STRING([--enable-xpath],
211 [enable support for XPath [default=no]]),
212 [],[enable_xpath="yes"])
213AC_MSG_RESULT([$enable_xpath])
214
215# check whether to enable XSLT support
216AC_MSG_CHECKING([whether to enable XSLT support])
217AC_ARG_ENABLE(xslt,
218 AC_HELP_STRING([--enable-xslt],
219 [enable support for XSLT [default=no]]),
220 [],[enable_xslt="yes"])
221AC_MSG_RESULT([$enable_xslt])
222
223# check whether to enable SVG support
224AC_MSG_CHECKING([whether to enable SVG support])
225AC_ARG_ENABLE(svg,
226 AC_HELP_STRING([--enable-svg],
227 [enable support for SVG [default=no]]),
228 [],[enable_svg="no"])
229AC_MSG_RESULT([$enable_svg])
230
231# check whether to enable support for SVG animation
232AC_MSG_CHECKING([whether to enable support for SVG animataion])
233AC_ARG_ENABLE(svg_animation,
234 AC_HELP_STRING([--enable-svg-animation],
235 [enable support for SVG animation feature (experimental) [default=no]]),
236 [],[enable_svg_animation="no"])
237AC_MSG_RESULT([$enable_svg_animation])
238
239# check whether to enable support for SVG filters
240AC_MSG_CHECKING([whether to enable support for SVG filters])
241AC_ARG_ENABLE(svg_filters,
242 AC_HELP_STRING([--enable-svg-filters],
243 [enable support for SVG filters (experimental) [default=no]]),
244 [],[enable_svg_filters="no"])
245AC_MSG_RESULT([$enable_svg_filters])
246
247# check whether to enable support for SVG fonts
248AC_MSG_CHECKING([whether to enable support for SVG fonts])
249AC_ARG_ENABLE(svg_fonts,
250 AC_HELP_STRING([--enable-svg-fonts],
251 [enable support for SVG fonts (experimental) [default=no]]),
252 [],[enable_svg_fonts="no"])
253AC_MSG_RESULT([$enable_svg_fonts])
254
255# check whether to enable SVG As Image support
256AC_MSG_CHECKING([whether to enable SVG as Image support])
257AC_ARG_ENABLE(svg_as_image,
258 AC_HELP_STRING([--enable-svg-as-image],
259 [enable SVG as Image support (experimental) [default=no]]),
260 [],[enable_svg_as_image="no"])
261AC_MSG_RESULT([$enable_svg_as_image])
262
263# check whether to enable SVG USE element support
264AC_MSG_CHECKING([whether to enable support for SVG use element])
265AC_ARG_ENABLE(svg_use_element,
266 AC_HELP_STRING([--enable-svg-use-element],
267 [enable SVG use element support (experimental) [default=no]]),
268 [],[enable_svg_use_element="no"])
269AC_MSG_RESULT([$enable_svg_use_element])
270
271# check whether to enable code coverage
272AC_MSG_CHECKING([whether to enable code coverage support])
273AC_ARG_ENABLE(coverage,
274 AC_HELP_STRING([--enable-coverage],
275 [enable code coverage support [default=no]]),
276 [],[enable_coverage="no"])
277AC_MSG_RESULT([$enable_coverage])
278
279# Add '-g' flag to gcc if it's debug build
280if test "$enable_debug" = "yes"; then
281 CXXFLAGS="$CXXFLAGS -g"
282 CFLAGS="$CFLAGS -g"
283fi
284
285# check if sqlite 3 is available
286if test "$enable_icon_database" = "yes" || test "$enable_database" = "yes"; then
287 PKG_CHECK_MODULES([SQLITE3], [sqlite3 >= $SQLITE_REQUIRED_VERSION])
288 AC_SUBST([SQLITE3_CFLAGS])
289 AC_SUBST([SQLITE3_LIBS])
290fi
291
292# check if libxslt is available
293if test "$enable_xslt" = "yes"; then
294 PKG_CHECK_MODULES([LIBXSLT],[libxslt >= $LIBXSLT_REQUIRED_VERSION])
295 AC_SUBST([LIBXSLT_CFLAGS])
296 AC_SUBST([LIBXSLT_LIBS])
297fi
298
299# check if gstreamer is available
300if test "$enable_video" = "yes"; then
301 PKG_CHECK_MODULES([GSTREAMER],
302 [gstreamer-0.10 >= $GSTREAMER_REQUIRED_VERSION
303 gstreamer-base-0.10,
304 gstreamer-plugins-base-0.10,
305 gnome-vfs-2.0 >= $GNOME_VFS_REQUIRED_VERSION])
306 AC_SUBST([GSTREAMER_CFLAGS])
307 AC_SUBST([GSTREAMER_LIBS])
308fi
309
310# check for code coverage support
311if test "$enable_coverage" = "yes"; then
312 COVERAGE_CFLAGS="-MD"
313 COVERAGE_LDFLAGS="-ftest-coverage -fprofile-arcs"
314 AC_SUBST([COVERAGE_CFLAGS])
315 AC_SUBST([COVERAGE_LDFLAGS])
316fi
317
318# check for SVG features, enabling SVG if necessary
319if test "$enable_svg" = "no" && (\
320 test "$enable_svg_animation" = "yes" || \
321 test "$enable_svg_filters" = "yes" || \
322 test "$enable_svg_fonts" = "yes" || \
323 test "$enable_svg_as_image" = "yes" || \
324 test "$enable_svg_use_element" = "yes"); then
325
326 AC_MSG_WARN([SVG feature(s) requested but SVG is disabled.. Enabling SVG support])
327 enable_svg = yes
328 svg_flags = yes
329fi
330
331# OS conditionals
332AM_CONDITIONAL([OS_WIN32],[test "$os_win32" = "yes"])
333AM_CONDITIONAL([OS_UNIX],[test "$os_win32" = "no"])
334AM_CONDITIONAL([OS_LINUX],[test "$os_linux" = "yes"])
335AM_CONDITIONAL([OS_FREEBSD],[test "$os_freebsd" = "yes"])
336
337# target conditionals
338AM_CONDITIONAL([TARGET_X11], [test "$with_webkit_target" = "x11"])
339AM_CONDITIONAL([TARGET_WIN32], [test "$with_webkit_target" = "win32"])
340AM_CONDITIONAL([TARGET_QUARTZ], [test "$with_webkit_target" = "quartz"])
341AM_CONDITIONAL([TARGET_DIRECTFB], [test "$with_webkit_target" = "directfb"])
342
343# WebKit feature conditionals
344AM_CONDITIONAL([ENABLE_DEBUG],[test "$enable_debug" = "yes"])
345AM_CONDITIONAL([ENABLE_DATABASE],[test "$enable_database" = "yes"])
346AM_CONDITIONAL([ENABLE_ICONDATABASE],[test "$enable_icon_database" = "yes"])
347AM_CONDITIONAL([ENABLE_XPATH],[test "$enable_xpath" = "yes"])
348AM_CONDITIONAL([ENABLE_XSLT],[test "$enable_xslt" = "yes"])
349AM_CONDITIONAL([ENABLE_VIDEO],[test "$enable_video" = "yes"])
350AM_CONDITIONAL([ENABLE_SVG],[test "$enable_svg" = "yes"])
351AM_CONDITIONAL([ENABLE_SVG_ANIMATION],[test "$enable_svg_animation" = "yes"])
352AM_CONDITIONAL([ENABLE_SVG_FILTERS],[test "$enable_svg_filters" = "yes"])
353AM_CONDITIONAL([ENABLE_SVG_FONTS],[test "$enable_svg_fonts" = "yes"])
354AM_CONDITIONAL([ENABLE_SVG_AS_IMAGE],[test "$enable_svg_as_image" = "yes"])
355AM_CONDITIONAL([ENABLE_SVG_USE],[test "$enable_svg_use_element" = "yes"])
356AM_CONDITIONAL([ENABLE_COVERAGE],[test "$enable_coverage" = "yes"])
357AM_CONDITIONAL([SVG_FLAGS],[test "$svg_flags" = "yes"])
358
359AC_CONFIG_FILES([
360GNUmakefile
361WebKit/gtk/WebKitGtk.pc:WebKit/gtk/WebKitGtk.pc.in
362]
363)
364
365AC_OUTPUT
366
367echo "
368WebKit was configured with the following options:
369
370 Target : $with_webkit_target
371 Enable debug : $enable_debug
372 Code coverage support : $enable_coverage
373 HTML5 client-side storage support : $enable_database
374 HTML5 video element support : $enable_video
375 Icon database support : $enable_icon_database
376 SVG support : $enable_svg
377 SVG animation support : $enable_svg_animation
378 SVG filters support : $enable_svg_filters
379 SVG fonts support : $enable_svg_fonts
380 SVG as image support : $enable_svg_as_image
381 SVG use element support : $enable_svg_use_element
382 XPATH support : $enable_xpath
383 XSLT support : $enable_xslt
384"
diff --git a/meta/packages/webkit/webkit-gtk_svn.bb b/meta/packages/webkit/webkit-gtk_svn.bb
index 262c6820db..6a99a96001 100644
--- a/meta/packages/webkit/webkit-gtk_svn.bb
+++ b/meta/packages/webkit/webkit-gtk_svn.bb
@@ -1,15 +1,23 @@
1DEPENDS = "curl icu libxml2 cairo libxslt libidn gnutls gtk+" 1DEPENDS = "curl icu libxml2 cairo libxslt libidn gnutls gtk+"
2 2
3# If you activate HTML5 media support (ENABLE_VIDEO=1) you'll need:
4# DEPENDS += " gstreamer gst-plugins-base gnome-vfs "
5
3 6
4WEBKIT_PORT = "gtk-port" 7WEBKIT_PORT = "gtk-port"
5WEBKIT_EXTRA_OPTIONS = "CONFIG-=qt" 8WEBKIT_EXTRA_OPTIONS = "CONFIG-=qt"
6 9
7FILES_webkit-gtklauncher = "${bindir}/GtkLauncher" 10FILES_webkit-gtklauncher = "${bindir}/GtkLauncher"
8FILES_webkit-gtklauncher-dbg = "${bindir}/.debug/GtkLauncher" 11FILES_webkit-gtklauncher-dbg += "${bindir}/.debug/GtkLauncher"
9 12
10require webkit.inc 13require webkit.inc
11 14
12PR = "r3" 15SRC_URI += "file://autogen.sh \
16 file://configure.ac \
17 file://GNUmakefile.am \
18 "
19
20PR = "r4"
13 21
14do_install() { 22do_install() {
15 install -d ${D}${bindir} 23 install -d ${D}${bindir}
diff --git a/meta/packages/webkit/webkit.inc b/meta/packages/webkit/webkit.inc
index 81c2d91bf8..e7820409a2 100644
--- a/meta/packages/webkit/webkit.inc
+++ b/meta/packages/webkit/webkit.inc
@@ -6,7 +6,7 @@ PACKAGES =+ "${PN}launcher-dbg ${PN}launcher"
6# Yes, this is wrong... 6# Yes, this is wrong...
7PV = "0.1+svnr${SRCREV}" 7PV = "0.1+svnr${SRCREV}"
8 8
9inherit qmake2 pkgconfig 9inherit qmake2
10 10
11SRC_URI = "\ 11SRC_URI = "\
12 svn://svn.webkit.org/repository/webkit/trunk/;module=JavaScriptCore;proto=http \ 12 svn://svn.webkit.org/repository/webkit/trunk/;module=JavaScriptCore;proto=http \
@@ -51,5 +51,7 @@ do_stage() {
51 cd ${S}/WebKitBuilds/Debug 51 cd ${S}/WebKitBuilds/Debug
52 PWD=`pwd` ${WEBKIT_QMAKE} WEBKIT_INC_DIR=${STAGING_INCDIR} WEBKIT_LIB_DIR=${STAGING_LIBDIR} $PWD/../../WebKit.pro 52 PWD=`pwd` ${WEBKIT_QMAKE} WEBKIT_INC_DIR=${STAGING_INCDIR} WEBKIT_LIB_DIR=${STAGING_LIBDIR} $PWD/../../WebKit.pro
53 oe_runmake install 53 oe_runmake install
54
55#sed -i -e "s:${WORKDIR}/image/::g" ${PKG_CONFIG_DIR}/WebKitGtk.pc
54} 56}
55 57