1 |
commit: 883a6231317bc0cbf3277248661dc0309a8e1258 |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jan 2 17:24:42 2017 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jan 2 17:25:39 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=883a6231 |
7 |
|
8 |
app-emulation/open-vm-tools: replace mount.vmhgfs with a wrapper |
9 |
|
10 |
This will allow people to continue using fstype 'vmhgfs' in fstab with |
11 |
the FUSE mounter. |
12 |
|
13 |
Package-Manager: Portage-2.3.3_p12, Repoman-2.3.1_p5 |
14 |
|
15 |
app-emulation/open-vm-tools/files/mount.vmhgfs | 2 + |
16 |
.../open-vm-tools/open-vm-tools-10.1.0-r1.ebuild | 153 +++++++++++++++++++++ |
17 |
2 files changed, 155 insertions(+) |
18 |
|
19 |
diff --git a/app-emulation/open-vm-tools/files/mount.vmhgfs b/app-emulation/open-vm-tools/files/mount.vmhgfs |
20 |
new file mode 100644 |
21 |
index 00000000..d4b319c |
22 |
--- /dev/null |
23 |
+++ b/app-emulation/open-vm-tools/files/mount.vmhgfs |
24 |
@@ -0,0 +1,2 @@ |
25 |
+#!/bin/sh |
26 |
+hgfsmounter "$@" >/dev/null 2>&1 || vmhgfs-fuse "$@" |
27 |
|
28 |
diff --git a/app-emulation/open-vm-tools/open-vm-tools-10.1.0-r1.ebuild b/app-emulation/open-vm-tools/open-vm-tools-10.1.0-r1.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000..8cc9d43 |
31 |
--- /dev/null |
32 |
+++ b/app-emulation/open-vm-tools/open-vm-tools-10.1.0-r1.ebuild |
33 |
@@ -0,0 +1,153 @@ |
34 |
+# Copyright 1999-2017 Gentoo Foundation |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+# $Id$ |
37 |
+ |
38 |
+EAPI=6 |
39 |
+MODULES_OPTIONAL_USE="modules" |
40 |
+ |
41 |
+inherit autotools linux-mod pam systemd toolchain-funcs user |
42 |
+ |
43 |
+DESCRIPTION="Opensourced tools for VMware guests" |
44 |
+HOMEPAGE="https://github.com/vmware/open-vm-tools" |
45 |
+MY_P="${P}-4449150" |
46 |
+SRC_URI="https://github.com/vmware/open-vm-tools/files/590760/${MY_P}.tar.gz" |
47 |
+ |
48 |
+LICENSE="LGPL-2" |
49 |
+SLOT="0" |
50 |
+KEYWORDS="~amd64 ~x86" |
51 |
+IUSE="X doc grabbitmqproxy icu pam +pic vgauth xinerama" |
52 |
+ |
53 |
+COMMON_DEPEND=" |
54 |
+ dev-libs/glib:2 |
55 |
+ dev-libs/libdnet |
56 |
+ sys-fs/fuse |
57 |
+ >=sys-process/procps-3.3.2 |
58 |
+ grabbitmqproxy? ( dev-libs/openssl:0 ) |
59 |
+ icu? ( dev-libs/icu:= ) |
60 |
+ pam? ( virtual/pam ) |
61 |
+ vgauth? ( |
62 |
+ dev-libs/openssl:0 |
63 |
+ dev-libs/xerces-c |
64 |
+ dev-libs/xml-security-c |
65 |
+ ) |
66 |
+ X? ( |
67 |
+ dev-cpp/gtkmm:3.0 |
68 |
+ x11-libs/gtk+:3 |
69 |
+ x11-libs/libICE |
70 |
+ x11-libs/libSM |
71 |
+ x11-libs/libX11 |
72 |
+ x11-libs/libXcomposite |
73 |
+ x11-libs/libXext |
74 |
+ x11-libs/libXi |
75 |
+ x11-libs/libXrender |
76 |
+ x11-libs/libXrandr |
77 |
+ x11-libs/libXtst |
78 |
+ xinerama? ( x11-libs/libXinerama ) |
79 |
+ ) |
80 |
+" |
81 |
+ |
82 |
+DEPEND="${COMMON_DEPEND} |
83 |
+ doc? ( app-doc/doxygen ) |
84 |
+ virtual/pkgconfig |
85 |
+" |
86 |
+ |
87 |
+RDEPEND="${COMMON_DEPEND} |
88 |
+" |
89 |
+ |
90 |
+S="${WORKDIR}/${MY_P}/open-vm-tools" |
91 |
+ |
92 |
+PATCHES=( |
93 |
+ "${FILESDIR}/10.1.0-mount.vmhgfs.patch" |
94 |
+ "${FILESDIR}/10.1.0-vgauth.patch" |
95 |
+ "${FILESDIR}/10.1.0-Werror.patch" |
96 |
+) |
97 |
+ |
98 |
+pkg_setup() { |
99 |
+ linux-info_get_any_version |
100 |
+ local CONFIG_CHECK="~VMWARE_BALLOON ~VMWARE_PVSCSI ~VMXNET3" |
101 |
+ use X && CONFIG_CHECK+=" ~DRM_VMWGFX" |
102 |
+ kernel_is -lt 3 9 || CONFIG_CHECK+=" ~VMWARE_VMCI ~VMWARE_VMCI_VSOCKETS" |
103 |
+ kernel_is -lt 3 || CONFIG_CHECK+=" ~FUSE_FS" |
104 |
+ if use modules; then |
105 |
+ linux-mod_pkg_setup |
106 |
+ else |
107 |
+ linux-info_pkg_setup |
108 |
+ fi |
109 |
+} |
110 |
+ |
111 |
+src_prepare() { |
112 |
+ eapply -p2 "${PATCHES[@]}" |
113 |
+ eapply_user |
114 |
+ eautoreconf |
115 |
+} |
116 |
+ |
117 |
+src_configure() { |
118 |
+ local myeconfargs=( |
119 |
+ --disable-deploypkg |
120 |
+ --disable-static |
121 |
+ --disable-tests |
122 |
+ --with-procps |
123 |
+ --with-dnet |
124 |
+ $(use_enable doc docs) |
125 |
+ $(use_enable grabbitmqproxy) |
126 |
+ $(use_enable vgauth) |
127 |
+ $(use_enable xinerama multimon) |
128 |
+ $(use_with icu) |
129 |
+ $(use_with pam) |
130 |
+ $(use_with pic) |
131 |
+ --without-gtk2 |
132 |
+ --without-gtkmm |
133 |
+ $(use_with X gtk3) |
134 |
+ $(use_with X gtkmm3) |
135 |
+ $(use_with X x) |
136 |
+ |
137 |
+ # configure locates the kernel object directory by looking for |
138 |
+ # "/lib/modules/${KERNEL_RELEASE}/build". |
139 |
+ # This will fail if the user is building against an uninstalled kernel. |
140 |
+ # Fixing this would mean reworking the build system. |
141 |
+ $(use_with modules kernel-modules) |
142 |
+ --without-root-privileges |
143 |
+ --with-kernel-release="${KV_FULL}" |
144 |
+ ) |
145 |
+ |
146 |
+ econf "${myeconfargs[@]}" |
147 |
+} |
148 |
+ |
149 |
+src_compile() { |
150 |
+ use modules && set_arch_to_kernel |
151 |
+ default |
152 |
+} |
153 |
+ |
154 |
+src_install() { |
155 |
+ default |
156 |
+ prune_libtool_files --modules |
157 |
+ |
158 |
+ if use pam; then |
159 |
+ rm "${ED%/}"/etc/pam.d/vmtoolsd || die |
160 |
+ pamd_mimic_system vmtoolsd auth account |
161 |
+ fi |
162 |
+ |
163 |
+ newinitd "${FILESDIR}/open-vm-tools.initd" vmware-tools |
164 |
+ newconfd "${FILESDIR}/open-vm-tools.confd" vmware-tools |
165 |
+ systemd_dounit "${FILESDIR}"/vmtoolsd.service |
166 |
+ |
167 |
+ # Replace mount.vmhgfs with a wrapper |
168 |
+ mv "${ED%/}"/usr/sbin/{mount.vmhgfs,hgfsmounter} || die |
169 |
+ dosbin "${FILESDIR}/mount.vmhgfs" |
170 |
+ |
171 |
+ # Make fstype = vmhgfs-fuse work in fstab |
172 |
+ dosym vmhgfs-fuse /usr/bin/mount.vmhgfs-fuse |
173 |
+ |
174 |
+ if use X; then |
175 |
+ fperms 4711 /usr/bin/vmware-user-suid-wrapper |
176 |
+ dobin scripts/common/vmware-xdg-detect-de |
177 |
+ |
178 |
+ elog "To be able to use the drag'n'drop feature of VMware for file" |
179 |
+ elog "exchange, please add the users to the 'vmware' group." |
180 |
+ fi |
181 |
+} |
182 |
+ |
183 |
+pkg_postinst() { |
184 |
+ enewgroup vmware |
185 |
+ linux-mod_pkg_postinst |
186 |
+} |