1717
1818#include " aliceHLTwrapper/EventSampler.h"
1919#include < getopt.h>
20- #ifdef NANOMSG
21- #include < nanomsg/FairMQTransportFactoryNN.h>
22- #endif
23- #include < zeromq/FairMQTransportFactoryZMQ.h>
2420#include < tools/FairMQTools.h>
2521
2622#include < FairMQStateMachine.h>
@@ -309,16 +305,11 @@ int main(int argc, char** argv)
309305 return 0 ;
310306 }
311307
312- FairMQTransportFactory* transportFactory = nullptr ;
308+ std::string transport ;
313309 if (strcmp (factoryType, " nanomsg" ) == 0 ) {
314- #ifdef NANOMSG
315- transportFactory = new FairMQTransportFactoryNN ();
316- #else
317- cerr << " can not create factory for NANOMSG: not enabled in build" << endl;
318- return -ENODEV;
319- #endif
310+ transport = " nanomsg" ;
320311 } else if (strcmp (factoryType, " zmq" ) == 0 ) {
321- transportFactory = new FairMQTransportFactoryZMQ () ;
312+ transport = " zeromq " ;
322313 } else {
323314 cerr << " invalid factory type: " << factoryType << endl;
324315 return -ENODEV;
@@ -338,7 +329,7 @@ int main(int argc, char** argv)
338329 { // scope for the device reference variable
339330 FairMQDevice& device = *gDevice ;
340331
341- device.SetTransport (transportFactory );
332+ device.SetTransport (transport );
342333 device.SetProperty (FairMQDevice::Id, id.c_str ());
343334 device.SetProperty (FairMQDevice::NumIoThreads, numIoThreads);
344335 // device.SetProperty(FairMQDevice::LogIntervalInMs, deviceLogInterval);
0 commit comments