summaryrefslogtreecommitdiffstats
path: root/third_party/python/gyp/test/win/uldi
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/python/gyp/test/win/uldi')
-rw-r--r--third_party/python/gyp/test/win/uldi/a.cc7
-rw-r--r--third_party/python/gyp/test/win/uldi/b.cc7
-rw-r--r--third_party/python/gyp/test/win/uldi/dll.cc6
-rw-r--r--third_party/python/gyp/test/win/uldi/exe.cc7
-rw-r--r--third_party/python/gyp/test/win/uldi/main.cc10
-rw-r--r--third_party/python/gyp/test/win/uldi/uldi-depending-on-module.gyp42
-rw-r--r--third_party/python/gyp/test/win/uldi/uldi.gyp45
7 files changed, 124 insertions, 0 deletions
diff --git a/third_party/python/gyp/test/win/uldi/a.cc b/third_party/python/gyp/test/win/uldi/a.cc
new file mode 100644
index 0000000000..0fe05d5afb
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/a.cc
@@ -0,0 +1,7 @@
+// Copyright (c) 2012 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 some_function() {
+ return 0;
+}
diff --git a/third_party/python/gyp/test/win/uldi/b.cc b/third_party/python/gyp/test/win/uldi/b.cc
new file mode 100644
index 0000000000..0fe05d5afb
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/b.cc
@@ -0,0 +1,7 @@
+// Copyright (c) 2012 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 some_function() {
+ return 0;
+}
diff --git a/third_party/python/gyp/test/win/uldi/dll.cc b/third_party/python/gyp/test/win/uldi/dll.cc
new file mode 100644
index 0000000000..93a6c19003
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/dll.cc
@@ -0,0 +1,6 @@
+// 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.
+
+__declspec(dllexport) void SomeFunction() {
+}
diff --git a/third_party/python/gyp/test/win/uldi/exe.cc b/third_party/python/gyp/test/win/uldi/exe.cc
new file mode 100644
index 0000000000..b3039ace96
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/exe.cc
@@ -0,0 +1,7 @@
+// 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/third_party/python/gyp/test/win/uldi/main.cc b/third_party/python/gyp/test/win/uldi/main.cc
new file mode 100644
index 0000000000..81b46d863a
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/main.cc
@@ -0,0 +1,10 @@
+// Copyright (c) 2012 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.
+
+extern int some_function();
+
+int main() {
+ some_function();
+ return 0;
+}
diff --git a/third_party/python/gyp/test/win/uldi/uldi-depending-on-module.gyp b/third_party/python/gyp/test/win/uldi/uldi-depending-on-module.gyp
new file mode 100644
index 0000000000..3e34de8418
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/uldi-depending-on-module.gyp
@@ -0,0 +1,42 @@
+# 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': 'an_exe',
+ 'type': 'executable',
+ 'sources': ['exe.cc'],
+ 'dependencies': [
+ 'a_dll',
+ ],
+ },
+ {
+ 'target_name': 'a_dll',
+ 'type': 'shared_library',
+ 'sources': ['dll.cc'],
+ 'dependencies': [
+ 'a_lib',
+ ],
+ 'msvs_settings': {
+ 'VCLinkerTool': {
+ 'UseLibraryDependencyInputs': 'true'
+ },
+ },
+ },
+ {
+ 'target_name': 'a_lib',
+ 'type': 'static_library',
+ 'dependencies': [
+ 'a_module',
+ ],
+ 'sources': ['a.cc'],
+ },
+ {
+ 'target_name': 'a_module',
+ 'type': 'loadable_module',
+ 'sources': ['a.cc'],
+ },
+ ]
+}
diff --git a/third_party/python/gyp/test/win/uldi/uldi.gyp b/third_party/python/gyp/test/win/uldi/uldi.gyp
new file mode 100644
index 0000000000..c32f5e0956
--- /dev/null
+++ b/third_party/python/gyp/test/win/uldi/uldi.gyp
@@ -0,0 +1,45 @@
+# Copyright (c) 2012 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': 'lib1',
+ 'type': 'static_library',
+ 'sources': ['a.cc'],
+ },
+ {
+ 'target_name': 'final_uldi',
+ 'type': 'executable',
+ 'dependencies': [
+ 'lib1',
+ 'lib2',
+ ],
+ 'msvs_settings': {
+ 'VCLinkerTool': {
+ 'UseLibraryDependencyInputs': 'true'
+ },
+ },
+ 'sources': ['main.cc'],
+ },
+ {
+ 'target_name': 'final_no_uldi',
+ 'type': 'executable',
+ 'dependencies': [
+ 'lib1',
+ 'lib2',
+ ],
+ 'sources': ['main.cc'],
+ },
+ {
+ 'target_name': 'lib2',
+ 'type': 'static_library',
+ # b.cc has the same named function as a.cc, but don't use the same name
+ # so that the .obj will have a different name. If the obj file has the
+ # same name, the linker will discard the obj file, invalidating the
+ # test.
+ 'sources': ['b.cc'],
+ },
+ ]
+}