aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
authorGravatar Yun Peng <pcloudy@google.com>2016-06-30 15:42:57 +0000
committerGravatar Lukacs Berki <lberki@google.com>2016-07-01 07:09:44 +0000
commit7e9358786a756fd8362b9577e94946235114b182 (patch)
tree5e8b730e5b931a49e6d00dd7d7760122d9f75532 /tools
parent7128b02078eab0904624c2f970adaa082eb08984 (diff)
Remove hacks of building dll from msvc_link.py
-- Change-Id: I53ec66581c59d4bba8460fb3e5d20258ea36d0f1 Reviewed-on: https://bazel-review.googlesource.com/#/c/3940 MOS_MIGRATED_REVID=126306276
Diffstat (limited to 'tools')
-rw-r--r--tools/cpp/wrapper/bin/pydir/msvc_link.py15
1 files changed, 2 insertions, 13 deletions
diff --git a/tools/cpp/wrapper/bin/pydir/msvc_link.py b/tools/cpp/wrapper/bin/pydir/msvc_link.py
index 95f1315652..8436f5fbef 100644
--- a/tools/cpp/wrapper/bin/pydir/msvc_link.py
+++ b/tools/cpp/wrapper/bin/pydir/msvc_link.py
@@ -15,7 +15,6 @@
"""Wrapper script for executing the Microsoft Linker."""
import os
-import shutil
import sys
import msvc_tools
@@ -70,15 +69,9 @@ class MsvcLinker(msvc_tools.WindowsRunner):
# Find the output file name.
name = ''
- self.output_dll_file = None
for arg in parser.options:
if '/OUT:' in arg:
name = arg[5:]
- # if output file ends with .so, we generate dll library.
- if name.endswith('.so'):
- default_args.append('/DLL')
- self.output_dll_file = os.path.normpath(name[0:-3])
- break
if not name:
raise msvc_tools.Error('No output file name specified!')
# Check if the library is empty, which is what happens when we create header
@@ -123,12 +116,8 @@ class MsvcLinker(msvc_tools.WindowsRunner):
else:
default_args.insert(0, 'libcmt.lib')
- ret_code = self.RunBinary(tool, default_args + parser.options,
- parser.target_arch, parser)
- if not ret_code and self.output_dll_file:
- shutil.copyfile(self.output_dll_file + '.so',
- self.output_dll_file + '.dll')
- return ret_code
+ return self.RunBinary(tool, default_args + parser.options,
+ parser.target_arch, parser)
def main(argv):