From 36287404831db22d94d6e163ef65ae58e2bc2391 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:38:42 -0500 Subject: [PATCH 01/48] Add container 16.04 build --- .github/workflows/build_cmake.yml | 2 - .github/workflows/build_nilrt.yml | 2 - .github/workflows/build_ubuntu.yml | 233 +++++++++++++++++++++++++++++ 3 files changed, 233 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/build_ubuntu.yml diff --git a/.github/workflows/build_cmake.yml b/.github/workflows/build_cmake.yml index a6fc53885..d961eb238 100644 --- a/.github/workflows/build_cmake.yml +++ b/.github/workflows/build_cmake.yml @@ -5,8 +5,6 @@ on: branches: - main - 'releases/**' - pull_request: - types: [opened, synchronize, reopened] workflow_dispatch: env: diff --git a/.github/workflows/build_nilrt.yml b/.github/workflows/build_nilrt.yml index 611e2bb95..92ae37f8e 100644 --- a/.github/workflows/build_nilrt.yml +++ b/.github/workflows/build_nilrt.yml @@ -5,8 +5,6 @@ on: branches: - main - 'releases/**' - pull_request: - types: [opened, synchronize, reopened] workflow_dispatch: env: diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml new file mode 100644 index 000000000..5d32c0279 --- /dev/null +++ b/.github/workflows/build_ubuntu.yml @@ -0,0 +1,233 @@ +name: Ubuntu build + +on: + push: + branches: + - main + - 'releases/**' + pull_request: + types: [opened, synchronize, reopened] + workflow_dispatch: + +jobs: + build: + name: Build with ubuntu 16.04 + runs-on: ubuntu-latest + container: + image: ubuntu:16.04 + env: + CMAKE_VERSION: 3.18.3 + BUILD_TYPE: Release + ports: + - 80 + options: --cpus 2 + + steps: + - name: Cancel Build(s) + uses: styfle/cancel-workflow-action@0.7.0 + if: "github.ref != 'refs/heads/main'" + with: + access_token: ${{ github.token }} + + - name: Checkout Repo + uses: actions/checkout@v2 + + - name: Setup python3 + uses: actions/setup-python@v2 + with: + python-version: '3.x' + + - name: Install mako + run: python -m pip install mako + + - name: Install dev tools + run: sudo apt install -y build-essential cmake + + - name: Update Submodules + run: git submodule update --init --recursive + + - name: Configure + shell: cmake -P {0} + run: | + set(ENV{CC} ${{ matrix.config.cc }}) + set(ENV{CXX} ${{ matrix.config.cxx }}) + set(path_separator ":") + if ("${{ runner.os }}" STREQUAL "Windows") + set(path_separator ";") + endif() + set(ENV{PATH} "$ENV{GITHUB_WORKSPACE}${path_separator}$ENV{PATH}") + execute_process( + COMMAND cmake + -S . + -B build + -D CMAKE_BUILD_TYPE=$ENV{BUILD_TYPE} + ${{ matrix.config.cmake_platform }} + RESULT_VARIABLE result + ) + if (NOT result EQUAL 0) + message(FATAL_ERROR "Bad exit status") + endif() + + - name: Build + shell: cmake -P {0} + run: | + execute_process( + COMMAND cmake --build build --config $ENV{BUILD_TYPE} ${{ matrix.config.cmake_number_of_jobs }} + RESULT_VARIABLE result + OUTPUT_VARIABLE output + ERROR_VARIABLE output + ECHO_OUTPUT_VARIABLE ECHO_ERROR_VARIABLE + ) + if (NOT result EQUAL 0) + string(REGEX MATCH "FAILED:.*$" error_message "${output}") + string(REPLACE "\n" "%0A" error_message "${error_message}") + message("::error::${error_message}") + message(FATAL_ERROR "Build failed") + endif() + + - name: Run Tests + shell: cmake -P {0} + run: | + include(ProcessorCount) + ProcessorCount(N) + + execute_process( + COMMAND ctest -j ${N} -C $ENV{BUILD_TYPE} -E System --output-on-failure + WORKING_DIRECTORY build + RESULT_VARIABLE result + ) + if (NOT result EQUAL 0) + message(FATAL_ERROR "Running tests failed!") + endif() + + - name: Tar Linux Server Binaries + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + run: >- + tar -cvzf ni-grpc-device-server-linux-glibc2_23-x64.tar.gz + -C ${GITHUB_WORKSPACE}/build + ni_grpc_device_server + server_config.json + -C ${GITHUB_WORKSPACE} + LICENSE + ThirdPartyNotices.txt + + - name: Upload Linux Server Binaries Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + with: + name: ni-grpc-device-server-linux-glibc2_23-x64 + path: ni-grpc-device-server-linux-glibc2_23-x64.tar.gz + retention-days: 5 + + - name: Tar Linux Test Binaries + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + run: >- + tar -cvzf ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz + -C ${GITHUB_WORKSPACE}/build + certs/ + IntegrationTestsRunner + libTestApi.so + SystemTestsRunner + test_mutual_tls_config.json + UnitTestsRunner + -C ${GITHUB_WORKSPACE} + LICENSE + ThirdPartyNotices.txt + + - name: Upload Linux Test Binaries Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + with: + name: ni-grpc-device-tests-linux-glibc2_23-x64 + path: ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz + retention-days: 5 + + - name: Stage Linux Client Files + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + run: | + mkdir -p ${{ runner.temp }}/staging/proto + cp generated/**/*.proto source/protobuf/*.proto ${{ runner.temp }}/staging/proto + cp -r examples/ ${{ runner.temp }}/staging/ + cp LICENSE ThirdPartyNotices.txt ${{ runner.temp }}/staging/ + tar -cvzf ni-grpc-device-client.tar.gz -C ${{ runner.temp }}/staging/ --exclude *nifake* examples/ proto/ LICENSE ThirdPartyNotices.txt + + - name: Upload Linux Client Files Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + with: + name: ni-grpc-device-client-Linux + path: ni-grpc-device-client.tar.gz + retention-days: 5 + + - name: Upload Windows Server Binaries Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} + with: + name: ni-grpc-device-server-windows-x64 + path: | + build/Release/ni_grpc_device_server.exe + build/Release/server_config.json + LICENSE + ThirdPartyNotices.txt + retention-days: 5 + + - name: Upload Windows Test Binaries Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} + with: + name: ni-grpc-device-tests-windows-x64 + path: | + build/Release/certs/ + build/Release/IntegrationTestsRunner.exe + build/Release/TestApi.dll + build/Release/SystemTestsRunner.exe + build/Release/test_mutual_tls_config.json + build/Release/UnitTestsRunner.exe + LICENSE + ThirdPartyNotices.txt + retention-days: 5 + + - name: Stage Windows Client Files + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} + shell: powershell + run: | + mkdir "${{ runner.temp }}/staging/proto" + Copy-Item "source/protobuf/*.proto", "generated/**/*.proto" -Exclude "*nifake*" -Destination "${{ runner.temp }}/staging/proto/" + Copy-Item "examples/" -Recurse -Destination "${{ runner.temp }}/staging/" + Copy-Item "LICENSE","ThirdPartyNotices.txt" -Destination "${{ runner.temp }}/staging/" + + - name: Upload Windows Client Files Artifact + uses: actions/upload-artifact@v2 + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} + with: + name: ni-grpc-device-client + path: | + ${{ runner.temp }}/staging + retention-days: 5 + + trigger_main_ci: + name: Trigger Main CI + needs: build + runs-on: windows-latest + if: ${{ github.repository == 'ni/grpc-device' && github.ref == 'refs/heads/main' }} + steps: + - name: Trigger Main CI + uses: Azure/pipelines@v1 + with: + azure-devops-project-url: 'https://dev.azure.com/ni/DevCentral' + azure-pipeline-name: 'ni-central-grpc-device-main-desktop' + azure-devops-token: ${{ secrets.AZDO_PIPELINE_TRIGGERS }} + + trigger_release_ci: + name: Trigger Release CI + needs: build + runs-on: windows-latest + if: ${{ github.repository == 'ni/grpc-device' && startsWith(github.ref, 'refs/heads/releases') }} + steps: + - name: Trigger Release CI + uses: Azure/pipelines@v1 + with: + azure-devops-project-url: 'https://dev.azure.com/ni/DevCentral' + azure-pipeline-name: 'ni-central-grpc-device-release-desktop' + azure-devops-token: ${{ secrets.AZDO_PIPELINE_TRIGGERS }} + From 148038b6f9dc2ef8ec716b2b5b014442d2d5de87 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:42:43 -0500 Subject: [PATCH 02/48] install cmake --- .github/workflows/build_ubuntu.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 5d32c0279..bb4fbfd3a 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -29,6 +29,11 @@ jobs: with: access_token: ${{ github.token }} + - name: Install dependencies + run: | + apt update + apt install -y cmake + - name: Checkout Repo uses: actions/checkout@v2 @@ -40,9 +45,6 @@ jobs: - name: Install mako run: python -m pip install mako - - name: Install dev tools - run: sudo apt install -y build-essential cmake - - name: Update Submodules run: git submodule update --init --recursive From 1a292b713403214bb82f986fff23c6130b57acf1 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:47:10 -0500 Subject: [PATCH 03/48] python --- .github/workflows/build_ubuntu.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index bb4fbfd3a..214a92fea 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -32,16 +32,11 @@ jobs: - name: Install dependencies run: | apt update - apt install -y cmake + apt install -y cmake python3-pip - name: Checkout Repo uses: actions/checkout@v2 - - name: Setup python3 - uses: actions/setup-python@v2 - with: - python-version: '3.x' - - name: Install mako run: python -m pip install mako From 285817df329859d7a785c83181d7a78dab3e72e0 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:49:27 -0500 Subject: [PATCH 04/48] more python --- .github/workflows/build_ubuntu.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 214a92fea..35559cef9 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,6 +33,7 @@ jobs: run: | apt update apt install -y cmake python3-pip + update-alternatives --install /usr/bin/python python /usr/bin/python3 10 - name: Checkout Repo uses: actions/checkout@v2 From 68fe7f403c08bc3fedf0945de9f0b5f84349a00d Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:50:59 -0500 Subject: [PATCH 05/48] git --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 35559cef9..0d34094b2 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -32,7 +32,7 @@ jobs: - name: Install dependencies run: | apt update - apt install -y cmake python3-pip + apt install -y cmake python3-pip git update-alternatives --install /usr/bin/python python /usr/bin/python3 10 - name: Checkout Repo From 06a7bbe9dab5851f959c3c1f3283883b1777122e Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 16:57:01 -0500 Subject: [PATCH 06/48] cd --- .github/workflows/build_ubuntu.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 0d34094b2..647b07052 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -42,7 +42,9 @@ jobs: run: python -m pip install mako - name: Update Submodules - run: git submodule update --init --recursive + run: | + cd "$GITHUB_WORKSPACE" + git submodule update --init --recursive - name: Configure shell: cmake -P {0} From 4fd9a3c2a8240dda467e00328dea43d443e90684 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:03:45 -0500 Subject: [PATCH 07/48] g --- .github/workflows/build_ubuntu.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 647b07052..d84a51371 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -43,7 +43,9 @@ jobs: - name: Update Submodules run: | - cd "$GITHUB_WORKSPACE" + cd ${GITHUB_WORKSPACE} + pwd + ls git submodule update --init --recursive - name: Configure From 420ff9a72aa9ee5e11ce91f390337cef7d4d4d77 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:07:53 -0500 Subject: [PATCH 08/48] j --- .github/workflows/build_ubuntu.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index d84a51371..7267e5ab7 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,16 +37,16 @@ jobs: - name: Checkout Repo uses: actions/checkout@v2 + with: + submodules: 'recursive' - name: Install mako run: python -m pip install mako - - name: Update Submodules + - name: Print state run: | - cd ${GITHUB_WORKSPACE} pwd ls - git submodule update --init --recursive - name: Configure shell: cmake -P {0} From 0d23489256809f389b3257d89f18005678cb5692 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:12:11 -0500 Subject: [PATCH 09/48] add repo --- .github/workflows/build_ubuntu.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 7267e5ab7..cd1b5549b 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -31,6 +31,7 @@ jobs: - name: Install dependencies run: | + add-apt-repository ppa:git-core/ppa apt update apt install -y cmake python3-pip git update-alternatives --install /usr/bin/python python /usr/bin/python3 10 From adbd775607fde971e0b3e81cb6eb770b050887d8 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:15:20 -0500 Subject: [PATCH 10/48] still --- .github/workflows/build_ubuntu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index cd1b5549b..b6fc03e3c 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -31,7 +31,8 @@ jobs: - name: Install dependencies run: | - add-apt-repository ppa:git-core/ppa + apt-get install software-properties-common python-software-properties + add-apt-repository -y ppa:git-core/ppa apt update apt install -y cmake python3-pip git update-alternatives --install /usr/bin/python python /usr/bin/python3 10 From 232848b4f439f29d96ae8de75ce5a7c56fd4eefc Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:16:54 -0500 Subject: [PATCH 11/48] t --- .github/workflows/build_ubuntu.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index b6fc03e3c..87ca49ec4 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -31,6 +31,7 @@ jobs: - name: Install dependencies run: | + apt update apt-get install software-properties-common python-software-properties add-apt-repository -y ppa:git-core/ppa apt update From c9c215897c5ffe5f263f1c30161c991585145494 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:17:44 -0500 Subject: [PATCH 12/48] y --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 87ca49ec4..00eda8c09 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -32,7 +32,7 @@ jobs: - name: Install dependencies run: | apt update - apt-get install software-properties-common python-software-properties + apt install -y software-properties-common python-software-properties add-apt-repository -y ppa:git-core/ppa apt update apt install -y cmake python3-pip git From c72bebc815ffd7924bf5ab22ae254368fb0b46db Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:33:05 -0500 Subject: [PATCH 13/48] delete matrix stuff --- .github/workflows/build_ubuntu.yml | 96 ++++-------------------------- 1 file changed, 10 insertions(+), 86 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 00eda8c09..18fc43c3e 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -18,6 +18,8 @@ jobs: env: CMAKE_VERSION: 3.18.3 BUILD_TYPE: Release + CC: gcc-9 + CXX: g++-9 ports: - 80 options: --cpus 2 @@ -35,7 +37,7 @@ jobs: apt install -y software-properties-common python-software-properties add-apt-repository -y ppa:git-core/ppa apt update - apt install -y cmake python3-pip git + apt install -y cmake python3-pip git gcc-9 update-alternatives --install /usr/bin/python python /usr/bin/python3 10 - name: Checkout Repo @@ -54,19 +56,13 @@ jobs: - name: Configure shell: cmake -P {0} run: | - set(ENV{CC} ${{ matrix.config.cc }}) - set(ENV{CXX} ${{ matrix.config.cxx }}) set(path_separator ":") - if ("${{ runner.os }}" STREQUAL "Windows") - set(path_separator ";") - endif() set(ENV{PATH} "$ENV{GITHUB_WORKSPACE}${path_separator}$ENV{PATH}") execute_process( COMMAND cmake -S . -B build -D CMAKE_BUILD_TYPE=$ENV{BUILD_TYPE} - ${{ matrix.config.cmake_platform }} RESULT_VARIABLE result ) if (NOT result EQUAL 0) @@ -77,7 +73,7 @@ jobs: shell: cmake -P {0} run: | execute_process( - COMMAND cmake --build build --config $ENV{BUILD_TYPE} ${{ matrix.config.cmake_number_of_jobs }} + COMMAND cmake --build build --config $ENV{BUILD_TYPE} -j 2 RESULT_VARIABLE result OUTPUT_VARIABLE output ERROR_VARIABLE output @@ -106,7 +102,7 @@ jobs: endif() - name: Tar Linux Server Binaries - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: >- tar -cvzf ni-grpc-device-server-linux-glibc2_23-x64.tar.gz -C ${GITHUB_WORKSPACE}/build @@ -118,14 +114,14 @@ jobs: - name: Upload Linux Server Binaries Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-server-linux-glibc2_23-x64 path: ni-grpc-device-server-linux-glibc2_23-x64.tar.gz retention-days: 5 - name: Tar Linux Test Binaries - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: >- tar -cvzf ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz -C ${GITHUB_WORKSPACE}/build @@ -141,14 +137,14 @@ jobs: - name: Upload Linux Test Binaries Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-tests-linux-glibc2_23-x64 path: ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz retention-days: 5 - name: Stage Linux Client Files - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: | mkdir -p ${{ runner.temp }}/staging/proto cp generated/**/*.proto source/protobuf/*.proto ${{ runner.temp }}/staging/proto @@ -158,81 +154,9 @@ jobs: - name: Upload Linux Client Files Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Linux') }} + if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-client-Linux path: ni-grpc-device-client.tar.gz retention-days: 5 - - name: Upload Windows Server Binaries Artifact - uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} - with: - name: ni-grpc-device-server-windows-x64 - path: | - build/Release/ni_grpc_device_server.exe - build/Release/server_config.json - LICENSE - ThirdPartyNotices.txt - retention-days: 5 - - - name: Upload Windows Test Binaries Artifact - uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} - with: - name: ni-grpc-device-tests-windows-x64 - path: | - build/Release/certs/ - build/Release/IntegrationTestsRunner.exe - build/Release/TestApi.dll - build/Release/SystemTestsRunner.exe - build/Release/test_mutual_tls_config.json - build/Release/UnitTestsRunner.exe - LICENSE - ThirdPartyNotices.txt - retention-days: 5 - - - name: Stage Windows Client Files - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} - shell: powershell - run: | - mkdir "${{ runner.temp }}/staging/proto" - Copy-Item "source/protobuf/*.proto", "generated/**/*.proto" -Exclude "*nifake*" -Destination "${{ runner.temp }}/staging/proto/" - Copy-Item "examples/" -Recurse -Destination "${{ runner.temp }}/staging/" - Copy-Item "LICENSE","ThirdPartyNotices.txt" -Destination "${{ runner.temp }}/staging/" - - - name: Upload Windows Client Files Artifact - uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases')) && (runner.os == 'Windows') }} - with: - name: ni-grpc-device-client - path: | - ${{ runner.temp }}/staging - retention-days: 5 - - trigger_main_ci: - name: Trigger Main CI - needs: build - runs-on: windows-latest - if: ${{ github.repository == 'ni/grpc-device' && github.ref == 'refs/heads/main' }} - steps: - - name: Trigger Main CI - uses: Azure/pipelines@v1 - with: - azure-devops-project-url: 'https://dev.azure.com/ni/DevCentral' - azure-pipeline-name: 'ni-central-grpc-device-main-desktop' - azure-devops-token: ${{ secrets.AZDO_PIPELINE_TRIGGERS }} - - trigger_release_ci: - name: Trigger Release CI - needs: build - runs-on: windows-latest - if: ${{ github.repository == 'ni/grpc-device' && startsWith(github.ref, 'refs/heads/releases') }} - steps: - - name: Trigger Release CI - uses: Azure/pipelines@v1 - with: - azure-devops-project-url: 'https://dev.azure.com/ni/DevCentral' - azure-pipeline-name: 'ni-central-grpc-device-release-desktop' - azure-devops-token: ${{ secrets.AZDO_PIPELINE_TRIGGERS }} - From 9349baceaaef330337f36d7463e2b28c7d262c04 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:35:33 -0500 Subject: [PATCH 14/48] gcc --- .github/workflows/build_ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 18fc43c3e..b39908ac8 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -35,9 +35,9 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties - add-apt-repository -y ppa:git-core/ppa + add-apt-repository -y ppa:git-core/ppa ppa:ubuntu-toolchain-r/test apt update - apt install -y cmake python3-pip git gcc-9 + apt install -y cmake python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/python python /usr/bin/python3 10 - name: Checkout Repo From 7d5c999e8e938d63352c340f633f3743879b5203 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:36:31 -0500 Subject: [PATCH 15/48] more gcc --- .github/workflows/build_ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index b39908ac8..5dc149d5b 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -18,8 +18,6 @@ jobs: env: CMAKE_VERSION: 3.18.3 BUILD_TYPE: Release - CC: gcc-9 - CXX: g++-9 ports: - 80 options: --cpus 2 @@ -39,6 +37,8 @@ jobs: apt update apt install -y cmake python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/python python /usr/bin/python3 10 + update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 + update-alternatives --config gcc - name: Checkout Repo uses: actions/checkout@v2 From 78b804788b40d5e0392282bd1f1081e489394d4e Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:43:02 -0500 Subject: [PATCH 16/48] m --- .github/workflows/build_ubuntu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 5dc149d5b..be998aad1 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,7 +33,8 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties - add-apt-repository -y ppa:git-core/ppa ppa:ubuntu-toolchain-r/test + add-apt-repository -y ppa:git-core/ppa + add-apt-repository -y ppa:ubuntu-toolchain-r/test apt update apt install -y cmake python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/python python /usr/bin/python3 10 From 32d6a78a9f2dd336add548863587fa922e9f13df Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 17:54:55 -0500 Subject: [PATCH 17/48] wtf --- .github/workflows/build_ubuntu.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index be998aad1..defd5ebdc 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -64,6 +64,7 @@ jobs: -S . -B build -D CMAKE_BUILD_TYPE=$ENV{BUILD_TYPE} + RESULT_VARIABLE result ) if (NOT result EQUAL 0) From 57b6e9fe1c5931f6ce00daed4a619231c17fa929 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 18:01:22 -0500 Subject: [PATCH 18/48] version --- .github/workflows/build_ubuntu.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index defd5ebdc..48bd5b166 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -53,6 +53,7 @@ jobs: run: | pwd ls + cmake --version - name: Configure shell: cmake -P {0} @@ -63,8 +64,8 @@ jobs: COMMAND cmake -S . -B build - -D CMAKE_BUILD_TYPE=$ENV{BUILD_TYPE} - + -DCMAKE_BUILD_TYPE=$ENV{BUILD_TYPE} + RESULT_VARIABLE result ) if (NOT result EQUAL 0) From f76b3fe39a92fcb7c25655f1bcfb9677dd910db3 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 18:06:38 -0500 Subject: [PATCH 19/48] cmake newer --- .github/workflows/build_ubuntu.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 48bd5b166..e4341337a 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -32,7 +32,9 @@ jobs: - name: Install dependencies run: | apt update - apt install -y software-properties-common python-software-properties + apt install -y software-properties-common python-software-properties lsb-release + wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null + apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test apt update From bbe34dcf4d609c10e9341ea02f87ad78cdb17b45 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:03:33 -0500 Subject: [PATCH 20/48] no check cert --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index e4341337a..3419afca0 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,7 +33,7 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties lsb-release - wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null + wget --no-check-certificate -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test From 1ada2960ef08a4e70816424b707e097235b0c1a1 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:05:22 -0500 Subject: [PATCH 21/48] no check cert --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 3419afca0..3272f1350 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,7 +33,7 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties lsb-release - wget --no-check-certificate -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null + wget --no-check-certificate -vO - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test From d6b0deddaefcd38071bd62f06dc921d5d497f3ad Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:06:01 -0500 Subject: [PATCH 22/48] no check cert --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 3272f1350..ab47aed51 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,7 +33,7 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties lsb-release - wget --no-check-certificate -vO - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null + wget --no-check-certificate -vO - https://apt.kitware.com/keys/kitware-archive-latest.asc | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test From c6d572761f9acaed1c46aac5e410010a5d7a2e73 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:11:03 -0500 Subject: [PATCH 23/48] s --- .github/workflows/build_ubuntu.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index ab47aed51..5d9c89915 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -33,16 +33,21 @@ jobs: run: | apt update apt install -y software-properties-common python-software-properties lsb-release - wget --no-check-certificate -vO - https://apt.kitware.com/keys/kitware-archive-latest.asc | gpg --dearmor - | sudo tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null - apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test apt update - apt install -y cmake python3-pip git gcc-9 g++-9 + apt install -y python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/python python /usr/bin/python3 10 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc + - name: Setup cmake + uses: jwlawson/actions-setup-cmake@v1.9 + with: + cmake-version: '3.16.x' + - name: Use cmake + run: cmake --version + - name: Checkout Repo uses: actions/checkout@v2 with: From 73020424648de93b432c0b2265cd12851493f39d Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:38:02 -0500 Subject: [PATCH 24/48] no echo error var --- .github/workflows/build_nilrt.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build_nilrt.yml b/.github/workflows/build_nilrt.yml index 92ae37f8e..2c06d0bc0 100644 --- a/.github/workflows/build_nilrt.yml +++ b/.github/workflows/build_nilrt.yml @@ -123,7 +123,6 @@ jobs: RESULT_VARIABLE result OUTPUT_VARIABLE output ERROR_VARIABLE output - ECHO_OUTPUT_VARIABLE ECHO_ERROR_VARIABLE ) if (NOT result EQUAL 0) string(REGEX MATCH "FAILED:.*$" error_message "${output}") From 7ac8b3879aac34cbe2d29b8ae1f4c98c02229b60 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:42:17 -0500 Subject: [PATCH 25/48] no echo error var --- .github/workflows/build_ubuntu.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 5d9c89915..eb2a1f9d0 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -87,7 +87,6 @@ jobs: RESULT_VARIABLE result OUTPUT_VARIABLE output ERROR_VARIABLE output - ECHO_OUTPUT_VARIABLE ECHO_ERROR_VARIABLE ) if (NOT result EQUAL 0) string(REGEX MATCH "FAILED:.*$" error_message "${output}") From d372eff18e174ee745f5d8c38d3856d6468498cf Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:54:37 -0500 Subject: [PATCH 26/48] n --- .github/workflows/build_ubuntu.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index eb2a1f9d0..82761a546 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -82,16 +82,10 @@ jobs: - name: Build shell: cmake -P {0} run: | - execute_process( - COMMAND cmake --build build --config $ENV{BUILD_TYPE} -j 2 + cmake --build build --config $ENV{BUILD_TYPE} -j 2 RESULT_VARIABLE result - OUTPUT_VARIABLE output - ERROR_VARIABLE output ) if (NOT result EQUAL 0) - string(REGEX MATCH "FAILED:.*$" error_message "${output}") - string(REPLACE "\n" "%0A" error_message "${error_message}") - message("::error::${error_message}") message(FATAL_ERROR "Build failed") endif() From 947e1bf6d4659895bfd42c1f0fdf265c7cf2ff91 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 19:55:56 -0500 Subject: [PATCH 27/48] n --- .github/workflows/build_ubuntu.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 82761a546..7dfe6ba54 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -83,11 +83,6 @@ jobs: shell: cmake -P {0} run: | cmake --build build --config $ENV{BUILD_TYPE} -j 2 - RESULT_VARIABLE result - ) - if (NOT result EQUAL 0) - message(FATAL_ERROR "Build failed") - endif() - name: Run Tests shell: cmake -P {0} From 8d19ec4e237660a8d7be6860e07bc2d02746be49 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:02:09 -0500 Subject: [PATCH 28/48] n --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 7dfe6ba54..092f18893 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -82,7 +82,7 @@ jobs: - name: Build shell: cmake -P {0} run: | - cmake --build build --config $ENV{BUILD_TYPE} -j 2 + cmake --build build --config Release -j 2 - name: Run Tests shell: cmake -P {0} From abc0cb3a313ec8902b353246fe49f1218fbf0819 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:07:48 -0500 Subject: [PATCH 29/48] n --- .github/workflows/build_ubuntu.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 092f18893..171045b37 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -44,7 +44,7 @@ jobs: - name: Setup cmake uses: jwlawson/actions-setup-cmake@v1.9 with: - cmake-version: '3.16.x' + cmake-version: '3.18.x' - name: Use cmake run: cmake --version @@ -81,8 +81,7 @@ jobs: - name: Build shell: cmake -P {0} - run: | - cmake --build build --config Release -j 2 + run: cmake --build build -CRelease -j 2 - name: Run Tests shell: cmake -P {0} From c5eaa4fe589d551d8c7fdda16fa0359f5ce4e3c1 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:13:00 -0500 Subject: [PATCH 30/48] n --- .github/workflows/build_ubuntu.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 171045b37..05d7c9441 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -80,7 +80,6 @@ jobs: endif() - name: Build - shell: cmake -P {0} run: cmake --build build -CRelease -j 2 - name: Run Tests From c541c5a3d003586cc8c44d65582a85f3521b22cc Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:17:19 -0500 Subject: [PATCH 31/48] n --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 05d7c9441..81123f2a2 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -80,7 +80,7 @@ jobs: endif() - name: Build - run: cmake --build build -CRelease -j 2 + run: cmake --build build --config Release -j 2 - name: Run Tests shell: cmake -P {0} From 9858919497958c4b21e6577ac92c03a95e499af2 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:43:07 -0500 Subject: [PATCH 32/48] python --- .github/workflows/build_ubuntu.yml | 5 ++--- CMakeLists.txt | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 81123f2a2..0d0209a54 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -36,8 +36,7 @@ jobs: add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test apt update - apt install -y python3-pip git gcc-9 g++-9 - update-alternatives --install /usr/bin/python python /usr/bin/python3 10 + apt install -y python3.9 python3.9-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc @@ -54,7 +53,7 @@ jobs: submodules: 'recursive' - name: Install mako - run: python -m pip install mako + run: python3.9 -m pip install mako - name: Print state run: | diff --git a/CMakeLists.txt b/CMakeLists.txt index 72d386f1c..770df1af1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -45,7 +45,7 @@ set(CMAKE_CXX_EXTENSIONS OFF) #---------------------------------------------------------------------- # Find python3 for the build system #---------------------------------------------------------------------- -find_package(Python3 COMPONENTS Interpreter) +find_package(Python3 3.6...<3.10 COMPONENTS Interpreter) if(NOT ${Python3_FOUND}) message(WARNING "Python3 not found. Python3 is required for code generation.") endif() From 6ab9440be2110b69288e5360b16b5066f75b2938 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:44:41 -0500 Subject: [PATCH 33/48] python --- .github/workflows/build_ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 0d0209a54..bb960b92b 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -36,7 +36,7 @@ jobs: add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test apt update - apt install -y python3.9 python3.9-pip git gcc-9 g++-9 + apt install -y python3.8 python3.8-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc @@ -53,7 +53,7 @@ jobs: submodules: 'recursive' - name: Install mako - run: python3.9 -m pip install mako + run: python3.8 -m pip install mako - name: Print state run: | From d9417ac9198990c14b6f9e5a901d428b8ca179c1 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 20:59:34 -0500 Subject: [PATCH 34/48] python --- .github/workflows/build_ubuntu.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index bb960b92b..1a8cb8abe 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -35,6 +35,7 @@ jobs: apt install -y software-properties-common python-software-properties lsb-release add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test + add-apt-repository -y ppa:deadsnakes/ppa apt update apt install -y python3.8 python3.8-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 From f476c9763d65ffd3e4e5d226f739e260d974883f Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:07:40 -0500 Subject: [PATCH 35/48] python --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 1a8cb8abe..3a2e60605 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,7 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-pip git gcc-9 g++-9 + apt install -y python3.8 python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 9df28249378fcb5583c80031531bf336c409d2c3 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:13:58 -0500 Subject: [PATCH 36/48] python --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 3a2e60605..05324b898 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,7 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3-pip git gcc-9 g++-9 + apt install -y python3.8 python3.8-distutils python3-pip git gcc-9 g++-9 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 5ebfb4d7fbccfad3b5878cd03ebc633816bf7a2a Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:24:29 -0500 Subject: [PATCH 37/48] python --- .github/workflows/build_ubuntu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 05324b898..2b52ee0fc 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,8 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-distutils python3-pip git gcc-9 g++-9 + apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 + python3.8 -m easy_install pip update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 645813ef1b69fc920c071c24e700b31770c42c0f Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:29:25 -0500 Subject: [PATCH 38/48] python --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 2b52ee0fc..99d9ab407 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -38,7 +38,7 @@ jobs: add-apt-repository -y ppa:deadsnakes/ppa apt update apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 - python3.8 -m easy_install pip + python3.8 -m easy_install_pip update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 06d5d1fcb1ccd933b67ba72df2f7f9c5101d5e99 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:34:12 -0500 Subject: [PATCH 39/48] python --- .github/workflows/build_ubuntu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 99d9ab407..a69aed0fc 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,8 +37,8 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 - python3.8 -m easy_install_pip + apt install -y python3.8 python3.8-setuptools python3.8-distutils git gcc-9 g++-9 + python3.8 -m easy_install spip update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 019469db1dc20cedafe04984a90537c1dccf8843 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Thu, 16 Sep 2021 21:41:43 -0500 Subject: [PATCH 40/48] python --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index a69aed0fc..7f245c682 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,7 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-setuptools python3.8-distutils git gcc-9 g++-9 + apt install -y python3.8 python3-setuptools python3.8-distutils git gcc-9 g++-9 python3.8 -m easy_install spip update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 6277259b719aff2ff7cda7a8686189bf2ef7cf8b Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 12:16:50 -0500 Subject: [PATCH 41/48] spip --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 7f245c682..65165934d 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -38,7 +38,7 @@ jobs: add-apt-repository -y ppa:deadsnakes/ppa apt update apt install -y python3.8 python3-setuptools python3.8-distutils git gcc-9 g++-9 - python3.8 -m easy_install spip + python3.8 -m easy_install pip update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 5296076c578194913e1b2a9ebfe6b2dfe7bea993 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 12:25:29 -0500 Subject: [PATCH 42/48] get pip --- .github/workflows/build_ubuntu.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 65165934d..4487e3ed0 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -36,9 +36,9 @@ jobs: add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa - apt update - apt install -y python3.8 python3-setuptools python3.8-distutils git gcc-9 g++-9 - python3.8 -m easy_install pip + apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 + curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py + python3.8 get-pip.py update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 07010f761567d8e552a80e246ef4689d2e921af8 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 12:31:47 -0500 Subject: [PATCH 43/48] get pip --- .github/workflows/build_ubuntu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 4487e3ed0..d31de6918 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -36,8 +36,9 @@ jobs: add-apt-repository -y ppa:git-core/ppa add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa + apt update apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 - curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py + wget https://bootstrap.pypa.io/get-pip.py python3.8 get-pip.py update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 update-alternatives --config gcc From 22e91cf3f888413d54e3737d1e55fa717e64cf07 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 13:14:13 -0500 Subject: [PATCH 44/48] get pip --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index d31de6918..0bd58eb1b 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,7 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 + apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 wget wget https://bootstrap.pypa.io/get-pip.py python3.8 get-pip.py update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 From fd0baba10d98b75d15fb864c7f3d74934ca6f758 Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 13:27:20 -0500 Subject: [PATCH 45/48] build-essential --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 0bd58eb1b..cbe9e245c 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -37,7 +37,7 @@ jobs: add-apt-repository -y ppa:ubuntu-toolchain-r/test add-apt-repository -y ppa:deadsnakes/ppa apt update - apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 wget + apt install -y python3.8 python3.8-distutils git gcc-9 g++-9 wget build-essential wget https://bootstrap.pypa.io/get-pip.py python3.8 get-pip.py update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9 From 9a318974f8376e9b002ada24542c6905ed6f0d3d Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 13:46:57 -0500 Subject: [PATCH 46/48] p --- .github/workflows/build_ubuntu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index cbe9e245c..0bc0dcd25 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -46,7 +46,7 @@ jobs: - name: Setup cmake uses: jwlawson/actions-setup-cmake@v1.9 with: - cmake-version: '3.18.x' + cmake-version: '3.20.x' - name: Use cmake run: cmake --version From 596999511d8722e57df4c4b5c10648dbb0ee294a Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 14:07:05 -0500 Subject: [PATCH 47/48] cmake --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 770df1af1..03f2cb474 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.12.0) +cmake_minimum_required(VERSION 3.19.0) project(ni_grpc_device_server C CXX) From d9878eb5be7c14b162781131b8021fde901d5b3d Mon Sep 17 00:00:00 2001 From: Alex Starche Date: Fri, 17 Sep 2021 14:59:40 -0500 Subject: [PATCH 48/48] retention --- .github/workflows/build_ubuntu.yml | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build_ubuntu.yml b/.github/workflows/build_ubuntu.yml index 0bc0dcd25..a2013de14 100644 --- a/.github/workflows/build_ubuntu.yml +++ b/.github/workflows/build_ubuntu.yml @@ -100,7 +100,6 @@ jobs: endif() - name: Tar Linux Server Binaries - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: >- tar -cvzf ni-grpc-device-server-linux-glibc2_23-x64.tar.gz -C ${GITHUB_WORKSPACE}/build @@ -112,14 +111,12 @@ jobs: - name: Upload Linux Server Binaries Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-server-linux-glibc2_23-x64 path: ni-grpc-device-server-linux-glibc2_23-x64.tar.gz - retention-days: 5 + retention-days: 1 - name: Tar Linux Test Binaries - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: >- tar -cvzf ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz -C ${GITHUB_WORKSPACE}/build @@ -135,14 +132,12 @@ jobs: - name: Upload Linux Test Binaries Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-tests-linux-glibc2_23-x64 path: ni-grpc-device-tests-linux-glibc2_23-x64.tar.gz - retention-days: 5 + retention-days: 1 - name: Stage Linux Client Files - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} run: | mkdir -p ${{ runner.temp }}/staging/proto cp generated/**/*.proto source/protobuf/*.proto ${{ runner.temp }}/staging/proto @@ -152,9 +147,8 @@ jobs: - name: Upload Linux Client Files Artifact uses: actions/upload-artifact@v2 - if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/releases'))}} with: name: ni-grpc-device-client-Linux path: ni-grpc-device-client.tar.gz - retention-days: 5 + retention-days: 1