hi everybody, i'm trying to add a new object into ns-2, but when i compile i
get some error related to loading the common ns-2 headers files, i can not
figure out why is this happening. if some can help me thanks in advance.
*mySkts/APIns.h:26:19: error: trace.h: No such file or directory
mySkts/APIns.h:27:18: error: node.h: No such file or directory
mySkts/APIns.h:28:19: error: agent.h: No such file or directory
mySkts/APIns.cc:21:23: error: simulator.h: No such file or directory
mySkts/APIns.cc:22:24: error: mobilenode.h: No such file or directory*
In file included from mySkts/APIns.cc:18:
mySkts/APIns.h:36: error: expected class-name before ‘,’ token
mySkts/APIns.h:37: error: expected class-name before ‘{’ token
mySkts/APIns.cc:28: error: expected class-name before ‘{’ token
mySkts/APIns.cc:34: error: ISO C++ forbids declaration of ‘TclObject’ with
no type
mySkts/APIns.cc:34: error: expected ‘;’ before ‘*’ token
mySkts/APIns.cc:38: error: expected ‘;’ before ‘}’ token
mySkts/APIns.cc: In constructor ‘APIskNSClass::APIskNSClass()’:
mySkts/APIns.cc:30: error: class ‘APIskNSClass’ does not have any field
named ‘TclClass’
make: *** [ns] Error 1
r...@calvin:/home/pdro7/Desktop/ns-allinone-2.34/ns-2.34# pwd
/home/pdro7/Desktop/ns-allinone-2.34/ns-2.34
*my .h file*
#include <string>
#include <set>
#include <map>
#include <iostream>
#include <fstream>
#include <trace.h>
#include "node.h"
#include "agent.h"
#include <assert.h>
//#include "tcpip/socket.h"
//#include "tcpip/storage.h"
//#include "TraCIConstants.h"
using namespace std;
class APIskNS : public TclObject, public Handler
{
public:
/// Constructor
APIskNS();
.
.
.
.
.
.
.
--
Ing Pedro Alonso Chaparro Valero
Ciudad Politecnica de la Innovación
iTEAM - Mobile Communications Group
Polytechnic University of Valencia
C\ Camino de Vera S/N, Edificio 8G
46022 Valencia, Spain