[reSIProcate] Re: Compiling on Windows, Visual Studio alternatives
Hi,
I am compiling reSIProcate on WinXP Pro.
I couldn't use MSVisualStudio so I tried
MinGW+MSYS, as Shen Jinti suggested.
I compiled "resiprocate", "resipdum" and "ares" Libraries succesfuly.
Then I compiled, linked and ran 2 of the simplest DUM tests (basicCall
and basicMessage), so I think I've completed my first reSIProcate
"experiment".
Here are the few tweaks I had to make:
1) In $(RESIPROCATE_HOME)/resiprocate/os/Timer.cxx at line 213
I changed the unsigned 64 bits integer constant suffix for the WIN32 branch.
Instead of "ui64", I used "ULL".
2) In $(RESIPROCATE_HOME)/resiprocate/TransportSelector.cxx at line 317
I commented out the invocation to the gai_strerror() function.
This function is declared but not implemented in MinGW's win32api.
It was only used to provide a meaningful trace, so I could live without it.
3) In the generated $(RESIPROCATE_HOME)/resiprocate/test/Makefile
I deleted the following tests:
- testRSP-2.cxx
- tesTransactionFSM.cxx
- testTCP
All of them showed compiler errors that I weren't able to fix,
so I had no choice but to disable them.
In the same Makefile I replaced the line:
LIBS = -lares -lpthread
with the following one:
LIBS = ../../contrib/ares/libares.a \
-lws2_32 -lmswsock -lwsock32 -lnetapi32 -liphlpapi
Which has these changes:
- It doesn't use pthreads library which I think is not available in MinGW
- It uses ares library as static, instead of dynamic lib
- It includes the win32api libraries that ships with MinGW package.
4) The final step, is the one at resiprocate's INSTALL documentation,
in my case, at the MSYS console I wrote:
$ configure --enable-ssl=no
$ make
I hope this helps if someone wish to polish MinGW's support in sipfoundry.
I there's any further question regarding this "experiment", do not hesitate to
contact me on: dsusa-at-cestel-dot-es
Cheers !
Diego