0
0
mirror of https://github.com/OpenVPN/openvpn.git synced 2024-09-19 19:42:30 +02:00
OpenVPN is an open source VPN daemon
Go to file
Frank Lichtenheld e8881ec6dd CMake: Add complete MinGW and MSVC build
This is based on the initial CMake patch by
Arne Schwabe, but extends that to provide
a complete replacement for existing MinGW
build (autotools based) and MSVC build
(openvpn.sln).

The following features are added while switching
these builds to CMake:
 - vcpkg support for MinGW build, allowing for
   trivial cross-compilation on Linux
 - Add unittests to MSVC build
 - Rework MSVC config header generation, removing
   need for separate headers between autotools
   and MSVC

The following advantages are reasons for switching
to CMake over the existing MSVC build:
 - Easier to maintain CMake files without IDE
   than the sln and vcxproj files
 - Able to maintain MSVC and MinGW build side-by-side

The plan is to completely remove the existing MSVC
build system but leave the existing autotools builds
in place as-is, including MinGW support.

CMake is not the intended build system for Unix-like
platforms and there are no current plans to switch
to it.

v2:
 - Reduce default warning level for MSVC to /W2. With
   /W3 the build is just much too noisy, making it
   difficult to spot new warnings.
 - Change MSVC CMake presets to have hardcoded build
   type. When using pkg_search_module MSVC Multi-Config
   builds do not work correctly at all since PkgConfig
   doesn't seem to be able to create multi-config
   libraries like find_package does.
 - Change minGW presets to be Multi-Config capable.
 - Remove OPENVPN_VERSION_MAJOR, OPENVPN_VERSION_MINOR,
   OPENVPN_VERSION_PATCH from config.h.cmake.in.
   They are not required and cause macro redefinition
   warnings in MSVC (with openvpn-plugin.h). gcc doesn't
   warn about this because the definitions are identical
   so no need to fix this in autoheader config.h.in.
v3:
 - Apply fixes by Lev Stipakov to match MSVC compile
   options better to previous build.
 - Apply change by Lev Stipakov to enable generation
   of PDB files.
 - Move /Brepro to its own commit. This is a behavior
   change that should be more visible.
 - Rebase on top of my dist fixes.

Change-Id: I237f28eca618d4fc476225b887c0be26cca362b1
Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
Acked-by: Lev Stipakov <lstipakov@gmail.com>
Message-Id: <20230620135310.94455-3-frank@lichtenheld.com>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg26754.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
2023-06-27 18:07:03 +02:00
.github CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
.travis Change travis build scripts to use https when fetching prerequisites. 2020-11-24 18:01:46 +01:00
build dist: add more missing files only used in the MSVC build 2023-06-21 13:30:46 +02:00
contrib CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
debug build: standard directory layout 2012-03-22 22:07:08 +01:00
dev-tools Update copyright year to 2023 2023-01-10 17:24:37 +01:00
distro Update copyright year to 2023 2023-01-10 17:24:37 +01:00
doc CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
include Update copyright year to 2023 2023-01-10 17:24:37 +01:00
m4 Remove support for non ISO C99 vararg support 2021-03-28 16:34:42 +02:00
sample sample-plugins: Fix memleak in client-connect example plugin 2023-05-16 12:18:32 +02:00
src CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
tests unit_tests: Add missing cert_data.h to source list for unit tests 2023-06-21 14:19:08 +02:00
.git-blame-ignore-revs uncrustify: add sp_after_comma=add 2022-05-22 13:10:22 +02:00
.gitattributes cleanup: add .gitattributes to control eol style explicitly 2012-04-26 20:54:26 +02:00
.gitignore CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
.mailmap Update .mailmap to unify and clean up odd names and e-mail addresses 2016-10-18 13:46:04 +02:00
.svncommitters Added mapping files from SVN commit ID to more descriptive commit IDs. 2010-10-21 11:31:26 +02:00
.travis.yml travis: don't run t_net.sh test 2020-08-10 18:34:19 +02:00
AUTHORS This is the start of the BETA21 branch. 2005-09-26 05:28:27 +00:00
ChangeLog Update copyright year to 2023 2023-01-10 17:24:37 +01:00
Changes.rst Refuse connection if server pushes an option contradicting allow-compress 2023-03-23 18:25:40 +01:00
CMakeLists.txt CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
CMakePresets.json CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
compat.m4 Remove checks for uint* types that are part of C99 2021-04-07 08:30:34 +02:00
config-msvc-version.h.in msvc: fix product version display 2021-10-14 16:29:35 +02:00
config-msvc.h msvc: add branch name and commit hash to version output 2022-09-26 11:21:44 +02:00
config.h.cmake.in CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
configure.ac version.sh: remove 2023-03-30 13:26:15 +02:00
CONTRIBUTING.rst Add git pre-commit hook script to uncrustify 2022-04-22 09:25:55 +02:00
COPYING Add Apache2 linking with for new commits 2023-05-03 18:09:46 +02:00
COPYRIGHT.GPL copyright: Update GPLv2 license texts 2017-06-16 10:38:03 +02:00
INSTALL GitHub Issues: add new links to INSTALL and README 2022-11-30 15:46:35 +01:00
Makefile.am CMake: Add complete MinGW and MSVC build 2023-06-27 18:07:03 +02:00
NEWS This is the start of the BETA21 branch. 2005-09-26 05:28:27 +00:00
openvpn.sln msvc: add ARM64 configuration 2021-05-10 17:54:57 +02:00
PORTS Update copyright year to 2023 2023-01-10 17:24:37 +01:00
README GitHub Issues: add new links to INSTALL and README 2022-11-30 15:46:35 +01:00
README.dco.md dco-win: add documentation to README.dco.md 2022-08-25 22:17:50 +02:00
README.ec Implement tls-groups option to specify eliptic curves/groups 2020-07-21 22:33:58 +02:00
README.mbedtls Add warning about mbed TLS licensing problem 2022-02-17 16:13:53 +01:00
README.wolfssl README.wolfssl Update 2021-03-19 15:19:31 +01:00
version.m4 Change version.m4 to 2.7_git 2022-12-01 16:33:25 +01:00

OpenVPN -- A Secure tunneling daemon

Copyright (C) 2002-2022 OpenVPN Inc. This program is free software;
you can redistribute it and/or modify
it under the terms of the GNU General Public License version 2
as published by the Free Software Foundation.

*************************************************************************

To get the latest release of OpenVPN, go to:

	https://openvpn.net/community-downloads/

To Build and Install,

	tar -zxf openvpn-<version>.tar.gz
	cd openvpn-<version>
	./configure
	make
	make install

or see the file INSTALL for more info.

*************************************************************************

For detailed information on OpenVPN, including examples, see the man page
  http://openvpn.net/man.html

For a sample VPN configuration, see
  http://openvpn.net/howto.html

To report an issue, see
  https://github.com/OpenVPN/openvpn/issues/new
  (Note: We recently switched to GitHub for reporting new issues,
   old issues can be found at:
   https://community.openvpn.net/openvpn/report)

For a description of OpenVPN's underlying protocol,
  see the file ssl.h included in the source distribution.

*************************************************************************

Other Files & Directories:

* configure.ac -- script to rebuild our configure
  script and makefile.

* sample/sample-scripts/verify-cn

  A sample perl script which can be used with OpenVPN's
  --tls-verify option to provide a customized authentication
  test on embedded X509 certificate fields.

* sample/sample-keys/

  Sample RSA keys and certificates.  DON'T USE THESE FILES
  FOR ANYTHING OTHER THAN TESTING BECAUSE THEY ARE TOTALLY INSECURE.

* sample/sample-config-files/

  A collection of OpenVPN config files and scripts from
  the HOWTO at http://openvpn.net/howto.html

*************************************************************************

Note that easy-rsa and tap-windows are now maintained in their own subprojects.
Their source code is available here:

  https://github.com/OpenVPN/easy-rsa
  https://github.com/OpenVPN/tap-windows6

The old cross-compilation environment (domake-win) and the Python-based
buildsystem have been replaced with openvpn-build:

  https://github.com/OpenVPN/openvpn-build

See the INSTALL file for usage information.