Open infdahai opened 1 year ago
@infdahai Does the Ubuntu 20.04 have clang-16 in its repository?
No. clang-10
is the default version in ubuntu 20.04
.
I see the kvrocks.yaml file uses ubuntu-22.04
and this distro supports clang-15
. So I just ask this.
I have been using GCC 13 to build kvrocks for a long time and haven't encountered any issues so far.
Getting GCC 13 or Clang 16 in CI may require manual download and installation, but I don't object to adding new compiler builds in CI (currently, the default versions of GCC and Clang in both ubuntu 20 LTS and ubuntu 22 LTS are used in CI, refer to https://github.com/actions/runner-images).
for clang-16, we can refer to
or execute the shell script.
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 16
sudo apt-get install -y clang-tidy-16
But I havn't found a vaild example for gcc-13. What do you think @PragmaTwice or just pend for this?
for clang-16, we can refer to
or execute the shell script.
wget https://apt.llvm.org/llvm.sh chmod +x llvm.sh sudo ./llvm.sh 16 sudo apt-get install -y clang-tidy-16
But I havn't found a vaild example for gcc-13. What do you think @PragmaTwice or just pend for this?
For gcc-13 we can add a PPA for ubuntu, refer to https://launchpad.net/~ubuntu-toolchain-r/+archive/ubuntu/ppa .
BTW I am not a ubuntu user : )
I was suggested to add a blank line at the end of the code when I submitted a PR, but now there are no rules for clang-format. I learned that the rule InsertNewlineAtEOF
is supported in clang-format 16. Is it possible to update the clang-format version and add this rule?
https://clang.llvm.org/docs/ClangFormatStyleOptions.html#insertnewlineateof
Search before asking
Motivation
This issue has a request to use
clang-16
andgcc-13
to build docker images orcmakelists.txt
in local developing environment and useclang-tidy-16
andclang-format-16
to correct code formattings.Solution
No response
Are you willing to submit a PR?