build: gitpod support updated

This commit is contained in:
Mateusz Pusz
2022-10-03 17:34:05 +00:00
parent cd52588f56
commit 6d78ad8646
3 changed files with 38 additions and 7 deletions

4
.gitpod.Dockerfile vendored
View File

@@ -4,11 +4,13 @@ FROM trainiteu/gitpod-cpp
RUN lsb_rel=`lsb_release -cs` \ RUN lsb_rel=`lsb_release -cs` \
&& sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel}-12 main" \ && sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel}-12 main" \
&& sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel}-13 main" \ && sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel}-13 main" \
&& sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel}-14 main" \
&& sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel} main" && sudo add-apt-repository "deb http://apt.llvm.org/${lsb_rel}/ llvm-toolchain-${lsb_rel} main"
# Install older compilers supported by the project as well as clang-format-15 for code formatting # Install older compilers supported by the project as well as clang-format-15 for code formatting
RUN sudo install-packages \ RUN sudo install-packages \
g++-10 \ g++-10 \
g++-11 \
clang-12 \ clang-12 \
clang-13 \ clang-13 \
clang-format-15 clang-14

View File

@@ -75,6 +75,7 @@ tasks:
pushd /workspace/.conan/profiles pushd /workspace/.conan/profiles
cp default gcc10 cp default gcc10
cp default gcc11 cp default gcc11
cp default gcc12
cp default clang12 cp default clang12
cp default clang13 cp default clang13
cp default clang14 cp default clang14
@@ -82,6 +83,9 @@ tasks:
conan profile update settings.compiler.version=10 gcc10 conan profile update settings.compiler.version=10 gcc10
conan profile update env.CXX=/usr/bin/g++-10 gcc10 conan profile update env.CXX=/usr/bin/g++-10 gcc10
conan profile update env.CC=/usr/bin/gcc-10 gcc10 conan profile update env.CC=/usr/bin/gcc-10 gcc10
conan profile update settings.compiler.version=11 gcc11
conan profile update env.CXX=/usr/bin/g++-11 gcc11
conan profile update env.CC=/usr/bin/gcc-11 gcc11
conan profile update settings.compiler=clang clang12 conan profile update settings.compiler=clang clang12
conan profile update settings.compiler.version=12 clang12 conan profile update settings.compiler.version=12 clang12
conan profile update settings.compiler.libcxx=libstdc++11 clang12 conan profile update settings.compiler.libcxx=libstdc++11 clang12
@@ -94,9 +98,14 @@ tasks:
conan profile update env.CC=/usr/bin/clang-13 clang13 conan profile update env.CC=/usr/bin/clang-13 clang13
conan profile update settings.compiler=clang clang14 conan profile update settings.compiler=clang clang14
conan profile update settings.compiler.version=14 clang14 conan profile update settings.compiler.version=14 clang14
conan profile update settings.compiler.libcxx=libc++ clang14 conan profile update settings.compiler.libcxx=libc++11 clang14
conan profile update env.CXX=/usr/bin/clang++-14 clang14 conan profile update env.CXX=/usr/bin/clang++-14 clang14
conan profile update env.CC=/usr/bin/clang-14 clang14 conan profile update env.CC=/usr/bin/clang-14 clang14
conan profile update settings.compiler=clang clang15
conan profile update settings.compiler.version=15 clang15
conan profile update settings.compiler.libcxx=libc++ clang15
conan profile update env.CXX=/usr/bin/clang++-15 clang15
conan profile update env.CC=/usr/bin/clang-15 clang15
echo 'tools.cmake.cmaketoolchain:generator=Ninja Multi-Config' > /workspace/.conan/global.conf echo 'tools.cmake.cmaketoolchain:generator=Ninja Multi-Config' > /workspace/.conan/global.conf
echo 'tools.cmake.cmake_layout:build_folder_vars=["settings.compiler", "settings.compiler.version"]' >> /workspace/.conan/global.conf echo 'tools.cmake.cmake_layout:build_folder_vars=["settings.compiler", "settings.compiler.version"]' >> /workspace/.conan/global.conf
gp sync-done conan-init gp sync-done conan-init
@@ -123,6 +132,17 @@ tasks:
ctest -C Release ctest -C Release
ctest -C Debug ctest -C Debug
echo "🛠️ gcc-11 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️" echo "🛠️ gcc-11 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: gcc-12
init: |
gp sync-await conan-init
conan install . -pr gcc12 -c user.build:all=True -c user.build:skip_docs=True -b outdated
conan install . -pr gcc12 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug
cmake --preset gcc-12 -DCMAKE_C_COMPILER=/usr/bin/gcc-12 -DCMAKE_CXX_COMPILER=/usr/bin/g++-12
cmake --build --preset gcc-12-release -j
cmake --build --preset gcc-12-debug -j
ctest -C Release
ctest -C Debug
echo "🛠️ gcc-12 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: clang-12 - name: clang-12
init: | init: |
gp sync-await conan-init gp sync-await conan-init
@@ -137,7 +157,6 @@ tasks:
- name: clang-13 - name: clang-13
init: | init: |
gp sync-await conan-init gp sync-await conan-init
mkdir -p build/Clang-13 && cd build/Clang-13
conan install . -pr clang13 -c user.build:all=True -c user.build:skip_docs=True -b outdated conan install . -pr clang13 -c user.build:all=True -c user.build:skip_docs=True -b outdated
conan install . -pr clang13 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug conan install . -pr clang13 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug
cmake --preset clang-13 -DCMAKE_C_COMPILER=/usr/bin/clang-13 -DCMAKE_CXX_COMPILER=/usr/bin/clang++-13 cmake --preset clang-13 -DCMAKE_C_COMPILER=/usr/bin/clang-13 -DCMAKE_CXX_COMPILER=/usr/bin/clang++-13
@@ -149,7 +168,6 @@ tasks:
- name: clang-14 - name: clang-14
init: | init: |
gp sync-await conan-init gp sync-await conan-init
mkdir -p build/Clang-14 && cd build/Clang-14
conan install . -pr clang14 -c user.build:all=True -c user.build:skip_docs=True -b outdated conan install . -pr clang14 -c user.build:all=True -c user.build:skip_docs=True -b outdated
conan install . -pr clang14 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug conan install . -pr clang14 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug
cmake --preset clang-14 -DCMAKE_C_COMPILER=/usr/bin/clang-14 -DCMAKE_CXX_COMPILER=/usr/bin/clang++-14 cmake --preset clang-14 -DCMAKE_C_COMPILER=/usr/bin/clang-14 -DCMAKE_CXX_COMPILER=/usr/bin/clang++-14
@@ -158,6 +176,17 @@ tasks:
ctest -C Release ctest -C Release
ctest -C Debug ctest -C Debug
echo "🛠️ clang-14 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️" echo "🛠️ clang-14 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: clang-15
init: |
gp sync-await conan-init
conan install . -pr clang15 -c user.build:all=True -c user.build:skip_docs=True -b outdated
conan install . -pr clang15 -c user.build:all=True -c user.build:skip_docs=True -b outdated -s build_type=Debug
cmake --preset clang-15 -DCMAKE_C_COMPILER=/usr/bin/clang-15 -DCMAKE_CXX_COMPILER=/usr/bin/clang++-15
cmake --build --preset clang-15-release -j
cmake --build --preset clang-15-debug -j
ctest -C Release
ctest -C Debug
echo "🛠️ clang-15 pre-build done! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: documentation - name: documentation
init: | init: |
gp sync-await conan-init gp sync-await conan-init

View File

@@ -12,11 +12,11 @@ below or prefix any `mp-units` URL (main branch, other branches, issues, PRs, ..
The above environment provides you with: The above environment provides you with:
- all supported compilers for Linux development (`g++-10`, `g++-11`, `clang-12`, `clang-13`) and build tools like `cmake` and `conan` - all supported compilers for Linux development (`g++-10`, `g++-11`, `g++12`, `clang-12`, `clang-13`, `clang-14`, and `clang-15`)
and the latest version of build tools like `cmake` and `conan`
- all Conan dependencies preinstalled on the machine - all Conan dependencies preinstalled on the machine
- all documentation generation tools ready to use - all documentation generation tools ready to use
- completed prebuilds for all targets (each compiler as well as a documentation) - completed prebuilds for all targets (Debug and Release builds for each compiler as well as a documentation)
- `clang-format-15` for source code formatting
- VSCode preconfigured to benefit from all the above - VSCode preconfigured to benefit from all the above
## Download, Build, Install ## Download, Build, Install