Dockerfile 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. # escape=`
  2. # Distributed under the OSI-approved BSD 3-Clause License. See accompanying
  3. # file Copyright.txt or https://cmake.org/licensing for details.
  4. # Produce a base image with a test environment for packaged CMake binaries.
  5. # Build using the directory containing this file as its own build context.
  6. ARG FROM_IMAGE_NAME=kitware/cmake:build-win-x86-base-2020-04-27
  7. ARG FROM_IMAGE_DIGEST=@sha256:c5a8948d636319cdac0180266996558bb6fb037125792b5b837f069d02e53d7c
  8. ARG FROM_IMAGE=$FROM_IMAGE_NAME$FROM_IMAGE_DIGEST
  9. FROM $FROM_IMAGE
  10. # Python
  11. ADD https://www.python.org/ftp/python/3.8.2/python-3.8.2-embed-amd64.zip C:\python3\python3.zip
  12. RUN cd \python3 `
  13. && powershell -Command " `
  14. if ($(Get-FileHash python3.zip).Hash -eq '2927a3a6d0fe1f6e047a86059220aeda374eed23113b9ef5355acb8452d56453') {`
  15. Expand-Archive -Path python3.zip -DestinationPath .`
  16. } else {`
  17. exit 1 `
  18. }" `
  19. && del python3.zip `
  20. && del python38._pth
  21. # Ninja
  22. ADD https://github.com/ninja-build/ninja/releases/download/v1.10.0/ninja-win.zip C:\ninja\ninja.zip
  23. RUN cd \ninja `
  24. && powershell -Command " `
  25. if ($(Get-FileHash ninja.zip).Hash -eq '919fd158c16bf135e8a850bb4046ec1ce28a7439ee08b977cd0b7f6b3463d178') {`
  26. Expand-Archive -Path ninja.zip -DestinationPath .`
  27. } else {`
  28. exit 1 `
  29. }" `
  30. && del ninja.zip
  31. COPY test-nmake.bat test-ninja.bat C:\