Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(457)

Unified Diff: third_party/re2/re2.gyp

Issue 11366051: Linux: add option for building with system re2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: shim headers Created 7 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/re2/re2.gyp
diff --git a/third_party/re2/re2.gyp b/third_party/re2/re2.gyp
index fe11a6513d477d533b4d00472cd1055381cec80a..3c1afbedb3cac53e332b4e258c15483fbccf8b85 100644
--- a/third_party/re2/re2.gyp
+++ b/third_party/re2/re2.gyp
@@ -4,83 +4,113 @@
{
'variables': {
+ 'use_system_re2%': 0,
},
- 'targets': [
- {
- 'target_name': 're2',
- 'type': 'static_library',
- 'include_dirs': [
- '.',
- '<(DEPTH)',
- ],
- 'direct_dependent_settings': {
- 'include_dirs': [
- '.',
- '<(DEPTH)',
- ],
- },
- 'dependencies': [
- '<(DEPTH)/base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
- ],
- 'sources': [
- 're2/bitstate.cc',
- 're2/compile.cc',
- 're2/dfa.cc',
- 're2/filtered_re2.cc',
- 're2/filtered_re2.h',
- 're2/mimics_pcre.cc',
- 're2/nfa.cc',
- 're2/onepass.cc',
- 're2/parse.cc',
- 're2/perl_groups.cc',
- 're2/prefilter.cc',
- 're2/prefilter.h',
- 're2/prefilter_tree.cc',
- 're2/prefilter_tree.h',
- 're2/prog.cc',
- 're2/prog.h',
- 're2/re2.cc',
- 're2/re2.h',
- 're2/regexp.cc',
- 're2/regexp.h',
- 're2/set.cc',
- 're2/set.h',
- 're2/simplify.cc',
- 're2/stringpiece.h',
- 're2/tostring.cc',
- 're2/unicode_casefold.cc',
- 're2/unicode_casefold.h',
- 're2/unicode_groups.cc',
- 're2/unicode_groups.h',
- 're2/variadic_function.h',
- 're2/walker-inl.h',
- 'util/arena.cc',
- 'util/arena.h',
- 'util/atomicops.h',
- 'util/flags.h',
- 'util/hash.cc',
- 'util/logging.h',
- 'util/mutex.h',
- 'util/rune.cc',
- 'util/sparse_array.h',
- 'util/sparse_set.h',
- 'util/stringpiece.cc',
- 'util/stringprintf.cc',
- 'util/strutil.cc',
- 'util/utf.h',
- 'util/util.h',
- ],
- 'conditions': [
- ['OS=="win"', {
+ 'conditions': [
+ ['use_system_re2==0', {
+ 'targets': [
+ {
+ 'target_name': 're2',
+ 'type': 'static_library',
+ 'include_dirs': [
+ '.',
+ '<(DEPTH)',
+ ],
+ 'direct_dependent_settings': {
+ 'include_dirs': [
+ '.',
+ '<(DEPTH)',
+ ],
+ },
+ 'dependencies': [
+ '<(DEPTH)/base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
+ ],
'sources': [
- 'mswin/stdint.h'
+ 're2/bitstate.cc',
+ 're2/compile.cc',
+ 're2/dfa.cc',
+ 're2/filtered_re2.cc',
+ 're2/filtered_re2.h',
+ 're2/mimics_pcre.cc',
+ 're2/nfa.cc',
+ 're2/onepass.cc',
+ 're2/parse.cc',
+ 're2/perl_groups.cc',
+ 're2/prefilter.cc',
+ 're2/prefilter.h',
+ 're2/prefilter_tree.cc',
+ 're2/prefilter_tree.h',
+ 're2/prog.cc',
+ 're2/prog.h',
+ 're2/re2.cc',
+ 're2/re2.h',
+ 're2/regexp.cc',
+ 're2/regexp.h',
+ 're2/set.cc',
+ 're2/set.h',
+ 're2/simplify.cc',
+ 're2/stringpiece.h',
+ 're2/tostring.cc',
+ 're2/unicode_casefold.cc',
+ 're2/unicode_casefold.h',
+ 're2/unicode_groups.cc',
+ 're2/unicode_groups.h',
+ 're2/variadic_function.h',
+ 're2/walker-inl.h',
+ 'util/arena.cc',
+ 'util/arena.h',
+ 'util/atomicops.h',
+ 'util/flags.h',
+ 'util/hash.cc',
+ 'util/logging.h',
+ 'util/mutex.h',
+ 'util/rune.cc',
+ 'util/sparse_array.h',
+ 'util/sparse_set.h',
+ 'util/stringpiece.cc',
+ 'util/stringprintf.cc',
+ 'util/strutil.cc',
+ 'util/utf.h',
+ 'util/util.h',
],
- 'include_dirs': [
- 'mswin'
+ 'conditions': [
+ ['OS=="win"', {
+ 'sources': [
+ 'mswin/stdint.h'
+ ],
+ 'include_dirs': [
+ 'mswin'
+ ],
+ 'msvs_disabled_warnings': [ 4018, 4722 ],
+ }]
+ ]
+ },
+ ],
+ }, { # use_system_re2==1
+ 'targets': [
+ {
+ 'target_name': 're2',
+ 'type': 'none',
+ 'variables': {
+ 'headers_root_path': '.',
+ 'header_filenames': [
+ 're2/filtered_re2.h',
+ 're2/re2.h',
+ 're2/set.h',
+ 're2/stringpiece.h',
+ 're2/variadic_function.h',
Ryan Sleevi 2013/01/03 00:38:35 Can you explain why you do not need to handle prog
Paweł Hajdan Jr. 2013/01/03 01:05:43 This is what re2 snapshot I have installed into /u
+ ],
+ },
+ 'includes': [
+ '../../build/shim_headers.gypi',
],
- 'msvs_disabled_warnings': [ 4018, 4722 ],
- }]
- ]
- },
+ 'link_settings': {
+ 'libraries': [
+ '-lre2',
+ ],
+ },
+ }
+ ],
+ }],
],
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698