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

Fix the clang build for clang 14. #3923

Merged

Conversation

clalancette
Copy link
Contributor

@clalancette clalancette commented Oct 10, 2023

clang 14 does not understand -Wno-deprecated-builtins, which causes problems trying to compile Fast-DDS on Ubuntu 22.04

This has been causing ROS 2 CI to fail for a few days now: https://ci.ros2.org/view/nightly/job/nightly_linux_clang_libcxx/1669/

Description

Remove the unsupported -Wno-deprecated-builtins flag.

It may be the case that we want to port this to other branches as well; I leave it up to the maintainers to decide.

Contributor Checklist

  • Commit messages follow the project guidelines.
  • The code follows the style guidelines of this project.
  • [N/A] Tests that thoroughly check the new feature have been added/Regression tests checking the bug and its fix have been added; the added tests pass locally
  • [N/A] Any new/modified methods have been properly documented using Doxygen.
  • [N/A] Changes are ABI compatible.
  • [N/A] Changes are API compatible.
  • [N/A] New feature has been added to the versions.md file (if applicable).
  • [N/A ] New feature has been documented/Current behavior is correctly described in the documentation.
  • Applicable backports have been included in the description.

Reviewer Checklist

  • The PR has a milestone assigned.
  • Check contributor checklist is correct.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

clang 14 does not understand -Wno-deprecated-builtins,
which causes problems trying to compile Fast-DDS on
Ubuntu 22.04

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
CMakeLists.txt Show resolved Hide resolved
Signed-off-by: Chris Lalancette <clalancette@gmail.com>
@MiguelCompany MiguelCompany added the no-test Skip CI tests if PR marked with this label label Oct 11, 2023
@MiguelCompany
Copy link
Member

@richiprosima Please test this

@MiguelCompany MiguelCompany added the ci-pending PR which CI is running label Oct 11, 2023
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 if it builds ok in CI

@MiguelCompany MiguelCompany added this to the v2.11.3 milestone Oct 11, 2023
@MiguelCompany
Copy link
Member

@Mergifyio backport master 2.10.x 2.6.x

@mergify
Copy link
Contributor

mergify bot commented Oct 11, 2023

backport master 2.10.x 2.6.x

✅ Backports have been created

@MiguelCompany
Copy link
Member

@richiprosima Please test mac

@MiguelCompany MiguelCompany merged commit 38820e9 into eProsima:2.11.x Oct 11, 2023
2 of 6 checks passed
@MiguelCompany
Copy link
Member

@clalancette Thanks!

mergify bot pushed a commit that referenced this pull request Oct 11, 2023
* Fix the clang build for clang 14.

clang 14 does not understand -Wno-deprecated-builtins,
which causes problems trying to compile Fast-DDS on
Ubuntu 22.04

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

* Only add the flag for Clang 15 and newer.

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

---------

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
(cherry picked from commit 38820e9)
mergify bot pushed a commit that referenced this pull request Oct 11, 2023
* Fix the clang build for clang 14.

clang 14 does not understand -Wno-deprecated-builtins,
which causes problems trying to compile Fast-DDS on
Ubuntu 22.04

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

* Only add the flag for Clang 15 and newer.

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

---------

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
(cherry picked from commit 38820e9)
mergify bot pushed a commit that referenced this pull request Oct 11, 2023
* Fix the clang build for clang 14.

clang 14 does not understand -Wno-deprecated-builtins,
which causes problems trying to compile Fast-DDS on
Ubuntu 22.04

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

* Only add the flag for Clang 15 and newer.

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

---------

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
(cherry picked from commit 38820e9)
@clalancette clalancette deleted the clalancette/fix-clang-build branch October 11, 2023 14:24
@clalancette
Copy link
Contributor Author

@clalancette Thanks!

Thanks for merging so quickly.

EduPonz pushed a commit that referenced this pull request Oct 24, 2023
* Fix the clang build for clang 14.

clang 14 does not understand -Wno-deprecated-builtins,
which causes problems trying to compile Fast-DDS on
Ubuntu 22.04

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

* Only add the flag for Clang 15 and newer.

Signed-off-by: Chris Lalancette <clalancette@gmail.com>

---------

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
(cherry picked from commit 38820e9)

Co-authored-by: Chris Lalancette <clalancette@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci-pending PR which CI is running no-test Skip CI tests if PR marked with this label
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants