<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=iso-8859-9">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:"Simsun \(Founder Extended\)";}
@font-face
        {font-family:"\@Simsun \(Founder Extended\)";}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
h1
        {margin-top:12.0pt;
        margin-right:0cm;
        margin-bottom:3.0pt;
        margin-left:0cm;
        page-break-after:avoid;
        font-size:16.0pt;
        font-family:Arial;}
h2
        {margin-top:12.0pt;
        margin-right:0cm;
        margin-bottom:3.0pt;
        margin-left:0cm;
        text-indent:0cm;
        line-height:150%;
        page-break-after:avoid;
        mso-list:l3 level2 lfo3;
        font-size:14.0pt;
        font-family:"Times New Roman";}
h3
        {margin-top:12.0pt;
        margin-right:0cm;
        margin-bottom:3.0pt;
        margin-left:0cm;
        text-indent:0cm;
        line-height:150%;
        page-break-after:avoid;
        mso-list:l3 level3 lfo3;
        font-size:13.0pt;
        font-family:"Times New Roman";}
h4
        {margin-top:12.0pt;
        margin-right:0cm;
        margin-bottom:3.0pt;
        margin-left:0cm;
        text-align:justify;
        text-indent:0cm;
        line-height:150%;
        page-break-after:avoid;
        mso-list:l3 level4 lfo3;
        font-size:12.0pt;
        font-family:"Times New Roman";}
p.MsoToc1, li.MsoToc1, div.MsoToc1
        {margin-top:6.0pt;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:11.35pt;
        margin-bottom:.0001pt;
        text-align:justify;
        text-indent:-11.35pt;
        line-height:150%;
        mso-list:l2 level1 lfo6;
        font-size:12.0pt;
        font-family:"Times New Roman";}
p.MsoToc9, li.MsoToc9, div.MsoToc9
        {margin:0cm;
        margin-bottom:.0001pt;
        text-align:justify;
        line-height:150%;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
p.Style3, li.Style3, div.Style3
        {margin:0cm;
        margin-bottom:.0001pt;
        text-align:center;
        page-break-after:avoid;
        font-size:16.0pt;
        font-family:"Times New Roman";
        font-weight:bold;}
p.Style4, li.Style4, div.Style4
        {margin:0cm;
        margin-bottom:.0001pt;
        text-align:center;
        page-break-after:avoid;
        font-size:16.0pt;
        font-family:"Times New Roman";
        font-weight:bold;}
span.EmailStyle21
        {mso-style-type:personal-compose;
        font-family:Arial;
        color:windowtext;}
@page Section1
        {size:595.3pt 841.9pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.Section1
        {page:Section1;}
/* List Definitions */
@list l0
        {mso-list-id:961155768;
        mso-list-type:hybrid;
        mso-list-template-ids:1045181504 -996779880 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
@list l0:level1
        {mso-level-number-format:alpha-upper;
        mso-level-tab-stop:54.0pt;
        mso-level-number-position:left;
        margin-left:54.0pt;
        text-indent:-18.0pt;}
@list l0:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:90.0pt;
        mso-level-number-position:left;
        margin-left:90.0pt;
        text-indent:-18.0pt;}
@list l1
        {mso-list-id:1221288405;
        mso-list-type:hybrid;
        mso-list-template-ids:190510384 -1420397788 69140505 69140507 69140495 69140505 69140507 69140495 69140505 69140507;}
@list l1:level1
        {mso-level-tab-stop:0cm;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l2
        {mso-list-id:1375737816;
        mso-list-type:hybrid;
        mso-list-template-ids:-528950636 -2051506172 69140505 69140507 69140495 69140505 69140507 69140495 69140505 69140507;}
@list l2:level1
        {mso-level-style-link:"TOC 1";
        mso-level-tab-stop:0cm;
        mso-level-number-position:left;
        margin-left:11.35pt;
        text-indent:-11.35pt;
        mso-ansi-font-size:12.0pt;
        mso-bidi-font-size:12.0pt;
        font-family:"Times New Roman";
        mso-ansi-font-weight:normal;
        mso-ansi-font-style:normal;}
@list l3
        {mso-list-id:1929188870;
        mso-list-template-ids:-258440650;}
@list l3:level1
        {mso-level-suffix:space;
        mso-level-text:"CHAPTER %1";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level2
        {mso-level-style-link:"Heading 2";
        mso-level-suffix:none;
        mso-level-text:"%1\.%2\.";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level3
        {mso-level-style-link:"Heading 3";
        mso-level-suffix:none;
        mso-level-text:"%1\.%2\.%3\.";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level4
        {mso-level-style-link:"Heading 4";
        mso-level-suffix:none;
        mso-level-text:"%1\.%2\.%3\.%4\. ";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level5
        {mso-level-number-format:none;
        mso-level-suffix:none;
        mso-level-text:"";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level6
        {mso-level-number-format:none;
        mso-level-suffix:none;
        mso-level-text:"";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level7
        {mso-level-number-format:none;
        mso-level-suffix:none;
        mso-level-text:"";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level8
        {mso-level-number-format:none;
        mso-level-suffix:none;
        mso-level-text:"";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
@list l3:level9
        {mso-level-number-format:none;
        mso-level-suffix:none;
        mso-level-text:"";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        margin-left:0cm;
        text-indent:0cm;}
ol
        {margin-bottom:0cm;}
ul
        {margin-bottom:0cm;}
-->
</style>
</head>
<body lang=TR link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Hello,<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>First of all I’m a newbie in MPI and I apologize for
your time. I have a problem when trying to execute a “hello world”
application. I’m using Microsoft Visual C++ 6.0 on a Windows Machine and I
have installed </span></font>mpich2-1.0.3-1. <o:p></o:p></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>My code is:<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>#include "mpi.h"<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>#include <iostream><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>int main(int argc,char** argv)<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>{<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> using namespace std;<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> MPI::Init(argc, argv);<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> int rank = MPI::COMM_WORLD.Get_rank();<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> int size = MPI::COMM_WORLD.Get_size();<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> cout << "Hello World! I am " << rank <<
" of " << size << endl;<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> MPI::Finalize();<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> return(0);<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>}<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>I have followed the instructions and added
“C:\mpich2\include” to the “Additional include
directories” box. In Link Tab – CATEGORY: Input I have added cxxd.lib
and mpi.lib (for debug version). I can compile the file by adding “#define
HAVE_NO_VARIABLE_RETURN_TYPE_SUPPORT” to the top of “mpicxx.h”.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>But when I link the code I get the following error:<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Linking...<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>LINK : warning LNK4098: defaultlib "LIBCMTD" conflicts with
use of other libs; use /NODEFAULTLIB:library<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>cxxd.lib(initcxx1.obj) : error LNK2001: unresolved external symbol __RTC_CheckEsp<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>cxxd.lib(initcxx1.obj) : error LNK2001: unresolved external symbol
__RTC_Shutdown<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>cxxd.lib(initcxx1.obj) : error LNK2001: unresolved external symbol
__RTC_InitBase<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>cxxd.lib(initcxx1.obj) : error LNK2001: unresolved external symbol
@_RTC_CheckStackVars@8<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>cxxd.lib(initcxx1.obj) : error LNK2001: unresolved external symbol
__RTC_UninitUse<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Debug/paralel_1.exe : fatal error LNK1120: 5 unresolved externals<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Error executing link.exe.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>paralel_1.exe - 6 error(s), 1 warning(s)<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>I would be appreciated if you can help.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Thanks,<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Sertaç CİNEL<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Middle East Technical University<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
</div>
</body>
</html>