Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export required LogConsumer API on Windows platforms #2800

Merged
merged 3 commits into from
Jul 1, 2022

Conversation

rsanchez15
Copy link
Contributor

@rsanchez15 rsanchez15 commented Jul 1, 2022

Current version of Shapes Demo does not compile on Windows due to un-exported Fast DDS LogConsomer functions.

See the error below:

mainwindow.obj : error LNK2019: unresolved external symbol "protected: void __cdecl eprosima::fastdds::dds::LogConsumer::print_header(class std::basic_ostream<char,struct std::char_traits<char> > &,struct eprosima::fastdds::dds::Log::Entry const &,bool)const " (?print_header@LogConsumer@dds@fastdds@eprosima@@IEBAXAEAV?$basic_ostream@DU?$char_traits@D@std@@@std@@AEBUEntry@Log@234@_N@Z) referenced in function "public: virtual void __cdecl ShapesDemoLogConsumer::Consume(struct eprosima::fastdds::dds::Log::Entry const &)" (?Consume@ShapesDemoLogConsumer@@UEAAXAEBUEntry@Log@dds@fastdds@eprosima@@@Z) [C:\Users\eProsima\eProsima\shapesdemo\build\ShapesDemo\ShapesDemo.vcxproj]
mainwindow.obj : error LNK2019: unresolved external symbol "protected: void __cdecl eprosima::fastdds::dds::LogConsumer::print_context(class std::basic_ostream<char,struct std::char_traits<char> > &,struct eprosima::fastdds::dds::Log::Entry const &,bool)const " (?print_context@LogConsumer@dds@fastdds@eprosima@@IEBAXAEAV?$basic_ostream@DU?$char_traits@D@std@@@std@@AEBUEntry@Log@234@_N@Z) referenced in function "public: virtual void __cdecl ShapesDemoLogConsumer::Consume(struct eprosima::fastdds::dds::Log::Entry const &)" (?Consume@ShapesDemoLogConsumer@@UEAAXAEBUEntry@Log@dds@fastdds@eprosima@@@Z) [C:\Users\eProsima\eProsima\shapesdemo\build\ShapesDemo\ShapesDemo.vcxproj]
mainwindow.obj : error LNK2019: unresolved external symbol "protected: void __cdecl eprosima::fastdds::dds::LogConsumer::print_message(class std::basic_ostream<char,struct std::char_traits<char> > &,struct eprosima::fastdds::dds::Log::Entry const &,bool)const " (?print_message@LogConsumer@dds@fastdds@eprosima@@IEBAXAEAV?$basic_ostream@DU?$char_traits@D@std@@@std@@AEBUEntry@Log@234@_N@Z) referenced in function "public: virtual void __cdecl ShapesDemoLogConsumer::Consume(struct eprosima::fastdds::dds::Log::Entry const &)" (?Consume@ShapesDemoLogConsumer@@UEAAXAEBUEntry@Log@dds@fastdds@eprosima@@@Z) [C:\Users\eProsima\eProsima\shapesdemo\build\ShapesDemo\ShapesDemo.vcxproj]
C:\Users\eProsima\eProsima\shapesdemo\build\ShapesDemo\Release\ShapesDemo.exe : fatal error LNK1120: 3 unresolved externals [C:\Users\eProsima\eProsima\shapesdemo\build\ShapesDemo\ShapesDemo.vcxproj]
Failed   <<< ShapesDemo [1.92s, exited with code 1]

Description

Contributor Checklist

  • Commit messages follow the project guidelines.
  • The code follows the style guidelines of this project.
  • Tests that thoroughly check the new feature have been added/Regression tests checking the bug and its fix have been added.
  • Any new/modified methods have been properly documented using Doxygen.
  • Fast DDS test suite has been run locally.
  • Changes are ABI compatible.
  • Changes are API compatible.
  • Documentation builds and tests pass locally.
  • New feature has been added to the versions.md file (if applicable).
  • New feature has been documented/Current behavior is correctly described in the documentation.

Reviewer Checklist

  • Check contributor checklist is correct.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

@rsanchez15 rsanchez15 force-pushed the hotfix/export-log-consumer-dll branch 2 times, most recently from 866a5a2 to 61831d2 Compare July 1, 2022 08:29
Signed-off-by: Raúl Sánchez-Mateos <raul@eprosima.com>
@rsanchez15 rsanchez15 force-pushed the hotfix/export-log-consumer-dll branch from 61831d2 to af80109 Compare July 1, 2022 08:42
@EduPonz EduPonz added this to the v2.7.0 milestone Jul 1, 2022
Signed-off-by: Raúl Sánchez-Mateos <raul@eprosima.com>
Signed-off-by: Raúl Sánchez-Mateos <raul@eprosima.com>
@MiguelCompany
Copy link
Member

@richiprosima Please test mac

Copy link
Member

@MiguelCompany MiguelCompany left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@MiguelCompany
Copy link
Member

Checked locally that the new test passes correctly.

@MiguelCompany MiguelCompany merged commit 8540471 into master Jul 1, 2022
@MiguelCompany MiguelCompany deleted the hotfix/export-log-consumer-dll branch July 1, 2022 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants