Remove .pdb file on Visual Studio 2013? - visual-studio

When I compile a .sln file with Visual Studio 2013 a .pdb file is generated. How can I disable the creation of the .pdb file?

I found it.
Project -> Properties -> Build
Last category there is Output, click the Advanced button and the Debug info should be none.

In Project Properties see "Configuration Properties -> Linker -> Debugging -> Generate Debug Info".
Also see:
PDB Files - What are they and how to generate them
.net - Release generating .pdb files, why?
Those are relevant to Visual Studio 2013 also. Be sure to read the stackoverflow thread since it has important information.

Related

How to compile a VB6 program with extra debugging information?

How to compile a VB6 program with extra debugging information (PDB file / symbols)?
If I just choose "Make DLL" from the File menu, no PDB file is created.
From https://support.smartbear.com/viewarticle/2357/
Compiling Microsoft Visual Basic 6.0 Applications With Debug Information
This topic explains how to compile Microsoft Visual Basic 6.0
applications with debug information...
Visual Basic may include debug information in the executable file, or
add debug info to an external PDB file. ...if you compile a release
version of your product, it is recommended to generate debug
information as an external file. This will decrease the overall size
of your executable.
To specify the way in which debug information will be generated, use
the Link environment variable. If this variable is not defined, Visual
Basic will generate an external PDB file. Else, the compiler will
include the debug information in the executable. For more information
on this, see Visual Basic documentation.
To compile your Visual Basic application ... follow these steps:
If you compile a release version of your product, make certain that the Link environment variable is not defined. If this
environment variable exists, Visual Basic will embed debug information
in the executable and thus the overall size of your application will
increase.
Open your project in Microsoft Visual Basic.
Select Project | Project Properties from Visual Basic’s main menu. This will open the Project Properties dialog.
Move to the Compile tabbed page and select the Create Symbolic Debug Info check box:
Press OK to close the dialog.
Recompile your application.
There is no need to ship the generated PDB files along with your
application.

How to load OpenCV's PDB debug files for debugging OpenCV source codes

I compiled OpenCV and I have PDB file for both debug and release mode.
I can program and run OpenCV's APIs, but I can't debug into OpenCV's source files using F11.
I need to link to those pdb files. I did the followings, but still have the problems.
(1)Tools > Options > Debugging > Symbols > Check Microsoft Symbols Server
(2)In the same dialog, at Cache symbols in this directory, I link to D:\OpenCV_Lib_2.4.6\Win64\bin\Debug, where pdb files are there.
(3)Set D:\OpenCV_Lib_2.4.6\Win64\bin\Debug and D:\OpenCV_Lib_2.4.6\Win64\bin\Release to Environment Path.
What else I still need to do to have debugging into OpenCV's sources.
I use Visual Studio 2010.
Thanks
I solved the problem. The first step, all library files must have their pdb files in the same folder where library files are located. Secondly, in the VC++ project setting Configuration properties -> C/C++ -> optimization -> Disable. If it is selected for maximize speed, will have problem. Finally, Configuration properties -> Linker -> Debugging -> Generate debug info -> YES. Then problem is solved.

Force visual studio to have same include directories between debug and release mode

I was wondering if there is a way to synchronize settings for include and link directories between debug and release configurations for project/solution?
More precisely, is there any way to tell visual studio I would like project properties
C/C++ - > General -> "Additional Include Directories"
Linker -> General -> "Additional Library Directories"
Linker -> Input -> "Additional Dependencies"
to be same for debug and release configuration, or somehow efficiently/automatically forward those settings from one configuration to the other configurations? Perhaps there is any plugin/script for that, since it is only necessary to change few lines in project text file to do what I want?
I'm currently using visual studio 2005, but I think this feature should not depend too much on version of the studio, so please post answers/solutions for any version of visual studio.
Use property sheets: create a property sheet containing the common properties, then include it in each build configuration. Do everything via the Property Manager window; be careful now: any change you want to make to the common properties must be made in the property sheet, not in the project properties!

How to indicate to Visual studio where third party dll source code is?

I am writing a C++/CLI for a C library. I have the source code of the library. When I launch a debug session, I can't step into the C dll, VS says that the source code is not available. So how do I tell VS where it is?
Thank you... I've tried pointing Tools -> Options -> Debugging -> Symbols to add the folder where the pdb is but it changed nothing.
Regards
SOLVED:
Turns out I needed to copy the dll and .pdb files to the Debug folder of my C# project calling the C++/CLI dll.

Visual Studio cannot find CPPUNIT debugging database

I am using Visual Studio 2008 with CPPUNIT. I already compiled CPPUNIT and added the CPPUNIT path to Include and Library path. Currently, I can compile my program with CPPUNIT library.
However, the linker generates the following warning:
Warning 2 warning LNK4099: PDB 'vc90.pdb' was not found with
'C:\Program Files\cppunit\cppunit-1.12.1\lib\cppunitd.lib' or at
'c:\Users\hide1713\Desktop\3d_tank\cpp_pj\bin\vc90.pdb'; linking
object as if no debug info cppunitd.lib GameUnitTest
There's a cppunitd_dll.pdb file along with cppunitd.lib. How do I tell the linker where to find the CPPUNIT debug database?
Thanks all.
In your CppUnit project, be sure you have your compiler emitting a program database file that's compatible with your main project. In the CppUnit project properties window, under the Config properties / C++ / General tree, you'll see the Debug Information Format box. Select "Program Database /Zi" or whatever value exactly matches the same setting on your main project. You'll then have to recompile them both, of course.

Resources