| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2013 The Chromium Authors. All rights reserved. | 2 # Copyright 2013 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 """ | 6 """ |
| 7 Replaces gyp files in tree with files from here that | 7 Replaces gyp files in tree with files from here that |
| 8 make the build use system libraries. | 8 make the build use system libraries. |
| 9 """ | 9 """ |
| 10 | 10 |
| 11 | 11 |
| 12 import optparse | 12 import optparse |
| 13 import os.path | 13 import os.path |
| 14 import shutil | 14 import shutil |
| 15 import sys | 15 import sys |
| 16 | 16 |
| 17 | 17 |
| 18 REPLACEMENTS = { | 18 REPLACEMENTS = { |
| 19 'use_system_expat': 'third_party/expat/expat.gyp', | 19 'use_system_expat': 'third_party/expat/expat.gyp', |
| 20 'use_system_ffmpeg': 'third_party/ffmpeg/ffmpeg.gyp', | 20 'use_system_ffmpeg': 'third_party/ffmpeg/ffmpeg.gyp', |
| 21 'use_system_flac': 'third_party/flac/flac.gyp', | 21 'use_system_flac': 'third_party/flac/flac.gyp', |
| 22 'use_system_harfbuzz': 'third_party/harfbuzz-ng/harfbuzz.gyp', | 22 'use_system_harfbuzz': 'third_party/harfbuzz-ng/harfbuzz.gyp', |
| 23 'use_system_icu': 'third_party/icu/icu.gyp', | 23 'use_system_icu': 'third_party/icu/icu.gyp', |
| 24 'use_system_jsoncpp': 'third_party/jsoncpp/jsoncpp.gyp', | 24 'use_system_jsoncpp': 'third_party/jsoncpp/jsoncpp.gyp', |
| 25 'use_system_libevent': 'base/third_party/libevent/libevent.gyp', | 25 'use_system_libevent': 'base/third_party/libevent/libevent.gyp', |
| 26 'use_system_libjpeg': 'third_party/libjpeg/libjpeg.gyp', | 26 'use_system_libjpeg': 'third_party/libjpeg/libjpeg.gyp', |
| 27 'use_system_libpng': 'third_party/libpng/libpng.gyp', | 27 'use_system_libpng': 'third_party/libpng/libpng.gyp', |
| 28 'use_system_libusb': 'third_party/libusb/libusb.gyp', | 28 'use_system_libusb': 'third_party/libusb/libusb.gyp', |
| 29 'use_system_libvpx': 'third_party/libvpx_new/libvpx.gyp', | 29 'use_system_libvpx': 'third_party/libvpx/libvpx.gyp', |
| 30 'use_system_libwebp': 'third_party/libwebp/libwebp.gyp', | 30 'use_system_libwebp': 'third_party/libwebp/libwebp.gyp', |
| 31 'use_system_libxml': 'third_party/libxml/libxml.gyp', | 31 'use_system_libxml': 'third_party/libxml/libxml.gyp', |
| 32 'use_system_libxnvctrl' : 'third_party/libXNVCtrl/libXNVCtrl.gyp', | 32 'use_system_libxnvctrl' : 'third_party/libXNVCtrl/libXNVCtrl.gyp', |
| 33 'use_system_libxslt': 'third_party/libxslt/libxslt.gyp', | 33 'use_system_libxslt': 'third_party/libxslt/libxslt.gyp', |
| 34 'use_system_opus': 'third_party/opus/opus.gyp', | 34 'use_system_opus': 'third_party/opus/opus.gyp', |
| 35 'use_system_protobuf': 'third_party/protobuf/protobuf.gyp', | 35 'use_system_protobuf': 'third_party/protobuf/protobuf.gyp', |
| 36 'use_system_re2': 'third_party/re2/re2.gyp', | 36 'use_system_re2': 'third_party/re2/re2.gyp', |
| 37 'use_system_snappy': 'third_party/snappy/snappy.gyp', | 37 'use_system_snappy': 'third_party/snappy/snappy.gyp', |
| 38 'use_system_sqlite': 'third_party/sqlite/sqlite.gyp', | 38 'use_system_sqlite': 'third_party/sqlite/sqlite.gyp', |
| 39 'use_system_v8': 'v8/tools/gyp/v8.gyp', | 39 'use_system_v8': 'v8/tools/gyp/v8.gyp', |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 | 72 |
| 73 # Copy the gyp file from directory of this script to target path. | 73 # Copy the gyp file from directory of this script to target path. |
| 74 shutil.copyfile(os.path.join(my_dirname, os.path.basename(path)), | 74 shutil.copyfile(os.path.join(my_dirname, os.path.basename(path)), |
| 75 os.path.join(source_tree_root, path)) | 75 os.path.join(source_tree_root, path)) |
| 76 | 76 |
| 77 return 0 | 77 return 0 |
| 78 | 78 |
| 79 | 79 |
| 80 if __name__ == '__main__': | 80 if __name__ == '__main__': |
| 81 sys.exit(DoMain(sys.argv)) | 81 sys.exit(DoMain(sys.argv)) |
| OLD | NEW |