R
Rohini
Hi ,
I am getting the following LINK 2005 error when I tried to build my
project in vc++7.1.
I am doing the build process in win32release mode.
I have searched google on this but whatever I found was related to
standard dll's and lib's.
Here in my case it is not a standard lib.It is generated by a different
project in another workspace.
-----------------------------------------------------------------------------------------------------------------------------------
ghjkl.lib(ghjkl.dll) : error LNK2005: "public: int __thiscall
OSF_Task<class OSF_Thread_Mutex,class
OSF_Condition_Thread_Mutex>::getq(class OSF_Message_Block * &,class
OSF_Time_Value *)"
(?getq@?$OSF_Task@VOSF_Thread_Mutex@@VOSF_Condition_Thread_Mutex@@@@QAEHAAPAVOSF_Message_Block@@PAVOSF_Time_Value@@@Z)
already defined in abc.obj
-------------------------------------------------------------------------------------------------------------------------------------
The function getq(class OSF_Message_Block * &,class OSF_Time_Value *)
is not defined in abc.cpp but it is declared and defined in another
header file asd.h.
I am putting the relevant code below.
***asd.h
----------------------------------------------------------------------------------------------------------------------------------
class ghj{
typedef STL_Message_Queue<OSF_Recursive_Thread_Mutex, OSF_Manual_Event>
MessageQueue;
int getq(OSF_Message_Block*& mb, OSF_Time_Value* tv=0)
{
return mq_->dequeue_head(mb,tv);
}
private:
MessageQueue* mq_;
}
-------------------------------------------------------------------------------------------------------------------------------------
Any help is appreciated.
Thanks in advance
Best Regards,
Rohini Chandra
I am getting the following LINK 2005 error when I tried to build my
project in vc++7.1.
I am doing the build process in win32release mode.
I have searched google on this but whatever I found was related to
standard dll's and lib's.
Here in my case it is not a standard lib.It is generated by a different
project in another workspace.
-----------------------------------------------------------------------------------------------------------------------------------
ghjkl.lib(ghjkl.dll) : error LNK2005: "public: int __thiscall
OSF_Task<class OSF_Thread_Mutex,class
OSF_Condition_Thread_Mutex>::getq(class OSF_Message_Block * &,class
OSF_Time_Value *)"
(?getq@?$OSF_Task@VOSF_Thread_Mutex@@VOSF_Condition_Thread_Mutex@@@@QAEHAAPAVOSF_Message_Block@@PAVOSF_Time_Value@@@Z)
already defined in abc.obj
-------------------------------------------------------------------------------------------------------------------------------------
The function getq(class OSF_Message_Block * &,class OSF_Time_Value *)
is not defined in abc.cpp but it is declared and defined in another
header file asd.h.
I am putting the relevant code below.
***asd.h
----------------------------------------------------------------------------------------------------------------------------------
class ghj{
typedef STL_Message_Queue<OSF_Recursive_Thread_Mutex, OSF_Manual_Event>
MessageQueue;
int getq(OSF_Message_Block*& mb, OSF_Time_Value* tv=0)
{
return mq_->dequeue_head(mb,tv);
}
private:
MessageQueue* mq_;
}
-------------------------------------------------------------------------------------------------------------------------------------
Any help is appreciated.
Thanks in advance
Best Regards,
Rohini Chandra