You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
2.7 KiB

  1. os: Visual Studio 2019
  2. skip_commits:
  3. # Don't run AppVeyor for commits that only modify resource or non-code files
  4. files:
  5. - .gitignore
  6. - .gitattributes
  7. - .github/
  8. - res/
  9. - '**/*.cmd'
  10. - '**/*.md'
  11. - '**/*.rc'
  12. - '**/*.sh'
  13. - '**/*.txt'
  14. - '**/*.xml'
  15. environment:
  16. COVERITY_SCAN_EMAIL: "pete@akeo.ie"
  17. COVERITY_SCAN_TOKEN:
  18. secure: XZADvwlRFo57sBA54pBH2oVT/eR/OytZYY/sCKq61io=
  19. global:
  20. BITS: 32
  21. matrix:
  22. - CONFIGURATION: Release
  23. COMPILER: Coverity
  24. PLATFORM: x86
  25. - CONFIGURATION: Debug
  26. COMPILER: MSVC
  27. PLATFORM: x86
  28. - CONFIGURATION: Debug
  29. COMPILER: MSVC
  30. PLATFORM: x64
  31. - CONFIGURATION: Release
  32. COMPILER: MSVC
  33. PLATFORM: x86
  34. - CONFIGURATION: Release
  35. COMPILER: MSVC
  36. PLATFORM: x64
  37. - CONFIGURATION: Release
  38. COMPILER: MinGW
  39. PLATFORM: i686
  40. - CONFIGURATION: Release
  41. COMPILER: MinGW
  42. PLATFORM: x86_64
  43. init:
  44. # Set the AppVeyor build version number to our tag or, if untagged, to the commit hash
  45. # See https://github.com/appveyor/ci/issues/691
  46. # Also include the build number, to distinguish between rebuilds of the same commit
  47. - ps: |
  48. if ($env:APPVEYOR_REPO_TAG -eq "true") {
  49. Update-AppveyorBuild -Version "$($env:APPVEYOR_REPO_TAG_NAME)_#$env:APPVEYOR_BUILD_NUMBER";
  50. } else {
  51. Update-AppveyorBuild -Version "dev-$($env:APPVEYOR_REPO_COMMIT.Substring(0,8))_#$env:APPVEYOR_BUILD_NUMBER";
  52. }
  53. build:
  54. project: rufus.sln
  55. parallel: true
  56. verbosity: detailed
  57. install:
  58. ps: |
  59. if ($env:PLATFORM -eq "x86_64") {
  60. $env:BITS = 64
  61. }
  62. build_script:
  63. ps: |
  64. $APPVEYOR_LOGGER = "C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll";
  65. switch ($env:COMPILER) {
  66. MSVC {
  67. msbuild rufus.sln /m /p:Configuration=$env:CONFIGURATION,Platform=$env:PLATFORM /l:$APPVEYOR_LOGGER;
  68. }
  69. MinGW {
  70. C:\msys64\usr\bin\bash -lc "export PATH=/mingw$env:BITS/bin:`$PATH; cd /c/projects/rufus; mkdir -p m4; ./configure --build=$env:PLATFORM-w64-mingw32 --host=$env:PLATFORM-w64-mingw32 --disable-debug; make -j4";
  71. }
  72. Coverity {
  73. if (!"$env:COVERITY_SCAN_TOKEN") {
  74. Write-Output "Not running Coverity due to missing credential.";
  75. return;
  76. }
  77. cov-build.exe --dir cov-int msbuild rufus.sln /m /p:Configuration=$env:CONFIGURATION,Platform=$env:PLATFORM /l:$APPVEYOR_LOGGER;
  78. 7z a -r cov-int.zip cov-int
  79. # MUST use 'curl.exe' since 'curl' is a PowerShell alias to Invoke-Webrequest. Also MUST use @ sign before uploaded file.
  80. curl.exe -s --form email=$env:COVERITY_SCAN_EMAIL --form token=$env:COVERITY_SCAN_TOKEN --form file=@cov-int.zip --form version="$env:APPVEYOR_BUILD_VERSION" --form description="Rufus" https://scan.coverity.com/builds?project=pbatard%2Frufus
  81. }
  82. }