> There are only the following four options: > Multi-threaded (/MT), Multi-threaded debug (/MTd), Multi-threaded DLL > (/MD), Multi-threaded debug DLL (/MDd). I investigated this thing bit. (Normally I don't use the IDE for compiling, I always use makefiles.) As it turns out, with the vc8.0 compiler /ML would correspond to the absence of /M<anything> flags. OMNeT++ libs are compiled without any /M, and if simulations are also compiled without any /M, then everything is fine. The samples compile, INET Framework compiles, everything compiles -- if compiled using makefiles which don't supply a /M flag. However, as you wrote it, seems like there's no way to compile without a /M flag from the Visual Studio IDE!!! The combo box only indeed only contains those options you wrote, and I was unable to find any related setting elsewhere. So looks like whatever you do, Visual C++ wants to supply with a /M, and cannot be convinced otherwise. I'd call it an IDE bug, although I'm sure Microsoft would convince anyone that it's a feature... Thus, unless I'm missing something, there's no way to build simulation programs from normal Visual Studio projects using the supplied libs. However you can still invoke a Makefile.vc from Visual Studio. It goes like this: First, delete existing project files (.vcproj, .dsp, .dsw, etc). Then: File -> New Project... -> General / Makefile project. Enter the name of the directory of your simulation as "Name" and its parent directory path as "Location", uncheck "Create directory for solution" -> Next -> Specify "m.bat", "m.bat clean && m.bat" "m.bat clean" as build commands -> Finish. (Screenshots included.) Then create "m.bat" in the project directory with the following contents: call opp_nmakemake -f -N nmake -f Makefile.vc depend nmake -f Makefile.vc %* The makefile will always include all cpp files in the project directory. Hope this helps... Andras > -----Original Message----- > From: omnetpp-l-bounces at xxx [mailto:omnetpp-l-bounces at xxx] > On Behalf Of LENIN MEHEDY > Sent: Friday, November 24, 2006 8:24 AM > To: OMNeT++ Discussion List > Subject: Re: [omnetpp] problems in vc80-debug libraries ??? > > Hi Andras, > Thanks a lot for clearifying that OMNET++ is not multi-threaded. > However, when I tried to specify the runtime library at > "Project>Properties>C/C++>Code Generation>Runtime Library" I can not find > the /ML[d] options there. There are only the following four options: > Multi-threaded (/MT), Multi-threaded debug (/MTd), Multi-threaded DLL > (/MD), Multi-threaded debug DLL (/MDd). > > However, I dont know how to enable \ML[d] options. Could you please tell > me how to do this? > > Regards, > Lenin > > Andras Varga <andras at xxx> wrote: > Lenin, > > LIBCMT.LIB is the multi-threaded C library of Visual C++. OMNeT++ is not > multi-threaded, and should be linked with LIBC.LIB (LIBCD.LIB). Maybe > you've > accidentally compiled something with /MT (/MTd) and that causes the linker > to choose LIBCMT. If so, removing /MT (replacing with /ML for example) > should help. > > This library mismatch is probably the source of the linker errors too. > > See http://support.microsoft.com/kb/154753 > > Regards, > Andras > > > -----Original Message----- > > From: omnetpp-l-bounces at xxx [mailto:omnetpp-l- > bounces at xxx] > > On Behalf Of LENIN MEHEDY > > Sent: Thursday, November 23, 2006 9:29 PM > > To: omnetpp-l at xxx > > Subject: [omnetpp] problems in vc80-debug libraries ??? > > > > Dear All, > > I tried to use MSVC++ 8.0 to compile and build my old code that was ok > > with VC 6.0. However I failed to build due to link errors. Let me tell > you > > what I tried to do. > > > > At first, I copied the content of /lib/vc80-debug to /lib of the omnet > > installation directory AND then tried to build. but I got some link > error > > and a warning saying: > > "LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other > > libs; use /NODEFAULTLIB:library" > > So, I put 'libcmt' in "project>properties>linker>input>ignore specific > > library" > > AND then again tried to build. But this type I got several error saying > > for example > > "sim_std.lib(cpar.obj) : error LNK2001: unresolved external symbol > > __invalid_parameter_noinfo" > > > > So am I right if I say that the vc80-debug library in the recent release > > of omnet++ need to be checked again? > > > > However, You may also see several recent posts on this topic at > > http://www.omnetpp.org/forum/print.php?id=1028. But still no solution > has > > been found. However, I hope that the omnet release team may > > recompile/recheck vc80-debug libraries as early as possible and thus > help > > us in overcoming the problem . > > > > By the way, if someone has got anyother solution, please share with us. > > > > regards, > > Lenin > > > > > > > > --------------------------------- > > Everyone is raving about the all-new Yahoo! Mail beta. > > _______________________________________________ > > OMNeT++ Mailing List > > options: http://lists.omnetpp.org/mailman/listinfo/omnetpp-l > > archive: http://www.omnetpp.org/listarchive/index.php > > _______________________________________________ > OMNeT++ Mailing List > options: http://lists.omnetpp.org/mailman/listinfo/omnetpp-l > archive: http://www.omnetpp.org/listarchive/index.php > > > > --------------------------------- > Check out the all-new Yahoo! Mail beta - Fire up a more powerful email and > get things done faster. > _______________________________________________ > OMNeT++ Mailing List > options: http://lists.omnetpp.org/mailman/listinfo/omnetpp-l > archive: http://www.omnetpp.org/listarchive/index.php
Attachment:
vsmakefile.png
Description: PNG image
Attachment:
vsmakefile2.png
Description: PNG image
_______________________________________________ OMNeT++ Mailing List options: http://lists.omnetpp.org/mailman/listinfo/omnetpp-l archive: http://www.omnetpp.org/listarchive/index.php