Slightly late to the party but please have a look at how open-vm-tools
(VMware) works. Some observations:
(1) Anaconda has a special comps group for hypervisors. If Anaconda
is able to detect virtualization, it will install extra packages from
the hypervisor group automatically. For VMware it's called
‘platform-vmware’.
https://github.com/rhinstaller/anaconda/commit/a475dd0194df7abf0453786fc0...
https://pagure.io/fedora-comps/blob/master/f/comps-f27.xml.in#_4987
(2) In addition to the above, open-vm-tools is protected by
ConditionVirtualization=vmware. Despite the other comment in this
thread, this works fine and no udev rule is required.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch
http://libguestfs.org/virt-builder.1.html