error in building with rti version 6.1.1

3 posts / 0 new
Last post
Offline
Last seen: 1 year 11 months ago
Joined: 03/13/2022
Posts: 11
error in building with rti version 6.1.1

Hi

I want to use the rti version 6.1.1 with cmake tool in my program by Qt.
For this goal, add the following shared libraries:

$ENV{NDDSHOME}/lib/x64Linux3gcc5.4.0/libnddscd.so
$ENV{NDDSHOME}/lib/x64Linux3gcc5.4.0/libnddscored.so
$ENV{NDDSHOME}/lib/x64Linux3gcc5.4.0/libnddscpp2d.so
$ENV{NDDSHOME}/lib/x64Linux3gcc5.4.0/librtidlcppd.so
$ENV{NDDSHOME}/lib/x64Linux3gcc5.4.0/librtirsinfrastructured.so

In the building process, I confront with these Errors:

/opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscd.so: undefined reference to `RTILog_debug'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SampleProcessor_get_datareaders'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_TOPIC_QOS_PRINT_ALL'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `NDDS_Utility_stop_network_capture'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SNIPPET_OPTIMIZATION_RELIABILITY_PROTOCOL_HIGH_RATE'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SNIPPET_COMPATIBILITY_OTHER_DDS_VENDORS_ENABLE'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `NDDS_Config_Logger_get_print_format_by_log_level'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `NDDS_Utility_stop_network_capture_for_participant'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SNIPPET_OPTIMIZATION_DISCOVERY_COMMON'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SNIPPET_OPTIMIZATION_DATACACHE_LARGE_DATA_DYNAMICMEMALLOC'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SNIPPET_FEATURE_MONITORING_ENABLE'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SampleInfo_finalize'
/usr/bin/ld: /opt/DDS/rti_connext_dds-6.1.1/lib/x64Linux3gcc5.4.0/libnddscpp2d.so: undefined reference to `DDS_SampleProcessor_delete'

Thank you in Advance

Howard's picture
Offline
Last seen: 2 days 19 hours ago
Joined: 11/29/2012
Posts: 608

Are you using the "traditional" aka C++98 or "modern" aka C++11 version of the Connext DDS API?  You don't need to link both libnddscpp and libnddscpp2.

libnddscpp is for the traditional C++ API

and

libnddscpp2 is for the modern C++ API

also, are you using any RTI Routing Service APIs?   librtirsinfrastructure is only need if you're building your own version of RTI Routing Service (which would require libnddscpp2 but not libnddscpp).

And finally, I think that you need to list the libraries in order from most specific to most general so that the linker doesn't drop unused references.

It should be

librtirsinfrastructured.so (if you're doing RS stuff)

libnddscpp2d.so or libnddscppd.so

libnddscd.so

libnddscored.so

 

One last thing, I'm confused.  The symbol "RTILog_debug" does not appear in the Connext 6.1.1 libraries.  It was last used in Connext 6.0.x, and removed in Connext 6.1.0.  Are you sure that you have the correct libraries installed?

You can see if your version of the libraries are correct if you run

strings libnddscd.so | grep 6.1.1

there should be lots of output with the string "6.1.1" if the library was built for 6.1.1. 

Offline
Last seen: 1 year 11 months ago
Joined: 03/13/2022
Posts: 11

Hi

I use two version of rti in computer.  These errors are due to this. after uninstalling old version, the problem was solved.

Thank you