summaryrefslogtreecommitdiffstats
path: root/third_party
diff options
context:
space:
mode:
Diffstat (limited to 'third_party')
-rw-r--r--third_party/cython/cp_python_binary_modules.py46
-rw-r--r--third_party/cython/cython_compiler.gypi7
-rw-r--r--third_party/cython/python_module.gypi22
3 files changed, 0 insertions, 75 deletions
diff --git a/third_party/cython/cp_python_binary_modules.py b/third_party/cython/cp_python_binary_modules.py
deleted file mode 100644
index cd7505b..0000000
--- a/third_party/cython/cp_python_binary_modules.py
+++ /dev/null
@@ -1,46 +0,0 @@
-# Copyright 2014 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.
-
-import argparse
-import os
-import shutil
-import sys
-
-def touch(fname):
- if os.path.exists(fname):
- os.utime(fname, None)
- else:
- open(fname, 'a').close()
-
-def main():
- """Command line utility to copy python binary modules to the correct package
- hierarchy.
- """
- parser = argparse.ArgumentParser(
- description='Copy python binary modules to the correct package '
- 'hierarchy.')
- parser.add_argument('timestamp', help='The timetsamp file.')
- parser.add_argument('lib_dir', help='The directory containing the modules')
- parser.add_argument('destination_dir',
- help='The destination directory of the module')
- parser.add_argument('mappings', nargs='+',
- help='The mapping from module to library.')
- opts = parser.parse_args()
-
- if not os.path.exists(opts.destination_dir):
- try:
- os.makedirs(opts.destination_dir)
- except:
- # Ignore errors on directory creation.
- pass
-
- for mapping in opts.mappings:
- [module, library] = mapping.split('=')
- shutil.copy(os.path.join(opts.lib_dir, library),
- os.path.join(opts.destination_dir, module))
-
- touch(opts.timestamp)
-
-if __name__ == '__main__':
- main()
diff --git a/third_party/cython/cython_compiler.gypi b/third_party/cython/cython_compiler.gypi
index 39d8318..ca974a2 100644
--- a/third_party/cython/cython_compiler.gypi
+++ b/third_party/cython/cython_compiler.gypi
@@ -60,12 +60,5 @@
'library_dirs': [
'<!@(python <(python_flags) --library_dirs)',
],
- 'direct_dependent_settings': {
- 'variables': {
- 'python_binary_modules': [
- '<(python_cython_module)<(module_suffix)=<(module_prefix)<(_target_name)<(module_suffix)',
- ],
- },
- },
'hard_dependency': 1,
}
diff --git a/third_party/cython/python_module.gypi b/third_party/cython/python_module.gypi
index a61ca2d..138c416 100644
--- a/third_party/cython/python_module.gypi
+++ b/third_party/cython/python_module.gypi
@@ -4,10 +4,7 @@
{
'variables': {
- 'python_binary_modules%': [],
'python_module_destination': '<(PRODUCT_DIR)/python/<(python_base_module)',
- 'cp': '<(DEPTH)/third_party/cython/cp_python_binary_modules.py',
- 'timestamp': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)_py_module.stamp',
},
'rules': [
{
@@ -26,25 +23,6 @@
'<@(_outputs)',
],
'message': 'Moving <(RULE_INPUT_PATH) to its destination',
- }
- ],
- 'actions': [
- {
- 'action_name': '<(_target_name)_move_to_python_modules',
- 'inputs': [
- '<(cp)',
- ],
- 'outputs': [
- '<(timestamp)',
- ],
- 'action': [
- 'python',
- '<(cp)',
- '<(timestamp)',
- '<(PRODUCT_DIR)',
- '<(python_module_destination)',
- '>@(python_binary_modules)',
- ],
},
],
'hard_dependency': 1,