OSDN Git Service

Do all automated builds on AppVeyor!
authorJames Teh <jamie@nvaccess.org>
Fri, 5 Feb 2016 02:29:08 +0000 (12:29 +1000)
committerJames Teh <jamie@nvaccess.org>
Fri, 5 Feb 2016 03:47:17 +0000 (13:47 +1000)
Also, AppVeyor has Python 2.7.11, so we upgrade with it.
Fixes #5499. Fixes #5724.

appveyor.yml [new file with mode: 0644]
appveyor/authenticode.pfx.enc [new file with mode: 0644]
appveyor/ssh_id_rsa.enc [new file with mode: 0644]
appveyor/ssh_known_hosts [new file with mode: 0644]
readme.md

diff --git a/appveyor.yml b/appveyor.yml
new file mode 100644 (file)
index 0000000..29ed500
--- /dev/null
@@ -0,0 +1,100 @@
+version: "{branch}-{build}"\r
+\r
+branches:\r
+ only:\r
+  - master\r
+  - next\r
+  - rc\r
+  - /try-.*/\r
+  # For tags, branch = tag if GitHub couldn't work out the base branch.\r
+  - /release-.*/\r
+\r
+environment:\r
+ PY_PYTHON: 2.7-32\r
+ encFileKey:\r
+  secure: ekOvuyywHuDdGZmRmoj+b3jfrq39A2xlx4RD5ZUGd/8=\r
+ symstore: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\symstore.exe\r
+\r
+init:\r
+ - ps: |\r
+     if ($env:APPVEYOR_REPO_TAG_NAME -and $env:APPVEYOR_REPO_TAG_NAME.StartsWith("release-")) {\r
+      # Strip "release-" prefix.\r
+      $version = $env:APPVEYOR_REPO_TAG_NAME.Substring(8)\r
+      Set-AppveyorBuildVariable "release" "1"\r
+      if ($env:APPVEYOR_REPO_TAG_NAME.Contains("rc")) {\r
+       $versionType = "beta"\r
+      } else {\r
+       $versionType = "stable"\r
+      }\r
+     } else {\r
+      $version = "$env:APPVEYOR_REPO_BRANCH-$env:APPVEYOR_BUILD_NUMBER," + $env:APPVEYOR_REPO_COMMIT.Substring(0, 8)\r
+      # The version is unique even for rebuilds, so we can use it for the AppVeyor version.\r
+      Update-AppveyorBuild -Version $version\r
+      if (!$env:APPVEYOR_REPO_BRANCH.StartsWith("try-")) {\r
+       $versionType = "snapshot:$env:APPVEYOR_REPO_BRANCH"\r
+      }\r
+     }\r
+     Set-AppveyorBuildVariable "version" $version\r
+     if ($versionType) {\r
+      Set-AppveyorBuildVariable "versionType" $versionType\r
+     }\r
+\r
+clone_depth: 1\r
+\r
+install:\r
+ - cd appveyor\r
+ # Decrypt files.\r
+ - openssl enc -aes-256-cbc -d -pass pass:%encFileKey% -in authenticode.pfx.enc -out authenticode.pfx\r
+ - openssl enc -aes-256-cbc -d -pass pass:%encFileKey% -in ssh_id_rsa.enc -out ssh_id_rsa\r
+ # Install ssh stuff.\r
+ - copy ssh_id_rsa %userprofile%\.ssh\id_rsa\r
+ - type ssh_known_hosts >> %userprofile%\.ssh\known_hosts\r
+ - cd ..\r
+ - git submodule update --init\r
+\r
+build_script:\r
+ - ps: |\r
+     $sconsArgs = "launcher version=$env:version"\r
+     if ($env:release) {\r
+      $sconsArgs += " changes userGuide developerGuide release=1"\r
+     }\r
+     if ($env:versionType) {\r
+      $sconsArgs += " updateVersionType=$env:versionType"\r
+     }\r
+     $sconsArgs += ' publisher="NV Access"'\r
+     $sconsArgs += " certFile=appveyor\authenticode.pfx certTimestampServer=http://timestamp.digicert.com"\r
+     # We use cmd to run scons because PowerShell throws exceptions if warnings get dumped to stderr.\r
+     # It's possible to work around this, but the workarounds have annoying side effects.\r
+     Set-AppveyorBuildVariable "sconsArgs" $sconsArgs\r
+ - 'echo scons args: %sconsArgs%'\r
+ - py scons.py %sconsArgs%\r
+ # Build symbol store.\r
+ - ps: |\r
+     foreach ($syms in "source\*.pdb", "source\lib\*.pdb", "source\lib64\*.pdb", "source\synthDrivers\*.pdb") {\r
+      & $env:symstore add /s symbols /compress -:NOREFS /t NVDA /f $syms\r
+     }\r
+ - cd symbols\r
+ - 7z a -tzip -r ..\output\symbols.zip *.pd_\r
+ - cd ..\r
+\r
+artifacts:\r
+ - path: output\*\r
+ - path: output\*\*\r
+\r
+deploy_script:\r
+ - ps: |\r
+     if ($env:versionType) {\r
+      # Not a try build.\r
+      $exe = Get-ChildItem -Name output\*.exe\r
+      $hash = (Get-FileHash "output\$exe" -Algorithm SHA1).Hash.ToLower()\r
+      $data = @{\r
+       jobId=$env:APPVEYOR_JOB_ID;\r
+       commit=$env:APPVEYOR_REPO_COMMIT;\r
+       version=$env:version; versionType=$env:versionType;\r
+       avVersion=$env:APPVEYOR_BUILD_VERSION;\r
+       branch=$env:APPVEYOR_REPO_BRANCH;\r
+       exe=$exe; hash=$hash;\r
+       artifacts=$artifacts\r
+      }\r
+      ConvertTo-Json -InputObject $data -Compress | ssh nvaccess@exbi.nvaccess.org nvdaAppveyorHook\r
+     }\r
diff --git a/appveyor/authenticode.pfx.enc b/appveyor/authenticode.pfx.enc
new file mode 100644 (file)
index 0000000..1f7018b
Binary files /dev/null and b/appveyor/authenticode.pfx.enc differ
diff --git a/appveyor/ssh_id_rsa.enc b/appveyor/ssh_id_rsa.enc
new file mode 100644 (file)
index 0000000..4de2bbe
Binary files /dev/null and b/appveyor/ssh_id_rsa.enc differ
diff --git a/appveyor/ssh_known_hosts b/appveyor/ssh_known_hosts
new file mode 100644 (file)
index 0000000..5d596d6
--- /dev/null
@@ -0,0 +1,2 @@
+exbi.nvaccess.org ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBJZYcI3sI+IbIaiUcd5/LIL5+wfEoO+NQ8Gw1Ww9bxwpOyP/HYu/1yzuRNTDSckGM3hqaGGliTW2/3DYOvPDUwI=
+45.33.21.113 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBJZYcI3sI+IbIaiUcd5/LIL5+wfEoO+NQ8Gw1Ww9bxwpOyP/HYu/1yzuRNTDSckGM3hqaGGliTW2/3DYOvPDUwI=
index 8d31016..9e3bb6c 100644 (file)
--- a/readme.md
+++ b/readme.md
@@ -35,7 +35,7 @@ The NVDA source depends on several other packages to run correctly.
 ### Installed Dependencies\r
 The following dependencies need to be installed on your system:\r
 \r
-* [Python](http://www.python.org/), version 2.7.10, 32 bit\r
+* [Python](http://www.python.org/), version 2.7.11, 32 bit\r
 * Microsoft Visual Studio 2012 Update 1 or later (Express for Windows Desktop, or Professional)\r
        * [Download for Visual Studio Express 2012 (Windows Desktop)](http://www.microsoft.com/en-au/download/details.aspx?id=34673) (does not include updates)\r
        * [Download for Visual Studio 2012 latest update package](http://go.microsoft.com/fwlink/?LinkId=301713)\r