diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /media/webrtc/trunk/tools/gyp/test/multiple-targets | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'media/webrtc/trunk/tools/gyp/test/multiple-targets')
6 files changed, 111 insertions, 0 deletions
diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-all.py b/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-all.py new file mode 100755 index 000000000..3ef50090d --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-all.py @@ -0,0 +1,30 @@ +#!/usr/bin/env python + +# Copyright (c) 2009 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 TestGyp + +test = TestGyp.TestGyp() + +test.run_gyp('multiple.gyp', chdir='src') + +test.relocate('src', 'relocate/src') + +test.build('multiple.gyp', test.ALL, chdir='relocate/src', stderr=None) + +expect1 = """\ +hello from prog1.c +hello from common.c +""" + +expect2 = """\ +hello from prog2.c +hello from common.c +""" + +test.run_built_executable('prog1', stdout=expect1, chdir='relocate/src') +test.run_built_executable('prog2', stdout=expect2, chdir='relocate/src') + +test.pass_test() diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-default.py b/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-default.py new file mode 100755 index 000000000..db15d794c --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/gyptest-default.py @@ -0,0 +1,30 @@ +#!/usr/bin/env python + +# Copyright (c) 2009 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 TestGyp + +test = TestGyp.TestGyp() + +test.run_gyp('multiple.gyp', chdir='src') + +test.relocate('src', 'relocate/src') + +test.build('multiple.gyp', chdir='relocate/src') + +expect1 = """\ +hello from prog1.c +hello from common.c +""" + +expect2 = """\ +hello from prog2.c +hello from common.c +""" + +test.run_built_executable('prog1', stdout=expect1, chdir='relocate/src') +test.run_built_executable('prog2', stdout=expect2, chdir='relocate/src') + +test.pass_test() diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/common.c b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/common.c new file mode 100644 index 000000000..f1df7c143 --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/common.c @@ -0,0 +1,7 @@ +#include <stdio.h> + +void common(void) +{ + printf("hello from common.c\n"); + return; +} diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/multiple.gyp b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/multiple.gyp new file mode 100644 index 000000000..3db4ea30c --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/multiple.gyp @@ -0,0 +1,24 @@ +# Copyright (c) 2009 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': 'prog1', + 'type': 'executable', + 'sources': [ + 'prog1.c', + 'common.c', + ], + }, + { + 'target_name': 'prog2', + 'type': 'executable', + 'sources': [ + 'prog2.c', + 'common.c', + ], + }, + ], +} diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog1.c b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog1.c new file mode 100644 index 000000000..fbf8d4cd7 --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog1.c @@ -0,0 +1,10 @@ +#include <stdio.h> + +extern void common(void); + +int main(void) +{ + printf("hello from prog1.c\n"); + common(); + return 0; +} diff --git a/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog2.c b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog2.c new file mode 100644 index 000000000..a94b5c155 --- /dev/null +++ b/media/webrtc/trunk/tools/gyp/test/multiple-targets/src/prog2.c @@ -0,0 +1,10 @@ +#include <stdio.h> + +extern void common(void); + +int main(void) +{ + printf("hello from prog2.c\n"); + common(); + return 0; +} |