summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--webkit/appcache/webkit_appcache.gypi7
-rw-r--r--webkit/database/webkit_database.gypi7
-rw-r--r--webkit/glue/webkit_glue.gypi5
-rw-r--r--webkit/support/list_headers.py23
-rw-r--r--webkit/support/setup_third_party.gyp56
5 files changed, 98 insertions, 0 deletions
diff --git a/webkit/appcache/webkit_appcache.gypi b/webkit/appcache/webkit_appcache.gypi
index e28d9d5..61400af 100644
--- a/webkit/appcache/webkit_appcache.gypi
+++ b/webkit/appcache/webkit_appcache.gypi
@@ -59,6 +59,13 @@
'web_application_cache_host_impl.cc',
'web_application_cache_host_impl.h',
],
+ 'conditions': [
+ ['inside_chromium_build==0', {
+ 'dependencies': [
+ '<(DEPTH)/webkit/support/setup_third_party.gyp:third_party_headers',
+ ],
+ }],
+ ],
},
],
}
diff --git a/webkit/database/webkit_database.gypi b/webkit/database/webkit_database.gypi
index 4936a14..83ecf6b 100644
--- a/webkit/database/webkit_database.gypi
+++ b/webkit/database/webkit_database.gypi
@@ -27,6 +27,13 @@
'vfs_backend.cc',
'vfs_backend.h',
],
+ 'conditions': [
+ ['inside_chromium_build==0', {
+ 'dependencies': [
+ '<(DEPTH)/webkit/support/setup_third_party.gyp:third_party_headers',
+ ],
+ }],
+ ],
},
],
}
diff --git a/webkit/glue/webkit_glue.gypi b/webkit/glue/webkit_glue.gypi
index 6d510b7..c8f3725 100644
--- a/webkit/glue/webkit_glue.gypi
+++ b/webkit/glue/webkit_glue.gypi
@@ -344,6 +344,11 @@
'plugins/plugin_stubs.cc',
],
}],
+ ['inside_chromium_build==0', {
+ 'dependencies': [
+ '<(DEPTH)/webkit/support/setup_third_party.gyp:third_party_headers',
+ ],
+ }],
],
},
],
diff --git a/webkit/support/list_headers.py b/webkit/support/list_headers.py
new file mode 100644
index 0000000..c7397b5
--- /dev/null
+++ b/webkit/support/list_headers.py
@@ -0,0 +1,23 @@
+#!/usr/bin/python
+# Copyright (c) 2010 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+"""A helper script that lists the header files in the passed in argument.
+This is used by gyp to get a list of header files to copy."""
+
+import os
+import sys
+
+def main(argv):
+ if len(argv) != 2:
+ print 'USAGE: %s <dir>'
+ return 1
+
+ for filename in os.listdir(argv[1]):
+ if filename.endswith('.h'):
+ print os.path.join(argv[1], filename)
+ return 0
+
+if __name__ == '__main__':
+ sys.exit(main(sys.argv))
diff --git a/webkit/support/setup_third_party.gyp b/webkit/support/setup_third_party.gyp
new file mode 100644
index 0000000..3b39db2
--- /dev/null
+++ b/webkit/support/setup_third_party.gyp
@@ -0,0 +1,56 @@
+# Copyright (c) 2010 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+{
+ 'variables': {
+ 'list_headers_cmd': ['python', 'list_headers.py'],
+ 'destination': '<(DEPTH)/third_party/WebKit/WebKit/chromium/public',
+ },
+ 'targets': [
+ {
+ # TODO(tony): Would be nice if this would make symlinks on linux/mac
+ # and try to make hardlinks on ntfs.
+ 'target_name': 'third_party_headers',
+ 'type': 'none',
+ 'copies': [
+ {
+ 'destination': '<(destination)',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public)',
+ ],
+ },
+ {
+ 'destination': '<(destination)/gtk',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public/gtk)',
+ ],
+ },
+ {
+ 'destination': '<(destination)/linux',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public/linux)',
+ ],
+ },
+ {
+ 'destination': '<(destination)/mac',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public/mac)',
+ ],
+ },
+ {
+ 'destination': '<(destination)/win',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public/win)',
+ ],
+ },
+ {
+ 'destination': '<(destination)/x11',
+ 'files': [
+ '<!@(<(list_headers_cmd) <(DEPTH)/public/x11)',
+ ],
+ },
+ ]
+ },
+ ],
+}