Lines 4-69
Link Here
|
4 |
|
4 |
|
5 |
EAPI="2" |
5 |
EAPI="2" |
6 |
|
6 |
|
7 |
inherit eutils linux-mod pam versionator |
7 |
inherit autotools eutils linux-mod pam versionator |
8 |
|
8 |
|
9 |
MY_DATE="$(get_version_component_range 3)" |
9 |
MY_DATE="$(get_version_component_range 3)" |
10 |
MY_BUILD="$(get_version_component_range 4)" |
10 |
MY_BUILD="$(get_version_component_range 4)" |
11 |
MY_PV="${MY_DATE:0:4}.${MY_DATE:4:2}.${MY_DATE:6:2}-${MY_BUILD}" |
11 |
MY_PV="${MY_DATE:0:4}.${MY_DATE:4:2}.${MY_DATE:6:2}-${MY_BUILD}" |
12 |
MY_P="${PN}-${MY_PV}" |
12 |
MY_P="${PN}-${MY_PV}" |
13 |
|
13 |
|
14 |
S="${WORKDIR}/${MY_P}" |
14 |
DESCRIPTION="Opensourced tools for VMware guests." |
15 |
|
|
|
16 |
DESCRIPTION="Opensourced tools for VMware guests" |
17 |
HOMEPAGE="http://open-vm-tools.sourceforge.net/" |
15 |
HOMEPAGE="http://open-vm-tools.sourceforge.net/" |
18 |
SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz" |
16 |
SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz" |
19 |
|
17 |
|
20 |
LICENSE="LGPL-2" |
18 |
LICENSE="LGPL-2" |
21 |
SLOT="0" |
19 |
SLOT="0" |
22 |
KEYWORDS="~x86 ~amd64" |
20 |
KEYWORDS="~amd64 ~x86" |
23 |
IUSE="X xinerama icu unity" |
21 |
IUSE="X icu unity xinerama" |
24 |
DEPEND=" |
22 |
|
25 |
!app-emulation/vmware-workstation-tools |
23 |
DEPEND=">=dev-libs/glib-2 |
26 |
!app-emulation/vmware-server-tools |
24 |
dev-libs/libdnet |
27 |
!app-emulation/vmware-esx-tools |
25 |
dev-util/pkgconfig |
28 |
virtual/linux-sources |
26 |
sys-apps/ethtool |
29 |
sys-apps/ethtool |
27 |
sys-process/procps |
30 |
X? ( |
28 |
virtual/linux-sources |
31 |
x11-libs/libX11 |
29 |
X? ( |
32 |
x11-libs/gtk+ |
30 |
dev-cpp/gtkmm |
33 |
dev-cpp/gtkmm |
31 |
x11-libs/libnotify |
34 |
) |
32 |
x11-libs/libX11 |
35 |
unity? ( |
33 |
x11-libs/gtk+ |
36 |
x11-libs/libXScrnSaver |
34 |
) |
37 |
dev-libs/uriparser |
35 |
icu? ( dev-libs/icu ) |
38 |
) |
36 |
unity? ( |
39 |
xinerama? ( |
37 |
dev-libs/uriparser |
40 |
x11-libs/libXinerama |
38 |
x11-libs/libXScrnSaver |
41 |
) |
39 |
) |
42 |
sys-process/procps |
40 |
xinerama? ( x11-libs/libXinerama ) |
43 |
dev-libs/libdnet |
41 |
!app-emulation/vmware-workstation-tools |
44 |
>=dev-libs/glib-2 |
42 |
!app-emulation/vmware-server-tools |
45 |
icu? ( dev-libs/icu ) |
43 |
!app-emulation/vmware-esx-tools" |
46 |
" |
|
|
47 |
|
44 |
|
48 |
RDEPEND="${DEPEND/virtual\/linux\-sources/} |
45 |
RDEPEND="${DEPEND/virtual\/linux\-sources/} |
49 |
virtual/pam |
46 |
virtual/pam |
50 |
X? ( |
47 |
X? ( |
51 |
x11-base/xorg-server |
48 |
x11-base/xorg-server |
52 |
x11-drivers/xf86-video-vmware |
49 |
x11-drivers/xf86-input-vmmouse |
53 |
x11-drivers/xf86-input-vmmouse |
50 |
x11-drivers/xf86-video-vmware |
54 |
) |
51 |
)" |
55 |
unity? ( |
52 |
|
56 |
x11-libs/libXScrnSaver |
53 |
# TODO: Fuse, libnotify and doxygen automagic |
57 |
dev-libs/uriparser |
54 |
|
58 |
) |
55 |
S="${WORKDIR}/${MY_P}" |
59 |
" |
|
|
60 |
|
56 |
|
61 |
VMWARE_MOD_DIR="modules/linux" |
57 |
VMWARE_MOD_DIR="modules/linux" |
62 |
VMWARE_MODULE_LIST="pvscsi vmblock vmci vmhgfs vmsync vmmemctl vmxnet vmxnet3 vsock" |
58 |
VMWARE_MODULE_LIST="pvscsi vmblock vmci vmhgfs vmsync vmmemctl vmxnet vmxnet3 vsock" |
63 |
|
59 |
|
64 |
pkg_setup() { |
60 |
pkg_setup() { |
65 |
use unity && ! use xinerama && \ |
61 |
use unity && ! use xinerama && die "The Unity USE flag requires USE=\"xinerama\" as well." |
66 |
die 'The Unity USE flag requires USE="xinerama" as well' |
|
|
67 |
|
62 |
|
68 |
linux-mod_pkg_setup |
63 |
linux-mod_pkg_setup |
69 |
MODULE_NAMES="" |
64 |
MODULE_NAMES="" |
Lines 85-98
Link Here
|
85 |
|
80 |
|
86 |
src_prepare() { |
81 |
src_prepare() { |
87 |
epatch "${FILESDIR}/default-scripts.patch" |
82 |
epatch "${FILESDIR}/default-scripts.patch" |
88 |
sed -e 's:VMTOOLSD_PLUGIN_ROOT=\\"\$(pkglibdir)\\":VMTOOLSD_PLUGIN_ROOT=\\"\$(pkglibdir)/plugins\\":g' -i services/vmtoolsd/Makefile.in |
83 |
sed -i -e 's:VMTOOLSD_PLUGIN_ROOT=\\"\$(pkglibdir)\\":VMTOOLSD_PLUGIN_ROOT=\\"\$(pkglibdir)/plugins\\":g' \ |
|
|
84 |
"${S}"/services/vmtoolsd/Makefile.in || die "sed plugin path failed" |
85 |
|
86 |
# fix configure for >=sys-process/procps-3.2.8 |
87 |
sed -i -e 's/proc-3.2.7/proc/g' "${S}"/configure{,.ac} || die "sed configure failed" |
88 |
eautoreconf |
89 |
} |
89 |
} |
90 |
|
90 |
|
91 |
src_configure() { |
91 |
src_configure() { |
92 |
econf \ |
92 |
econf \ |
|
|
93 |
--with-procps \ |
94 |
--with-dnet \ |
93 |
--without-kernel-modules \ |
95 |
--without-kernel-modules \ |
94 |
$(use_with icu) \ |
96 |
$(use_with icu) \ |
95 |
$(use_with X x) \ |
97 |
$(use_with X x) \ |
|
|
98 |
$(use_with X gtk2) \ |
96 |
$(use_with X gtkmm) \ |
99 |
$(use_with X gtkmm) \ |
97 |
$(use_enable unity) \ |
100 |
$(use_enable unity) \ |
98 |
$(use_enable xinerama multimon) |
101 |
$(use_enable xinerama multimon) |
Lines 101-129
Link Here
|
101 |
src_compile() { |
104 |
src_compile() { |
102 |
linux-mod_src_compile |
105 |
linux-mod_src_compile |
103 |
|
106 |
|
104 |
emake || die |
107 |
emake || die "failed to compile" |
105 |
} |
108 |
} |
106 |
|
109 |
|
107 |
src_install() { |
110 |
src_install() { |
108 |
linux-mod_src_install |
111 |
linux-mod_src_install |
109 |
|
112 |
|
110 |
emake DESTDIR="${D}" install || die "Failed to install" |
113 |
emake DESTDIR="${D}" install || die "emake install failed" |
111 |
|
114 |
|
112 |
rm "${D}"/etc/pam.d/vmtoolsd |
115 |
rm "${D}"/etc/pam.d/vmtoolsd |
113 |
pamd_mimic_system vmtoolsd auth account |
116 |
pamd_mimic_system vmtoolsd auth account |
114 |
|
117 |
|
115 |
newinitd "${FILESDIR}/open-vm-tools.initd" vmware-tools |
118 |
newinitd "${FILESDIR}/open-vm-tools.initd" vmware-tools || die "newinit.d vmware-tools failed" |
116 |
newconfd "${FILESDIR}/open-vm.confd" vmware-tools |
119 |
newconfd "${FILESDIR}/open-vm.confd" vmware-tools || die "newconfd vmware-tools failed" |
117 |
|
120 |
|
118 |
if use X; |
121 |
if use X ; then |
119 |
then |
|
|
120 |
insinto /etc/xdg/autostart |
122 |
insinto /etc/xdg/autostart |
121 |
doins "${FILESDIR}/open-vm-tools.desktop" |
123 |
doins "${FILESDIR}/open-vm-tools.desktop" || die "doins .desktop file failed" |
122 |
|
124 |
|
123 |
elog "To be able to use the drag'n'drop feature of VMware for file" |
125 |
elog "To be able to use the drag'n'drop feature of VMware for file" |
124 |
elog "exchange, you need to do this:" |
126 |
elog "exchange, you need to do this:" |
125 |
elog " Add 'vmware-tools' to your default runlevel" |
127 |
elog " Add 'vmware-tools' to your default runlevel." |
126 |
elog " Add the users which should have access to this function" |
128 |
elog " Add the users which should have access to this function" |
127 |
elog " to the group 'vmware'" |
129 |
elog " to the group 'vmware'." |
128 |
fi |
130 |
fi |
129 |
} |
131 |
} |