summaryrefslogtreecommitdiff
path: root/net-vpn/openvpn
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-04-28 20:21:43 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-04-28 20:21:43 +0100
commit40aaaa64e86ba6710bbeb31c4615a6ce80e75e11 (patch)
tree758c221bad35c9288d0bd6df9c7dfc226728e52c /net-vpn/openvpn
parent8d5dbd847cbc704a6a06405856e94b461011afe3 (diff)
gentoo resync : 28.04.2021
Diffstat (limited to 'net-vpn/openvpn')
-rw-r--r--net-vpn/openvpn/Manifest8
-rw-r--r--net-vpn/openvpn/openvpn-2.4.9.ebuild44
-rw-r--r--net-vpn/openvpn/openvpn-2.5.0-r1.ebuild44
-rw-r--r--net-vpn/openvpn/openvpn-2.5.1-r1.ebuild174
-rw-r--r--net-vpn/openvpn/openvpn-9999.ebuild52
5 files changed, 274 insertions, 48 deletions
diff --git a/net-vpn/openvpn/Manifest b/net-vpn/openvpn/Manifest
index a12a1f03a681..ac1e5551dd62 100644
--- a/net-vpn/openvpn/Manifest
+++ b/net-vpn/openvpn/Manifest
@@ -5,7 +5,9 @@ AUX openvpn-2.5.0-auth-pam-missing-header.patch 339 BLAKE2B 8aa56f7d475c4d7a1f0d
AUX up.sh 2865 BLAKE2B f359c0078148a8ec59b68227844f39d784df2271e9640b54f50a9c0b6b67450cf8b397dba8fd735931790648c1d485c149a55ffcbf095623b491b8a827eccab9 SHA512 35201b0e60ad20358080007e595eb4f96d186ba8e88f0485c55d164c28e3d78a12f3e09347ba3d76abb9b8b03fb4a53664bd74ab484be1548090022b956925fd
DIST openvpn-2.4.9.tar.gz 1000602 BLAKE2B 4a10ec76d1a816f9184dd33e4384623e011a1af40ea38ad56cc06f70ab2c911b6fd92cf8ffcd2ec3ab4179fef87feb187fc9df61c5bea92b1c69ee4113093866 SHA512 7683dfb93592968459f080a07ea750992b7444708cdb1a5aafc0118ab8528fc488f2b9fbd7d042e57ad1811303208875237ae9decf0bb4977c45cd30da53751b
DIST openvpn-2.5.0-r1.tar.gz 1815964 BLAKE2B cca1c1ec4fbfe0c337c14525cf706280c9d961c4bba992dfa0b13c9f96e00092864301138037485095716c746ef6ff3473a2085780b3ef77183bf4a6f1c602ae SHA512 3deb55973b87cc95c0437ab9ce6c43fdc246aa7e42e3e68bd6a5651deffa798b6750f625917cb2aaa2c82f0b3a0805bcf206a2aa8e2c735fd24e6bd38f736562
-EBUILD openvpn-2.4.9.ebuild 4152 BLAKE2B 12740e8631ddf3cd91ca9d44312c2d362cf2e0b4dfea1ad2e3816a38fd025634ebde663a0cc6689f9d7bf05d2b5758b25be1080486a618deff6af946b701e0ad SHA512 fb0cb321df1988580246475b7279e252637ce4a50ff8c4f6814f803af593d9b2e8055567f3642cdb09b8ce13b346407f708363b80d0ccee11bedb80df7ca5431
-EBUILD openvpn-2.5.0-r1.ebuild 4171 BLAKE2B ad53061387fc66e86cf82ba90c1ba3a2db3a5f93e362fb9bc753f13128c89f8d2e69aa68005bf02b82f9b495c8c7682e051bffc56f0a94545e923a05d21d2578 SHA512 b2c4ede2de03cef22a7f8f17624c491081ecbe0429718fae6f7f3e5fee105c9692fc2e65b25cf8c4de4dfea402286530bcfec6622eb1270275e624378d711970
-EBUILD openvpn-9999.ebuild 4148 BLAKE2B d2942eb2659d5cc1cef40143b6cd84e4e869031cc23ac419865db1286c7bf3ec7c66433ed2c3149d654206f74b3db14b3cea17a5d90332e9bfa5cbb6b172fdf5 SHA512 0807ceb96db862c33e42c7b2eb1224cfdb01d32e09048250bb69a05244af9835e805a9a87fb47d8a0a2422c12088ab515389b180d93286093f2089eab2709c8d
+DIST openvpn-2.5.1.tar.gz 1827517 BLAKE2B 068af9313c9b2b93dcaa06f82ad66489154ce04973e323af07f38f209b4be77b7b785046aa31559a9f744b4b8c6976acd3e644d5a573f3c5511dc11f5bab3dce SHA512 eb85d14eeb383bed09670941451328db38feacc0b8b7b960840a3f465de83a7527de7d183e66344011da3a3655d558483c569d096b36964209a23418f89052e2
+EBUILD openvpn-2.4.9.ebuild 4756 BLAKE2B 44efa8c170cab681304afe8694e06283dd60941e1ab90f5348e467df4ae5ffff3fae7d565fc81d3bc213d23856c213b8f9be3c810217b13be0da3417582f9b67 SHA512 877e8640b156e031268c928b9c8702869ae774586047f38b79a3bf9e2c5d684b35b2fd46c92eaa071d8cb3e9c9d930b9ba18104a86fd96032db5f5be7ee5b0de
+EBUILD openvpn-2.5.0-r1.ebuild 4775 BLAKE2B fb9868cc03e1325bf551557526a24ab02ad355b73171903deae94fc58bf28bad69464575a2f90a208b2f991a455edd569a4d7cea9dbc2d0cf7a7494d74327abe SHA512 96baa09524a98794d6604ef1f9918745fe4f3de23ef79c6225c2913bc11a2cc02fba52efafe623265ab9287c3438e43570447ea2d20262c80256dbe5c25436d2
+EBUILD openvpn-2.5.1-r1.ebuild 4759 BLAKE2B 6c1575a2fa70dc433fca5405cfa73f62485289554dcd3c37f3cff1a162fe088176652a77a8e12874ecaa4cd59bdb0ba428b1f0b75318b0c05c6cb729199aabea SHA512 0d6452e99166557148dce32a7862138ae8b455aa1cab7b1a7940dbf7be5312f3734bfe92f5a13aa8d34e97ba1d0daf8ec3670890b779216a463ed18e088ccd6b
+EBUILD openvpn-9999.ebuild 4763 BLAKE2B d16e734db362f6ef1c68a16f980ea35d6bbad0a59e9e48bfa039e1be46499e04ffdd48e49574155aec6e9ac1db274b437dacd09a5928a9ecd17670c39f9c6c91 SHA512 0b776162a07b746aed576694bbd75594172675a2cede06696d4f99957661284b9e8917c94c42ca9f7db6c8aeabbfa5d6ef7a8a83da2d294680de379f30ad9254
MISC metadata.xml 1158 BLAKE2B 2d27c7254e0249fad84a5e676cb2c60f0edbb5cda6e66e44f380a39e835f4df72931c983d1989d03169e6003f497f39d928fdbe6548e3df799ffb62c8ba7cc45 SHA512 29af52059d7f381cf4956c116ba3d4ad420ae35af9a33ed97779f6b3cee291003def855e3b84bdafd60f30bdcad1baba70a639d2ad01c01af0a52ef18c50d9e5
diff --git a/net-vpn/openvpn/openvpn-2.4.9.ebuild b/net-vpn/openvpn/openvpn-2.4.9.ebuild
index 9ee9208aa816..6d6d5d7a02da 100644
--- a/net-vpn/openvpn/openvpn-2.4.9.ebuild
+++ b/net-vpn/openvpn/openvpn-2.4.9.ebuild
@@ -13,7 +13,7 @@ LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 ~sparc x86 ~amd64-linux ~x86-linux"
-IUSE="down-root examples inotify iproute2 libressl lz4 +lzo mbedtls pam"
+IUSE="down-root examples inotify iproute2 libressl +lz4 +lzo mbedtls pam"
IUSE+=" pkcs11 +plugins selinux +ssl systemd test userland_BSD"
RESTRICT="!test? ( test )"
@@ -128,19 +128,35 @@ pkg_postinst() {
elog "http://tuntaposx.sourceforge.net"
fi
- elog "The openvpn init script expects to find the configuration file"
- elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
- elog ""
- elog "To create more VPNs, simply create a new .conf file for it and"
- elog "then create a symlink to the openvpn init script from a link called"
- elog "openvpn.newconfname - like so"
- elog " cd /etc/openvpn"
- elog " ${EDITOR##*/} foo.conf"
- elog " cd /etc/init.d"
- elog " ln -s openvpn openvpn.foo"
- elog ""
- elog "You can then treat openvpn.foo as any other service, so you can"
- elog "stop one vpn and start another if you need to."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ elog "In order to use OpenVPN with systemd please use the correct systemd service file."
+ elog ""
+ elog "server:"
+ elog ""
+ elog "- Place your server configuration file in /etc/openvpn/server"
+ elog "- Use the openvpn-server@.service like so"
+ elog "systemctl start openvpn-server@{Server-config}"
+ elog ""
+ elog "client:"
+ elog ""
+ elog "- Place your client configuration file in /etc/openvpn/client"
+ elog "- Use the openvpn-client@.service like so:"
+ elog "systemctl start openvpn-client@{Client-config}"
+ else
+ elog "The openvpn init script expects to find the configuration file"
+ elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
+ elog ""
+ elog "To create more VPNs, simply create a new .conf file for it and"
+ elog "then create a symlink to the openvpn init script from a link called"
+ elog "openvpn.newconfname - like so"
+ elog " cd /etc/openvpn"
+ elog " ${EDITOR##*/} foo.conf"
+ elog " cd /etc/init.d"
+ elog " ln -s openvpn openvpn.foo"
+ elog ""
+ elog "You can then treat openvpn.foo as any other service, so you can"
+ elog "stop one vpn and start another if you need to."
+ fi
if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
ewarn ""
diff --git a/net-vpn/openvpn/openvpn-2.5.0-r1.ebuild b/net-vpn/openvpn/openvpn-2.5.0-r1.ebuild
index fe8028777553..2744ace92710 100644
--- a/net-vpn/openvpn/openvpn-2.5.0-r1.ebuild
+++ b/net-vpn/openvpn/openvpn-2.5.0-r1.ebuild
@@ -13,7 +13,7 @@ LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
-IUSE="down-root examples inotify iproute2 libressl lz4 +lzo mbedtls +openssl"
+IUSE="down-root examples inotify iproute2 libressl +lz4 +lzo mbedtls +openssl"
IUSE+=" pam pkcs11 +plugins selinux systemd test userland_BSD"
RESTRICT="!test? ( test )"
@@ -127,19 +127,35 @@ pkg_postinst() {
elog "http://tuntaposx.sourceforge.net"
fi
- elog "The openvpn init script expects to find the configuration file"
- elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
- elog ""
- elog "To create more VPNs, simply create a new .conf file for it and"
- elog "then create a symlink to the openvpn init script from a link called"
- elog "openvpn.newconfname - like so"
- elog " cd /etc/openvpn"
- elog " ${EDITOR##*/} foo.conf"
- elog " cd /etc/init.d"
- elog " ln -s openvpn openvpn.foo"
- elog ""
- elog "You can then treat openvpn.foo as any other service, so you can"
- elog "stop one vpn and start another if you need to."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ elog "In order to use OpenVPN with systemd please use the correct systemd service file."
+ elog ""
+ elog "server:"
+ elog ""
+ elog "- Place your server configuration file in /etc/openvpn/server"
+ elog "- Use the openvpn-server@.service like so"
+ elog "systemctl start openvpn-server@{Server-config}"
+ elog ""
+ elog "client:"
+ elog ""
+ elog "- Place your client configuration file in /etc/openvpn/client"
+ elog "- Use the openvpn-client@.service like so:"
+ elog "systemctl start openvpn-client@{Client-config}"
+ else
+ elog "The openvpn init script expects to find the configuration file"
+ elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
+ elog ""
+ elog "To create more VPNs, simply create a new .conf file for it and"
+ elog "then create a symlink to the openvpn init script from a link called"
+ elog "openvpn.newconfname - like so"
+ elog " cd /etc/openvpn"
+ elog " ${EDITOR##*/} foo.conf"
+ elog " cd /etc/init.d"
+ elog " ln -s openvpn openvpn.foo"
+ elog ""
+ elog "You can then treat openvpn.foo as any other service, so you can"
+ elog "stop one vpn and start another if you need to."
+ fi
if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
ewarn ""
diff --git a/net-vpn/openvpn/openvpn-2.5.1-r1.ebuild b/net-vpn/openvpn/openvpn-2.5.1-r1.ebuild
new file mode 100644
index 000000000000..5d4782a0359f
--- /dev/null
+++ b/net-vpn/openvpn/openvpn-2.5.1-r1.ebuild
@@ -0,0 +1,174 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools flag-o-matic systemd linux-info
+
+DESCRIPTION="Robust and highly flexible tunneling application compatible with many OSes"
+SRC_URI="https://build.openvpn.net/downloads/releases/${P}.tar.gz"
+HOMEPAGE="https://openvpn.net/"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+
+IUSE="down-root examples inotify iproute2 libressl +lz4 +lzo mbedtls +openssl"
+IUSE+=" pam pkcs11 +plugins selinux systemd test userland_BSD"
+
+RESTRICT="!test? ( test )"
+REQUIRED_USE="
+ ^^ ( openssl mbedtls )
+ pkcs11? ( !mbedtls )
+ !plugins? ( !pam !down-root )
+ inotify? ( plugins )
+"
+
+CDEPEND="
+ kernel_linux? (
+ iproute2? ( sys-apps/iproute2[-minimal] )
+ )
+ lz4? ( app-arch/lz4 )
+ lzo? ( >=dev-libs/lzo-1.07 )
+ mbedtls? ( net-libs/mbedtls:= )
+ openssl? (
+ !libressl? ( >=dev-libs/openssl-0.9.8:0= )
+ libressl? ( dev-libs/libressl:0= )
+ )
+ pam? ( sys-libs/pam )
+ pkcs11? ( >=dev-libs/pkcs11-helper-1.11 )
+ systemd? ( sys-apps/systemd )
+"
+DEPEND="${CDEPEND}
+ test? ( dev-util/cmocka )
+"
+RDEPEND="${CDEPEND}
+ acct-group/openvpn
+ acct-user/openvpn
+ selinux? ( sec-policy/selinux-openvpn )
+"
+
+PATCHES=(
+ "${FILESDIR}/openvpn-2.5.0-auth-pam-missing-header.patch"
+)
+
+pkg_setup() {
+ local CONFIG_CHECK="~TUN"
+ linux-info_pkg_setup
+}
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ local -a myeconfargs
+
+ if use libressl || ! use mbedtls; then
+ myeconfargs+=(
+ $(use_enable pkcs11)
+ )
+ fi
+ myeconfargs+=(
+ $(use_enable inotify async-push)
+ --with-crypto-library=$(usex mbedtls mbedtls openssl)
+ $(use_enable lz4)
+ $(use_enable lzo)
+ $(use_enable plugins)
+ $(use_enable iproute2)
+ $(use_enable pam plugin-auth-pam)
+ $(use_enable down-root plugin-down-root)
+ $(use_enable systemd)
+ )
+ SYSTEMD_UNIT_DIR=$(systemd_get_systemunitdir) \
+ TMPFILES_DIR="/usr/lib/tmpfiles.d" \
+ IPROUTE=$(usex iproute2 '/bin/ip' '') \
+ econf "${myeconfargs[@]}"
+}
+
+src_test() {
+ make check || die "top-level tests failed"
+ pushd tests/unit_tests > /dev/null || die
+ make check || die "unit tests failed"
+ popd > /dev/null || die
+}
+
+src_install() {
+ default
+ find "${ED}/usr" -name '*.la' -delete
+ # install documentation
+ dodoc AUTHORS ChangeLog PORTS README README.IPv6
+
+ # Install some helper scripts
+ keepdir /etc/openvpn
+ exeinto /etc/openvpn
+ doexe "${FILESDIR}/up.sh"
+ doexe "${FILESDIR}/down.sh"
+
+ # Install the init script and config file
+ newinitd "${FILESDIR}/${PN}-2.1.init" openvpn
+ newconfd "${FILESDIR}/${PN}-2.1.conf" openvpn
+
+ # install examples, controlled by the respective useflag
+ if use examples ; then
+ # dodoc does not supportly support directory traversal, #15193
+ docinto /usr/share/doc/${PF}/examples
+ dodoc -r sample contrib
+ fi
+
+ # https://bugs.gentoo.org/755680#c3
+ doman doc/openvpn.8
+}
+
+pkg_postinst() {
+ if use x64-macos; then
+ elog "You might want to install tuntaposx for TAP interface support:"
+ elog "http://tuntaposx.sourceforge.net"
+ fi
+
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ elog "In order to use OpenVPN with systemd please use the correct systemd service file."
+ elog ""
+ elog "server:"
+ elog ""
+ elog "- Place your server configuration file in /etc/openvpn/server"
+ elog "- Use the openvpn-server@.service like so"
+ elog "systemctl start openvpn-server@{Server-config}"
+ elog ""
+ elog "client:"
+ elog ""
+ elog "- Place your client configuration file in /etc/openvpn/client"
+ elog "- Use the openvpn-client@.service like so:"
+ elog "systemctl start openvpn-client@{Client-config}"
+
+ else
+
+ elog "The openvpn init script expects to find the configuration file"
+ elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
+ elog ""
+ elog "To create more VPNs, simply create a new .conf file for it and"
+ elog "then create a symlink to the openvpn init script from a link called"
+ elog "openvpn.newconfname - like so"
+ elog " cd /etc/openvpn"
+ elog " ${EDITOR##*/} foo.conf"
+ elog " cd /etc/init.d"
+ elog " ln -s openvpn openvpn.foo"
+ elog ""
+ elog "You can then treat openvpn.foo as any other service, so you can"
+ elog "stop one vpn and start another if you need to."
+ fi
+
+ if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
+ ewarn ""
+ ewarn "WARNING: If you use the remote keyword then you are deemed to be"
+ ewarn "a client by our init script and as such we force up,down scripts."
+ ewarn "These scripts call /etc/openvpn/\$SVCNAME-{up,down}.sh where you"
+ ewarn "can move your scripts to."
+ fi
+
+ if use plugins ; then
+ einfo ""
+ einfo "plugins have been installed into /usr/$(get_libdir)/${PN}/plugins"
+ fi
+}
diff --git a/net-vpn/openvpn/openvpn-9999.ebuild b/net-vpn/openvpn/openvpn-9999.ebuild
index 8ea466d6754f..b2945c23a0f7 100644
--- a/net-vpn/openvpn/openvpn-9999.ebuild
+++ b/net-vpn/openvpn/openvpn-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -14,7 +14,7 @@ LICENSE="GPL-2"
SLOT="0"
KEYWORDS=""
-IUSE="down-root examples inotify iproute2 libressl lz4 +lzo mbedtls pam"
+IUSE="down-root examples inotify iproute2 libressl +lz4 +lzo mbedtls pam"
IUSE+=" pkcs11 +plugins selinux +ssl systemd test userland_BSD"
RESTRICT="!test? ( test )"
@@ -65,7 +65,7 @@ src_configure() {
SYSTEMD_UNIT_DIR=$(systemd_get_systemunitdir) \
TMPFILES_DIR="/usr/lib/tmpfiles.d" \
econf \
- --with-plugindir="${EPREFIX}/usr/$(get_libdir)/$PN" \
+ --with-plugindir="${EPREFIX}/usr/$(get_libdir)/${PN}" \
$(use_enable inotify async-push) \
$(use_enable ssl crypto) \
$(use_with ssl crypto-library $(usex mbedtls mbedtls openssl)) \
@@ -88,7 +88,9 @@ src_test() {
src_install() {
default
- find "${ED}/usr" -name '*.la' -delete
+
+ find "${ED}/usr" -name '*.la' -delete || die
+
# install documentation
dodoc AUTHORS ChangeLog PORTS README README.IPv6
@@ -116,19 +118,35 @@ pkg_postinst() {
elog "http://tuntaposx.sourceforge.net"
fi
- elog "The openvpn init script expects to find the configuration file"
- elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
- elog ""
- elog "To create more VPNs, simply create a new .conf file for it and"
- elog "then create a symlink to the openvpn init script from a link called"
- elog "openvpn.newconfname - like so"
- elog " cd /etc/openvpn"
- elog " ${EDITOR##*/} foo.conf"
- elog " cd /etc/init.d"
- elog " ln -s openvpn openvpn.foo"
- elog ""
- elog "You can then treat openvpn.foo as any other service, so you can"
- elog "stop one vpn and start another if you need to."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ elog "In order to use OpenVPN with systemd please use the correct systemd service file."
+ elog ""
+ elog "server:"
+ elog ""
+ elog "- Place your server configuration file in /etc/openvpn/server"
+ elog "- Use the openvpn-server@.service like so"
+ elog "systemctl start openvpn-server@{Server-config}"
+ elog ""
+ elog "client:"
+ elog ""
+ elog "- Place your client configuration file in /etc/openvpn/client"
+ elog "- Use the openvpn-client@.service like so:"
+ elog "systemctl start openvpn-client@{Client-config}"
+ else
+ elog "The openvpn init script expects to find the configuration file"
+ elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
+ elog ""
+ elog "To create more VPNs, simply create a new .conf file for it and"
+ elog "then create a symlink to the openvpn init script from a link called"
+ elog "openvpn.newconfname - like so"
+ elog " cd /etc/openvpn"
+ elog " ${EDITOR##*/} foo.conf"
+ elog " cd /etc/init.d"
+ elog " ln -s openvpn openvpn.foo"
+ elog ""
+ elog "You can then treat openvpn.foo as any other service, so you can"
+ elog "stop one vpn and start another if you need to."
+ fi
if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
ewarn ""