[Xorp-hackers] Problems linking XORP modifications
Pavlin Radoslavov
pavlin@icir.org
Wed, 16 Feb 2005 17:18:18 -0800
> Hello,
>
> First of all, I want to say that what I really have is a linking related
> problem and not an XORP one, but probably somebody can help me.
> I'm trying to modify XORP in order to support QoS routing, more precisely,
> per-flow routing. For this purpose, as a first step, I'm modifying the RIB
> (the next step will be to modify the FEA).
> Well, I have added three new files:
> - xorp/xrl/interfaces/QoS_rib.xif
> - xorp/rib/QoS_rib.hh
> - xorp/rib/QoS_rib.cc
> And I have modified the next ones:
> - xorp/xrl/targets/rib.tgt
> - xorp/rib/xrl_target.hh
> - xorp/rib/xrl_target.cc
> - xorp/rib/rib_manager.hh
> - xorp/rib/rib_manager.cc
>
> When I run gmake I get linking error messages. The first of them is (I have a
> lot of them):
> ======================================================
> ./.libs/librib.a(rib_manager.o)(.text+0x12e): In function
> `RibManager::RibManager[not-in-charge](EventLoop&, XrlStdRouter&,
> std::basic_string<char, std::char_traits<char>, std::allocator<char> >
> const&)':
> /usr/include/g++/bits/stl_tree.h:1002: undefined reference to
> `RIB_QoS<IPv4>::RIB_QoS[in-charge](RibManager&, EventLoop&)'
> ======================================================
Have you defined somewhere the RIB_QoS class, such that one of its
constructors should have the appropriate arguments?
E.g.
template<class A>
class RIB_QoS {
public:
RIB_QoS(RibManager& rib_manager, EventLoop& eventloop);
...
};
Regards,
Pavlin
>
> Following this line is the beginning of my rib_manager.cc file that includes
> the part of code that I guess is issuing this first error message:
>
> ===========================================
> #include "rib_module.h"
>
> #include "libxorp/xorp.h"
> #include "libxorp/xlog.h"
> #include "libxorp/debug.h"
> #include "libxorp/utils.hh"
>
> #include "libxipc/xrl_error.hh"
>
> #include "xrl/interfaces/finder_event_notifier_xif.hh"
>
> #include "rib_manager.hh"
> #include "redist_xrl.hh"
> #include "redist_policy.hh"
> #include "profile_vars.hh"
>
> RibManager::RibManager(EventLoop& eventloop, XrlStdRouter& xrl_std_router,
> const string& fea_target)
> : _status_code(PROC_NOT_READY),
> _status_reason("Initializing"),
> _eventloop(eventloop),
> _xrl_router(xrl_std_router),
> _register_server(&_xrl_router),
> _urib4(UNICAST, *this, _eventloop),
> _mrib4(MULTICAST, *this, _eventloop),
> _urib6(UNICAST, *this, _eventloop),
> _mrib6(MULTICAST, *this, _eventloop),
> _QoSSrib(*this, _eventloop), //
> _QoSrib6(*this, _eventloop),
> _vif_manager(_xrl_router, _eventloop, this, fea_target),
> _xrl_rib_target(&_xrl_router, _urib4, _mrib4, _urib6, _mrib6, _QoSSrib,
> _vif_manager, this),
> _fea_target(fea_target)
> {
> _urib4.initialize(_register_server);
> _mrib4.initialize(_register_server);
> _urib6.initialize(_register_server);
> _mrib6.initialize(_register_server);
> _QoSrib.initialize(_register_server);
> _QoSrib6.initialize(_register_server);
> PeriodicTimerCallback cb = callback(this, &RibManager::status_updater);
> _status_update_timer = _eventloop.new_periodic(1000, cb);
> initialize_profiling_variables(_profile);
> }
> ===========================================================
>
> I was thinking on problems with the compiler version but the fact is that XORP
> without my modifications compiles perfectly so I guess that the problem is on
> my code but I don't see it. I have tried to do the same for the new QoS_rib
> that is done for the normal rib.
> If you need more information, please feel free in asking for it.
>
> Any idea or suggestion???
> Thanks in advance.
>
> --
> =============================================
> Julián David Morillo Pozo
> PhD Student - Computer Networking Group
> Department of Computer Architecture (DAC)
> Polytechnical University of Catalonia (UPC)
> Phone: +34-934017182 Fax: +34-934017055
> URL: http://people.ac.upc.edu/jmorillo
> =============================================
>
>
> _______________________________________________
> Xorp-hackers mailing list
> Xorp-hackers@icir.org
> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-hackers