compile error in socketft.cpp

View: New views
6 Messages — Rating Filter:   Alert me  

compile error in socketft.cpp

by mm-29 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi everyone

I am a new member to this group so firstly thnaks to evryone

I am trying to compile the crypto++ on omnet++ in windows xp.
first I got an error in rijndael.cpp which said  :'alloca' was not
declared in this scope therefore I add #include <malloc.h> at the
begining of rijndael.cpp  and try to compile again but I got 6 errors
in socketft.cpp as follows:

undefined reference to `_WSAEnumNetworkEvents@12'
undefined reference to `_WSAEventSelect@12'
undefined reference to `_WSAGetOverlappedResult@20'
undefined reference to `_WSAGetOverlappedResult@20'
undefined reference to `_WSARecv@28'
undefined reference to `_WSASend@28'

can you please help me what is wrong?

thanks in advance
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---


Re: compile error in socketft.cpp

by ka-bar :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Try this:
#pragma comment(lib,"Ws2_32.lib")
Add it to your file.


ka-bar

--------------------------------------------------
From: "mm" <minarz@...>
Sent: Tuesday, September 08, 2009 8:55 AM
To: "Crypto++ Users" <cryptopp-users@...>
Subject: compile error in socketft.cpp

>
> Hi everyone
>
> I am a new member to this group so firstly thnaks to evryone
>
> I am trying to compile the crypto++ on omnet++ in windows xp.
> first I got an error in rijndael.cpp which said  :'alloca' was not
> declared in this scope therefore I add #include <malloc.h> at the
> begining of rijndael.cpp  and try to compile again but I got 6 errors
> in socketft.cpp as follows:
>
> undefined reference to `_WSAEnumNetworkEvents@12'
> undefined reference to `_WSAEventSelect@12'
> undefined reference to `_WSAGetOverlappedResult@20'
> undefined reference to `_WSAGetOverlappedResult@20'
> undefined reference to `_WSARecv@28'
> undefined reference to `_WSASend@28'
>
> can you please help me what is wrong?
>
> thanks in advance
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---


Re: compile error in socketft.cpp

by mm-29 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi thank you for your reply

I add #pragma comment(lib,"Ws2_32.lib") at the begining of the
socketft.h  but nothing changed and still I have the errors. can you
please tell me what is wrong?

thank you

On Sep 8, 9:54 am, "ka-bar" <ka-bar_stri...@...> wrote:

> Try this:
> #pragma comment(lib,"Ws2_32.lib")
> Add it to your file.
>
> ka-bar
>
> --------------------------------------------------
> From: "mm" <min...@...>
> Sent: Tuesday, September 08, 2009 8:55 AM
> To: "Crypto++ Users" <cryptopp-users@...>
> Subject: compile error in socketft.cpp
>
>
>
>
>
> > Hi everyone
>
> > I am a new member to this group so firstly thnaks to evryone
>
> > I am trying to compile the crypto++ on omnet++ in windows xp.
> > first I got an error in rijndael.cpp which said  :'alloca' was not
> > declared in this scope therefore I add #include <malloc.h> at the
> > begining of rijndael.cpp  and try to compile again but I got 6 errors
> > in socketft.cpp as follows:
>
> > undefined reference to `_WSAEnumNetworkEvents@12'
> > undefined reference to `_WSAEventSelect@12'
> > undefined reference to `_WSAGetOverlappedResult@20'
> > undefined reference to `_WSAGetOverlappedResult@20'
> > undefined reference to `_WSARecv@28'
> > undefined reference to `_WSASend@28'
>
> > can you please help me what is wrong?
>
> > thanks in advance- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---


Re: compile error in socketft.cpp

by trungantran :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


If you are using a MSVC-compatible compiler(Borland, Intel ...), use
"#pragma comment("ws2_32.lib")".
If you are using GCC(MinGW/Cygwin) or a compiler that doesnt support
auto-linking, you need to fix the linker command. For example, in case
of GCC, you have to add "-lws2_32" to the linker command.

On Sep 8, 10:03 am, mm <min...@...> wrote:

> Hi thank you for your reply
>
> I add #pragma comment(lib,"Ws2_32.lib") at the begining of the
> socketft.h  but nothing changed and still I have the errors. can you
> please tell me what is wrong?
>
> thank you
>
> On Sep 8, 9:54 am, "ka-bar" <ka-bar_stri...@...> wrote:
>
> > Try this:
> > #pragma comment(lib,"Ws2_32.lib")
> > Add it to your file.
>
> > ka-bar
>
> > --------------------------------------------------
> > From: "mm" <min...@...>
> > Sent: Tuesday, September 08, 2009 8:55 AM
> > To: "Crypto++ Users" <cryptopp-users@...>
> > Subject: compile error in socketft.cpp
>
> > > Hi everyone
>
> > > I am a new member to this group so firstly thnaks to evryone
>
> > > I am trying to compile the crypto++ on omnet++ in windows xp.
> > > first I got an error in rijndael.cpp which said  :'alloca' was not
> > > declared in this scope therefore I add #include <malloc.h> at the
> > > begining of rijndael.cpp  and try to compile again but I got 6 errors
> > > in socketft.cpp as follows:
>
> > > undefined reference to `_WSAEnumNetworkEvents@12'
> > > undefined reference to `_WSAEventSelect@12'
> > > undefined reference to `_WSAGetOverlappedResult@20'
> > > undefined reference to `_WSAGetOverlappedResult@20'
> > > undefined reference to `_WSARecv@28'
> > > undefined reference to `_WSASend@28'
>
> > > can you please help me what is wrong?
>
> > > thanks in advance- Hide quoted text -
>
> > - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---


Re: compile error in socketft.cpp

by mm-29 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi thank you very much for the reply

I use Mingw but I dont know how I should do what you said about adding
"-lws2_32" to the linker command. can you please tell me where and how
I should add this "-lws2_32" ?

Thanks alot

On Sep 10, 12:39 am, trungantran <trantrun...@...> wrote:

> If you are using a MSVC-compatible compiler(Borland, Intel ...), use
> "#pragma comment("ws2_32.lib")".
> If you are using GCC(MinGW/Cygwin) or a compiler that doesnt support
> auto-linking, you need to fix the linker command. For example, in case
> of GCC, you have to add "-lws2_32" to the linker command.
>
> On Sep 8, 10:03 am, mm <min...@...> wrote:
>
>
>
> > Hi thank you for your reply
>
> > I add #pragma comment(lib,"Ws2_32.lib") at the begining of the
> > socketft.h  but nothing changed and still I have the errors. can you
> > please tell me what is wrong?
>
> > thank you
>
> > On Sep 8, 9:54 am, "ka-bar" <ka-bar_stri...@...> wrote:
>
> > > Try this:
> > > #pragma comment(lib,"Ws2_32.lib")
> > > Add it to your file.
>
> > > ka-bar
>
> > > --------------------------------------------------
> > > From: "mm" <min...@...>
> > > Sent: Tuesday, September 08, 2009 8:55 AM
> > > To: "Crypto++ Users" <cryptopp-users@...>
> > > Subject: compile error in socketft.cpp
>
> > > > Hi everyone
>
> > > > I am a new member to this group so firstly thnaks to evryone
>
> > > > I am trying to compile the crypto++ on omnet++ in windows xp.
> > > > first I got an error in rijndael.cpp which said  :'alloca' was not
> > > > declared in this scope therefore I add #include <malloc.h> at the
> > > > begining of rijndael.cpp  and try to compile again but I got 6 errors
> > > > in socketft.cpp as follows:
>
> > > > undefined reference to `_WSAEnumNetworkEvents@12'
> > > > undefined reference to `_WSAEventSelect@12'
> > > > undefined reference to `_WSAGetOverlappedResult@20'
> > > > undefined reference to `_WSAGetOverlappedResult@20'
> > > > undefined reference to `_WSARecv@28'
> > > > undefined reference to `_WSASend@28'
>
> > > > can you please help me what is wrong?
>
> > > > thanks in advance- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---


Re: compile error in socketft.cpp

by mm-29 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi dear trungantran

I did it and it compiled now thank you very very much




On Sep 10, 8:09 am, mm <min...@...> wrote:

> Hi thank you very much for the reply
>
> I use Mingw but I dont know how I should do what you said about adding
> "-lws2_32" to the linker command. can you please tell me where and how
> I should add this "-lws2_32" ?
>
> Thanks alot
>
> On Sep 10, 12:39 am, trungantran <trantrun...@...> wrote:
>
>
>
> > If you are using a MSVC-compatible compiler(Borland, Intel ...), use
> > "#pragma comment("ws2_32.lib")".
> > If you are using GCC(MinGW/Cygwin) or a compiler that doesnt support
> > auto-linking, you need to fix the linker command. For example, in case
> > of GCC, you have to add "-lws2_32" to the linker command.
>
> > On Sep 8, 10:03 am, mm <min...@...> wrote:
>
> > > Hi thank you for your reply
>
> > > I add #pragma comment(lib,"Ws2_32.lib") at the begining of the
> > > socketft.h  but nothing changed and still I have the errors. can you
> > > please tell me what is wrong?
>
> > > thank you
>
> > > On Sep 8, 9:54 am, "ka-bar" <ka-bar_stri...@...> wrote:
>
> > > > Try this:
> > > > #pragma comment(lib,"Ws2_32.lib")
> > > > Add it to your file.
>
> > > > ka-bar
>
> > > > --------------------------------------------------
> > > > From: "mm" <min...@...>
> > > > Sent: Tuesday, September 08, 2009 8:55 AM
> > > > To: "Crypto++ Users" <cryptopp-users@...>
> > > > Subject: compile error in socketft.cpp
>
> > > > > Hi everyone
>
> > > > > I am a new member to this group so firstly thnaks to evryone
>
> > > > > I am trying to compile the crypto++ on omnet++ in windows xp.
> > > > > first I got an error in rijndael.cpp which said  :'alloca' was not
> > > > > declared in this scope therefore I add #include <malloc.h> at the
> > > > > begining of rijndael.cpp  and try to compile again but I got 6 errors
> > > > > in socketft.cpp as follows:
>
> > > > > undefined reference to `_WSAEnumNetworkEvents@12'
> > > > > undefined reference to `_WSAEventSelect@12'
> > > > > undefined reference to `_WSAGetOverlappedResult@20'
> > > > > undefined reference to `_WSAGetOverlappedResult@20'
> > > > > undefined reference to `_WSARecv@28'
> > > > > undefined reference to `_WSASend@28'
>
> > > > > can you please help me what is wrong?
>
> > > > > thanks in advance- Hide quoted text -
>
> > > > - Show quoted text -- Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe@....
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---