1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
7 inherit versionator eutils webapp
9 MY_PV="$(replace_version_separator 2 '-')"
12 DESCRIPTION="Web-based administration for VirtualBox in PHP"
13 HOMEPAGE="https://sourceforge.net/projects/phpvirtualbox/"
14 SRC_URI="https://${PN}.googlecode.com/files/${MY_P}.zip"
17 KEYWORDS="~amd64 ~x86"
21 dev-lang/php[session,unicode,soap,gd]
24 DEPEND="app-arch/unzip"
31 dodoc CHANGELOG.txt LICENSE.txt README.txt || die
32 rm -f CHANGELOG.txt LICENSE.txt README.txt
34 insinto "${MY_HTDOCSDIR}"
37 webapp_configfile "${MY_HTDOCSDIR}"/config.php-example
38 webapp_serverowned "${MY_HTDOCSDIR}"/config.php-example
41 if has_version app-emulation/virtualbox[vboxwebsrv] || \
42 has_version app-emulation/virtualbox-bin[vboxwebsrv]
44 newinitd "${FILESDIR}"/vboxinit-initd vboxinit
50 elog "Local or remote virtualbox hosts must be compiled with"
51 elog "'vboxwebsrv' useflag and the respective init script"
52 elog "must be running to use this interface"
53 elog " /etc/init.d/vboxwebsrv start"
55 elog "To enable the automatic startup mode feature uncomment the"
56 elog "following line in the config.php file:"
57 elog " var \$startStopConfig = true;"
59 elog "You should also add the /etc/init.d/vboxinit script to the"
60 elog "default runlevel on the virtualbox host:"
61 elog "\`rc-update add vboxinit default\`"
62 elog "If the server is on a remote host, than the script must be"
63 elog "copied manually from"
64 elog "${FILESDIR}/vboxinit-initd to /etc/init.d/vboxinit"
65 elog "on the remote host."