OSDN Git Service

Fix no pic
[uclinux-h8/uClinux-dist.git] / user / gnugk / version.cxx
1 //////////////////////////////////////////////////////////////////
2 //
3 // PURPOSE OF THIS FILE: Give version info
4 //
5 // Copyright (C) 2003 Nils.Bokermann@mediaways.net
6 //
7 // This work is published under the GNU Public License (GPL)
8 // see file COPYING for details.
9 // We also explicitely grant the right to link this code
10 // with the OpenH323 library.
11 //
12 //////////////////////////////////////////////////////////////////
13
14 #if defined(_WIN32) && (_MSC_VER <= 1200)
15 #pragma warning(disable:4284)
16 #endif
17
18 #include <ptlib.h>
19 #include <ptlib/sockets.h>
20 #include "versionts.h"
21 #include "version.h"
22 #include "Toolkit.h"
23
24 const PString Toolkit::GKVersion()
25 {
26         return PString(PString::Printf,
27                        "Gatekeeper(%s) Version(%s) Ext(pthreads=%d,radius=%d,mysql=%d,pgsql=%d,firebird=%d,large_fdset=%d,crypto/ssl=%d)"
28                        " Build(%s, %s) Sys(%s %s %s)\r\n",
29                        (const unsigned char*)(PProcess::Current().GetManufacturer()),
30                        (const unsigned char*)(PProcess::Current().GetVersion(true)),
31 #ifdef P_PTHREADS
32                                 (int)1,
33 #else
34                                 (int)0,
35 #endif
36 #if HAS_RADIUS
37                                 (int)1,
38 #else
39                                 (int)0,
40 #endif
41 #if HAS_MYSQL
42                                 (int)1,
43 #else
44                                 (int)0,
45 #endif
46 #if HAS_PGSQL
47                                 (int)1,
48 #else
49                                 (int)0,
50 #endif
51 #if HAS_FIREBIRD
52                                 (int)1,
53 #else
54                                 (int)0,
55 #endif
56 #ifdef LARGE_FDSET
57                                 (int)LARGE_FDSET,
58 #else
59                                 (int)0,
60 #endif
61 #if P_SSL
62                                 (int)1,
63 #else
64                                 (int)0,
65 #endif
66                        __DATE__, __TIME__,
67                        (const unsigned char*)(PProcess::GetOSName()),
68                        (const unsigned char*)(PProcess::GetOSHardware()),
69                        (const unsigned char*)(PProcess::GetOSVersion())
70                 );
71 }