<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ObjectARX 2015 debug configuration and boost in ObjectARX Forum</title>
    <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935873#M10569</link>
    <description>&lt;P&gt;Despite of that hack, boost gives me linker errors:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;libboost_signals-vc110-mt-gd-1_52.lib(connection.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(connection.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(trackable.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(trackable.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(slot.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(slot.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(named_slot_map.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(named_slot_map.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(signal_base.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(signal_base.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Creating library ...&lt;BR /&gt;1&amp;gt;LINK : warning LNK4098: defaultlib 'MSVCRTD' conflicts with use of other libs; use /NODEFAULTLIB:library&lt;/P&gt;</description>
    <pubDate>Fri, 04 Dec 2015 10:22:34 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-12-04T10:22:34Z</dc:date>
    <item>
      <title>ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935867#M10568</link>
      <description>&lt;P&gt;Hi, I don't really understand why I shouldn't use _DEBUG preprocessor macro in my debug configuration. Without this, boost gives me errors (auto_link.hpp):&lt;/P&gt;&lt;PRE&gt;//
// error check:
//
#if defined(__MSVC_RUNTIME_CHECKS) &amp;amp;&amp;amp; !defined(_DEBUG)
#  pragma message("Using the /RTC option without specifying a debug runtime will lead to linker errors")
#  pragma message("Hint: go to the code generation options and switch to one of the debugging runtimes")
#  error "Incompatible build options"
#endif&lt;/PRE&gt;&lt;P&gt;So I need to do some hacking like:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;//&amp;lt;-- BOOST HACK!
#ifndef NDEBUG
	#define _DEBUG
#endif
#include &amp;lt;boost/foreach.hpp&amp;gt;
#include &amp;lt;boost/format.hpp&amp;gt;
#include &amp;lt;boost/signals.hpp&amp;gt;
#include &amp;lt;boost/cast.hpp&amp;gt;
#include &amp;lt;boost/algorithm/string.hpp&amp;gt;
#include &amp;lt;boost/shared_ptr.hpp&amp;gt;
#ifdef _DEBUG
	#undef _DEBUG
#endif
//BOOST HACK --&amp;gt;//&lt;/PRE&gt;&lt;P&gt;But I'm afraid that sooner or later something will go wrong. My boost version is 1.52. Anyone can help?&lt;/P&gt;</description>
      <pubDate>Fri, 04 Dec 2015 10:19:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935867#M10568</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-12-04T10:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935873#M10569</link>
      <description>&lt;P&gt;Despite of that hack, boost gives me linker errors:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;libboost_signals-vc110-mt-gd-1_52.lib(connection.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(connection.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(trackable.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(trackable.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(slot.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(slot.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(named_slot_map.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(named_slot_map.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(signal_base.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in AppManager.obj&lt;BR /&gt;1&amp;gt;libboost_signals-vc110-mt-gd-1_52.lib(signal_base.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in AppManager.obj&lt;BR /&gt;1&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Creating library ...&lt;BR /&gt;1&amp;gt;LINK : warning LNK4098: defaultlib 'MSVCRTD' conflicts with use of other libs; use /NODEFAULTLIB:library&lt;/P&gt;</description>
      <pubDate>Fri, 04 Dec 2015 10:22:34 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935873#M10569</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-12-04T10:22:34Z</dc:date>
    </item>
    <item>
      <title>Re: ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935968#M10570</link>
      <description>&lt;P&gt;Using _DEBUG in your project configurations preprocessor defines can cause several DEBUG-libraries to be linked in your module.&lt;/P&gt;&lt;P&gt;As an example look into afx.h:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;		#ifdef _DEBUG
			#pragma comment(lib, "afxnmcdd.lib")
		#else
			#pragma comment(lib, "afxnmcd.lib")
		#endif&lt;/PRE&gt;&lt;P&gt;Since you don't have a Debug-version of AutoCAD you cannot use modules linked with those Debug-Libs!&lt;/P&gt;&lt;P&gt;The common way to get around this is to include all relevant headers in stdafx.h and enclose the includes like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;#if defined (_DEBUG) &amp;amp;&amp;amp; !defined(DEBUG_AUTOCAD)
	#define DEBUG_WAS_DEFINED
	#undef  _DEBUG
#endif

... do all your includes here ...
#include &amp;lt;afx***.h&amp;gt;
#include &amp;lt;boost/smart_ptr/shared_ptr.hpp&amp;gt;

#ifdef DEBUG_WAS_DEFINED
	#define   _DEBUG
#endif&lt;/PRE&gt;</description>
      <pubDate>Fri, 04 Dec 2015 11:49:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5935968#M10570</guid>
      <dc:creator>tbrammer</dc:creator>
      <dc:date>2015-12-04T11:49:07Z</dc:date>
    </item>
    <item>
      <title>Re: ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5952452#M10571</link>
      <description>&lt;P&gt;That's not the issue. One more time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I try to compile debug version (without _DEBUG macro - default for Autocad), boost throws compiler error:&lt;/P&gt;&lt;P&gt;"&lt;STRONG&gt;Using the /RTC option without specifying a debug runtime will lead to linker errors&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;Hint: go to the code generation options and switch to one of the debugging runtimes&lt;/STRONG&gt;"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The boost code is:&lt;/P&gt;&lt;PRE&gt;#if defined(__MSVC_RUNTIME_CHECKS) &amp;amp;&amp;amp; !defined(_DEBUG)&lt;/PRE&gt;&lt;P&gt;So, it means that I have to have _DEBUG macro defined for boost. But not for Autocad. So I tried to do a little hack - see ma first post here. But then during linking time, boost hacked me - see the second post. So now I can't see any way to do this. Your suggestion doesn't work, because boost NEEDS _DEBUG macro.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Dec 2015 16:48:34 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5952452#M10571</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-12-15T16:48:34Z</dc:date>
    </item>
    <item>
      <title>Re: ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5953555#M10572</link>
      <description>&lt;P&gt;OK. I see.&lt;/P&gt;&lt;P&gt;You have to do what the pragma says: Disable the /RTC compiler option.&lt;/P&gt;&lt;P&gt;In your project settings--&amp;gt;C/C++--&amp;gt;Code generation turn the "runtime type check" options off so that all /RTC options are gone. __MSVC_RUNTIME_CHECKS will not longer be defined then. See &lt;A title="/RTC (Run-Time Error Checks)" href="https://msdn.microsoft.com/en-US/library/8wtf2dfz.aspx" target="_blank"&gt;here.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I use a german version of visual studio. Translated to english the settings are called&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;"Check smaller types" (set to "No")&amp;nbsp;&amp;nbsp; and&lt;/LI&gt;&lt;LI&gt;"Complete runtime check" (set to "Standard").&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Dec 2015 09:28:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5953555#M10572</guid>
      <dc:creator>tbrammer</dc:creator>
      <dc:date>2015-12-16T09:28:08Z</dc:date>
    </item>
    <item>
      <title>Re: ObjectARX 2015 debug configuration and boost</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5954143#M10573</link>
      <description>Yes, that worked. Thank You &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;</description>
      <pubDate>Wed, 16 Dec 2015 15:27:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/objectarx-2015-debug-configuration-and-boost/m-p/5954143#M10573</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-12-16T15:27:47Z</dc:date>
    </item>
  </channel>
</rss>

