OSDN Git Service

44f2cb2b989336e611693948b2c58ae31ef1cab7
[linuxjm/LDP_man-pages.git] / draft / man3 / gnu_get_libc_version.3
1 .\" Copyright (c) 2008, Linux Foundation, written by Michael Kerrisk
2 .\"     <mtk.manpages@gmail.com>
3 .\"
4 .\" Permission is granted to make and distribute verbatim copies of this
5 .\" manual provided the copyright notice and this permission notice are
6 .\" preserved on all copies.
7 .\"
8 .\" Permission is granted to copy and distribute modified versions of this
9 .\" manual under the conditions for verbatim copying, provided that the
10 .\" entire resulting derived work is distributed under the terms of a
11 .\" permission notice identical to this one.
12 .\"
13 .\" Since the Linux kernel and libraries are constantly changing, this
14 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
15 .\" responsibility for errors or omissions, or for damages resulting from
16 .\" the use of the information contained herein.  The author(s) may not
17 .\" have taken the same level of care in the production of this manual,
18 .\" which is licensed free of charge, as they might when working
19 .\" professionally.
20 .\"
21 .\" Formatted or processed versions of this manual, if unaccompanied by
22 .\" the source, must acknowledge the copyright and authors of this work.
23 .\"
24 .\" Japanese Version Copyright (c) 2008  Akihiro MOTOKI
25 .\"         all rights reserved.
26 .\" Translated 2008-08-21, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v3.04
27 .\" 
28 .TH GNU_GET_LIBC_VERSION 3 2010-09-10 "Linux" "Linux Programmer's Manual"
29 .\"O .SH NAME
30 .SH 名前
31 .\"O gnu_get_libc_version, gnu_get_libc_release \- get glibc version and release
32 gnu_get_libc_version, gnu_get_libc_release \- glibc のバージョンと
33 リリース状態を取得する
34 .\"O .SH SYNOPSIS
35 .SH 書式
36 .nf
37 .\"O .BR "#define _GNU_SOURCE" "             /* See feature_test_macros(7) */"
38 .BR "#define _GNU_SOURCE" "             /* feature_test_macros(7) 参照 */"
39 .B #include <gnu/libc-version.h>
40
41 .B const char *gnu_get_libc_version(void);
42 .B const char *gnu_get_libc_release(void);
43 .fi
44 .\"O .SH DESCRIPTION
45 .SH 説明
46 .\"O The function
47 .\"O .BR gnu_get_libc_version ()
48 .\"O returns a string that identifies the glibc version available on the system.
49 .BR gnu_get_libc_version ()
50 関数は、システムで利用可能な glibc のバージョンを特定する文字列を返す。
51
52 .\"O The function
53 .\"O .BR gnu_get_libc_release ()
54 .\"O returns a string indicates the release status of the glibc version
55 .\"O available on the system.
56 .\"O This will be a string such as
57 .\"O .IR "stable" .
58 .BR gnu_get_libc_release ()
59 関数は、システムで利用可能な glibc バージョンのリリース状態を示す
60 文字列を返す。
61 .I "stable"
62 といった文字列が返される。
63 .\"O .SH VERSIONS
64 .SH バージョン
65 .\"O These functions first appeared in glibc in version 2.1.
66 これらの関数は glibc バージョン 2.1 で初めて登場した。
67 .\"O .SH CONFORMING TO
68 .SH 準拠
69 .\"O These functions are glibc-specific.
70 これらの関数は glibc 固有である。
71 .\"O .SH EXAMPLE
72 .SH 例
73 .\"O When run, the program below will produce output such as the following:
74 下記のプログラムを実行すると、次のような出力が得られる。
75 .in +4n
76 .nf
77
78 .RB "$" " ./a.out"
79 GNU libc version: 2.8
80 GNU libc release: stable
81 .fi
82 .in
83 .\"O .SS Program source
84 .SS プログラムのソース
85 \&
86 .nf
87 #include <gnu/libc-version.h>
88 #include <stdlib.h>
89 #include <stdio.h>
90
91 int
92 main(int argc, char *argv[])
93 {
94     printf("GNU libc version: %s\\n", gnu_get_libc_version());
95     printf("GNU libc release: %s\\n", gnu_get_libc_release());
96     exit(EXIT_SUCCESS);
97 }
98 .fi
99 .\"O .SH SEE ALSO
100 .SH 関連項目
101 .BR confstr (3)