BUILD-WINDOWS-old.txt 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. NOTE: These instructions are out of date!
  2. The supported method for building Windows binaries is described in BUILD-WINDOWS.txt.
  3. 1 Requirements
  4. 1.1 Operating system
  5. Linux:
  6. - Linux kernel 2.6. Kernel 2.4 will work, but performance will suffer.
  7. - tested on x86, x86_64 and ARM architectures. Not tested on any big-endian architecture.
  8. Windows:
  9. - Windows XP or newer; tested on Windows XP and Windows 7
  10. FreeBSD:
  11. - Not regularly tested.
  12. Other systems are not supported.
  13. 1.2 Compilers
  14. Linux:
  15. - gcc
  16. - clang, except >=3.0 (clang bug http://llvm.org/bugs/show_bug.cgi?id=11535)
  17. Windows:
  18. - gcc from the mingw-w64 project for 32-bit targets
  19. C language features used:
  20. - Standard (all part of C99):
  21. - designated initializers
  22. - stdint.h, inttypes.h, stddef.h
  23. - intermingled declarations and code
  24. - for loop initial declaration
  25. - one-line "//" comments
  26. - Extensions:
  27. - packed structure attribute (to pack a structure and allow unaligned access)
  28. 1.3 CMake
  29. The build system uses CMake.
  30. 1.4 OpenSSL
  31. Libcrypto (part of OpenSSL) is used for block ciphers, hash functions and random data generation.
  32. 1.5 Network Security Services (NSS)
  33. The NSS library from Mozilla is used for TLS support. NSS command-line tools are also needed
  34. for setting up certificates.
  35. 1.6 TAP-Win32 (Windows only) (runtime only)
  36. The TAP-Win32 driver, part of OpenVPN.
  37. 2 Compilation
  38. 2.1 Compiling on Linux
  39. $ tar xf badvpn-<version>.tar.bz2
  40. $ mkdir build
  41. $ cd build
  42. $ cmake ../badvpn-<version> -DCMAKE_INSTALL_PREFIX=/usr/local
  43. $ make
  44. If you want to install it, run as root:
  45. # make install
  46. If you only want NCD or tun2socks and not the VPN system, you can avoid the NSS dependency by passing
  47. the following to the cmake command:
  48. -DBUILD_NCD=1 -DBUILD_TUN2SOCKS=1 -DBUILD_NOTHING_BY_DEFAULT=1
  49. 2.2 Compiling for Windows
  50. See the file INSTALL-WINDOWS for detailed instructions.
  51. 3 Usage
  52. The primary documentation is on the BadVPN homepage, http://code.google.com/p/badvpn/ .
  53. Additionally, some man pages are installed (badvpn(7), badvpn-server(8), badvpn-client(8)).