summaryrefslogtreecommitdiffstats
path: root/chromium/tools/gyp/test/rules/src
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/tools/gyp/test/rules/src')
-rw-r--r--chromium/tools/gyp/test/rules/src/actions.gyp1
-rw-r--r--chromium/tools/gyp/test/rules/src/special-variables.gyp1
-rw-r--r--chromium/tools/gyp/test/rules/src/subdir2/both_rule_and_action_input.gyp50
3 files changed, 51 insertions, 1 deletions
diff --git a/chromium/tools/gyp/test/rules/src/actions.gyp b/chromium/tools/gyp/test/rules/src/actions.gyp
index 5c0a40b0ce9..84376a71937 100644
--- a/chromium/tools/gyp/test/rules/src/actions.gyp
+++ b/chromium/tools/gyp/test/rules/src/actions.gyp
@@ -9,6 +9,7 @@
'type': 'none',
'dependencies': [
'subdir1/executable.gyp:*',
+ 'subdir2/both_rule_and_action_input.gyp:*',
'subdir2/never_used.gyp:*',
'subdir2/no_inputs.gyp:*',
'subdir2/no_action.gyp:*',
diff --git a/chromium/tools/gyp/test/rules/src/special-variables.gyp b/chromium/tools/gyp/test/rules/src/special-variables.gyp
index fc55665e75b..d1443af5ba0 100644
--- a/chromium/tools/gyp/test/rules/src/special-variables.gyp
+++ b/chromium/tools/gyp/test/rules/src/special-variables.gyp
@@ -13,7 +13,6 @@
'extension': 'S',
'inputs': [
'as.bat',
- '$(InputPath)'
],
'outputs': [
'$(IntDir)/$(InputName).obj',
diff --git a/chromium/tools/gyp/test/rules/src/subdir2/both_rule_and_action_input.gyp b/chromium/tools/gyp/test/rules/src/subdir2/both_rule_and_action_input.gyp
new file mode 100644
index 00000000000..e5e6f3ec2b1
--- /dev/null
+++ b/chromium/tools/gyp/test/rules/src/subdir2/both_rule_and_action_input.gyp
@@ -0,0 +1,50 @@
+# Copyright (c) 2014 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.
+
+# Tests that if a rule input is also an action input, both the rule and action
+# are executed
+{
+ 'targets': [
+ {
+ 'target_name': 'files_both_rule_and_action_input',
+ 'type': 'executable',
+ 'msvs_cygwin_shell': 0,
+ 'sources': [
+ 'program.c',
+ 'file1.in',
+ 'file2.in',
+ ],
+ 'rules': [
+ {
+ 'rule_name': 'copy_file',
+ 'extension': 'in',
+ 'inputs': [
+ '../copy-file.py',
+ ],
+ 'outputs': [
+ '<(RULE_INPUT_ROOT).out4',
+ ],
+ 'action': [
+ 'python', '<(_inputs)', '<(RULE_INPUT_PATH)', '<@(_outputs)',
+ ],
+ },
+ ],
+ 'actions': [
+ {
+ 'action_name': 'copy_file1_in',
+ 'inputs': [
+ '../copy-file.py',
+ 'file1.in',
+ ],
+ 'outputs': [
+ 'file1.copy',
+ ],
+ 'action': [
+ 'python', '<@(_inputs)', '<(_outputs)'
+ ],
+ },
+ ],
+ },
+ ],
+}