]> git.pld-linux.org Git - packages/virt-what.git/blob - virt-what.spec
17d2a7a65cccd4c547c774ec42eece0650b11dfc
[packages/virt-what.git] / virt-what.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # build without tests
4
5 Summary:        Detect if we are running in a virtual machine
6 Name:           virt-what
7 Version:        1.13
8 Release:        1
9 License:        GPL v2+
10 Group:          Applications/Emulators
11 Source0:        http://people.redhat.com/~rjones/virt-what/files/%{name}-%{version}.tar.gz
12 # Source0-md5:  28d3be1d8981e7fd83c012ebf0d95bb1
13 Patch0:         bashisms.patch
14 URL:            http://people.redhat.com/~rjones/virt-what/
15 # This is provided by the build root, but we make it explicit
16 # anyway in case this was dropped from the build root in future.
17 BuildRequires:  /usr/bin/pod2man
18 %if %{with tests}
19 # Required at build time in order to do 'make check' (for getopt).
20 BuildRequires:  util-linux
21 %endif
22 # virt-what script uses dmidecode and getopt (from util-linux).
23 # RPM cannot detect this so make the dependencies explicit here.
24 %ifarch %{ix86} %{x8664}
25 Requires:       dmidecode
26 %endif
27 Requires:       util-linux
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 %description
31 virt-what is a shell script which can be used to detect if the program
32 is running in a virtual machine.
33
34 The program prints out a list of "facts" about the virtual machine,
35 derived from heuristics. One fact is printed per line.
36
37 If nothing is printed and the script exits with code 0 (no error),
38 then it can mean either that the program is running on bare-metal or
39 the program is running inside a type of virtual machine which we don't
40 know about or can't detect.
41
42 Current types of virtualization detected:
43  - hyperv Microsoft Hyper-V
44  - kvm Linux Kernel Virtual Machine (KVM)
45  - openvz OpenVZ or Virtuozzo
46  - powervm_lx86 IBM PowerVM Lx86 Linux/x86 emulator
47  - qemu QEMU (unaccelerated)
48  - uml User-Mode Linux (UML)
49  - virtage Hitachi Virtualization Manager (HVM) Virtage LPAR
50  - virtualbox VirtualBox
51  - virtualpc Microsoft VirtualPC
52  - vmware VMware
53  - xen Xen
54  - xen-dom0 Xen dom0 (privileged domain)
55  - xen-domU Xen domU (paravirtualized guest domain)
56  - xen-hvm Xen guest fully virtualized (HVM)
57
58 %prep
59 %setup -q
60 %patch0 -p1
61
62 %build
63 %configure
64 %{__make}
65
66 %if %{with tests}
67 %{__make} check
68 %endif
69
70 %install
71 rm -rf $RPM_BUILD_ROOT
72 %{__make} install \
73         DESTDIR=$RPM_BUILD_ROOT
74
75 %clean
76 rm -rf $RPM_BUILD_ROOT
77
78 %files
79 %defattr(644,root,root,755)
80 %doc README COPYING
81 %attr(755,root,root) %{_sbindir}/virt-what
82 %attr(755,root,root) %{_libdir}/virt-what-cpuid-helper
83 %{_mandir}/man1/virt-what.1*
This page took 0.08898 seconds and 2 git commands to generate.