Skip to content

Commit

Permalink
Move to devops osx, enable CodeQL tasks (#2522)
Browse files Browse the repository at this point in the history
* Support OSX DevOps

* update cutil

* add codeql

* codeql

* codeql

* increase timeout

* enable ql

* increase timeout

* CodeQL.Enabled to main branch

* suppress curl_easy_perform

* move to VS2022
  • Loading branch information
ericwolz committed Aug 21, 2023
1 parent 3cffd13 commit 33435b7
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 13 deletions.
25 changes: 16 additions & 9 deletions build/.vsts-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
displayName: 'Check Submodules Match'
- job: windowsx86
pool:
name: 'sdk-c--win-vs2017'
name: 'sdk-c--win-vs2022'
displayName: "Windows x86"
steps:
- script: |
Expand Down Expand Up @@ -92,7 +92,7 @@ jobs:
condition: succeededOrFailed()
- job: windowsx64debug
pool:
name: 'sdk-c--win-vs2017'
name: 'sdk-c--win-vs2022'
displayName: 'Windows x64 (Debug)'
steps:
- script: |
Expand Down Expand Up @@ -131,16 +131,20 @@ jobs:
testRunTitle: 'windowsx64'
condition: succeededOrFailed()
- job: windowsx64release
timeoutInMinutes: 150
variables:
CodeQL.Enabled: true
CodeQL.Enabled: $[eq(variables['Build.SourceBranch'], 'refs/heads/main')]
CodeQL.Language: cpp
pool:
name: 'sdk-c--win-vs2017'
name: 'sdk-c--win-vs2022'
displayName: 'Windows x64 (Release)'
steps:
- task: CodeQL3000Init@0
- script: |
call jenkins\windows_c_release.cmd --platform x64
displayName: 'Build'
- task: CodeQL3000Finalize@0
condition: always()
- script: |
call jenkins\windows_c_VsDevCmd.cmd x64
cd cmake && ctest -T test --no-compress-output -C "Release" -V -j 16 --schedule-random
Expand Down Expand Up @@ -175,7 +179,7 @@ jobs:
condition: succeededOrFailed()
- job: windowsdynamic
pool:
name: 'sdk-c--win-vs2017'
name: 'sdk-c--win-vs2022'
displayName: "Windows Dynamic"
steps:
- script: |
Expand Down Expand Up @@ -838,7 +842,7 @@ jobs:
variables:
CodeQL.Enabled: false
pool:
name: OSX
vmImage: 'macOS-11'
steps:
- script: |
./jenkins/osx_gcc_openssl.sh
Expand Down Expand Up @@ -883,7 +887,7 @@ jobs:
variables:
CodeQL.Enabled: false
pool:
name: OSX
vmImage: 'macOS-11'
displayName: "Xcode Native"
steps:
- script: |
Expand Down Expand Up @@ -988,11 +992,12 @@ jobs:
- job: DotNET
displayName: .NET
variables:
CodeQL.Enabled: true
CodeQL.Language: csharp
Codeql.Enabled: $[eq(variables['Build.SourceBranch'], 'refs/heads/main')]
Codeql.Language: csharp,python
pool:
vmImage: 'windows-latest'
steps:
- task: CodeQL3000Init@0
- task: NuGetCommand@2
inputs:
command: 'restore'
Expand All @@ -1003,3 +1008,5 @@ jobs:
inputs:
command: 'build'
projects: 'tools\traceabilitytool\traceabilitytool.sln'
- task: CodeQL3000Finalize@0
condition: always()
2 changes: 1 addition & 1 deletion c-utility
Submodule c-utility updated 1 files
+1 −1 CMakeLists.txt
17 changes: 15 additions & 2 deletions iothub_client/tests/global_valgrind_suppression.supp
Original file line number Diff line number Diff line change
Expand Up @@ -656,12 +656,25 @@
fun:IoTHubMessaging_LL_SendMessageComplete
...
}
{
{
<insert_a_suppression_name_here>
drd:ConflictingAccess
...
fun:printf
fun:openCompleteCallback
fun:IoTHubMessaging_LL_ReceiverStateChanged
...
}
}
{
<insert_a_suppression_name_here>
Memcheck:Leak
match-leak-kinds: possible
...
fun:curl_multi_perform
fun:curl_easy_perform
fun:HTTPAPI_ExecuteRequest
...
fun:ThreadWrapper
fun:start_thread
fun:clone
}
2 changes: 2 additions & 0 deletions serializer/tests/codefirst_cpp_ut/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ set(${theseTestsName}_h_files
#C compiler doesn't like to complain about the same thing
if(WIN32)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4505")
elseif(LINUX OR MACOSX)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-deprecated-declarations")
endif()

build_c_test_artifacts(${theseTestsName} ON "tests/UnitTests")
4 changes: 3 additions & 1 deletion serializer/tests/codefirst_withstructs_cpp_ut/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ set(${theseTestsName}_h_files
#C compiler doesn't like to complain about the same thing
if(WIN32)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4505")
elseif(LINUX OR MACOSX)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-deprecated-declarations")
endif()

build_c_test_artifacts(${theseTestsName} ON "tests/UnitTests")
build_c_test_artifacts(${theseTestsName} ON "tests/UnitTests")

0 comments on commit 33435b7

Please sign in to comment.