diff options
author | Julian Ospald <hasufell@gentoo.org> | 2013-02-21 15:43:14 +0000 |
---|---|---|
committer | Julian Ospald <hasufell@gentoo.org> | 2013-02-21 15:43:14 +0000 |
commit | 2ba76ce5a51fa2e6d28585699451b509cf34325c (patch) | |
tree | 66b0cfb2ba5ea80f4a939422fec16460cc659040 /net-misc/badvpn | |
parent | Depend on dev-python/PyQt4[svg], bug 458546 by Piergiorgio Beruto. Also add P... (diff) | |
download | gentoo-2-2ba76ce5a51fa2e6d28585699451b509cf34325c.tar.gz gentoo-2-2ba76ce5a51fa2e6d28585699451b509cf34325c.tar.bz2 gentoo-2-2ba76ce5a51fa2e6d28585699451b509cf34325c.zip |
version bump by Ambroz Bizjak wrt #454476
(Portage version: 2.2.0_alpha163/cvs/Linux x86_64, signed Manifest commit with key E73C35B3)
Diffstat (limited to 'net-misc/badvpn')
-rw-r--r-- | net-misc/badvpn/ChangeLog | 10 | ||||
-rw-r--r-- | net-misc/badvpn/badvpn-1.999.127.ebuild | 93 | ||||
-rw-r--r-- | net-misc/badvpn/files/badvpn-1.999.127-ncd.init | 24 | ||||
-rw-r--r-- | net-misc/badvpn/files/badvpn-ncd.service | 11 |
4 files changed, 136 insertions, 2 deletions
diff --git a/net-misc/badvpn/ChangeLog b/net-misc/badvpn/ChangeLog index f0c06e72ab41..0813b10f1cb9 100644 --- a/net-misc/badvpn/ChangeLog +++ b/net-misc/badvpn/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-misc/badvpn -# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/badvpn/ChangeLog,v 1.10 2012/12/26 02:22:00 hasufell Exp $ +# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/badvpn/ChangeLog,v 1.11 2013/02/21 15:43:14 hasufell Exp $ + +*badvpn-1.999.127 (21 Feb 2013) + + 21 Feb 2013; Julian Ospald <hasufell@gentoo.org> +badvpn-1.999.127.ebuild, + +files/badvpn-1.999.127-ncd.init, +files/badvpn-ncd.service: + version bump by Ambroz Bizjak wrt #454476 *badvpn-1.999.126 (26 Dec 2012) diff --git a/net-misc/badvpn/badvpn-1.999.127.ebuild b/net-misc/badvpn/badvpn-1.999.127.ebuild new file mode 100644 index 000000000000..2c2950746c1f --- /dev/null +++ b/net-misc/badvpn/badvpn-1.999.127.ebuild @@ -0,0 +1,93 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/badvpn/badvpn-1.999.127.ebuild,v 1.1 2013/02/21 15:43:14 hasufell Exp $ + +EAPI=5 +inherit eutils cmake-utils user toolchain-funcs systemd + +MY_P=${PN}-${PV/_rc/rc} +DESCRIPTION="Peer-to-peer VPN, NCD scripting language, tun2socks proxifier" +HOMEPAGE="http://code.google.com/p/badvpn/" +SRC_URI="http://badvpn.googlecode.com/files/${MY_P}.tar.bz2" + +LICENSE="BSD" +KEYWORDS="~amd64 ~arm ~x86" +SLOT="0" +TARGETS="+client +ncd +server +tun2socks +udpgw" +IUSE="${TARGETS} debug" +# tests are only ncd related +RESTRICT="!ncd? ( test )" + +COMMON_DEPEND=" + client? ( + dev-libs/nspr + dev-libs/nss + dev-libs/openssl + ) + server? ( + dev-libs/nspr + dev-libs/nss + dev-libs/openssl + ) + ncd? ( + dev-libs/openssl + )" +RDEPEND="${COMMON_DEPEND} + ncd? ( + sys-apps/iproute2 + >=virtual/udev-171 + )" +DEPEND="${COMMON_DEPEND} + virtual/pkgconfig" +# we need at least one target +REQUIRED_USE="|| ( ${TARGETS//+/} )" + +S=${WORKDIR}/${MY_P} + +pkg_setup() { + enewuser ${PN} +} + +src_prepare() { + # allow user to easily apply patches + epatch_user +} + +src_configure() { + local mycmakeargs=( + -DBUILD_NOTHING_BY_DEFAULT=1 + $(cmake-utils_use_build client CLIENT) + $(cmake-utils_use_build server SERVER) + $(cmake-utils_use_build ncd NCD) + $(cmake-utils_use_build tun2socks TUN2SOCKS) + $(cmake-utils_use_build udpgw UDPGW) + ) + + cmake-utils_src_configure +} + +src_test() { + # OOHMSA: do this on portage level? + tc-is-cross-compiler && die "these tests do not work when cross compiling!" + + einfo "Running NCD tests" + cd "${S}"/ncd/tests || die + bash ./run_tests "${CMAKE_BUILD_DIR}/ncd/badvpn-ncd" \ + || die "one or more tests failed" +} + +src_install() { + cmake-utils_src_install + dodoc ChangeLog + + if use server; then + newinitd "${FILESDIR}"/${PN}-server.init ${PN}-server + newconfd "${FILESDIR}"/${PN}-server.conf ${PN}-server + fi + + if use ncd; then + newinitd "${FILESDIR}"/${P}-ncd.init ${PN}-ncd + newconfd "${FILESDIR}"/${PN}-ncd.conf ${PN}-ncd + systemd_dounit "${FILESDIR}"/badvpn-ncd.service + fi +} diff --git a/net-misc/badvpn/files/badvpn-1.999.127-ncd.init b/net-misc/badvpn/files/badvpn-1.999.127-ncd.init new file mode 100644 index 000000000000..509a17f71f18 --- /dev/null +++ b/net-misc/badvpn/files/badvpn-1.999.127-ncd.init @@ -0,0 +1,24 @@ +#!/sbin/runscript +# Copyright 1999-2013 Gentoo Foundation +# Released under the 3-clause BSD license. + +command="${ncd_exec:-"/usr/bin/badvpn-ncd"}" +command_args="${ncd_args} --config-file ${ncd_config:-/etc/ncd.conf}" +command_background="YES" +description="Network Configuration Daemon" +pidfile="/var/run/${RC_SVCNAME}.pid" + +depend() { + need localmount + after bootmisc + before netmount +} + +start_pre() { + if yesno "${ncd_syslog:-NO}"; then + command_args="${command_args} + --logger syslog + --syslog-ident \"${ncd_syslog_ident:-${RC_SVCNAME}}\" + --channel-loglevel ncd_log_msg info" + fi +} diff --git a/net-misc/badvpn/files/badvpn-ncd.service b/net-misc/badvpn/files/badvpn-ncd.service new file mode 100644 index 000000000000..6ca7aa515e00 --- /dev/null +++ b/net-misc/badvpn/files/badvpn-ncd.service @@ -0,0 +1,11 @@ +[Unit] +Description=Network Configuation Daemon +After=syslog.target + +[Service] +ExecStart=/usr/bin/badvpn-ncd --logger syslog --syslog-ident ncd --loglevel warning --channel-loglevel ncd_log_msg info /etc/ncd.conf +Restart=always + +[Install] +WantedBy=multi-user.target + |