Re: [PATCH] show compiled in options in virsh --version

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/28/2010 07:13 AM, Daniel P. Berrange wrote:
> On Thu, Oct 28, 2010 at 03:00:45PM +0200, Daniel Veillard wrote:
>>   To ease debugging this trivial patch allows to find what was compiled
>> in in the local version of libvirt, this doesn't work for remote access
>> but that's probably sufficient. With the patch I get on my machine:
>>
>> paphio:~/libvirt/tools -> ./virsh --version
>> Virsh command line tool of libvirt 0.8.4
>> See web site at http://libvirt.org/
>>
>> Compiled with support for:
>>  Hypervisors: Xen QEmu/KVM UML OpenVZ LXC ESX PHYP Test 
>>  Networking: Remote Daemon Network Bridging Netcf Nwfilter 
>>  Storage: Dir Disk Filesystem SCSI Multipath iSCSI LVM 
>>  Miscellaneous: SELinux Secrets Debug Readline 
>> paphio:~/libvirt/tools -> 
>>
>>  instead of just "0.8.4"
> 
> Hmm, if any script is running the current 'virsh --version' command
> to get the version number then this will break their usage. I think
> we should require a different and/or extra flag to print the
> extended data. --version is not a great place since this isn't
> really version information.
> 

We already have:

$ virsh version
Compiled against library: libvir 0.8.2
Using library: libvir 0.8.2
Using API: QEMU 0.8.2
Running hypervisor: QEMU 0.12.5

Can we just beef that up, and leave 'virsh --version' as the short
information?


> Apache uses  -v for plain version number, and -V for version number
> plus build options/info

Those are fine for short options; and for long options, ./configure
already has the precedence of taking an optional argument.  So maybe we
could do:

--version[=style], where style is short or long, defaults to short
-v => --version=short
-V => --version=long => 'virsh version'

-- 
Eric Blake   eblake@xxxxxxxxxx    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]