Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat github action for windows with clang #1205

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Configure CMake
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/macos-ustk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Clone ustk-dataset
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Clone visp_sample
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/other-arch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
apt-get update && apt-get install -y libssl-dev libusb-1.0-0-dev pkg-config libgtk-3-dev libglfw3-dev libgl1-mesa-dev libglu1-mesa-dev

git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
export VISP_INPUT_IMAGE_PATH=$HOME
export VISP_INPUT_IMAGE_PATH=$HOME/visp-images
echo ${VISP_INPUT_IMAGE_PATH}

pwd
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu-dep-apt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Clone visp_sample
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu-dep-src.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Configure CMake
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu-sanitizers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Configure CMake
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu-ustk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Clone ustk-dataset
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/valgrind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=$HOME/visp-images" >> $GITHUB_ENV
echo ${VISP_INPUT_IMAGE_PATH}

- name: Configure CMake
Expand Down
75 changes: 75 additions & 0 deletions .github/workflows/windows-clang.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: Windows - clang
on:
pull_request:
push:

jobs:
build:
runs-on: ${{ matrix.os }}
defaults:
run:
shell: cmd
strategy:
fail-fast: false
matrix:
name: [windows-latest-clang]

include:
- name: windows-latest-clang
os: windows-2022
compiler: clang-cl

steps:
# https://github.com/marketplace/actions/cancel-workflow-action
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.9.1
with:
access_token: ${{ github.token }}

- name: Checkout repository
uses: actions/checkout@v3

- name: Display the workspace path
working-directory: ${{ github.workspace }}
run: pwd

- name: Clone visp-images
shell: bash
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=C:\Users\runneradmin\visp-images" >> $GITHUB_ENV

- name: Configure ViSP
working-directory: ${{ github.workspace }}
run: |
mkdir build
cd build
cmake .. -G "Visual Studio 17 2022" -T "ClangCl" -A "x64"
type ViSP-third-party.txt

- name: Build ViSP
working-directory: build
run: |
cmake --build . --config Release

- name: Install ViSP
working-directory: build
run: |
cmake --build . --config Release --target install

- name: Check installation folder
working-directory: build
run: |
dir ${{ github.workspace }}\build\install\
dir ${{ github.workspace }}\build\install\x64\
dir ${{ github.workspace }}\build\install\x64\vc17\
dir ${{ github.workspace }}\build\install\x64\vc17\bin

- name: Test ViSP
working-directory: build
run: |
set PATH=%PATH%;${{ github.workspace }}\build\install\x64\vc17\bin
echo "PATH: "
echo %PATH%
ctest --output-on-failure -C Release -V
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,14 @@ jobs:
# https://remarkablemark.org/blog/2022/09/25/check-git-branch-exists-in-remote-repository/
run: |
git clone --depth 1 https://github.com/lagadic/visp-images ${HOME}/visp-images
echo "VISP_INPUT_IMAGE_PATH=$HOME" >> $GITHUB_ENV
echo "VISP_INPUT_IMAGE_PATH=C:\Users\runneradmin\visp-images" >> $GITHUB_ENV

- name: Configure ViSP
working-directory: ${{ github.workspace }}
run: |
mkdir build
cd build
cmake .. -G "Visual Studio 16 2019" -A "x64" -DCMAKE_GENERATOR_PLATFORM=x64
cmake .. -G "Visual Studio 16 2019" -A "x64"
type ViSP-third-party.txt

- name: Build ViSP
Expand All @@ -65,7 +65,6 @@ jobs:
- name: Test ViSP
working-directory: build
run: |
echo "VISP_INPUT_IMAGE_PATH: ${{ env.VISP_INPUT_IMAGE_PATH }}"
set PATH=%PATH%;${{ github.workspace }}\build\install\x64\vc16\bin
echo "PATH: "
echo %PATH%
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/clapack/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ if(NOT BUILD_SHARED_LIBS)
vp_install_target(${LAPACK_LIBRARY} EXPORT VISPModules ARCHIVE DESTINATION ${VISP_3P_LIB_INSTALL_PATH} COMPONENT dev)
endif()

if(MSVC)
if(MSVC AND NOT ((CMAKE_CXX_COMPILER MATCHES "clang") OR (CMAKE_CXX_COMPILER_ID MATCHES "Clang")))
# Disable Visual C++ warnings
foreach(f ${lib_srcs})
vp_set_source_file_compile_flag(${f} /wd4244 /wd4267 /wd4273 /wd4554 /wd4723 /wd4996)
Expand Down
Loading