README_WINDOWS.rst 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. Borg native on Windows
  2. ======================
  3. Running Borg natively on Windows is in an early alpha stage. Expect many things to fail.
  4. Do not use the native Windows build on any data that you do not want to lose!
  5. Build Requirements
  6. ------------------
  7. - VC 14.0 Compiler
  8. - OpenSSL Library v1.1.1c, 64-bit (available at https://github.com/python/cpython-bin-deps)
  9. Use the `win-download-openssl.ps1` script to download and extract the library to
  10. the correct location. See also the OpenSSL section below.
  11. - Patience and a lot of coffee/beer
  12. What's working
  13. --------------
  14. .. note::
  15. The following examples assume that the `BORG_REPO` and `BORG_PASSPHRASE` environment variables are set
  16. when the repository or passphrase is not explicitly provided.
  17. - Borg does not crash if called with ``borg``
  18. - ``borg init --encryption repokey-blake2 ./demoRepo`` runs without errors or warnings.
  19. Note that absolute paths only work if the protocol is explicitly set to ``file://``
  20. - ``borg create ::backup-{now} D:\DemoData`` works as expected.
  21. - ``borg list`` works as expected.
  22. - ``borg extract --strip-components 1 ::backup-XXXX`` works.
  23. If absolute paths are extracted, it is important to pass ``--strip-components 1``,
  24. otherwise the data is restored to the original location!
  25. What's NOT working
  26. ------------------
  27. - Extracting a backup created on a Windows machine on a non-Windows machine will fail.
  28. - Many other things.
  29. OpenSSL, Windows and Python
  30. ---------------------------
  31. Windows does not ship OpenSSL by default, so we need to get the library from somewhere else.
  32. However, a default Python installation does include `libcrypto`, which is required by Borg.
  33. The only things missing to build Borg are the header and `*.lib` files.
  34. Luckily, the Python developers provide all required files in a separate repository.
  35. The `win-download-openssl.ps1` script can be used to download the package from
  36. https://github.com/python/cpython-bin-deps and extract the files to the correct location.
  37. For Anaconda, the required libraries can be installed with ``conda install -c anaconda openssl``.