phpvirtualbox-4.3.0.ebuild 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. # Copyright 1999-2016 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="5"
  4. inherit versionator eutils webapp readme.gentoo
  5. MY_PV="$(replace_version_separator 2 '-')"
  6. MY_P="${PN}-${MY_PV}"
  7. DESCRIPTION="Web-based administration for VirtualBox in PHP"
  8. HOMEPAGE="https://sourceforge.net/projects/phpvirtualbox/"
  9. SRC_URI="mirror://sourceforge/${PN}/${MY_P}.zip"
  10. LICENSE="GPL-2"
  11. KEYWORDS="~amd64 ~x86"
  12. IUSE=""
  13. RDEPEND="
  14. dev-lang/php[session,unicode,soap,gd]
  15. virtual/httpd-php:*
  16. "
  17. DEPEND="app-arch/unzip"
  18. S="${WORKDIR}"
  19. DISABLE_AUTOFORMATTING="yes"
  20. DOC_CONTENTS="
  21. Local or remote virtualbox hosts must be compiled with
  22. 'vboxwebsrv' useflag and the respective init script
  23. must be running to use this interface:
  24. /etc/init.d/vboxwebsrv start
  25. To enable the automatic startup mode feature uncomment the
  26. following line in the config.php file:
  27. var \$startStopConfig = true;
  28. You should also add the /etc/init.d/vboxinit script to the
  29. default runlevel on the virtualbox host:
  30. \`rc-update add vboxinit default\`
  31. If the server is on a remote host, than the script must be
  32. copied manually from
  33. '${FILESDIR}'/vboxinit-initd to
  34. /etc/init.d/vboxinit on the remote host."
  35. src_install() {
  36. webapp_src_preinst
  37. dodoc CHANGELOG.txt LICENSE.txt README.txt
  38. rm -f CHANGELOG.txt LICENSE.txt README.txt
  39. insinto "${MY_HTDOCSDIR}"
  40. doins -r .
  41. webapp_configfile "${MY_HTDOCSDIR}"/config.php-example
  42. webapp_serverowned "${MY_HTDOCSDIR}"/config.php-example
  43. webapp_src_install
  44. if has_version app-emulation/virtualbox[vboxwebsrv] || \
  45. has_version app-emulation/virtualbox-bin[vboxwebsrv]
  46. then
  47. newinitd "${FILESDIR}"/vboxinit-initd vboxinit
  48. fi
  49. readme.gentoo_create_doc
  50. }
  51. pkg_postinst() {
  52. webapp_pkg_postinst
  53. readme.gentoo_print_elog
  54. }