# Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/net-misc/openvpn/openvpn-1.6.0.ebuild,v 1.7 2005/02/05 16:59:59 solar Exp $ inherit gnuconfig #IUSE="ssl threads" # I can't test most of these. They mostly only make sense when enabled. IUSE="ssl threads lzo socks5 http debug" DESCRIPTION="OpenVPN is a robust and highly flexible tunneling application compatible with many OSes." SRC_URI="http://openvpn.net/release/${P}.tar.gz" HOMEPAGE="http://openvpn.net/" SLOT="0" LICENSE="GPL-2" KEYWORDS="~x86 ~ppc ~sparc ~alpha ~ppc-macos ~amd64" RDEPEND="dev-libs/lzo >=dev-libs/openssl-0.9.7" DEPEND="${RDEPEND} virtual/os-headers" src_unpack() { unpack ${A} gnuconfig_update } src_compile() { econf \ `use_with ssl` \ `use_with ssl crypto` \ `use_with lzo` \ `use_enable threads pthread` \ `use_enable socks5 socks` \ `use_enable http` \ `use_enable debug` \ || die emake || die } src_install() { make DESTDIR=${D} install || die # There must be a better way of doing this. pushd ${S} tar -cjpSf easy-rsa.tar.bz2 easy-rsa popd dodoc COPYING ChangeLog INSTALL PORTS README easy-rsa.tar.bz2 exeinto /etc/init.d doexe ${FILESDIR}/openvpn # This initscript is a little pragmatic with giving each instance its own # directory. After all, only one instance is needed on the server end, # and not many clients will want multiple tunnels. # But anyhow, we should give them some sample configs. } pkg_postinst() { einfo "The init.d script that comes with OpenVPN expects directories /etc/openvpn/*/ with a local.conf and any supporting files, such as keys." ewarn "OpenVPN is forwards and backwards compatible, with some crude hacks." ewarn "If you want to use this with any non-2.0 version, read the notes at" ewarn " http://openvpn.net/compat.html" }