From 8f6ba5912a831892360fb119368b4d50c9d5b3d1 Mon Sep 17 00:00:00 2001 From: "Andreas K. Huettel (dilfridge)" Date: Sat, 11 Oct 2014 22:40:04 +0200 Subject: EAPI bump to 5, remove some die, replace perl-core dependencies with virtual/perl- Package-Manager: portage-2.2.14_rc1 --- .../vmware-vsphere-cli-4.1.0.254719-r1.ebuild | 141 +++++++++++++++++++++ 1 file changed, 141 insertions(+) create mode 100644 app-emulation/vmware-vsphere-cli/vmware-vsphere-cli-4.1.0.254719-r1.ebuild (limited to 'app-emulation/vmware-vsphere-cli/vmware-vsphere-cli-4.1.0.254719-r1.ebuild') diff --git a/app-emulation/vmware-vsphere-cli/vmware-vsphere-cli-4.1.0.254719-r1.ebuild b/app-emulation/vmware-vsphere-cli/vmware-vsphere-cli-4.1.0.254719-r1.ebuild new file mode 100644 index 0000000..94b8255 --- /dev/null +++ b/app-emulation/vmware-vsphere-cli/vmware-vsphere-cli-4.1.0.254719-r1.ebuild @@ -0,0 +1,141 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +# Unlike many other binary packages the user doesn't need to agree to a licence +# to download VMWare. The agreeing to a licence is part of the configure step +# which the user must run manually. + +EAPI=5 + +inherit eutils perl-module versionator + +MY_PV=$(replace_version_separator 3 '-' ) +MY_PN="VMware-vSphere-CLI-${MY_PV}" + +DESCRIPTION="VMware vSphere Command-Line Interface" +HOMEPAGE="http://www.vmware.com/" +SRC_URI=" x86? ( mirror://vmware/software/vmserver/${MY_PN}.i386.tar.gz ) + amd64? ( mirror://vmware/software/vmserver/${MY_PN}.x86_64.tar.gz ) " + +LICENSE="vmware" +IUSE="" +SLOT="0" +KEYWORDS="-* ~x86 ~amd64" +RESTRICT="strip" + +DEPEND=" + >=dev-lang/perl-5 + dev-libs/expat + dev-libs/glib + dev-libs/libxml2 + dev-libs/openssl + dev-perl/Archive-Zip + dev-perl/Class-MethodMaker + dev-perl/Crypt-SSLeay + dev-perl/Data-Dump + dev-perl/Data-Dumper-Concise + dev-perl/HTML-Parser + dev-perl/SOAP-Lite + dev-perl/URI + dev-perl/Data-UUID + dev-perl/XML-LibXML + dev-perl/XML-NamespaceSupport + dev-perl/XML-SAX + dev-perl/libwww-perl + dev-perl/libxml-perl + virtual/perl-Compress-Raw-Zlib + virtual/perl-IO-Compress + virtual/perl-version + sys-fs/e2fsprogs + sys-libs/zlib" +# !app-emulation/vmware-server +# !app-emulation/vmware-vix +# !app-emulation/vmware-workstation" +RDEPEND="${DEPEND}" + +S=${WORKDIR}/${PN}-distrib + +pkg_setup() { + if use x86; then + MY_P="${MY_PN}.i386" + elif use amd64; then + MY_P="${MY_PN}.x86_64" + fi +} + +src_prepare() { + VMWARE_GROUP=${VMWARE_GROUP:-vmware} + VMWARE_INSTALL_DIR=/opt/${PN//-//} + + shortname="vcli" + product="vmware-vcli" + config_dir="/etc/vmware-vcli" + product_name="vSphere CLI" + + enewgroup ${VMWARE_GROUP} + + sed -i.bak -e "s:/sbin/lsmod:/bin/lsmod:" "${S}"/installer/services.sh || die "sed of services" + + # We won't want any perl scripts from VMware + rm -f *.pl bin/*.pl + rm -f etc/installer.sh + + epatch "${FILESDIR}"/makefile.patch + + perl-module_src_prepare +} + +src_install() { + # We loop through our directories and copy everything to our system. + for x in apps bin + do + if [[ -e "${S}"/${x} ]] + then + dodir "${VMWARE_INSTALL_DIR}"/${x} + cp -pPR "${S}"/${x}/* "${D}""${VMWARE_INSTALL_DIR}"/${x} || die "copying ${x}" + fi + done + + perl-module_src_install + + # init script + if [[ -e "${FILESDIR}/${PN}.rc" ]] + then + newinitd "${FILESDIR}"/${PN}.rc ${product} + fi + + # create the environment + local envd="${T}/90vmware-cli" + cat > "${envd}" <<-EOF + PATH='${VMWARE_INSTALL_DIR}/bin' + ROOTPATH='${VMWARE_INSTALL_DIR}/bin' + EOF + doenvd "${envd}" + + # Last, we check for any mime files. + if [[ -e "${FILESDIR}/${PN}.xml" ]] + then + insinto /usr/share/mime/packages + doins "${FILESDIR}"/${PN}.xml + fi + + if [[ -e doc/EULA ]] + then + insinto "${VMWARE_INSTALL_DIR}"/doc + doins doc/EULA + fi + + doman man/* + + # create the configuration + #dodir "${config_dir}" + +} + +pkg_postinst() { + [[ -d "${config_dir}" ]] && chown -R root:${VMWARE_GROUP} ${config_dir} + + ewarn "In order to run ${product_name}, you have to" + ewarn "be in the '${VMWARE_GROUP}' group." +} -- cgit v1.2.3-65-gdbad