<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Setting Breakpoints Dependent on Microsoft Compiler Environment"
href="https://bugs.llvm.org/show_bug.cgi?id=46158">46158</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Setting Breakpoints Dependent on Microsoft Compiler Environment
</td>
</tr>
<tr>
<th>Product</th>
<td>lldb
</td>
</tr>
<tr>
<th>Version</th>
<td>10.0
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Windows 2000
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>All Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>lldb-dev@lists.llvm.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>info@zeusedit.com
</td>
</tr>
<tr>
<th>CC</th>
<td>jdevlieghere@apple.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>This is more of a question than a bug report.
In playing with LLDB on a Windows 10 I struggled to get the breakpoints to
work.
Eventually I stumbled across the cause of the issue, which is described in the
steps below:
1. Open command line prompt:
Microsoft Windows [Version 10.0.18363.836]
(c) 2019 Microsoft Corporation. All rights reserved.
2. Run LLDB on a debug 'test.exe' but as shown below the breakpoints fail to
set:
C:\Tutorial\c++>lldb.exe test.exe
(lldb) target create "test.exe"
Current executable set to 'C:\Tutorial\c++\test.exe' (i686).
(lldb) b 7
error: No selected frame to use to find the default file.
error: No file supplied and no default file available.
(lldb) exit
3. The command prompt used was not configured to run the Microsoft compiler:
C:\Tutorial\c++>cl.exe
'cl.exe' is not recognized as an internal or external command, operable
program or batch file.
4. I then setup the command prompt to run the Microsoft compiler using their
standard batch file:
C:\Tutorial\c++>"C:\Program Files (x86)\Microsoft Visual
Studio\2019\Community\Common7\Tools\VsDevCmd.bat"
**********************************************************************
** Visual Studio 2019 Developer Command Prompt v16.6.0
** Copyright (c) 2020 Microsoft Corporation
**********************************************************************
5. With the command prompt configured for the Microsoft compiler:
C:\Tutorial\c++>cl.exe
Microsoft (R) C/C++ Optimizing Compiler Version 19.26.28805 for x86
Copyright (C) Microsoft Corporation. All rights reserved.
6. Now the LLDB breakpoints work as expected:
C:\Tutorial\c++>lldb.exe test.exe
(lldb) target create "test.exe"
Current executable set to 'C:\Tutorial\c++\test.exe' (i686).
(lldb) b 7
Breakpoint 1: where = test.exe`_main + 87 at test.cpp:7, address =
0x0040b527
(lldb) exit
So it seems the LLDB is somehow dependent of the Microsoft compiler environment
setup. Is this correct?
If so what is the actual dependency?
Cheers Jussi</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>