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

Update Yaml files for Checked C continuous integration jobs #2

Merged
merged 7 commits into from
Sep 24, 2024
Merged
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
4 changes: 2 additions & 2 deletions .github/workflows/check-clang-linux.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Checked C Clang CI Linux]
name: Checked C Clang CI [Linux]

on:
workflow_dispatch:
Expand All @@ -18,7 +18,7 @@ on:
clang_repo:
description: 'Clang Repo name'
required: true
default: 'https://github.com/checkedc/checkedc-llvm-project.git'
default: 'https://github.com/checkedc/checkedc-clang.git'
testType:
description: 'Test Type'
required: true
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/check-clang-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:
clang_repo:
description: 'Clang Repo name'
required: true
default: 'https://github.com/checkedc/checkedc-llvm-project.git'
default: 'https://github.com/checkedc/checkedc-clang.git'
testType:
description: 'Test Type'
required: true
Expand Down Expand Up @@ -47,8 +47,12 @@ env:
jobs:
test_CheckedC_Clang_on_windows :
name: Build Checked C clang and test it on Windows
runs-on: [ self-hosted, Windows, X64 ]
runs-on: [ windows-latest ]
steps:
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Checkout Checked C Clang code
uses: actions/checkout@v2
with:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/checkedc-clang-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:
clang_repo:
description: 'Clang Repo name'
required: true
default: 'https://github.com/checkedc/checkedc-llvm-project.git'
default: 'https://github.com/checkedc/checkedc-clang.git'
testType:
description: 'Test Type'
required: true
Expand All @@ -42,7 +42,7 @@ jobs:
# Cleanup files left behind by prior runs
clean:
name: Clean
runs-on: macOS
runs-on: [ macos-latest ]
steps:
- name: Clean
run: |
Expand All @@ -53,10 +53,10 @@ jobs:
rm -rf ${{env.BUILD_SOURCESDIRECTORY}}
mkdir -p ${{env.BUILD_SOURCESDIRECTORY}}

test_CheckedC_Clang_UNIX:
test_CheckedC_Clang_MacOS:
name: Build and test Checked C Clang on MacOS
needs: clean
runs-on: macOS
runs-on: [ macos-latest ]
steps:
- name: Checkout Checked C Clang code
uses: actions/checkout@v2
Expand Down
2 changes: 2 additions & 0 deletions test_scripts/automation/UNIX/config-vars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,8 @@ if [ "$CHECKEDC_CONFIG_STATUS" == "passed" ]; then
echo "Configured environment variables:"
echo
echo " BUILDCONFIGURATION: $BUILDCONFIGURATION"
echo " CLANG_REPO: $CLANG_REPO"
echo " CHECKEDC_REPO: $CHECKEDC_REPO"
echo " BUILD_PACKAGE: $BUILD_PACKAGE"
echo " BUILDOS: $BUILDOS"
echo " TEST_TARGET_ARCH: $TEST_TARGET_ARCH"
Expand Down
12 changes: 12 additions & 0 deletions test_scripts/automation/Windows/config-vars.bat
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,16 @@ if NOT DEFINED BUILDCONFIGURATION (
exit /b 1
)

if NOT DEFINED CLANG_REPO (
echo CLANG_REPO not set: must be set to the URL of the Clang repository
exit /b /1
)

if NOT DEFINED CHECKEDC_REPO (
echo CHECKEDC_REPO not set: must be set to the URL of the Clang repository
exit /b /1
)

rem Validate build OS

if NOT DEFINED BUILDOS (
Expand Down Expand Up @@ -195,6 +205,8 @@ if NOT DEFINED MSBUILD_CPU_COUNT (
echo Configured environment variables:
echo.
echo. BUILDCONFIGURATION: %BUILDCONFIGURATION%
echo. CLANG_REPO: %CLANG_REPO%
echo. CHECKEDC_REPO: %CHECKEDC_REPO%
echo. BUILDOS: %BUILDOS%
echo. TEST_TARGET_ARCH: %TEST_TARGET_ARCH%
echo. TEST_SUITE: %TEST_SUITE%
Expand Down
2 changes: 1 addition & 1 deletion test_scripts/automation/Windows/run-cmake.bat
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ set OLD_DIR=%CD%

cd %LLVM_OBJ_DIR%

cmake -G Ninja %EXTRA_FLAGS% -DCMAKE_BUILD_TYPE=%BUILDCONFIGURATION% -DLLVM_ENABLE_PROJECTS=clang -DLLVM_INSTALL_TOOLCHAIN_ONLY=ON %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project\llvm
cmake -G Ninja %EXTRA_FLAGS% -DCMAKE_BUILD_TYPE=%BUILDCONFIGURATION% -DLLVM_ENABLE_PROJECTS=clang -DLLVM_INSTALL_TOOLCHAIN_ONLY=ON %BUILD_SOURCESDIRECTORY%\checkedc-clang\llvm

:succeeded
cd %OLD_DIR%
Expand Down
12 changes: 6 additions & 6 deletions test_scripts/automation/Windows/setup-files.bat
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ if "%BUILD_CHECKEDC_CLEAN%"=="Yes" (
)
)

if not exist %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project\.git (
git clone -c core.autocrlf=false https://github.com/checkedc/checkedc-llvm-project %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project
if not exist %BUILD_SOURCESDIRECTORY%\checkedc-clang\.git (
git clone -c core.autocrlf=false %CLANG_REPO% %BUILD_SOURCESDIRECTORY%\checkedc-clang
if ERRORLEVEL 1 (goto cmdfailed)
)

if not exist %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project\llvm\projects\checkedc-wrapper\checkedc\.git (
git clone https://github.com/checkedc/checkedc %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project\llvm\projects\checkedc-wrapper\checkedc
if not exist %BUILD_SOURCESDIRECTORY%\checkedc-clang\llvm\projects\checkedc-wrapper\checkedc\.git (
git clone %CHECKEDC_REPO% %BUILD_SOURCESDIRECTORY%\checkedc-clang\llvm\projects\checkedc-wrapper\checkedc
if ERRORLEVEL 1 (goto cmdfailed)
)

Expand All @@ -34,7 +34,7 @@ if "%SIGN_INSTALLER%" NEQ "No" (
)

rem Set up clang sources
cd %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project
cd %BUILD_SOURCESDIRECTORY%\checkedc-clang
if ERRORLEVEL 1 (goto cmdfailed)
git fetch origin
if ERRORLEVEL 1 (goto cmdfailed)
Expand All @@ -52,7 +52,7 @@ if not exist %LLVM_OBJ_DIR% (
)

rem set up Checked C sources
cd %BUILD_SOURCESDIRECTORY%\checkedc-llvm-project\llvm\projects\checkedc-wrapper\checkedc
cd %BUILD_SOURCESDIRECTORY%\checkedc-clang\llvm\projects\checkedc-wrapper\checkedc
if ERRORLEVEL 1 (goto cmdfailed)
git fetch origin
if ERRORLEVEL 1 (goto cmdfailed)
Expand Down
Loading