Skip to content

Install llvm repository for newer versions of clang-format#877

Open
dave992 wants to merge 2 commits into
ros-industrial:masterfrom
sam-xl:recent_clang_format_version
Open

Install llvm repository for newer versions of clang-format#877
dave992 wants to merge 2 commits into
ros-industrial:masterfrom
sam-xl:recent_clang_format_version

Conversation

@dave992

@dave992 dave992 commented Aug 20, 2024

Copy link
Copy Markdown

Using CLANG_FORMAT_VERSION we can specify which clang-format version to use. This assumes the version is available via apt.

I wanted to be able to use more recent versions of clang-format uniformly across multiple different ROS versions. Being limited to what is available for the base image is somewhat restrictive in this case. Furthermore, the packages that are included in Ubuntu are quite old.

The proposed changes check if the requested version is available via apt. If not, it will install the requested version using the Automatic installation script recommended by https://apt.llvm.org/

@dave992 dave992 force-pushed the recent_clang_format_version branch from 7d16042 to 1547277 Compare August 20, 2024 10:17
@dave992 dave992 force-pushed the recent_clang_format_version branch from 7ae2def to 1cc0528 Compare October 22, 2024 11:36
@mathias-luedtke

Copy link
Copy Markdown
Member

This seems to be very specific to your use case.
It might be better to prepare a custom docker image or a script hook.

the Automatic installation script recommended by https://apt.llvm.org/

This pulls more dependencies in, which are not needed for running clang-format and slow the process down.

@dave992 dave992 force-pushed the recent_clang_format_version branch from 1cc0528 to d69268d Compare June 10, 2025 14:01
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.

2 participants