Thanks a lot Rudolf.
It helped. But I had another problem with INET_API. I have seen your reply in another post in this forum to add a header "INETDefs.h" and "make makefiles". But still having an error.
MyAlgo.h
-------------
#ifndef __INET_MYALGO_H_
#define __INET_MYALGO_H_
#include <omnetpp.h>
#include "INETDefs.h"
#include "PassiveQueueBase.h"
#include <IPassiveQueue.h>
class INET_API MyAlgo : public PassiveQueueBase
{
Protected:
virtual void initialize();
..
..
virtual void finish();
};
#endif
--------------
I am getting the error like:
out/gcc-debug//MyAlgo.o: In function `MyAlgo':
H:\Simulator\omnetpp-4.2.2\samples\coalg/MyAlgo.h:18: undefined reference to `_imp___ZTV6MyAlgo'
H:\Simulator\omnetpp-4.2.2\samples\coalg/MyAlgo.h:18: undefined reference to `_imp___ZTV6MyAlgo'
out/gcc-debug//MyAlgo.o: In function `~MyAlgo':
H:\Simulator\omnetpp-4.2.2\samples\coalg/MyAlgo.h:18: undefined reference to `_imp___ZTV6MyAlgo'
H:\Simulator\omnetpp-4.2.2\samples\coalg/MyAlgo.h:18: undefined reference to `_imp___ZTV6MyAlgo'
collect2: ld returned 1 exit status
make: *** [out/gcc-debug//coalg.exe] Error 1
--------------
Please provide some hints if you see that I am missing some logic.