sommer / veins

Veins - The open source vehicular network simulation framework.
http://veins.car2x.org
GNU General Public License v2.0
289 stars 228 forks source link

OMNeT++ 5.1 compatibility w/ Windows 64 bits #27

Closed gabrielbiasi closed 7 years ago

gabrielbiasi commented 7 years ago

I found some problems when trying to compile veins on Windows 64 bits and OMNeT 5.1 after the commit b96ba5043342586360c4ce15dd245fc942277751:

'make MODE=release all make[1]: Entering directory '/c/omnetpp-5.1/workspace/veins/src' Creating shared library: ../out/gcc-release/src/libveins.dll .tmplib4768(TraCIConnection.o):TraCIConnection.cc:(.text+0x145): undefined reference to '__imp_closesocket' (... a lot lines hidden ...) .tmplib4768(TraCIScenarioManagerForker.o):TraCIScenarioManagerForker.cc:(.text+0x1854): undefined reference to '__mp_WSAStartup' collect2.exe: error: ld returned 1 exit status make[1]: [Makefile:170: ../out/gcc-release/src/libveins.dll] Error 1 make[1]: Leaving directory '/c/omnetpp-5.1/workspace/veins/src' make: [Makefile:12: all] Error 2`'

I think it's probably the missing link from the socket communication library, so I simply solved this problem adding the parameter -lws2_32 to the makemake configuration. I hope this help some windows users to enjoy their simulations in 64 bits now.

riebl commented 7 years ago

Have you been able to compile Veins using Windows 64bit and OMNeT++ 5.1 before commit b96ba50? I suppose this issue is not caused by aforementioned commit but a "side effect" of OMNeT++ 5.1.

gabrielbiasi commented 7 years ago

I've tried and failed too. I am not saying that exactly your commit caused the error, sorry if it sounded that way. I think that the change of the new toolchain and libraries for mingw64 in OMNeT++ 5.1 is probably the case.

riebl commented 7 years ago

No offence taken. I have just been curious if you succeeded without this commit :-)

ChenKangQiang commented 7 years ago

Is it using command ./configuremake -lws2_32. In my machine,it still doesn't work. My GCC is TDM-GCC-64.

gabrielbiasi commented 7 years ago

Solved by e13b64247dcb7e19928620e9be57c94c1f092206.