You are not logged in.

#1 2024-05-29 13:57:06

makslikesalo
Member
Registered: 2024-05-29
Posts: 1

packages: clang-format is missing in clang-16 package

Hello dear forum users,

By the will of fate I am forced to use clang-format version 16.

Unfortunately, after successful installation, the `clang-format` application is missing from the system. Also, the `clang*` utilities are not autocompleted in bash.

```
sudo pacman -Sy clang16
```

```
ls /usr/lib/llvm16/bin/clang*                                                                               

/usr/lib/llvm16/bin/clang        /usr/lib/llvm16/bin/clang-cpp               /usr/lib/llvm16/bin/clang-refactor
/usr/lib/llvm16/bin/clang++      /usr/lib/llvm16/bin/clang-extdef-mapping    /usr/lib/llvm16/bin/clang-repl
/usr/lib/llvm16/bin/clang-16     /usr/lib/llvm16/bin/clang-linker-wrapper    /usr/lib/llvm16/bin/clang-scan-deps
/usr/lib/llvm16/bin/clang-check  /usr/lib/llvm16/bin/clang-offload-bundler
/usr/lib/llvm16/bin/clang-cl     /usr/lib/llvm16/bin/clang-offload-packager
```
`clang-format` is missing in the list of files in package contents as well: https://archlinux.org/packages/extra/x86_64/clang16/.

If I install the latest clang (v17), then everything is present there, and the autocompletion works fine.

Can you tell me what's wrong?

Last edited by makslikesalo (2024-05-29 13:58:44)

Offline

#2 2024-05-29 15:16:23

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 12,025
Website

Re: packages: clang-format is missing in clang-16 package

makslikesalo wrote:
sudo pacman -Sy clang16

Do not do this. It is a partial upgrade.

It appears that these features are deliberately omitted from the clang16 build: https://gitlab.archlinux.org/archlinux/ … ads#L42-44

I would hazard a guess that this is because including these would cause a conflict with the non-versioned 'clang' package, which does provide them.

You could try rebuilding the package with these components enabled (remove the 'continue' from the match), but if you run into conflicts, you will need to resolve those, possibly by passing additional flags to the build process (cmake_args), or by renaming files in the package() function.

Mod note: Moving to Creating and Modifying packages.

Last edited by WorMzy (2024-05-29 15:17:23)


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

Board footer

Powered by FluxBB