<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title></title>
</head>
<body>
<br>
I added this definition using Microsoft Visual C++ 6.0 Menu: "Project", "Settings".<br>
Now I managed to compile my application, but I had to remove some include
directories<br>
from the statement: INCLUDE_DIRECTORIES( ). <br>
(So maybe there was a confict between some .h and ADD_DEFINITIONS(-DAFXDLL)
... ??)<br>
And the AFXDLL definition appears in the MSVC++ project settings again.<br>
<br>
Sergio<br>
<br>
William A. Hoffman escribió:<br>
<blockquote type="cite"
cite="mid6.1.1.1.2.20040827093756.09274660@pop.nycap.rr.com">
<pre wrap="">That is the same cmake code that builds the CMakeSetup GUI.
You say if you add AFXDLL manually it works. Where do you add that?
Would this work:
ADD_DEFINITIONS(-DAFXDLL)
-Bill
At 07:48 AM 8/27/2004, Sergio Andres wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi all,
I have a CMakeLists.txt to generate a MS Visual C++ 6.0 Project with MFC.
The CMakeList contains the following lines:
ADD_DEFINITIONS(-D_AFXDLL)
SET(CMAKE_MFC_FLAG 6)
ADD_EXECUTABLE(VisualizationAppMDI WIN32 ${SRCS})
but, it seems to ignore the first two, because when I try to compile the project I get the following errors:
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argv
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argc
nafxcwd.lib(olelink.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(dcmeta.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(timecore.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(apphelp.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(filelist.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(oledlgs1.obj) : error LNK2001: unresolved external symbol __mbctype
And, if I add the definition (AFXDLL) manually to Project/Settings... It compiles.
So what is the problem??
Thanks in advance!
Sergio.
_______________________________________________
Cmake mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Cmake@www.cmake.org">Cmake@www.cmake.org</a>
<a class="moz-txt-link-freetext" href="http://www.cmake.org/mailman/listinfo/cmake">http://www.cmake.org/mailman/listinfo/cmake</a>
</pre>
</blockquote>
<pre wrap=""><!---->
</pre>
</blockquote>
<br>
</body>
</html>