From 5f8de423f190bbb79a62f804151bc24824fa32d8 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 2 Feb 2018 04:16:08 -0500 Subject: Add m-esr52 at 52.6.0 --- .../src/action.gyp | 28 ++++++++++++++++++++++ .../src/rcopy.py | 20 ++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/action.gyp create mode 100644 media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/rcopy.py (limited to 'media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src') diff --git a/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/action.gyp b/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/action.gyp new file mode 100644 index 000000000..a305d65ea --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/action.gyp @@ -0,0 +1,28 @@ +# Copyright (c) 2015 Google Inc. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +{ + 'targets': [ + { + 'target_name': 'upper', + 'type': 'none', + 'actions': [{ + 'action_name': 'upper_action', + 'inputs': ['<(PRODUCT_DIR)/out2.txt'], + 'outputs': ['<(PRODUCT_DIR)/result.txt'], + 'action': ['python', 'rcopy.py', '<@(_inputs)', '<@(_outputs)'], + }], + }, + { + 'target_name': 'lower', + 'type': 'none', + 'actions': [{ + 'action_name': 'lower_action', + 'inputs': ['input.txt'], + 'outputs': ['<(PRODUCT_DIR)/out1.txt', '<(PRODUCT_DIR)/out2.txt'], + 'action': ['python', 'rcopy.py', '<@(_inputs)', '<@(_outputs)'], + }], + }, + ], +} diff --git a/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/rcopy.py b/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/rcopy.py new file mode 100644 index 000000000..fb029598c --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/actions-multiple-outputs-with-dependencies/src/rcopy.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python +# +# Copyright (c) 2015 Google Inc. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +import os +import sys + +"""A slightly odd 'cp' implementation for this test. + +This 'cp' can have many targets, but only one source. 'cp src dest1 dest2' +will copy the file 'src' to both 'dest1' and 'dest2'.""" + +with open(sys.argv[1], 'r') as f: + src = f.read() +for dest in sys.argv[2:]: + with open(dest, 'w') as f: + f.write(src) + -- cgit v1.2.3