Re: [Opalvoip-devel] [Opalvoip-user] HOWTO build OPAL/PTLIB for Windows 2000
Brought to you by:
csoutheren,
rjongbloed
From: Robert J. <ro...@vo...> - 2010-02-12 23:08:42
|
Until recently when my old Windows 2000 machine finally died after nearly 10 years of sterling service, I was regularly compiling on it. But sadly, no more. Anyway, the real point I wanted to make is there is a --disable-winver option on the PTLib configure program that should be used if you want your target to be W2K. Essentially this makes WINVER=0x500 which is the API level that will guarantee that no functions, such as you describe, are defined in the headers so you don't get the run time DLL mismatch. If that still does not work for you, then I suppose that adding the extra includes is the solution. Robert Jongbloed OPAL/OpenH323/PTLib Architect and Co-founder. > -----Original Message----- > From: Vyacheslav Frolov [mailto:v.f...@or...] > Sent: Saturday, 13 February 2010 6:33 AM > To: opa...@li...; opa...@li... > Subject: [Opalvoip-user] HOWTO build OPAL/PTLIB for Windows 2000 > > When I running OPAL based executable on Windows 2000 it popups me > that there is no one of the following entry points: > > freeaddrinfo > getaddrinfo > GetAdaptersAddresses > DnsFree > > Yes, I know that "While Windows 2000 may work for builds and running > executables, it is expected that at least Windows XP would be used > and no gurantees are made the future versions", but I still need > OPAL for Windows 2000. Possible I'm not alone ... > > Here is a possible solution: > > 1. Apply the following patch: > > ---------------------------------------------------------------------------- - > -------------- > Index: src/ptlib/msos/win32.cxx > =================================================================== > --- src/ptlib/msos/win32.cxx (revision 24055) > +++ src/ptlib/msos/win32.cxx (working copy) > @@ -37,6 +37,7 @@ > #include <ptlib/msos/ptlib/debstrm.h> > #include <winsock2.h> > #include <ws2tcpip.h> > +#include <wspiapi.h> // for running on Windows 2000 > > #ifdef __MINGW32__ > #include <process.h> > Index: include/ptlib/msos/ptlib/contain.h > =================================================================== > --- include/ptlib/msos/ptlib/contain.h (revision 24055) > +++ include/ptlib/msos/ptlib/contain.h (working copy) > @@ -290,6 +290,7 @@ > > #include <winsock2.h> // Version 2 of windows socket > #include <ws2tcpip.h> // winsock2 is not complete, ws2tcpip add some > defines such as IP_TOS > + #include <wspiapi.h> // for running on Windows 2000 > > #if defined(_MSC_VER) > #pragma warning(pop) > ---------------------------------------------------------------------------- - > -------------- > > WARNING: The wspiapi.h replaces the WspiapiGetAddrInfo, WspiapiGetNameInfo > and WspiapiFreeAddrInfo functions by inline code that looks not thread safe > at first call (but it works for me). > > 2. Set the environment variable: > > PTLIB_CONFIGURE_OPTIONS=--disable-ipv6 --disable-resolver > > Now you can build Windows 2000 compatible OPAL/PTLIB. > > > **************************************************************************** * > ************************** > This message and any attachments (the "message") are confidential and > intended solely for the addressees. > Any unauthorised use or dissemination is prohibited. > Messages are susceptible to alteration. Orange Business Services shall not be > liable for the message if altered, changed or > falsified. If you are not the intended addressee of this message, please > cancel it immediately and inform > the sender. > **************************************************************************** * > ************************** > > ---------------------------------------------------------------------------- - > - > SOLARIS 10 is the OS for Data Centers - provides features such as DTrace, > Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW > http://p.sf.net/sfu/solaris-dev2dev > _______________________________________________ > Opalvoip-user mailing list > Opa...@li... > https://lists.sourceforge.net/lists/listinfo/opalvoip-user |