summaryrefslogtreecommitdiff
path: root/deps/gyp/test/linux
diff options
context:
space:
mode:
Diffstat (limited to 'deps/gyp/test/linux')
-rw-r--r--deps/gyp/test/linux/gyptest-implicit-rpath.py48
-rw-r--r--deps/gyp/test/linux/gyptest-ldflags-duplicates.py22
-rw-r--r--deps/gyp/test/linux/implicit-rpath/file.c1
-rw-r--r--deps/gyp/test/linux/implicit-rpath/main.c1
-rw-r--r--deps/gyp/test/linux/implicit-rpath/test.gyp47
-rwxr-xr-xdeps/gyp/test/linux/ldflags-duplicates/check-ldflags.py25
-rw-r--r--deps/gyp/test/linux/ldflags-duplicates/lib1.c6
-rw-r--r--deps/gyp/test/linux/ldflags-duplicates/lib2.c6
-rw-r--r--deps/gyp/test/linux/ldflags-duplicates/main.c7
-rw-r--r--deps/gyp/test/linux/ldflags-duplicates/test.gyp45
10 files changed, 0 insertions, 208 deletions
diff --git a/deps/gyp/test/linux/gyptest-implicit-rpath.py b/deps/gyp/test/linux/gyptest-implicit-rpath.py
deleted file mode 100644
index dd7718c76d..0000000000
--- a/deps/gyp/test/linux/gyptest-implicit-rpath.py
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2013 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.
-
-"""
-Verifies that the implicit rpath is added only when needed.
-"""
-
-import TestGyp
-
-import re
-import subprocess
-import sys
-
-if sys.platform.startswith('linux'):
- test = TestGyp.TestGyp(formats=['ninja', 'make'])
-
- CHDIR = 'implicit-rpath'
- test.run_gyp('test.gyp', chdir=CHDIR)
- test.build('test.gyp', test.ALL, chdir=CHDIR)
-
- def GetRpaths(p):
- p = test.built_file_path(p, chdir=CHDIR)
- r = re.compile(r'Library rpath: \[([^\]]+)\]')
- proc = subprocess.Popen(['readelf', '-d', p], stdout=subprocess.PIPE)
- o = proc.communicate()[0]
- assert not proc.returncode
- return r.findall(o)
-
- if test.format == 'ninja':
- expect = '$ORIGIN/lib/'
- elif test.format == 'make':
- expect = '$ORIGIN/lib.target/'
- else:
- test.fail_test()
-
- if GetRpaths('shared_executable') != [expect]:
- test.fail_test()
-
- if GetRpaths('shared_executable_no_so_suffix') != [expect]:
- test.fail_test()
-
- if GetRpaths('static_executable'):
- test.fail_test()
-
- test.pass_test()
diff --git a/deps/gyp/test/linux/gyptest-ldflags-duplicates.py b/deps/gyp/test/linux/gyptest-ldflags-duplicates.py
deleted file mode 100644
index 43a4607adf..0000000000
--- a/deps/gyp/test/linux/gyptest-ldflags-duplicates.py
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/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.
-
-"""
-Verifies duplicate ldflags are not removed.
-"""
-
-import TestGyp
-
-import sys
-
-if sys.platform.startswith('linux'):
- test = TestGyp.TestGyp()
-
- CHDIR = 'ldflags-duplicates'
- test.run_gyp('test.gyp', chdir=CHDIR)
- test.build('test.gyp', chdir=CHDIR)
-
- test.pass_test()
diff --git a/deps/gyp/test/linux/implicit-rpath/file.c b/deps/gyp/test/linux/implicit-rpath/file.c
deleted file mode 100644
index 56757a701b..0000000000
--- a/deps/gyp/test/linux/implicit-rpath/file.c
+++ /dev/null
@@ -1 +0,0 @@
-void f() {}
diff --git a/deps/gyp/test/linux/implicit-rpath/main.c b/deps/gyp/test/linux/implicit-rpath/main.c
deleted file mode 100644
index 237c8ce181..0000000000
--- a/deps/gyp/test/linux/implicit-rpath/main.c
+++ /dev/null
@@ -1 +0,0 @@
-int main() {}
diff --git a/deps/gyp/test/linux/implicit-rpath/test.gyp b/deps/gyp/test/linux/implicit-rpath/test.gyp
deleted file mode 100644
index b546106986..0000000000
--- a/deps/gyp/test/linux/implicit-rpath/test.gyp
+++ /dev/null
@@ -1,47 +0,0 @@
-# Copyright (c) 2013 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': 'shared',
- 'type': 'shared_library',
- 'sources': [ 'file.c' ],
- },
- {
- 'target_name': 'shared_no_so_suffix',
- 'product_extension': 'so.0.1',
- 'type': 'shared_library',
- 'sources': [ 'file.c' ],
- },
- {
- 'target_name': 'static',
- 'type': 'static_library',
- 'sources': [ 'file.c' ],
- },
- {
- 'target_name': 'shared_executable',
- 'type': 'executable',
- 'sources': [ 'main.c' ],
- 'dependencies': [
- 'shared',
- ]
- },
- {
- 'target_name': 'shared_executable_no_so_suffix',
- 'type': 'executable',
- 'sources': [ 'main.c' ],
- 'dependencies': [
- 'shared_no_so_suffix',
- ]
- },
- {
- 'target_name': 'static_executable',
- 'type': 'executable',
- 'sources': [ 'main.c' ],
- 'dependencies': [
- 'static',
- ]
- },
- ],
-}
diff --git a/deps/gyp/test/linux/ldflags-duplicates/check-ldflags.py b/deps/gyp/test/linux/ldflags-duplicates/check-ldflags.py
deleted file mode 100755
index 0515da95e4..0000000000
--- a/deps/gyp/test/linux/ldflags-duplicates/check-ldflags.py
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/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.
-
-"""
-Verifies duplicate ldflags are not removed.
-"""
-
-import sys
-
-def CheckContainsFlags(args, substring):
- if args.find(substring) is -1:
- print 'ERROR: Linker arguments "%s" are missing in "%s"' % (substring, args)
- return False;
- return True;
-
-if __name__ == '__main__':
- args = " ".join(sys.argv)
- print "args = " +args
- if not CheckContainsFlags(args, 'lib1.a -Wl,--no-whole-archive') \
- or not CheckContainsFlags(args, 'lib2.a -Wl,--no-whole-archive'):
- sys.exit(1);
- sys.exit(0)
diff --git a/deps/gyp/test/linux/ldflags-duplicates/lib1.c b/deps/gyp/test/linux/ldflags-duplicates/lib1.c
deleted file mode 100644
index a1322e7395..0000000000
--- a/deps/gyp/test/linux/ldflags-duplicates/lib1.c
+++ /dev/null
@@ -1,6 +0,0 @@
-// 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.
-
-void foo() {
-}
diff --git a/deps/gyp/test/linux/ldflags-duplicates/lib2.c b/deps/gyp/test/linux/ldflags-duplicates/lib2.c
deleted file mode 100644
index 8e7a082820..0000000000
--- a/deps/gyp/test/linux/ldflags-duplicates/lib2.c
+++ /dev/null
@@ -1,6 +0,0 @@
-// 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.
-
-void bar() {
-}
diff --git a/deps/gyp/test/linux/ldflags-duplicates/main.c b/deps/gyp/test/linux/ldflags-duplicates/main.c
deleted file mode 100644
index b3039ace96..0000000000
--- a/deps/gyp/test/linux/ldflags-duplicates/main.c
+++ /dev/null
@@ -1,7 +0,0 @@
-// 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.
-
-int main() {
- return 0;
-}
diff --git a/deps/gyp/test/linux/ldflags-duplicates/test.gyp b/deps/gyp/test/linux/ldflags-duplicates/test.gyp
deleted file mode 100644
index c36835b18f..0000000000
--- a/deps/gyp/test/linux/ldflags-duplicates/test.gyp
+++ /dev/null
@@ -1,45 +0,0 @@
-# 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.
-
-{
- 'make_global_settings': [
- ['LINK_wrapper', './check-ldflags.py'],
- ],
- 'targets': [
- {
- 'target_name': 'test',
- 'type': 'executable',
- 'ldflags': [
- '-Wl,--whole-archive <(PRODUCT_DIR)/lib1.a',
- '-Wl,--no-whole-archive',
-
- '-Wl,--whole-archive <(PRODUCT_DIR)/lib2.a',
- '-Wl,--no-whole-archive',
- ],
- 'dependencies': [
- 'lib1',
- 'lib2',
- ],
- 'sources': [
- 'main.c',
- ],
- },
- {
- 'target_name': 'lib1',
- 'type': 'static_library',
- 'standalone_static_library': 1,
- 'sources': [
- 'lib1.c',
- ],
- },
- {
- 'target_name': 'lib2',
- 'type': 'static_library',
- 'standalone_static_library': 1,
- 'sources': [
- 'lib2.c',
- ],
- },
- ],
-}