<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Justin,<br>
<br>
/MD means link for the C/C++ release, runtime dlls (msvc... dlls
etc). /MDd means link for the C/C++ debug, runtime dll (msvc...d
dlls). /MT means link the C/C++ release, runtime static library
(libc.... libs etc). /MTd means link the C/C++ debug, runtime
static library (libc...d libs). <br>
<br>
If the notes say release is /MT and debug is /MD, that's linking
static release libraries on a release build, and dynamic release
dlls on a debug build. That's a bit unusual, and won't always work
well on a debug build, depending on how exceptions or errors are
handled.<br>
<br>
It's generally not a good idea to mix debug and release runtimes,
and sometimes you can get weird link errors mixing static lib and
dll runtimes, so use only /MT or only /MD everywhere for release,
and only /MTd or only /MDd everywhere for debug. You can't control
what third parties do with their code though. I generally do /MD or
/MDd for the runtimes, because the dll is only loaded once, no
matter how many times it's linked to from anyone's library.<br>
<br>
Damien<br>
<br>
On 21/09/2010 9:56 AM, Vallon, Justin wrote:
<blockquote
cite="mid:ED121D68651D774A99B1E5E569D1CA3E01698DA4@NYCMBX3.winmail.deshaw.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft Word 12 (filtered
medium)">
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Arial","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
-->
</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";">The wiki
<a class="moz-txt-link-freetext" href="https://projects.coin-or.org/Ipopt/wiki/CompilationHints">https://projects.coin-or.org/Ipopt/wiki/CompilationHints</a>
... Windows VS2008 ...
General Notes says that release binaries are built with
/MT and debug are built
with /MD.<o:p></o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";"><o:p> </o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";">For debug C++
code, shouldn’t I be
using /MDd or /MTd in my application? Can I mix my /MTd
or /MDd code with
Ipopt /MD?<o:p></o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";"><o:p> </o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";">I looked at the
win32/debug/Ipopt.dll, and I
don’t see a dependency on any VS DLLs. Maybe debug is
/MTd?<o:p></o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";"><o:p> </o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";">-- </span></font><o:p></o:p></p>
<p class="MsoNormal"><font size="2" face="Arial"><span
style="font-size: 10pt; font-family:
"Arial","sans-serif";">-Justin<o:p></o:p></span></font></p>
<p class="MsoNormal"><font size="2" face="Calibri"><span
style="font-size: 11pt;"><o:p> </o:p></span></font></p>
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Ipopt mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Ipopt@list.coin-or.org">Ipopt@list.coin-or.org</a>
<a class="moz-txt-link-freetext" href="http://list.coin-or.org/mailman/listinfo/ipopt">http://list.coin-or.org/mailman/listinfo/ipopt</a>
</pre>
</blockquote>
</body>
</html>