Hi Tamas,<br><br>I really appreciate your help. <br><br>and in my case, I uncomment also several options, but for my application Oracle Spatial support is needed, so I use the latest version BuiltKit from Howard Butler. I will try to compile all the needed libraries with VS2005.
<br><br>BTW: to compile CSharp/MapScript with MapServer, what I need to do is to umcomment the DOTNET option in the nmake.opt file in the mapserver-4.8.3 folder, which is:<br><pre class="literal-block">#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<br># .NET/C# MapScript<br># ----------------------------------------------------------------------<br># .NET will of course only work with MSVC 7.0 and 7.1. Also note that<br># you will definitely want USE_THREAD defined.
<br>#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>DOT_NET = YES<br><br>is that right? but the MSVC 7.0 and 7.1.seems for VS2003.<br><br>thank you very much.<br><br>zhonghai<br></pre><font face="Times New Roman" size="3">
<span style="font-size: 12pt;"></span></font><br><div><span class="gmail_quote">On 6/14/06, <b class="gmail_sendername">Tamas Szekeres</b> <<a href="mailto:szekerest@gmail.com">szekerest@gmail.com</a>> wrote:</span>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div>
<div link="blue" vlink="blue" lang="HU">
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Zhonghai,</span></font></p>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">The buildkit was compiled originally with VS2003, compiling with VS2005
is not so straightforward.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">When compiling gdal you probably link against several libs
compiled with VS2003 previously so you should compile those libraries with
VS2005 first.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">See nmake.opt and search for the .lib references to locate those
libraries.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I suggest to disable the libraries not really needed for your
application. (Even with mapserver and gdal)</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I cannot confirm if all of the libraries could be enabled easily. In my
application ORACLE, SDE, XERCES, GEOS, ECW were disabled. (however these are
enabled by default). </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">However some folks might have gone forward with the libraries mentioned
previously as well.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Best Regards,</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Tamas Szekeres</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<div style="text-align: center;" align="center"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">
<hr align="center" size="2" width="100%">
</span></font></div>
<p><b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold;">From:</span></font></b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma;"> UMN MapServer
Users List [mailto:<a href="mailto:MAPSERVER-USERS@LISTS.UMN.EDU" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MAPSERVER-USERS@LISTS.UMN.EDU</a>] <b><span style="font-weight: bold;">On Behalf Of
</span></b>Zhonghai Wang<br>
<b><span style="font-weight: bold;">Sent:</span></b> Wednesday, June 14, 2006
5:33 PM<br>
<b><span style="font-weight: bold;">To:</span></b> <a href="mailto:MAPSERVER-USERS@LISTS.UMN.EDU" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MAPSERVER-USERS@LISTS.UMN.EDU</a><br>
<b><span style="font-weight: bold;">Subject:</span></b> [UMN_MAPSERVER-USERS]
Compile MapSevrer with VS2005 (MapServer BuiltKit source code)</span></font></p>
</div></div><div><span class="e" id="q_10bd43d3d5c9ab65_1">
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">hi guys,</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I am trying to compile MapServer with VS2005 now, and I've struggle
with it for almost one day, but I am still in the dark...the following is done
for the compilation, and any ideas from you will be so helpful.</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">1.source code download: -- the MapServer BuildKit from Howard
Butler</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> <a href="http://hobu.stat.iastate.edu/mapserver/build_output/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://hobu.stat.iastate.edu/mapserver/build_output/
</a></span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> and I have downloaded the latest package version "mapserver-4.8.3-2-msvc71-buildk-kit.zip"</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">2.and I follow the compilation guide here: </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> <a href="http://www.nabble.com/Windows-build-kit-for-MSVC-7.1-t1143108.html#a2997024" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://www.nabble.com/Windows-build-kit-for-MSVC-7.1-t1143108.html#a2997024</a> </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> to compile MapServer, according to this doc, I should at
first compile the GDAL package, and then come to the MapServer package. But
when I am trying to compile the GDAL </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> package under VS2005 command prompt with the command
"nmake /f <a href="http://makefile.vc" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">makefile.vc</a>", there are
some error messages appears, the scenario is:</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">********************************</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*C:\buildkit\gdal-1.3.2>nmake /f <a href="http://makefile.vc" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">makefile.vc</a>
clean</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*C:\buildkit\gdal-1.3.2>nmake /f <a href="http://makefile.vc" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">makefile.vc</a>
</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*and here come the error messages, I paste only the first one here,
because I think if I fix this problem, the other error may be fixed at the same
time:</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*msvcprt.lib(MSVCP80.dll) : error LNK2005: "class std::basic_string<char,struct
s<br>
*td::char_traits<char>,class std::allocator<char> > __cdecl
std::operator+<char,s<br>
*truct std::char_traits<char>,class std::allocator<char> >(class
std::basic_strin <br>
*g<char,struct std::char_traits<char>,class std::allocator<char>
> const &,char c<br>
*onst *)" (<a href="mailto:??$?HDU?$char_traits@D@std@@V?$allocator@D@1@@std@@YA?AV?$basic_string" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">??$?HDU?$char_traits@D@std@@V?$allocator@D@1@@std@@YA?AV?$basic_string
</a>*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*<a href="mailto:*@DU?$char_traits@D@std@@V?$allocator@D@2@@0@ABV10@PBD@Z" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">@DU?$char_traits@D@std@@V?$allocator@D@2@@0@ABV10@PBD@Z
</a>)
already defined in geos<br>
*.lib(WKTReader.obj)</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">*********************************</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Because I want to use CSharp/MapScript under the .NET FW 2.0, and I've
also got some info from the Doc:<a href="http://mapserver.gis.umn.edu/docs/howto/mapscriptcscompile" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://mapserver.gis.umn.edu/docs/howto/mapscriptcscompile
</a>, it says that I should compile MapServer and the related libraries using
VS2005 for .NET FW 2.0, I begin with the VS2005 command prompt instead of
following the compilation guide in the mapserver README.WIN32, which gives: </span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">***</span></font></p>
</div>
<div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">To build
the package using the <a href="http://Makefile.vc" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Makefile.vc</a> and NMAKE:</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> -
Edit nmake.opt to select (or deselect) optional components of <br>
the MapServer. Please read the notes below about each
component<br>
before you move ahead with the compilation.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> -
Open a DOS prompt window</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> -
Run the VCVARS32.BAT script to initialize the VC++ environment<br>
variables. VCVARS32.BAT is automatically generated by the
MSVC++<br>
install procedure and should be located in the BIN sub-directory
of<br>
your MSVC++ installation. </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> -
Then start the build with: <br>
nmake /f <a href="http://Makefile.vc" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Makefile.vc</a> </span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">This will
create "mapserv.exe" (the main MapServer CGI program), the<br>
other command-line utilities, "mapserver.lib" and
"libmap.dll" that is <br>
used by theMapScript modules.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">***</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I am now
just wondering if it's possible to compile MapServer and related libraries with
VS2005, since the MSVCP80.dll can always not be found. Did anyone have some
experiences about that?</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I would
really appreciate it if you give me some HINTS for my compilation.</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">zhonghai</span></font></p>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
</div>
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p></span></div><div>
<p><font face="Times New Roman" size="2"><span style="font-size: 10pt;">--<br>
No virus found in this incoming message.<br>
Checked by AVG Free Edition.<br>
Version: 7.1.394 / Virus Database: 268.8.4/364 - Release Date: 2006.06.14.</span></font></p>
</div>
</div>
<br>
<p><font size="2">--<br>
No virus found in this outgoing message.<br>
Checked by AVG Free Edition.<br>
Version: 7.1.394 / Virus Database: 268.8.4/364 - Release Date: 2006.06.14.<br>
</font> </p>
</div></blockquote></div><br>