anchor.diff:  which.exe openssl || exit 1
   which.exe openssl | tee.exe -a build.log
   
  -
  -REM .Net
  +REM Install Java GPG
  +echo Install Java GPG: ... | tee.exe -a build.log
  +openssl aes-256-cbc -iter 42 -pass pass:%ORTOOLS_TOKEN% -in tools\release\private-key.gpg.enc -out private-key.gpg -d
  +gpg --batch --import private-key.gpg
  +del private-key.gpg
  +mkdir -p %userprofile%/.m2
  +openssl aes-256-cbc -iter 42 -pass pass:%ORTOOLS_TOKEN% -in tools\release\settings.xml.enc -out %userprofile%/.m2/settings.xml -d
  +echo Install Java GPG: DONE | tee -a build.log
  +
  +echo make java: ... | tee.exe -a build.log
  +make.exe java WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make java: DONE | tee.exe -a build.log
  +REM make.exe test_java WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +REM echo make test_java: DONE | tee.exe -a build.log
  +
  +for %%i in (temp_java\ortools-win32-x86-64\target\*.jar*) do copy %%i export\.
  +for %%i in (temp_java\ortools-java\target\*.jar*) do copy %%i export\.
  +echo %BRANCH% %SHA1%>build_java.log
  +exit /B 0
  +
  +
  +:BUILD_DOTNET
  +title Build .Net
  +set HASH=
  +for /F "tokens=* delims=" %%x in (build_dotnet.log) do (set HASH=%%x)
  +if "%HASH%"=="%BRANCH% %SHA1%" (
  +echo .Net build seems up to date, skipping
  +exit /B 0
  +)
  +
  +REM Check .Net
   which.exe dotnet || exit 1
   which.exe dotnet | tee.exe -a build.log
   
  -REM ###############################
  -REM ##  Build Examples Archives  ##
  -REM ###############################
  +REM Install .Net snk
  +echo Install .Net snk | tee.exe -a build.log
  +openssl aes-256-cbc -iter 42 -pass pass:%ORTOOLS_TOKEN% -in tools\release\or-tools.snk.enc -out or-tools.snk -d
  +set DOTNET_SNK=or-tools.snk
  +
  +echo make dotnet: ... | tee.exe -a build.log
  +make.exe dotnet WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make dotnet: DONE | tee.exe -a build.log
  +REM make.exe test_dotnet WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +REM echo make test_dotnet: DONE | tee.exe -a build.log
  +
  +for %%i in (packages\*nupkg*) do copy %%i export\.
  +echo %BRANCH% %SHA1%>build_dotnet.log
  +exit /B 0
  +
  +
  +REM Create Archive
  +:BUILD_ARCHIVE
  +title Build archives
  +set HASH=
  +for /F "tokens=* delims=" %%x in (build_archive.log) do (set HASH=%%x)
  +if "%HASH%"=="%BRANCH% %SHA1%" (
  +echo Archive build seems up to date, skipping
  +exit /B 0
  +)
  +
  +make.exe archive WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make archive: DONE | tee.exe -a build.log
  +make.exe test_archive WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make test_archive: DONE | tee.exe -a build.log
  +make.exe fz_archive WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make fz_archive: DONE | tee.exe -a build.log
  +make.exe test_fz_archive WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  +echo make test_fz_archive: DONE | tee.exe -a build.log
  +
  +echo %BRANCH% %SHA1%>build_archive.log
  +exit /B 0
  +
  +
  +REM Build Examples Archives
  +:BUILD_EXAMPLES
  +title Build examples
  +set HASH=
  +for /F "tokens=* delims=" %%x in (build_examples.log) do (set HASH=%%x)
  +if "%HASH%"=="%BRANCH% %SHA1%" (
  +echo Examples build seems up to date, skipping
  +exit /B 0
  +)
  +
   rm.exe -rf temp *.zip || exit 1
   echo Build examples archives... | tee.exe -a build.log
   echo   C++ examples archive... | tee.exe -a build.log
  
positive.code: REM /!\ THIS SCRIPT SUPPOSE A FIXED PATH FOR PYTHON /!\
  REM Each blocks could be triggered independently (i.e. commenting others)
  REM run it as:
  REM set PATH=%PATH%;tools;tools\win
  REM cmd /c tools\release\build_delivery_win.cmd
  
  REM Check all prerequisite
  set PATH=%PATH%;tools;tools\win
  
  if "%ORTOOLS_TOKEN%" == "" (
    echo ORTOOLS_TOKEN: NOT FOUND | tee.exe build.log
    exit 1
  )
  
  REM Print version
  make.exe print-OR_TOOLS_VERSION | tee.exe build.log
  
  REM clean everything
  echo clean everything... | tee.exe -a build.log
  make.exe clean_third_party || exit 1
  make.exe clean || exit 1
  
  which.exe cmake || exit 1
  which.exe cmake | tee.exe -a build.log
  REM Python
  which.exe C:\python36-64\python.exe || exit 1
  echo C:\python36-64\python.exe: FOUND | tee.exe -a build.log
  C:\python36-64\python.exe -m pip install --user absl-py mypy-protobuf
  
  which.exe C:\python37-64\python.exe || exit 1
  echo C:\python37-64\python.exe: FOUND | tee.exe -a build.log
  C:\python37-64\python.exe -m pip install --user absl-py mypy-protobuf
  
  which.exe C:\python38-64\python.exe || exit 1
  echo C:\python38-64\python.exe: FOUND | tee.exe -a build.log
  C:\python38-64\python.exe -m pip install --user absl-py mypy-protobuf
  
  which.exe C:\python39-64\python.exe || exit 1
  echo C:\python39-64\python.exe: FOUND | tee.exe -a build.log
  C:\python39-64\python.exe -m pip install --user absl-py mypy-protobuf
  
  REM Java
  echo JAVA_HOME: %JAVA_HOME% | tee.exe -a build.log
  which.exe java || exit 1
  which.exe java | tee.exe -a build.log
  
negative.code: make.exe dotnet_examples_archive WINDOWS_PATH_TO_PYTHON=c:\python39-64 || exit 1
  echo DONE | tee.exe -a build.log
  
  echo %BRANCH% %SHA1%>build_examples.log
  exit /B 0
  
  
  REM PYTHON 3.6,3.7,3.8,3.9
  :BUILD_PYTHON
  title Build Python
  set HASH=
  for /F "tokens=* delims=" %%x in (build_python.log) do (set HASH=%%x)
  if "%HASH%"=="%BRANCH% %SHA1%" (
  echo Python build seems up to date, skipping
  exit /B 0
  )
  
  for %%v in (6 7 8 9) do (
  title Build Python 3.%%v
  REM Check Python
  which.exe C:\python3%%v-64\python.exe || exit 1
  echo C:\python3%%v-64\python.exe: FOUND | tee.exe -a build.log
  C:\python3%%v-64\python.exe -m pip install --user absl-py mypy-protobuf
  
  echo Cleaning Python... | tee.exe -a build.log
  make.exe clean_python WINDOWS_PATH_TO_PYTHON=c:\python3%%v-64
  echo Cleaning Python...DONE | tee.exe -a build.log
  
  REM make.exe python WINDOWS_PATH_TO_PYTHON=c:\python3%%v-64 || exit 1
  REM echo make python3.%%v: DONE | tee.exe -a build.log
  REM make.exe test_python WINDOWS_PATH_TO_PYTHON=c:\python3%%v-64 || exit 1
  REM echo make test_python3.%%v: DONE | tee.exe -a build.log
  echo Rebuild Python3.%%v pypi archive... | tee.exe -a build.log
  make.exe package_python WINDOWS_PATH_TO_PYTHON=c:\python3%%v-64 || exit 1
  echo Rebuild Python3.%%v pypi archive...DONE | tee.exe -a build.log
  echo Test Python3.%%v pypi archive... | tee.exe -a build.log
  make.exe test_package_python WINDOWS_PATH_TO_PYTHON=c:\python3%%v-64 || exit 1
  echo Test Python3.%%v pypi archive...DONE | tee.exe -a build.log
  
  set TEMP_DIR=temp_python3%%v
  for %%i in (%TEMP_DIR%\ortools\dist\*.whl) do copy %%i export\.
  )
  
  echo %BRANCH% %SHA1%>build_python.log
  exit /B 0
  
  