From 49964c647daf8a38a411a0245b71aae01440ee5a Mon Sep 17 00:00:00 2001 From: Ruud Overeem <overeem@astron.nl> Date: Fri, 21 Mar 2008 08:50:12 +0000 Subject: [PATCH] Bug 1167: Cleaned up MAC layers. There are less dependancies between the packages now. --- MAC/APL/PIC/TBBDriver/configure.in | 2 +- MAC/APL/PIC/TBBDriver/src/DriverSettings.cc | 2 +- MAC/APL/PIC/TBBDriver/src/Makefile.am | 4 ++-- MAC/APL/PIC/TBBDriver/src/MsgHandler.h | 8 ++++---- MAC/APL/PIC/TBBDriver/src/TBBDriver.cc | 7 +++---- MAC/APL/PIC/TBBDriver/src/TP_Protocol.prot | 2 +- MAC/APL/PIC/TBBDriver/src/tbbctl.cc | 4 ++-- MAC/APL/PIC/TBBDriver/test/TBBTest.cc | 4 ++-- MAC/APL/PIC/TBBDriver/test/TPStub.cc | 2 +- MAC/APL/PIC/TBB_Protocol/Makefile.am | 1 - MAC/APL/PIC/TBB_Protocol/configure.in | 6 +++--- MAC/APL/PIC/TBB_Protocol/src/Makefile.am | 4 ++-- MAC/APL/PIC/TBB_Protocol/src/TBB_Protocol.prot | 2 +- 13 files changed, 23 insertions(+), 25 deletions(-) diff --git a/MAC/APL/PIC/TBBDriver/configure.in b/MAC/APL/PIC/TBBDriver/configure.in index 163839e7a67..77beda52faf 100644 --- a/MAC/APL/PIC/TBBDriver/configure.in +++ b/MAC/APL/PIC/TBBDriver/configure.in @@ -56,7 +56,7 @@ dnl lofar_MPI lofar_INTERNAL(LCS/Common,Common,,1,Common/LofarTypedefs.h,,) lofar_INTERNAL(MAC/Test/Suite, suite, , 1, Suite/test.h,,) lofar_INTERNAL(MAC/GCF/TM, GCFTM, , 1, GCF/TM/GCF_Control.h,,) -lofar_INTERNAL(MAC/GCF/GCFCommon, GCFCommon, , 1, GCF/GCF_Defines.h,,) +lofar_INTERNAL(MAC/MACIO, MACIO, , 1, MACIO/MACServiceInfo.h,,) lofar_INTERNAL(MAC/APL/PIC/TBB_Protocol,TBB_Protocol,,1,APL/TBB_Protocol/TBB_Protocol.ph,,) lofar_INTERNAL(LCS/ACC/APS,aps,,1,APS/ParameterSet.h) diff --git a/MAC/APL/PIC/TBBDriver/src/DriverSettings.cc b/MAC/APL/PIC/TBBDriver/src/DriverSettings.cc index b692e876d0d..084ef485fab 100644 --- a/MAC/APL/PIC/TBBDriver/src/DriverSettings.cc +++ b/MAC/APL/PIC/TBBDriver/src/DriverSettings.cc @@ -26,7 +26,7 @@ #include <Common/LofarLocators.h> #include <APS/ParameterSet.h> #include <APS/Exceptions.h> -#include <GCF/GCF_ServiceInfo.h> +#include <MACIO/MACServiceInfo.h> #include <DriverSettings.h> using namespace LOFAR; diff --git a/MAC/APL/PIC/TBBDriver/src/Makefile.am b/MAC/APL/PIC/TBBDriver/src/Makefile.am index 2bb2478cefd..6a8689f4e20 100644 --- a/MAC/APL/PIC/TBBDriver/src/Makefile.am +++ b/MAC/APL/PIC/TBBDriver/src/Makefile.am @@ -8,10 +8,10 @@ AM_CPPFLAGS = \ AUTOGEN = autogen SUFFIXES = .ph %.cc: %.prot - $(AUTOGEN) --writable -L $(datadir)/GCF/TM $< + $(AUTOGEN) --writable -L $(datadir)/MACIO $< %.ph: %.prot - $(AUTOGEN) --writable -L $(datadir)/GCF/TM $< + $(AUTOGEN) --writable -L $(datadir)/MACIO $< cp $*.ph $(top_builddir)/include/TBBDriver/TP_Protocol BUILT_SOURCES = \ diff --git a/MAC/APL/PIC/TBBDriver/src/MsgHandler.h b/MAC/APL/PIC/TBBDriver/src/MsgHandler.h index 6374ac82aa5..3fd875c0862 100644 --- a/MAC/APL/PIC/TBBDriver/src/MsgHandler.h +++ b/MAC/APL/PIC/TBBDriver/src/MsgHandler.h @@ -29,7 +29,7 @@ #include <Common/LofarTypes.h> #include <GCF/TM/GCF_Control.h> -#include <Common/lofar_set.h> +#include <Common/lofar_list.h> #include <APL/TBB_Protocol/TBB_Protocol.ph> #include "TP_Protocol.ph" @@ -85,9 +85,9 @@ namespace LOFAR { private: TbbSettings *TS; - std::list<GCFPortInterface*> itsClientTriggerMsgList; // list of clients witch receive messages - std::list<GCFPortInterface*> itsClientHardwareMsgList; // list of clients witch receive messages - std::list<TriggerStruct*> itsTriggerList; // list of Received Trigger + list<GCFPortInterface*> itsClientTriggerMsgList; // list of clients witch receive messages + list<GCFPortInterface*> itsClientHardwareMsgList; // list of clients witch receive messages + list<TriggerStruct*> itsTriggerList; // list of Received Trigger TBBTriggerEvent *itsTriggerE; TBBErrorEvent *itsErrorE; diff --git a/MAC/APL/PIC/TBBDriver/src/TBBDriver.cc b/MAC/APL/PIC/TBBDriver/src/TBBDriver.cc index 0cea3b4c6b8..d76394dc0ab 100644 --- a/MAC/APL/PIC/TBBDriver/src/TBBDriver.cc +++ b/MAC/APL/PIC/TBBDriver/src/TBBDriver.cc @@ -26,7 +26,7 @@ #include <Common/LofarLocators.h> #include <APL/RTCCommon/daemonize.h> #include <APS/ParameterSet.h> -#include <GCF/GCF_ServiceInfo.h> +#include <MACIO/MACServiceInfo.h> #include <Common/hexdump.h> #include <getopt.h> @@ -68,7 +68,6 @@ #define ETHERTYPE_TP 0x7BB0 // letters of TBB using namespace LOFAR; -using namespace GCFCommon; using namespace ACC::APS; using namespace TBB; @@ -133,8 +132,8 @@ TBBDriver::TBBDriver(string name) // tell broker we are here LOG_DEBUG_STR("Registering protocols"); - GCF::TM::registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); - GCF::TM::registerProtocol (TP_PROTOCOL, TP_PROTOCOL_STRINGS); + registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); + registerProtocol (TP_PROTOCOL, TP_PROTOCOL_STRINGS); // open client port LOG_DEBUG_STR("Opening listener for clients"); diff --git a/MAC/APL/PIC/TBBDriver/src/TP_Protocol.prot b/MAC/APL/PIC/TBBDriver/src/TP_Protocol.prot index 8bd1b535b2e..62e1a8d42bd 100644 --- a/MAC/APL/PIC/TBBDriver/src/TP_Protocol.prot +++ b/MAC/APL/PIC/TBBDriver/src/TP_Protocol.prot @@ -5,7 +5,7 @@ autogen definitions protocol; description = "Protocol for the TBB driver interface"; prefix = "TP"; // for the signal names -id = "(LOFAR::GCF::TM::F_APL_PROTOCOL+15)"; +id = "(LOFAR::MACIO::F_APL_PROTOCOL+15)"; // specify extra include files // e.g. diff --git a/MAC/APL/PIC/TBBDriver/src/tbbctl.cc b/MAC/APL/PIC/TBBDriver/src/tbbctl.cc index 0869d398b9a..5fde81537ec 100644 --- a/MAC/APL/PIC/TBBDriver/src/tbbctl.cc +++ b/MAC/APL/PIC/TBBDriver/src/tbbctl.cc @@ -26,7 +26,7 @@ #include <lofar_config.h> #include <Common/LofarLogger.h> -#include <GCF/GCF_ServiceInfo.h> +#include <MACIO/MACServiceInfo.h> #include <APL/TBB_Protocol/TBB_Protocol.ph> @@ -2102,7 +2102,7 @@ TBBCtl::TBBCtl(string name, int argc, char** argv): GCFTask((State)&TBBCtl::init for(int boardnr = 0; boardnr < MAX_N_TBBBOARDS; boardnr++) { itsMemory[boardnr] = 0; } - GCF::TM::registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); + registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); itsServerPort.init(*this, MAC_SVCMASK_TBBDRIVER, GCFPortInterface::SAP, TBB_PROTOCOL); itsCmdTimer = new GCFTimerPort(*this, "AliveTimer"); } diff --git a/MAC/APL/PIC/TBBDriver/test/TBBTest.cc b/MAC/APL/PIC/TBBDriver/test/TBBTest.cc index 2cab0c18cd8..6607a8d4478 100644 --- a/MAC/APL/PIC/TBBDriver/test/TBBTest.cc +++ b/MAC/APL/PIC/TBBDriver/test/TBBTest.cc @@ -24,7 +24,7 @@ #include <lofar_config.h> #include <Common/LofarLogger.h> -#include <GCF/GCF_ServiceInfo.h> +#include <MACIO/MACServiceInfo.h> #include <APL/TBB_Protocol/TBB_Protocol.ph> #include <APL/RTCCommon/TestSuite.h> @@ -45,7 +45,7 @@ using namespace TBB_Test; TBBTest::TBBTest(string name) : GCFTask((State)&TBBTest::initial, name), Test(name) { - GCF::TM::registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); + registerProtocol (TBB_PROTOCOL, TBB_PROTOCOL_STRINGS); itsClient.init(*this, MAC_SVCMASK_TBBDRIVER, GCFPortInterface::SAP, TBB_PROTOCOL); diff --git a/MAC/APL/PIC/TBBDriver/test/TPStub.cc b/MAC/APL/PIC/TBBDriver/test/TPStub.cc index 79818138e42..19dbdb76df1 100644 --- a/MAC/APL/PIC/TBBDriver/test/TPStub.cc +++ b/MAC/APL/PIC/TBBDriver/test/TPStub.cc @@ -48,7 +48,7 @@ using namespace TBB_Test; TPStub::TPStub(string name) : GCFTask((State)&TPStub::initial, name), Test(name) { - GCF::TM::registerProtocol (TP_PROTOCOL, TP_PROTOCOL_STRINGS); + registerProtocol (TP_PROTOCOL, TP_PROTOCOL_STRINGS); char addrstr[64]; snprintf(addrstr, 64, "TPStub.MAC_ADDR_TBBDRIVER"); diff --git a/MAC/APL/PIC/TBB_Protocol/Makefile.am b/MAC/APL/PIC/TBB_Protocol/Makefile.am index ec233a4b306..24c67bc511c 100644 --- a/MAC/APL/PIC/TBB_Protocol/Makefile.am +++ b/MAC/APL/PIC/TBB_Protocol/Makefile.am @@ -6,7 +6,6 @@ pkgext_DATA = pkgext pkgextcppflags pkgextcxxflags pkgextldflags DISTCHECK_CONFIGURE_FLAGS=\ --with-common=$(prefix) \ - --with-gcfcommon=$(prefix) \ --with-gcftm=$(prefix) \ --with-rtccommon=$(prefix) diff --git a/MAC/APL/PIC/TBB_Protocol/configure.in b/MAC/APL/PIC/TBB_Protocol/configure.in index b78b575cb73..fb939d49e3a 100644 --- a/MAC/APL/PIC/TBB_Protocol/configure.in +++ b/MAC/APL/PIC/TBB_Protocol/configure.in @@ -53,9 +53,9 @@ dnl lofar_GENERAL lofar_BLITZ dnl lofar_MPI -lofar_INTERNAL(LCS/Common, common, , 1, Common/LofarTypes.h,,) -lofar_INTERNAL(MAC/GCF/TM, GCFTM, , 1, GCF/TM/GCF_Control.h,,) -lofar_INTERNAL(MAC/APL/RTCCommon, RTCCommon, , 1, APL/RTCCommon/Marshalling.h,,) +lofar_INTERNAL(LCS/Common, Common, , 1, Common/LofarTypes.h,,) +lofar_INTERNAL(MAC/MACIO, MACIO, , 1, MACIO/GCF_Event.h,,) +lofar_INTERNAL(MAC/APL/RTCCommon, RTCCommon, , 1, APL/RTCCommon/MarshallBlitz.h,,) dnl dnl Output Makefiles diff --git a/MAC/APL/PIC/TBB_Protocol/src/Makefile.am b/MAC/APL/PIC/TBB_Protocol/src/Makefile.am index 728d6a994da..e5286036a5e 100644 --- a/MAC/APL/PIC/TBB_Protocol/src/Makefile.am +++ b/MAC/APL/PIC/TBB_Protocol/src/Makefile.am @@ -5,10 +5,10 @@ AM_CPPFLAGS = \ AUTOGEN = autogen SUFFIXES = .ph %.cc: %.prot - $(AUTOGEN) --writable -L $(datadir)/GCF/TM $< + $(AUTOGEN) --writable -L $(datadir)/MACIO $< %.ph: %.prot - $(AUTOGEN) --writable -L $(datadir)/GCF/TM $< + $(AUTOGEN) --writable -L $(datadir)/MACIO $< cp $*.ph $(top_builddir)/include/APL/TBB_Protocol EXTRA_DIST = \ diff --git a/MAC/APL/PIC/TBB_Protocol/src/TBB_Protocol.prot b/MAC/APL/PIC/TBB_Protocol/src/TBB_Protocol.prot index ae5ffbe3bae..5cbcfbbfe57 100644 --- a/MAC/APL/PIC/TBB_Protocol/src/TBB_Protocol.prot +++ b/MAC/APL/PIC/TBB_Protocol/src/TBB_Protocol.prot @@ -5,7 +5,7 @@ autogen definitions protocol; description = "Protocol for the TBB driver interface"; prefix = "TBB"; // for the signal names -id = "(LOFAR::GCF::TM::F_APL_PROTOCOL+14)"; +id = "(LOFAR::MACIO::F_APL_PROTOCOL+14)"; // specify extra include files // e.g. -- GitLab