Skip to content

Commit ae2f207

Browse files
committed
Merge branch 'master' of https://github.com/learning-process/parallel_programming_course into an/unite-tests
# Conflicts: # tasks/CMakeLists.txt
2 parents e16b65d + 6d32569 commit ae2f207

3 files changed

Lines changed: 151 additions & 1 deletion

File tree

.github/workflows/main.yml

Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,55 @@ jobs:
8989
with:
9090
name: ubuntu-gcc-install-${{ matrix.os }}
9191
path: ubuntu-gcc-install-${{ matrix.os }}.tar.gz
92+
ubuntu-gcc-build-debug:
93+
needs:
94+
- clang-format
95+
- python-lint
96+
runs-on: ${{ matrix.os }}
97+
strategy:
98+
matrix:
99+
os: ["ubuntu-24.04"]
100+
steps:
101+
- uses: actions/checkout@v4
102+
with:
103+
submodules: recursive
104+
- name: Setup environment
105+
run: |
106+
sudo apt-get update
107+
sudo apt-get install --no-install-recommends -y gcc-14 g++-14 ninja-build libmpich-dev libomp-dev valgrind
108+
python3 -m pip install -r requirements.txt
109+
- name: ccache
110+
uses: hendrikmuhs/ccache-action@v1.2
111+
with:
112+
key: ${{ runner.os }}-gcc
113+
create-symlink: true
114+
max-size: 1G
115+
- name: CMake configure
116+
run: >
117+
cmake -S . -B build
118+
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
119+
-G Ninja
120+
-D CMAKE_BUILD_TYPE=DEBUG -DCMAKE_INSTALL_PREFIX=install
121+
env:
122+
CC: gcc-14
123+
CXX: g++-14
124+
- name: Build project
125+
run: |
126+
cmake --build build --parallel
127+
env:
128+
CC: gcc-14
129+
CXX: g++-14
130+
- name: Install project
131+
run: |
132+
cmake --build build --target install
133+
- name: Archive installed package
134+
run: |
135+
tar -czvf ubuntu-gcc-debug-install-${{ matrix.os }}.tar.gz -C install .
136+
- name: Upload installed package
137+
uses: actions/upload-artifact@v4
138+
with:
139+
name: ubuntu-gcc-debug-install-${{ matrix.os }}
140+
path: ubuntu-gcc-debug-install-${{ matrix.os }}.tar.gz
92141
ubuntu-gcc-test:
93142
needs:
94143
- ubuntu-gcc-build
@@ -564,6 +613,51 @@ jobs:
564613
with:
565614
name: macos-clang-sanitizer-install
566615
path: macos-clang-sanitizer-install.tar.gz
616+
macos-clang-build-debug:
617+
needs:
618+
- clang-format
619+
- python-lint
620+
runs-on: macOS-latest
621+
steps:
622+
- uses: actions/checkout@v4
623+
with:
624+
submodules: recursive
625+
- name: Setup environment
626+
run: |
627+
brew update-reset
628+
brew install ninja mpich llvm
629+
brew install libomp
630+
brew link libomp --overwrite --force
631+
brew install openssl
632+
brew link openssl --overwrite --force
633+
- name: ccache
634+
uses: hendrikmuhs/ccache-action@v1.2
635+
with:
636+
key: ${{ runner.os }}-clang
637+
create-symlink: true
638+
max-size: 1G
639+
- name: CMake configure
640+
run: >
641+
cmake -S . -B build
642+
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
643+
-G Ninja -DCMAKE_C_FLAGS="-I$(brew --prefix)/opt/libomp/include"
644+
-DCMAKE_CXX_FLAGS="-I$(brew --prefix)/opt/libomp/include"
645+
-D CMAKE_BUILD_TYPE=DEBUG
646+
-DCMAKE_INSTALL_PREFIX=install
647+
- name: Build project
648+
run: |
649+
cmake --build build --parallel
650+
- name: Install project
651+
run: |
652+
cmake --build build --target install
653+
- name: Archive installed package
654+
run: |
655+
tar -czvf macos-clang-debug-install.tar.gz -C install .
656+
- name: Upload installed package
657+
uses: actions/upload-artifact@v4
658+
with:
659+
name: macos-clang-debug-install
660+
path: macos-clang-debug-install.tar.gz
567661
macos-clang-test:
568662
needs:
569663
- macos-clang-build
@@ -717,6 +811,55 @@ jobs:
717811
with:
718812
name: windows-msvc-install
719813
path: windows-msvc-install.zip
814+
windows-msvc-build-debug:
815+
needs:
816+
- clang-format
817+
- python-lint
818+
runs-on: windows-latest
819+
defaults:
820+
run:
821+
shell: bash
822+
steps:
823+
- uses: actions/checkout@v4
824+
with:
825+
submodules: recursive
826+
- name: Add msbuild to PATH
827+
uses: microsoft/setup-msbuild@v2
828+
with:
829+
vs-version: 'latest'
830+
- name: Setup MPI
831+
uses: mpi4py/setup-mpi@v1
832+
with:
833+
mpi: msmpi
834+
- name: Setup ccache
835+
uses: Chocobo1/setup-ccache-action@v1
836+
with:
837+
windows_compile_environment: msvc
838+
- name: Setup ninja
839+
uses: seanmiddleditch/gha-setup-ninja@v6
840+
- name: Setup MSVC for Ninja again
841+
uses: ilammy/msvc-dev-cmd@v1
842+
- name: CMake configure
843+
shell: bash
844+
run: >
845+
cmake -S . -B build -G Ninja -D CMAKE_C_COMPILER=cl -DCMAKE_CXX_COMPILER=cl
846+
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
847+
-D CMAKE_BUILD_TYPE=DEBUG -DCMAKE_INSTALL_PREFIX=install
848+
- name: Build project
849+
shell: bash
850+
run: |
851+
cmake --build build --config Debug --parallel
852+
- name: Install project
853+
run: |
854+
cmake --build build --target install
855+
- name: Archive installed package
856+
run: Compress-Archive -Path install -DestinationPath windows-msvc-debug-install.zip
857+
shell: pwsh
858+
- name: Upload installed package
859+
uses: actions/upload-artifact@v4
860+
with:
861+
name: windows-msvc-debug-install
862+
path: windows-msvc-debug-install.zip
720863
windows-msvc-test:
721864
needs:
722865
- windows-msvc-build

cmake/onetbb.cmake

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,10 @@ ExternalProject_Add(ppc_onetbb
2525
)
2626
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/ppc_onetbb/install/"
2727
DESTINATION "${CMAKE_INSTALL_PREFIX}")
28+
29+
string(TOLOWER "${CMAKE_BUILD_TYPE}" cmake_build_type_lower)
30+
if(cmake_build_type_lower STREQUAL "debug")
31+
set(PPC_TBB_LIB_NAME tbb_debug)
32+
else()
33+
set(PPC_TBB_LIB_NAME tbb)
34+
endif()

docs/_templates/footer.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
{% if code == language %}
2828
<span class="current-language">{{ name }}</span>
2929
{% else %}
30-
<a href="/{{ code }}/{{ pagename }}.html">{{ name }}</a>
30+
<a href="../{{ code }}/{{ pagename }}.html">{{ name }}</a>
3131
{% endif %}
3232
{% if not loop.last %} | {% endif %}
3333
{% endfor %}

0 commit comments

Comments
 (0)