Hi there,
I've several issues in including dds header files, so I tried to follow the simple way described in the RTI Modern C++ API documentation (rti_connext_dds-5.2.0/doc/api/connext_dds/api_cpp2/group__DDSNamespaceModule.html).
So I tried first with:
#include <dds/dds.hpp>
and then with:
#include <rti/rti.hpp>
In both cases I got compilation errors. I did a really simple test program with an empty main() and the DDS header include declarations.
I attached the source file I used for test and the log of compilation errors to this post.
I'm running DDS 5.2.0 on Ubuntu 12.04 compiling with g++ 4.6.3.
I compiled the test program with the following command:
g++ -DRTI_UNIX -DRTI_LINUX -DRTI_64BIT -W -Wall -Wextra -Winit-self -Werror -O3 -fvisibility=hidden -fvisibility-inlines-hidden -Wno-unused-parameter -fPIC -I/opt/COTS/DDS/rti_connext_dds-5.2.0/include -I/opt/COTS/DDS/rti_connext_dds-5.2.0/include/ndds -I/opt/COTS/DDS/rti_connext_dds-5.2.0/include/ndds/hpp -o test_dds_header_all.o -c test_dds_header_all.cpp 2>test_dds_header_all.log
Could anyone tell me what I missing ?
Kind regards
Massimo
Attachment | Size |
---|---|
rti_include.zip | 1.7 KB |
Hi Massimo,
Thank you for pointing out those warnings. They have just been fixed in the development branch and will no longer be there in upcoming release. If you want to get your application to build against 5.2.0 though, you will need to to disable the
-Werror
flag that treats warnings as errors.Thanks,
Fernando.
Hi Fernando,
even removing the -Werror flag (and also removing all others -W... flags) the compilation fails.
Basically I'm trying to port a class that prints the content of DDS entities (working with 5.1.0, non modern C++) to modern C++.
I had to do a lot of changes due to the different way DDS entities attributes and valid values are made available to application code in the modern C++ binding language. SInce I didn't succeed in making the class compile by including the individual header files, I tried to follow the simple way by including the <rti/rti.hpp> but still I got the same error I have by including the individual header files (related to xxxBuiltinTopicData).