1lgrp_version(3LGRP)    Locality Group Library Functions    lgrp_version(3LGRP)
2
3
4

NAME

6       lgrp_version - coordinate library and application versions
7

SYNOPSIS

9       cc [ flag ... ] file... -llgrp [ library ... ]
10       #include <sys/lgrp_user.h>
11
12       int lgrp_version(const int version);
13
14

DESCRIPTION

16       The lgrp_version() function takes an interface version number, version,
17       as an argument and returns an lgroup interface  version.   The  version
18       argument  should be the value of LGRP_VER_CURRENT bound to the applica‐
19       tion when it was compiled or LGRP_VER_NONE  to  find  out  the  current
20       lgroup interface version on the running system.
21

RETURN VALUES

23       If  version  is  still  supported by the implementation, then lgrp_ver‐
24       sion() returns the requested version. If LGRP_VER_NONE is returned, the
25       implementation  cannot  support  the requested version. The application
26       should be recompiled and might require further changes.
27
28
29       If version is LGRP_VER_NONE, lgrp_version() returns the current version
30       of the library.
31

EXAMPLES

33       Example  1 Test whether the version of the interface used by the caller
34       is supported.
35
36
37       The following example tests whether the version of the  interface  used
38       by the caller is supported:
39
40
41         #include <sys/lgrp_user.h>
42
43         if (lgrp_version(LGRP_VER_CURRENT) != LGRP_VER_CURRENT) {
44             fprintf(stderr, "Built with unsupported lgroup interface %d\n",
45                 LGRP_VER_CURRENT);
46             exit (1);
47         }
48
49

ATTRIBUTES

51       See attributes(5) for descriptions of the following attributes:
52
53
54
55
56       ┌─────────────────────────────┬─────────────────────────────┐
57       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
58       ├─────────────────────────────┼─────────────────────────────┤
59       │Interface Stability          │Evolving                     │
60       ├─────────────────────────────┼─────────────────────────────┤
61       │MT-Level                     │MT-Safe                      │
62       └─────────────────────────────┴─────────────────────────────┘
63

SEE ALSO

65       lgrp_init(3LGRP), liblgrp(3LIB), attributes(5)
66
67
68
69SunOS 5.11                        16 Apr 2003              lgrp_version(3LGRP)
Impressum