[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Programmatic manner to determine version?

Buchan Milne wrote:
On 7/20/07, Tony Earnshaw <tonni@hetnet.nl> wrote:
Mark Lavi skrev, on 20-07-2007 01:42:


Is this the only way?
Well, "slapd -V 2>&1 | head -n1 | awk -F " " '{ print $4 }'" works for
me. Or isn't this what you meant?

Use something like: slapd -VV 2>&1|head -n1|awk '{print $4}'

Unless you want a stray slapd running ... (which you may get with  just -V).

ldapsearch -VV 2>&1|head -n1|awk '{print $5}'

Headers you have, but for libraries ... I'd use my package management
system (e.g. 'rpm -qf --qf "%{VERSION}\n"
/usr/lib64/libldap-2.3.so.0'). You shouldn't have any software
installed except by your package management system :-P.

All of this is basic system administration, nothing specific to OpenLDAP Software.

re: shared library version numbers, read the libtool documentation for the explanation of the version numbering scheme.
-- Howard Chu
Chief Architect, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/